2

LaTeX hyperref パッケージは、いくつかの点で私を混乱させます。これが私の特定の問題です。

私のドキュメントでは、コマンド

\footnote{
\url{http://www.boston.com/news/science/articles/2010/04/25/new_atlas_shows_the_state_of_nature_as_well_as_the_nature_of_states/}
}

正常に動作します - pdflatex は有効なリンクのみを生成します。

しかし、コマンド

\newcommand{\webref}[1]{\footnote{\url{#1}}}

\webref{http://www.boston.com/news/science/articles/2010/04/25/new_atlas_shows_the_state_of_nature_as_well_as_the_nature_of_states/
}

リンクを生成します

file:///C|/eb/qrbook/%20http://www.boston.com/news/science/articles/2010/04/25/new_atlas_shows_the_state_of_nature_as_well_as_the_nature_of_states/

余分な「file://...」がどこから来たのか、それを取り除く方法を教えてもらえますか?

4

1 に答える 1

1

勝手な推測: どこにも余分なスペースを導入していないのですか? 直前に改行を入れると挙動が再現でき#1ます。%(上級者向けのヒント:複数行コマンドの最後の文字の直後にa を置くと、 LaTeX は改行を処理しません。)

于 2011-08-24T21:31:42.050 に答える