ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* relative scaling for fonts
@ 2006-11-12 21:17 Pablo Rodríguez
  2006-11-13 20:06 ` Henning Hraban Ramm
  2006-11-14 11:15 ` Hans Hagen
  0 siblings, 2 replies; 11+ messages in thread
From: Pablo Rodríguez @ 2006-11-12 21:17 UTC (permalink / raw)


Hi there,

I'm using XeTeX one of the features that I miss at most from XeLaTeX
(from fontspec), is the possibility to set automatically the scaling of
fonts so that they match the lowercase or uppercase letters of the roman
font. I wonder whether there is something similar for ConTeXt.

By the way, the ConTeXt uses in my view, the wrong XeTeX way to set the
interlinear space, since it seems that \XeTeXuseglyphmetrics is set to
0. Probably I should be missing something, but if \XeTeXuseglyphmetrics
is not set to 1, ConTeXt will set the interlinear space not by itself,
but following the glyph metrics and in some fonts the font height. I
guess it would be better to use \XeTeXuseglyphmetrics=1.

Best,


Pablo

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: relative scaling for fonts
  2006-11-12 21:17 relative scaling for fonts Pablo Rodríguez
@ 2006-11-13 20:06 ` Henning Hraban Ramm
  2006-11-13 23:38   ` Pablo Rodríguez
  2006-11-14 11:15 ` Hans Hagen
  1 sibling, 1 reply; 11+ messages in thread
From: Henning Hraban Ramm @ 2006-11-13 20:06 UTC (permalink / raw)


Am 2006-11-12 um 22:17 schrieb Pablo Rodríguez:

> I'm using XeTeX one of the features that I miss at most from XeLaTeX
> (from fontspec), is the possibility to set automatically the  
> scaling of
> fonts so that they match the lowercase or uppercase letters of the  
> roman
> font. I wonder whether there is something similar for ConTeXt.

I never tried XeTeX, but the relative scaling of fonts is setup in  
typescripts, e.g.

\starttypescript [postscript] [texnansi,ec,8r]

\definetypeface [postscript] [rm] [serif] [times]     [default]  
[encoding=\typescripttwo]
\definetypeface [postscript] [mm] [math]  [times]     [default]
\definetypeface [postscript] [ss] [sans]  [helvetica] [default]  
[rscale=.9,encoding=\typescripttwo]
\definetypeface [postscript] [tt] [mono]  [courier]   [default]  
[rscale=1.1,encoding=\typescripttwo]

\stoptypescript



Greetlings from Lake Constance!
Hraban
---
http://www.fiee.net/texnique/
http://contextgarden.net
http://www.cacert.org (I'm an assurer)

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: relative scaling for fonts
  2006-11-13 20:06 ` Henning Hraban Ramm
@ 2006-11-13 23:38   ` Pablo Rodríguez
  0 siblings, 0 replies; 11+ messages in thread
From: Pablo Rodríguez @ 2006-11-13 23:38 UTC (permalink / raw)


Henning Hraban Ramm wrote:
> Am 2006-11-12 um 22:17 schrieb Pablo Rodríguez:
> 
>> I'm using XeTeX one of the features that I miss at most from XeLaTeX
>> (from fontspec), is the possibility to set automatically the  
>> scaling of
>> fonts so that they match the lowercase or uppercase letters of the  
>> roman
>> font. I wonder whether there is something similar for ConTeXt.
> 
> I never tried XeTeX, but the relative scaling of fonts is setup in  
> typescripts, e.g.

Sorry, I'm a ConTeXt newbie and I'm not sure whether I have expressed
myself in an accurate manner or I don't understand what you mean.

In XeTeX you can set your fonts in these way:

\definetypeface[myfont][rm][Xserif][Junicode]
\definetypeface[myfont][tt][Xmono][Epigrafica][][rscale=1]
\setupbodyfont[myfont,13pt]

But the problem there is that one should know which is the value of
rscale is. If \lowercase and \uppercase variables were defined, it would
be possible that ConTeXt calculates by itself which is the required
scaling factor to match the roman font (lowercase or uppercase,
respectively). This is explained (for LaTeX I'm afraid) at page 45
(section 8.7.3) of the fontspec documentation
(http://www.ctan.org/tex-archive/macros/xetex/latex/fontspec/fontspec.pdf).

In this way, it would be possible to autoscale to the rm font all fonts
used in a document.

I hope it is clear now,


Pablo

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: relative scaling for fonts
  2006-11-12 21:17 relative scaling for fonts Pablo Rodríguez
  2006-11-13 20:06 ` Henning Hraban Ramm
@ 2006-11-14 11:15 ` Hans Hagen
  2006-11-14 19:34   ` Pablo Rodríguez
  2006-11-15 13:53   ` Pablo Rodríguez
  1 sibling, 2 replies; 11+ messages in thread
From: Hans Hagen @ 2006-11-14 11:15 UTC (permalink / raw)


� wrote:
> Hi there,
>
> I'm using XeTeX one of the features that I miss at most from XeLaTeX
> (from fontspec), is the possibility to set automatically the scaling of
> fonts so that they match the lowercase or uppercase letters of the roman
> font. I wonder whether there is something similar for ConTeXt.
>   
as already answered in other mails this is possible with the rscale 
option in typefaces (is completely unrelated to xetex and has been part 
of the regular context font mechanisms for quite some time)

You can use

\showfontstrip
\showminimalbaseline

and alike

relative scaling is not automatic (trivial to implement) simply because 
it's a visual thing; having similar x-heights is not always the best
> By the way, the ConTeXt uses in my view, the wrong XeTeX way to set the
> interlinear space, since it seems that \XeTeXuseglyphmetrics is set to
> 0. Probably I should be missing something, but if \XeTeXuseglyphmetrics
> is not set to 1, ConTeXt will set the interlinear space not by itself,
> but following the glyph metrics and in some fonts the font height. I
> guess it would be better to use \XeTeXuseglyphmetrics=1.
>   
o must admit that i don't keep track of such things; since interline 
space as well as struct height/depth rations are document properties (a 
document can use many different fonts) deriving one automatically cq. 
adapting it automatically based on font properties can be dangerous

does this mean that when

\XeTeXuseglyphmetrics=0 (default) 

xetex will mess around with the interlinespace? that would be a bad default behaviour


Hans

-----------------------------------------------------------------
                                          Hans Hagen | PRAGMA ADE
              Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                             | www.pragma-pod.nl
-----------------------------------------------------------------

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: relative scaling for fonts
  2006-11-14 11:15 ` Hans Hagen
@ 2006-11-14 19:34   ` Pablo Rodríguez
  2006-11-15  9:39     ` Hans Hagen
  2006-11-15 13:53   ` Pablo Rodríguez
  1 sibling, 1 reply; 11+ messages in thread
From: Pablo Rodríguez @ 2006-11-14 19:34 UTC (permalink / raw)


Hans Hagen wrote:
> does this mean that when
> 
> \XeTeXuseglyphmetrics=0 (default) 
> 
> xetex will mess around with the interlinespace? that would be a bad default behaviour

In XeTeX (and XeLaTeX) the default value is one.

I guess XeConTeXt should have \XeTeXuseglyphmetrics=1 by default.



Pablo

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: relative scaling for fonts
  2006-11-14 19:34   ` Pablo Rodríguez
@ 2006-11-15  9:39     ` Hans Hagen
  0 siblings, 0 replies; 11+ messages in thread
From: Hans Hagen @ 2006-11-15  9:39 UTC (permalink / raw)


Pablo Rodríguez wrote:
> Hans Hagen wrote:
>   
>> does this mean that when
>>
>> \XeTeXuseglyphmetrics=0 (default) 
>>
>> xetex will mess around with the interlinespace? that would be a bad default behaviour
>>     
>
> In XeTeX (and XeLaTeX) the default value is one.
>
> I guess XeConTeXt should have \XeTeXuseglyphmetrics=1 by default.
>
>   
only i if know exactly what it does and if it does not interfere with any other spacing (i.e. when it is traditional tex compatible) 

Hans 

-----------------------------------------------------------------
                                          Hans Hagen | PRAGMA ADE
              Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                             | www.pragma-pod.nl
-----------------------------------------------------------------

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: relative scaling for fonts
  2006-11-14 11:15 ` Hans Hagen
  2006-11-14 19:34   ` Pablo Rodríguez
@ 2006-11-15 13:53   ` Pablo Rodríguez
  2006-11-15 14:12     ` Hans Hagen
  1 sibling, 1 reply; 11+ messages in thread
From: Pablo Rodríguez @ 2006-11-15 13:53 UTC (permalink / raw)


Hans Hagen wrote:
> � wrote:
>> Hi there,
>>
>> Using XeTeX, one of the features that I miss at most from XeLaTeX
>> (from fontspec), is the possibility to set automatically the scaling of
>> fonts so that they match the lowercase or uppercase letters of the roman
>> font. I wonder whether there is something similar for ConTeXt.
>>   
> as already answered in other mails this is possible with the rscale 
> option in typefaces (is completely unrelated to xetex and has been part 
> of the regular context font mechanisms for quite some time)
> 
> You can use
> 
> \showfontstrip
> \showminimalbaseline
> 
> and alike
> 
> relative scaling is not automatic (trivial to implement) simply because 
> it's a visual thing; having similar x-heights is not always the best

Thanks for your explanation, Hans.

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.

Thanks,


Pablo
_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: relative scaling for fonts
  2006-11-15 13:53   ` Pablo Rodríguez
@ 2006-11-15 14:12     ` Hans Hagen
  2006-11-16  8:56       ` Pablo Rodríguez
  0 siblings, 1 reply; 11+ messages in thread
From: Hans Hagen @ 2006-11-15 14:12 UTC (permalink / raw)


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 

Hans 


-----------------------------------------------------------------
                                          Hans Hagen | PRAGMA ADE
              Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                             | www.pragma-pod.nl
-----------------------------------------------------------------

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: relative scaling for fonts
  2006-11-15 14:12     ` Hans Hagen
@ 2006-11-16  8:56       ` Pablo Rodríguez
  2006-11-16  9:05         ` Thomas A. Schmitz
  2006-11-16 10:54         ` Hans Hagen
  0 siblings, 2 replies; 11+ messages in thread
From: Pablo Rodríguez @ 2006-11-16  8:56 UTC (permalink / raw)


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.

Thanks,


Pablo
_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: relative scaling for fonts
  2006-11-16  8:56       ` Pablo Rodríguez
@ 2006-11-16  9:05         ` Thomas A. Schmitz
  2006-11-16 10:54         ` Hans Hagen
  1 sibling, 0 replies; 11+ messages in thread
From: Thomas A. Schmitz @ 2006-11-16  9:05 UTC (permalink / raw)



On Nov 16, 2006, at 9:56 AM, Pablo Rodríguez wrote:

> 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.

But will that work? What is the x-height of a Unicode font (and  
AFAIK, XeTeX can't handle any other font) that has Latin and Greek  
letters? You have to rely on the fact that the font designer will  
have implemented an equal x-height for all his characters - which is  
simply not the case for a majority of fonts, IMHO. So I'm not sure  
that this is a necessary or useful thing to have. When all is said  
and done, I still see no possibility other than looking at the  
printed page and deciding yourself whether the relation between both  
fonts is "right." Btw, most publishers don't seem to bother anymore  
and just set the fonts at whatever is their design size. OUP, e.g.,  
uses Porson, which is a lot smaller than most Roman fonts, but they  
don't scale. I find this horrible, but what I want to say is: there  
doesn't seem to be an established typographical practice that could  
just be automated.

Best

Thomas

^ permalink raw reply	[flat|nested] 11+ messages in thread

* Re: relative scaling for fonts
  2006-11-16  8:56       ` Pablo Rodríguez
  2006-11-16  9:05         ` Thomas A. Schmitz
@ 2006-11-16 10:54         ` Hans Hagen
  1 sibling, 0 replies; 11+ messages in thread
From: Hans Hagen @ 2006-11-16 10:54 UTC (permalink / raw)


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.

Adam Lindsay made/had plans for predefined typefaces and actually that 
is then the best way to go: predefine interesting combinations of fonts 
with optimized values for relative scaling and ht/dp ratios.

Hans

-----------------------------------------------------------------
                                          Hans Hagen | PRAGMA ADE
              Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
     tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                             | www.pragma-pod.nl
-----------------------------------------------------------------

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2006-11-16 10:54 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-11-12 21:17 relative scaling for fonts Pablo Rodríguez
2006-11-13 20:06 ` Henning Hraban Ramm
2006-11-13 23:38   ` Pablo Rodríguez
2006-11-14 11:15 ` Hans Hagen
2006-11-14 19:34   ` Pablo Rodríguez
2006-11-15  9:39     ` Hans Hagen
2006-11-15 13:53   ` Pablo Rodríguez
2006-11-15 14:12     ` Hans Hagen
2006-11-16  8:56       ` Pablo Rodríguez
2006-11-16  9:05         ` Thomas A. Schmitz
2006-11-16 10:54         ` Hans Hagen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).