Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
如何为列表定义字体?
我想要行号上的一种字体(Sans 6pt)和代码上的另一种字体(Monospace(8pt)。
您可以使用以下命令定义行号的样式:
\lstdefinestyle{numbers}{numberstyle=\tiny}
可以使用以下方式定义代码外观:
\lstset{basicstyle=\small}
您可以用您自己的样式规格替换\tiny和。\small
\tiny
\small
查看清单或fancyvrb包。