How do I adjust the height of the underline?

I need to underline all \nd text. The default underline, however, is a bit too low. The PTXprint Technical Reference lists:

\UnderlineLower 0.1em — Distance below base line of underline rule

But what do I do with this? How do I use it to make the underline on all \nd text a bit higher?

Hi @EricP,

The Advanced tab has these settings available as tweakable parameters:

Play with those until you get the underline looking just right.

Great, except I think the tooltip is wrong. -0.10 is too low, but changing it to -0.25 raised it higher where I wanted to see it.

The description is wrong. The value is not related to the baseline, but the bottom of any descenders actually present, (tails of g, p etc)with the presumption that (since we haven’t any way of skipping them) crossing out bits of letters is bad, and underlining just below the bottom of the lowest descent in a given string is a better idea.

If you set a negative value, beware that at present it will cross out the body of the text if there is no descenders.

If there’s a demand for baseline relative underline, that will eventually be signaled by a negative value.

How does this look for the improved tooltip?

This sets the vertical position
(in ems) of the underline relative
to the bottom of any descenders. 
Negative values raise it.
Positive values lower it.

Further testing has shown that the intended functioning was getting confused by switching off XeTeXuseglyphmetrics. I’m considering this a bug, and unfortunately people are probably used to it, since XeTeXuseglyphmetrics was normally turned off by the python code. In fixing that, I’ve also fixed the partly implemented negative value = absolute position.

Intended default value:\def\UnderlineLower{0.2em}

Old, buggy behaviour \def\UnderlineLower{0.2em}

New absolute position: \def\UnderlineLower{-0.2em)

Set to zero:

Set to -0.1:

My suggestion for a tooltip:

This sets how far (in ems) underline is below the text
and what it is relative to. If positive or zero, it is the distance
below the bottom of any descenders. If negative,
it is the distance below the baseline. There is (now) no way
to use underlining to cross out text.