答案1
如果我理解你的目的正确的话,你不仅需要修复第 5 行,还需要修复第 6 行。如果这是正确的,我建议你替换
\renewcommand\theparagraph{\thesubsubsection.\AlphAlph{\value{paragraph}}}
\renewcommand\thesubparagraph{\theparagraph.\AlphAlph{\value{subparagraph}}}
和
\renewcommand\theparagraph{\thesubsubsection.%
\AlphAlph{\value{paragraph}}}
\renewcommand\thesubparagraph{\theparagraph.%
\AlphAlph{\value{subparagraph}}}
我相信您知道,%
“百分号”字符是 TeX 的默认注释字符。如果将其放在输入行中最后一个“正常”字符之后(如建议的修复中的情况),TeX 不会“看到”嵌入的 EOL 字符,而是继续读取下一行的内容(同时忽略续行开头可能存在的任何空格字符)。因此,就 TeX 而言,执行上述指令的两种方式没有区别\renewcommand
。
\documentclass{article}
\usepackage{alphalph} % is there a package called 'AlphAlph' ?
\setcounter{secnumdepth}{5}
\renewcommand\theparagraph{\thesubsubsection.%
\AlphAlph{\value{paragraph}}}
\renewcommand\thesubparagraph{\theparagraph.%
\AlphAlph{\value{subparagraph}}}
\begin{document}
\section{Once}
\subsection{upon}
\subsubsection{a time,}
\addtocounter{paragraph}{26} % just for this example
\paragraph{there was}
\addtocounter{subparagraph}{288}
\subparagraph{a beautiful frog.}
\end{document}