Am 29.11.25 um 16:37 schrieb Hans Hagen via ntg-context:
On 11/29/2025 4:26 PM, Henning Hraban Ramm wrote:

BTW, why does the following work without \the? Is this not a dimension?

"""
\setwidthof{ABCDE}\to\Width
{ABCDE} is \Width\ wide.
"""

because it is defined as

\permanent\protected\def\setwidthof#1\to#2{\edef#2{\widthofstring{#1}}}

actually a mkii-ish macro so one can as wel l use

\scratchdimen\widthofstring{abc}

Ah, thank you!


if you doubt if something is a dimen, use \todimension

\dimensiondef\WhatIsThis\widthofstring{abc}

\todimension\scratchdimen

\todimension10pt

\todimension{10pt + ex + \WhatIsThis}

\toscaled{10pt + ex + \WhatIsThis}

etc etc

The influx of new commands never ends …

Hraban
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : [email protected] / 
https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage  : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive  : https://github.com/contextgarden/context
wiki     : https://wiki.contextgarden.net
___________________________________________________________________________________

Reply via email to