Hi, I'm experiencing issues with rscale. When using: \starttypescript [MyFnt] \definetypeface [MyFnt] [rm] [serif] [rfont] [default] [encoding=ec] \definetypeface [MyFnt] [mm] [math] [mfont] [default] [rscale=0.99,encoding=default] \definetypeface [MyFnt] [tt] [mono] [tfont] [default] [rscale=0.1,encoding=texnansi] \stoptypescript everything works as expected (text font is indeed rfont, math font is indeed mfont, tt font is indeed tfont, and moreover the math font is correctly rscaled) but the tt font isn't rscaled at all. Any idea where the issue might come from? Thanks, Olivier
Olivier said this at Wed, 31 Aug 2005 16:53:56 +0200:
moreover the math font is correctly rscaled) but the tt font isn't rscaled at all. Any idea where the issue might come from?
I suspect it's in your local specifics. As we don't have access to your rfont/mfont/tfont typescripts, here's a similar example that works here: \definetypeface [MyFnt] [rm] [serif] [palatino] [default] [encoding=ec] \definetypeface [MyFnt] [mm] [math] [palatino] [default] [rscale=0.9,encoding=default] \definetypeface [MyFnt] [tt] [mono] [courier] [default] [rscale=0.5,encoding=ec] \setupbodyfont [MyFnt] \starttext something $a+b$ here {\tt teeny text} \stoptext So, barring further analysis of your typescripts, rscale seems to work here... -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Adam T. Lindsay, Computing Dept. atl@comp.lancs.ac.uk Lancaster University, InfoLab21 +44(0)1524/510.514 Lancaster, LA1 4WA, UK Fax:+44(0)1524/510.492 -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Quoting "Adam Lindsay" :
-- was atl@comp.lancs.ac.uk on Aug 31, 2005 at 04:44:35PM --
Olivier said this at Wed, 31 Aug 2005 16:53:56 +0200:
moreover the math font is correctly rscaled) but the tt font isn't rscaled at all. Any idea where the issue might come from?
I suspect it's in your local specifics. As we don't have access to your rfont/mfont/tfont typescripts,
\starttypescript [mono] [my-officina] [texnansi] \definefontsynonym [MY-Officina][texnansi-LIGA-KERN-OfficinaSerifStd-Book] [encoding=texnansi] \stoptypescript \starttypescript [mono] [my-officina] [name] \definefontsynonym [Mono] [MY-Officina] \definefontsynonym [MonoBold] [Mono] \definefontsynonym [MonoItalic] [Mono] \definefontsynonym [MonoSlanted] [Mono] \definefontsynonym [MonoBoldItalic] [Mono] \definefontsynonym [MonoBoldSlanted] [Mono] \definefontsynonym [MonoCaps] [Mono] \stoptypescript \starttypescript [MyFnt] \definetypeface [MyFnt] [rm] [serif] [rfont] [default][encoding=ec] \definetypeface [MyFnt] [mm] [math] [euler] [default][rscale=0.99,encoding=default] \definetypeface [MyFnt] [tt] [mono] [my-officina] [default][rscale=3,encoding=texnansi] \stoptypescript I used texfont to generate the fonts tfm, map file and vf via texfont --fo=. --ma --in --ve=linotype --co=officina --lcdf --pre --va=liga,kern It's ok since I get the correct font, just it isn't rscaled. THe mechanism seems to work well here however since the euler font is correctly rscaled. The information is all I put in the typescript for the tt font. Thanks, Olivier
Olivier said this at Wed, 31 Aug 2005 18:03:57 +0200:
Quoting "Adam Lindsay" :
-- was atl@comp.lancs.ac.uk on Aug 31, 2005 at 04:44:35PM --
Olivier said this at Wed, 31 Aug 2005 16:53:56 +0200:
moreover the math font is correctly rscaled) but the tt font isn't rscaled at all. Any idea where the issue might come from?
I suspect it's in your local specifics. As we don't have access to your rfont/mfont/tfont typescripts,
\starttypescript [mono] [my-officina] [texnansi] \definefontsynonym [MY-Officina][texnansi-LIGA-KERN-OfficinaSerifStd-Book] [encoding=texnansi] \stoptypescript
Well, in testing, I used the locally-defined pcrr8t in the place of the file you cite, but your example works for me. I tested (just in case) if it was something to do with the OTF conversion (highly unlikely), but the following lines added to your typescripts (calling a locally-installed font) did what was expected: \loadmapfile[texnansi-LIGA-KERN-adobe-myriad] \starttypescript [sans] [myriad] [texnansi] \definefontsynonym [myriadreg] [texnansi-LIGA-KERN-MyriadPro-SemiCn] [encoding=texnansi] \stoptypescript \starttypescript [sans] [myriad] [name] \setups[font:fallback:sans] \definefontsynonym [Sans] [myriadreg] \stoptypescript \definetypeface [MyFnt] [ss] [sans] [myriad] [default][rscale=0.6,encoding=texnansi]
It's ok since I get the correct font, just it isn't rscaled. THe mechanism seems to work well here however since the euler font is correctly rscaled.
The information is all I put in the typescript for the tt font.
All I can ask now is: ConTeXt version? How do you call the font in your text/for testing? -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Adam T. Lindsay, Computing Dept. atl@comp.lancs.ac.uk Lancaster University, InfoLab21 +44(0)1524/510.514 Lancaster, LA1 4WA, UK Fax:+44(0)1524/510.492 -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
I got the guilty lines: \definebodyfont[13pt] \definebodyfont[11.6pt] \definebodyfont[8.3pt] \definebodyfont[8.2pt] \definebodyfont[6pt] \definebodyfont[5.8pt] \setupbodyfontenvironment[11.6pt] [text=11.6pt, script=8.3pt, scriptscript=5.8pt, x=8.2pt, xx=5.8pt, big=13pt, small=6pt] at the very end of the typescript file. Sorry for not having strip down to the minimal buggy file before posting... So how to setup such relative font sizes for a specific family say \rm and then rscale the other one (mm, tt, ss) so that the x-heights match? Do I have to put such sizes inside the typescripts of all families? Thanks Olivier
Actually, those lines
\definebodyfont[13pt] \definebodyfont[11.6pt] \definebodyfont[8.3pt] \definebodyfont[8.2pt] \definebodyfont[6pt] \definebodyfont[5.8pt] \setupbodyfontenvironment[11.6pt] [text=11.6pt, script=8.3pt, scriptscript=5.8pt, x=8.2pt, xx=5.8pt, big=13pt, small=6pt]
originated from the following issue: When using euler fonts with a text serif font let's call it myrm, myrm has a bigger x-height than euler's. So I used
\definetypeface [MyFnt] [mm] [math] [euler] [default] [rscale=0.99,encoding=default] which did the trick perfectly well.
But then, say we would like to typeset something like
$n^{n\log{n}}$
Of course, you would expect the x-height of the two fonts in the exponent to be in the same ratio as well... but this is not the case! Hence the need to tweak the bodyfont sizes as shown above. Is this a bug, or something I didn't get? Thanks, Olivier
Olivier said this at Wed, 31 Aug 2005 22:07:42 +0200:
\definetypeface [MyFnt] [mm] [math] [euler] [default] [rscale=0.99,encoding=default] which did the trick perfectly well.
Ideally, you should be using the euler size typescript as well: \definetypeface [MyFnt] [mm] [math] [euler] [euler] [rscale=1] ^^^^^
But then, say we would like to typeset something like
$n^{n\log{n}}$
Of course, you would expect the x-height of the two fonts in the exponent to be in the same ratio as well... but this is not the case!
You must be using a different setting still. "log" is typeset in euler, still, with the default settings. I can't stress the importance enough of really doing minimal test case documents for debugging, especially when asking the list. I know I've found bugs in my code before posting many times that way! -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= Adam T. Lindsay, Computing Dept. atl@comp.lancs.ac.uk Lancaster University, InfoLab21 +44(0)1524/510.514 Lancaster, LA1 4WA, UK Fax:+44(0)1524/510.492 -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Quoting "Adam Lindsay" :
-- was atl@comp.lancs.ac.uk on Aug 31, 2005 at 11:29:56PM --
"log" is typeset in euler, still, with the default settings.
You're perfectly right. However, I use to typeset maths functions in the text font, this is why I'm trying to replace euler a way or another. Maths functions are typeset in the concrete maths book for instance (see p 107 or p 111 if you have one) with rm being concrete.
You must be using a different setting still.
So you're right; This one shows why log isn't typeset in euler but with the serif one \def\mfunction#1% {\mathchoice {\hbox{\rm \tf #1}} {\hbox{\rm \tf #1}} {\hbox{\rm \tfx #1}} {\hbox{\rm \tfxx #1}}} This was my way of getting around the above mentioned issue. It also shows why maths functions and pure maths doesn't match anymore in scriptsize. And this is why I tried to tweak the bodyfontenvironment sizes... Now, if you get the picture and know the simple trick I missed at the very first begining... Anyway, many thanks for your answers, Olivier
Olivier wrote:
Quoting "Adam Lindsay" :
-- was atl@comp.lancs.ac.uk on Aug 31, 2005 at 11:29:56PM --
"log" is typeset in euler, still, with the default settings.
You're perfectly right. However, I use to typeset maths functions in the text font, this is why I'm trying to replace euler a way or another.
Maths functions are typeset in the concrete maths book for instance (see p 107 or p 111 if you have one) with rm being concrete.
You must be using a different setting still.
So you're right; This one shows why log isn't typeset in euler but with the serif one
\def\mfunction#1% {\mathchoice {\hbox{\rm \tf #1}} {\hbox{\rm \tf #1}} {\hbox{\rm \tfx #1}} {\hbox{\rm \tfxx #1}}}
This was my way of getting around the above mentioned issue.
It also shows why maths functions and pure maths doesn't match anymore in scriptsize. And this is why I tried to tweak the bodyfontenvironment sizes... Now, if you get the picture and know the simple trick I missed at the very first begining...
there is an additional math scaling option built into context: copied from font-ini: %D \macros %D {mapfontsize} %D %D For special purposes, like in math, you may want to use %D slightly different sizes than the ones given. This happens %D for instance with the Math Times fonts. Mapped font sizes %D can be specified by using the \type {mo} key instead of %D \type {sa} in font definitions. %D %D \startbuffer %D \mapfontsize[10pt][11pt] %D \mapfontsize[11pt][12pt] %D \mapfontsize[12pt][13pt] %D %D \definefont[test][Serif]\test TEST \par %D \definefont[test][Serif sa 5]\test TEST \par %D \definefont[test][Serif mo 5]\test TEST \par %D \definefont[test][Serif sa d]\test TEST \par %D \definefont[test][Serif at 60pt]\test TEST \par %D \definefont[test][Serif scaled 6000]\test TEST \par %D \stopbuffer %D %D \typebuffer %D %D \startpacked %D \getbuffer %D \stoppacked ----------------------------------------------------------------- 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 -----------------------------------------------------------------
Olivier wrote:
Hi,
I'm experiencing issues with rscale. When using:
\starttypescript [MyFnt] \definetypeface [MyFnt] [rm] [serif] [rfont] [default] [encoding=ec] \definetypeface [MyFnt] [mm] [math] [mfont] [default] [rscale=0.99,encoding=default] \definetypeface [MyFnt] [tt] [mono] [tfont] [default] [rscale=0.1,encoding=texnansi] \stoptypescript
everything works as expected (text font is indeed rfont, math font is indeed mfont, tt font is indeed tfont, and moreover the math font is correctly rscaled) but the tt font isn't rscaled at all. Any idea where the issue might come from?
how about trying .55 or so? .1 is pretty small 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 -----------------------------------------------------------------
Quoting "Hans Hagen" :
-- was pragma@wxs.nl on Aug 31, 2005 at 05:53:45PM --
Olivier wrote:
Hi,
I'm experiencing issues with rscale. When using:
\starttypescript [MyFnt] \definetypeface [MyFnt] [rm] [serif] [rfont] [default] [encoding=ec] \definetypeface [MyFnt] [mm] [math] [mfont] [default] [rscale=0.99,encoding=default] \definetypeface [MyFnt] [tt] [mono] [tfont] [default] [rscale=0.1,encoding=texnansi] \stoptypescript
everything works as expected (text font is indeed rfont, math font is indeed mfont, tt font is indeed tfont, and moreover the math font is correctly rscaled) but the tt font isn't rscaled at all. Any idea where the issue might come from?
how about trying .55 or so? .1 is pretty small all right, I used .98 first, then .5 and now .1 just in case :)
Olivier
participants (3)
-
Adam Lindsay
-
Hans Hagen
-
Olivier