显示/重定义内部宏
Posted
tags:
篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了显示/重定义内部宏相关的知识,希望对你有一定的参考价值。
These four LaTeX control sequences are workalikes of the built-ins show, showthe and def and of a command sequence call. Unlike the usual variants, they work on internal macros which contain characters with the "wrong" category code, such as "@". They take the name of the command sequence (without the leading "") as their argument.The scrollmode is not necessary, it just saves you pressing Return for every listing output. The obeyspaces is needed only if you want to display or manipulate control sequences whose names contain spaces.
Gratuitous use of don and/or defn will probably break LaTeX.
scrollmode obeyspaces defshowthen#1{expandaftershowthecsnamestring#1endcsname} defdon#1{csnamestring#1endcsname} % example usage: % show listing of [email protected] shown{@startsection} % show the value of the skip @tempskipa showthen{@tempskipa} % execute control sequence "\ " don{ } % redefine @startsection (works like def) defn{@startsection}{ elax} % use at your own risk. user forfeits all rights to data integrity, mental health, world order, cookies.
以上是关于显示/重定义内部宏的主要内容,如果未能解决你的问题,请参考以下文章