
私は論文で algorithm2e パッケージを使用していますが、何らかの理由で TexStudio は algorithm2e.sty からメッセージや行番号のない 2 つの警告を報告しています。
これらの警告がどこから発生しているかを確認するためにタブを有効にするとIssues and Log
、ログ ファイルの次の出力内のアスタリスクを含む行を指しているようです。
********************************************************
Package `algorithm2e' Release 5.0 -- january 06 2013 --
- [email protected] mailing list for announcement about releases
- [email protected] mailing list for discussion about package
subscribe by emailing [email protected] with 'subscribe <list> <firstname name>'
- Author: Christophe Fiorio ([email protected])
********************************************************
どこかに実際の警告があるのかどうか、あるいは単に TexStudio がこれらを誤解しているだけなのかはわかりません。
これらの警告は実際にはどこか別の場所から来ているのでしょうか? それとも、これは単に TexStudio が誤解しているだけなのでしょうか?
答え1
このメッセージは、次の行が原因ですalgorithm2e.sty
:
1214 %%%%%%%%%%%%%%%%%%%%%%%%%%%%% Main Part %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
1215 %
1216 \newcommand{\algocf@name}{algorithm2e}%
1217 \newcommand{\algocf@date}{january 06 2013}%
1218 \newcommand{\algocf@version}{Release 5.0}%
1219 \newcommand{\algocf@id}{\algocf@version\space -- \algocf@date\space --}%
1220 \typeout{********************************************************^^JPackage `\algocf@name'\space\algocf@id^^J%
1221 - [email protected] mailing list for announcement about releases^^J%
1222 - [email protected] mailing list for discussion about package^^J%
1223 subscribe by emailing [email protected] with 'subscribe <list> <firstname name>'^^J%
1224 - Author: Christophe Fiorio ([email protected])^^J********************************************************}%
残念ながら、パッケージコードを変更したり、次のような厄介なトリックを実行したりせずにメッセージを削除することは不可能です。
\let\latextypeout\typeout\def\typeout#1{}
\usepackage{algorithm2e}
\let\typeout\latextypeout
お勧めしません。
代わりにコードでは以下を使用する必要があります\PackageInfo
:
\PackageInfo{algorithm2e}{%
********************************************************\MessageBreak
Package `\algocf@name'\space\algocf@id\MessageBreak
- [email protected] mailing list for announcement about releases\MessageBreak
- [email protected] mailing list for discussion about package\MessageBreak
subscribe by emailing [email protected] with 'subscribe <list> <firstname name>'\MessageBreak
- Author: Christophe Fiorio ([email protected])\MessageBreak
********************************************************%
}
これにより、情報はターミナル出力ではなくログ ファイルにのみ書き込まれるため、TeXStudio のパーサーが混乱するようです。