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
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)
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
� 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 -----------------------------------------------------------------
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
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 -----------------------------------------------------------------
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
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 -----------------------------------------------------------------
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
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
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 -----------------------------------------------------------------
participants (4)
-
Hans Hagen
-
Henning Hraban Ramm
-
Pablo Rodríguez
-
Thomas A. Schmitz