Finding the meaning of a command
Posted on June 16, 2020
ConTeXt has a nice command to find a meaning of a command. Sometimes the easiest way to find the meaning of a macro is to simply use
\show\macroname
In LMTX, context
defaults to running with --batchmode
, which means that
you then have to hunt for the output of \show
in the console output.
ConTeXt comes with a nice script to simply get the meaning of a macro on console.
$ mtxrun --script interface --meaning <macroname>
For example:
$ mtxrun --script interface --meaning dotfill
meaning > dotfill
protected macro:->\cleaders \hbox {\normalstartimath \mathsurround \zeropoint \mkern 1.5mu.\mkern 1.5mu\normalstopimath }\hfill
Behind the scenes this runs
mtxrun --silent --script context --extra=meaning --once --noconsole --nostatistics <macroname>
A side effect of this is that a file context-extra.pdf
is generated in the
current directory. I usually run this command in /tmp
. so I don’t mind the
extra file.
This entry was posted in CLI and tagged \show.