我正在尝试使用breakurl
包来打破长 URL,因此它会绕行,因为它会弄乱我的表格的对齐方式。问题是我不断收到消息
Package breakurl Warning: You are using breakurl while processing via pdflatex.
(breakurl) \burl will be just a synonym of \url.
(breakurl) on input line 48.
即使文件是用 lualatex 编译的。我按照显示的答案如何打破项目中的长 URL我之前从未使用过这个包,所以我可能做错了什么,但到目前为止我还没有发现。
这是 MWE
\documentclass[11pt]{article}%
\usepackage[utf8]{inputenc}
\usepackage{hyperref}
\usepackage[hyphenbreaks]{breakurl}
\begin{document}
\burl{http://www.google.com}%same error with \url
\end{document}
现在
lualatex foo.tex
This is LuaTeX, Version beta-0.80.0 (TeX Live 2015) (rev 5238)
(/usr/local/texlive/2015/texmf-dist/tex/latex/url/url.sty))
Package hyperref Message: Driver (autodetected): hpdftex.
(/usr/local/texlive/2015/texmf-dist/tex/latex/hyperref/hpdftex.def
....
(/usr/local/texlive/2015/texmf-dist/tex/latex/breakurl/breakurl.sty
(/usr/local/texlive/2015/texmf-dist/tex/latex/xkeyval/xkeyval.sty
(/usr/local/texlive/2015/texmf-dist/tex/generic/xkeyval/xkeyval.tex
(/usr/local/texlive/2015/texmf-dist/tex/generic/xkeyval/xkvutils.tex)))
Package breakurl Warning: You are using breakurl while processing via pdflatex.
(breakurl) \burl will be just a synonym of \url.
(breakurl) on input line 48.
我的问题是,为什么命令是 lualatex,却显示使用 pdflatex?我需要做什么才能消除这个错误?
这是文件列表
*File List*
article.cls 2014/09/29 v1.4h Standard LaTeX document class
size11.clo 2014/09/29 v1.4h Standard LaTeX file (size option)
fontenc.sty
t1enc.def 2005/09/27 v1.99g Standard LaTeX file
hyperref.sty 2012/11/06 v6.83m Hypertext links for LaTeX
hobsub-hyperref.sty 2012/05/28 v1.13 Bundle oberdiek, subset hyperref (HO)
hobsub-generic.sty 2012/05/28 v1.13 Bundle oberdiek, subset generic (HO)
hobsub.sty 2012/05/28 v1.13 Construct package bundles (HO)
infwarerr.sty 2010/04/08 v1.3 Providing info/warning/error messages (HO)
ltxcmds.sty 2011/11/09 v1.22 LaTeX kernel commands for general use (HO)
ifluatex.sty 2010/03/01 v1.3 Provides the ifluatex switch (HO)
ifvtex.sty 2010/03/01 v1.5 Detect VTeX and its facilities (HO)
intcalc.sty 2007/09/27 v1.1 Expandable calculations with integers (HO)
ifpdf.sty 2011/01/30 v2.3 Provides the ifpdf switch (HO)
etexcmds.sty 2011/02/16 v1.5 Avoid name clashes with e-TeX commands (HO)
kvsetkeys.sty 2012/04/25 v1.16 Key value parser (HO)
kvdefinekeys.sty 2011/04/07 v1.3 Define keys (HO)
luatex-loader.sty 2010/03/09 v0.4 Lua module loader (HO)
pdftexcmds.sty 2011/11/29 v0.20 Utility functions of pdfTeX for LuaTeX (HO)
pdfescape.sty 2011/11/25 v1.13 Implements pdfTeX's escape features (HO)
bigintcalc.sty 2012/04/08 v1.3 Expandable calculations on big integers (HO)
bitset.sty 2011/01/30 v1.1 Handle bit-vector datatype (HO)
uniquecounter.sty 2011/01/30 v1.2 Provide unlimited unique counter (HO)
letltxmacro.sty 2010/09/02 v1.4 Let assignment for LaTeX macros (HO)
hopatch.sty 2012/05/28 v1.2 Wrapper for package hooks (HO)
xcolor-patch.sty 2011/01/30 xcolor patch
atveryend.sty 2011/06/30 v1.8 Hooks at the very end of document (HO)
atbegshi.sty 2011/10/05 v1.16 At begin shipout hook (HO)
refcount.sty 2011/10/16 v3.4 Data extraction from label references (HO)
hycolor.sty 2011/01/30 v1.7 Color options for hyperref/bookmark (HO)
keyval.sty 2014/10/28 v1.15 key=value parser (DPC)
ifxetex.sty 2010/09/12 v0.6 Provides ifxetex conditional
auxhook.sty 2011/03/04 v1.3 Hooks for auxiliary files (HO)
kvoptions.sty 2011/06/30 v3.11 Key value format for package options (HO)
pd1enc.def 2012/11/06 v6.83m Hyperref: PDFDocEncoding definition (HO)
hyperref.cfg 2002/06/06 v1.2 hyperref configuration of TeXLive
url.sty 2013/09/16 ver 3.4 Verb mode for urls, etc.
hpdftex.def 2012/11/06 v6.83m Hyperref driver for pdfTeX
rerunfilecheck.sty 2011/04/15 v1.7 Rerun checks for auxiliary files (HO)
breakurl.sty 2013/04/10 v1.40 Breakable hyperref URLs
xkeyval.sty 2014/12/03 v2.7a package option processing (HA)
xkeyval.tex 2014/12/03 v2.7a key=value parser (HA)
nameref.sty 2012/10/27 v2.43 Cross-referencing by name of section
gettitlestring.sty 2010/12/03 v1.4 Cleanup title references (HO)
foo.out
foo.out
t1cmtt.fd 2014/09/29 v2.5h Standard LaTeX font definitions
***********
答案1
Luatex 0.80 与 pdflatex 兼容,因此对于大多数特定于驱动程序的功能使用相同的后端文件。正如您的日志所示:
(/usr/local/texlive/2015/texmf-dist/tex/latex/hyperref/hpdftex.def
使用pdftex hyperef文件。
为了避免出现警告,只需不要使用该包,对于 pdftex 或 luatex 来说,它是没有必要的,而且也没有什么用处。
对于 luatex,您还应该避免使用 inputenc 和 fontenc 包。