# [NTG-context] relative scaling for fonts

Hans Hagen pragma at wxs.nl
Thu Nov 16 11:54:50 CET 2006

```Pablo Rodríguez wrote:
> Hans Hagen wrote:
>
>> Pablo Rodríguez wrote:
>>
>>> After using \showfontstrip to get fonts with the same x-height by
>>> calculating the rscale factor, I guess it would be very useful (at least
>>> for me) to have an option that calculates relative scaling automatically
>>> to match both x-heights.
>>>
>>> I think it would be a useful option for rscale.
>>>
>>>
>> hm, it's not that hard to do, but then the question is: what is the reference font; also, my experience is that an automated scaling in most cases looks as ugly as no scaling; it's a visual thing; the xheight is a factor but the 'boldness' too
>>
>
> The reference font would be the roman font and the automated scaling
> with the same x-height might be wrong in some cases, but it is a useful
> starting point to start learning for newcomers (like me) how to set the
> proper visual scaling factor.
>
> My most common scenario for font scaling is not roman with sansserif or
> typewritter, but roman Latin with roman Greek characters and setting the
> same x-height for both. And I thought there were fine with the same
> x-height for both.
>
> My typographical ability wouldn't let my set other relative scaling
> factor other than 1 or the same x-height for both fonts.
>
>
Hm. Just typeset fontstrips, scale the doc up/down on the screen and
find the best visual match. You need to do that only once for a given
combination of fonts. In most cases i use lm for monospaced and palatino
for math when combined with other fonts, and my experience is that one
really need to typeset some text (with e.g. inline verbatim) in order to
find out what value is best.

The problem is that in that case, we would end up with 4 line
definitions replaced by 4 line definitions; ok, when we have luatex, we
can think of some aux macros (\rscaled{"fontname"}) because then fully
expandable solutions are possible.

is then the best way to go: predefine interesting combinations of fonts
with optimized values for relative scaling and ht/dp ratios.

Hans

-----------------------------------------------------------------