是否存在现有的 LaTeX 命令 \1、\2、\3 或 \4?

是否存在现有的 LaTeX 命令 \1、\2、\3 或 \4?

我想用名称创建新的命令\1 \2 \3 \4。但如果这些名称与现有的标准名称冲突,我就不想使用这些名称。我不知道有任何现有的 LaTeX 命令使用这些名称,但我想检查一下。

答案1

只需查找本地安装中的文件\[0-9]即可找到粗略的估计。latex/*/*.sty

例如

$ grep '[^`\\]\\[0-9]' /usr/local/texlive/2017/texmf-dist/tex/latex/*/*.sty | grep -v Digits

每个包只需保留一行并删除注释和用途,就会\string返回以下列表,其中一些将是内部用途,但每个都需要检查。

/arabtex/hebchrs.sty:\ifx #1\relax \relax \else \uppercase {\gdef \1{#1}}%
/bengali/beng.sty:\def\3#1z{{\char"#1}}
/bibarts/bibarts.sty:   \def\3{\string\3}%
/biblatex/biblatex.sty:  \do\0\do\1\do\2\do\3\do\4\do\5\do\6\do\7\do\8\do\9%
/cbcoptic/coptic.sty:\let\0\^^b0 % alias name for keyboards missing the "degree" key
/cmdtrack/cmdtrack.sty:\ifcat ?$\relax{\catcode37=7 \catcode127=9 \def\0{\@sanitize\catcode}\fi
/cryptocode/cryptocode.sty:      { \1\u{l_pc_strsub_replace_tl} }
/csquotes/csquotes.sty:  \do\!\do\?\do\0\do\1\do\2\do\3\do\4\do\5\do\6\do\7\do\8\do\9}
/cuisine/cuisine.sty:  \let\0\d@grees
/dialogl/grabhedr.sty:  \edef\0{\meaning\input}\edef\1{\string\input}%
/dialogl/menus.sty:  \begingroup \def\0{?}\def\1{Q}%
/dvdcoll/pdfnotiz.sty:    \edef\0{\string\0}%
/etextools/etextools.sty:   \long\edef\1##1/##2/##3{##1\endgroup\unexpanded{#2}##3}%
/fonttable/fonttable.sty: \f@tm=\f@tn \divide\f@tm by 64 \xdef\0{\the\f@tm}%
/gmdoc/gmdoc.sty:    \DoNotIndex{\1 \2 \3 \4 \5 \6 \7 \8 \9 \0}%
/hyperref/hyperref.sty:    \edef\1{\string\1}%
/longfigure/longfigure.sty:  \begingroup\def\2{#2}
/media9/media9.sty:    \regex_replace_once:nnN{([^:]+):??.*}{\1}\l_tmpa_tl
/mftinc/mftinc.sty:\long\def\mfcomment#1\9#2\par{\unskip#2 }
/mhchem/mhchem.sty:        { \c{\\}(\[.*?\])? } { \0 }
/nicetext/niceverb.sty:      \def\cs{\134}%                    %% 2010/03/17, 2011/06/27
/outlines/outlines.sty:%   \1 <level 1 text>
/pdfx/pdfx.sty: \edef\0{\string\0}
/pkgloader/pkgloader.sty:       \c{g__pkgloader_pkg_graph}\cB\{\0\.sty\cE\}) }
/prftree/prftree.sty:  \global\prf@samefalse\begingroup\def\1{#1}\def\2{#2}%
/proba/proba.sty:\DeclareRobustCommand{\1}[1]{\ensuremath \mathbf{1}_{\{#1\}}}
/protex/AlProTex.sty:   \def\1{#1}%
/qsymbols/qsymbols.sty:  \expandafter\let\expandafter\1\csname qsym@@#1\endcsname
/qtree/qtree.sty:  \def\0{\ifmmode ^0\else \rlap{$^0$}\fi}%
/regexpatch/regexpatch.sty:      \regex_replace_once:nnN { .*? \{ (.*) \} \Z } { \1 }
/snapshot/snapshot.sty:      \edef\0{\csname rqv@#1\endcsname}%
/songs/songs.sty:  \let\2\1\let\3\1\let\4\1\let\5\1%
/teubner/teubner.sty:\def\2#1 {\csname2#1\endcsname}
/tikz-qtree/tikz-qtree-compat.sty:  \def\0{\ifmmode ^0\else \rlap{$^0$}\fi}%
/toptesi/topfront.sty:        \ifx\2\empty
/toptesi/topfront.sty:            \noexpand\oldstylenums{\1} -- \noexpand\oldstylenums{\2}}
/uaclasses/my-title.sty:    {\def \1{#1}%
/uaclasses/ua-title.sty:    {\edef \3{#1}%
/ucs/ucshyper.sty:      \edef\1{\string\1}%
/units/units.sty:    \def\0{#1}%
/velthuis/dev209.sty:\def\0{\llap{\char13}}
/velthuis/devanagari.sty:\DeclareRobustCommand*\0{\llap{\char13}}%

相关内容