Re: [NTG-context] Probably simple: using a variable for \switchtobodyfont size

2023-05-19 Thread Hans van der Meer via ntg-context
\def\relationsFontSize{8pt}\starttextHello World!\crlf\switchtobodyfont[\relationsFontSize]Hello, world!\stoptext

Untitled.pdf
Description: Adobe PDF document
dr. Hans van der MeerOn 19 May 2023, at 11:43, Gerben Wierda via ntg-context  wrote:I want to use a variable for a font size so I can set it based on language (as some translated texts have widely different sizes)This fails:%===\newdimen\relationsFontSize\relationsFontSize=8pt\starttext\switchtobodyfont[\relationsFontSize]Hello, world!\stoptext%===How can I use a variable to steer \switchtobodyfont size?
Gerben Wierda (LinkedIn, Mastodon)R&A IT Strategy (main site)Book: Chess and the Art of Enterprise ArchitectureBook: Mastering ArchiMate


___If your question is of interest to others as well, please add an entry to the Wiki!maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-contextwebpage  : https://www.pragma-ade.nl / http://context.aanhet.netarchive  : https://bitbucket.org/phg/context-mirror/commits/wiki : https://contextgarden.net__
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] Probably simple: using a variable for \switchtobodyfont size

2023-05-19 Thread Wolfgang Schuster via ntg-context

Gerben Wierda via ntg-context schrieb am 19.05.2023 um 11:43:
I want to use a variable for a font size so I can set it based on 
language (as some translated texts have widely different sizes)


This fails:

%===
\newdimen\relationsFontSize
\relationsFontSize=8pt
\starttext
\switchtobodyfont[\relationsFontSize]
Hello, world!
\stoptext
%===

How can I use a variable to steer \switchtobodyfont size?


You need \the\, i.e.

\switchtobodyfont[\the\relationsFontSize]

but I would use the measure command, e.g.

\definemeasure[relationsFontSize][8pt]
\starttext
\switchtobodyfont[\measure{relationsFontSize}]
Hello, world!
\stoptext

Wolfgang

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


[NTG-context] Probably simple: using a variable for \switchtobodyfont size

2023-05-19 Thread Gerben Wierda via ntg-context
I want to use a variable for a font size so I can set it based on language (as 
some translated texts have widely different sizes)

This fails:

%===
\newdimen\relationsFontSize
\relationsFontSize=8pt
\starttext
\switchtobodyfont[\relationsFontSize]
Hello, world!
\stoptext
%===

How can I use a variable to steer \switchtobodyfont size?

Gerben Wierda (LinkedIn <https://www.linkedin.com/in/gerbenwierda>, Mastodon 
<https://newsie.social/@gctwnl>)
R&A IT Strategy <https://ea.rna.nl/> (main site)
Book: Chess and the Art of Enterprise Architecture <https://ea.rna.nl/the-book/>
Book: Mastering ArchiMate <https://ea.rna.nl/the-book-edition-iii/>

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / https://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : https://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : https://contextgarden.net
___


Re: [NTG-context] definedfont vs switchtobodyfont (was "shrink inter-line space")

2021-12-20 Thread Hans Hagen via ntg-context

On 12/20/2021 12:06 PM, mf via ntg-context wrote:

Il 18/12/21 13:00, Wolfgang Schuster ha scritto:

\definefontfeature [tightlines] [dimensions={*,0,0}]

\starttext

\samplefile{ward}\par

\blank

\start
 \setupinterlinespace[line=5pt]
 \definedfont[Normal*default,tightlines]
 \samplefile{ward}\par
\stop

\stoptext



Thanks Wolfgang.

I tried this:

\definefontfeature [tightlines] [dimensions={*,0,0}]

\starttext

\samplefile{ward}\par

\blank

\start
     \setupinterlinespace[line=5pt]
     \feature[+][tightlines]
     \samplefile{ward}\par
\stop

\stoptext

but it doesn't add the feature to the current font.
I understand I need a font switch.
Usually I use \switchtobodyfont. How is \definedfont different?
it's a 'permanent' one ... so when the font is loaded the dimensions are 
adapted so you need a new font definition


Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] definedfont vs switchtobodyfont (was "shrink inter-line space")

2021-12-20 Thread mf via ntg-context

Il 18/12/21 13:00, Wolfgang Schuster ha scritto:

\definefontfeature [tightlines] [dimensions={*,0,0}]

\starttext

\samplefile{ward}\par

\blank

\start
     \setupinterlinespace[line=5pt]
     \definedfont[Normal*default,tightlines]
     \samplefile{ward}\par
\stop

\stoptext



Thanks Wolfgang.

I tried this:

\definefontfeature [tightlines] [dimensions={*,0,0}]

\starttext

\samplefile{ward}\par

\blank

\start
\setupinterlinespace[line=5pt]
\feature[+][tightlines]
\samplefile{ward}\par
\stop

\stoptext

but it doesn't add the feature to the current font.
I understand I need a font switch.
Usually I use \switchtobodyfont. How is \definedfont different?

Massi
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont issue

2021-05-22 Thread Pablo Rodriguez
On 5/22/21 1:10 PM, Wolfgang Schuster wrote:
> [...]
> You can't use x and a with \switchtobodyfont, only small and big are
> possible.
>
> \starttext
> a
> \switchtobodyfont[small]
> a
> \switchtobodyfont[big]
> a
> \stoptext
Many thanks for your fast reply, Wolfgang.

This works fine with standard sizes:

  \starttext
  a
  \switchtobodyfont[x]
  a
  \stoptext

Many thanks for your help,

Pablo
--
http://www.ousia.tk
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont issue

2021-05-22 Thread Wolfgang Schuster

Pablo Rodriguez schrieb am 22.05.2021 um 12:51:

Dear list,

I have the following sample:

   \setupbodyfont[11.25pt]
   \starttext
   a
   \switchtobodyfont[x]
   a
   \switchtobodyfont[a]
   a
   \stoptext

How can I get both \switchtobodyfont working in both appearances?



You can't use x and a with \switchtobodyfont, only small and big are 
possible.


\starttext
a
\switchtobodyfont[small]
a
\switchtobodyfont[big]
a
\stoptext

Wolfgang
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


[NTG-context] \switchtobodyfont issue

2021-05-22 Thread Pablo Rodriguez
Dear list,

I have the following sample:

  \setupbodyfont[11.25pt]
  \starttext
  a
  \switchtobodyfont[x]
  a
  \switchtobodyfont[a]
  a
  \stoptext

How can I get both \switchtobodyfont working in both appearances?

Many thanks for your help,

Pablo
--
http://www.ousia.tk
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont behaves differenctly with splitted parameters

2020-11-08 Thread Sylvain Hubert
On Sun, 8 Nov 2020 at 12:52, Hans Hagen  wrote:

> On 11/8/2020 12:46 PM, Sylvain Hubert wrote:
> > On Sun, 8 Nov 2020 at 12:14, Hans Hagen  > <mailto:j.ha...@xs4all.nl>> wrote:
> >
> > when yyou use several bodyfonts you can do this before \starttext:
> >
> > \usebodyfont[face,24pt]
> > \usebodyfont[deface]
> >
> > \starttext
> > 
> > \stoptext
> >
> >
> > Thank you for the information, Hans!
> >
> > Could you please also shed some light on the relation/difference among
> > \{setup,switchto,use}bodyfont?
> > There seems to be not much documentation on this. Can one conclude, from
> > the wiki <https://wiki.contextgarden.net/Command/switchtobodyfont> and
> > the source code
> > <
> https://source.contextgarden.net/tex/context/base/mkiv/font-ini.mklx#l2287>,
>
> > that they are mostly the same, except that \switchtobodyfont is
> > restricted to the content area, and \usebodyfont is a helper to call
> > \setupbodyfont in the beginning?
> >
> > If this is the case, is it recommended to always put a
> > \setupbodyfont[...] in the beginning, even if it's just a
> > \setupbodyfont[modern]?
> > One reason might be that the following example somehow enlarges the page
> > number in the header, intuitively contradicting what is claimed by the
> > wiki <https://wiki.contextgarden.net/Command/switchtobodyfont>:
> >
> >  \switchtobodyfont[dejavu]
> >  \starttext \switchtobodyfont[dejavu, 24pt]a\stoptext
>
> \setup  is document wide
> \switch is for local usage
>

So \switchtobodyfont before \starttext is semantically an error then.
Thanks for the confirmation!


> (has to do with picking up font/space related issues after page breaks
> and when typesetting page ornaments like headers and footers)
>
>
>
> -
>Hans Hagen | PRAGMA ADE
>Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
> tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
> -
>

Sylvain
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont behaves differenctly with splitted parameters

2020-11-08 Thread Hans Hagen

On 11/8/2020 12:46 PM, Sylvain Hubert wrote:
On Sun, 8 Nov 2020 at 12:14, Hans Hagen <mailto:j.ha...@xs4all.nl>> wrote:


when yyou use several bodyfonts you can do this before \starttext:

\usebodyfont[face,24pt]
\usebodyfont[deface]

\starttext
    
\stoptext


Thank you for the information, Hans!

Could you please also shed some light on the relation/difference among 
\{setup,switchto,use}bodyfont?
There seems to be not much documentation on this. Can one conclude, from 
the wiki <https://wiki.contextgarden.net/Command/switchtobodyfont> and 
the source code 
<https://source.contextgarden.net/tex/context/base/mkiv/font-ini.mklx#l2287>, 
that they are mostly the same, except that \switchtobodyfont is 
restricted to the content area, and \usebodyfont is a helper to call 
\setupbodyfont in the beginning?


If this is the case, is it recommended to always put a 
\setupbodyfont[...] in the beginning, even if it's just a 
\setupbodyfont[modern]?
One reason might be that the following example somehow enlarges the page 
number in the header, intuitively contradicting what is claimed by the 
wiki <https://wiki.contextgarden.net/Command/switchtobodyfont>:


     \switchtobodyfont[dejavu]
     \starttext \switchtobodyfont[dejavu, 24pt]a\stoptext


\setup  is document wide
\switch is for local usage

(has to do with picking up font/space related issues after page breaks 
and when typesetting page ornaments like headers and footers)




-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont behaves differenctly with splitted parameters

2020-11-08 Thread Sylvain Hubert
On Sun, 8 Nov 2020 at 12:14, Hans Hagen  wrote:

> when yyou use several bodyfonts you can do this before \starttext:
>
> \usebodyfont[face,24pt]
> \usebodyfont[deface]
>
> \starttext
>
> \stoptext
>

Thank you for the information, Hans!

Could you please also shed some light on the relation/difference among
\{setup,switchto,use}bodyfont?
There seems to be not much documentation on this. Can one conclude, from the
wiki <https://wiki.contextgarden.net/Command/switchtobodyfont> and the source
code
<https://source.contextgarden.net/tex/context/base/mkiv/font-ini.mklx#l2287>,
that they are mostly the same, except that \switchtobodyfont is restricted
to the content area, and \usebodyfont is a helper to call \setupbodyfont in
the beginning?

If this is the case, is it recommended to always put a \setupbodyfont[...]
in the beginning, even if it's just a \setupbodyfont[modern]?
One reason might be that the following example somehow enlarges the page
number in the header, intuitively contradicting what is claimed by the wiki
<https://wiki.contextgarden.net/Command/switchtobodyfont>:

\switchtobodyfont[dejavu]
\starttext \switchtobodyfont[dejavu, 24pt]a\stoptext

Thanks!

Sylvain
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont behaves differenctly with splitted parameters

2020-11-08 Thread Hans Hagen

On 11/8/2020 12:02 PM, Sylvain Hubert wrote:
On Sun, 8 Nov 2020 at 11:37, Pablo Rodriguez <mailto:oi...@gmx.es>> wrote:


On 11/8/20 11:18 AM, Sylvain Hubert wrote:
 > Hi Pablo,
 >
 > thanks for the suggestion. Here's the minimal example which shows the
 > difference:
 >
 >     \definefontfamily[face][rm][dejavuserif]
 >     \starttext\switchtobodyfont[face, 24pt]ɑ\stoptext
 >
 > this should warn:
 >
 >     fonts           > checking > char ɑ (U+00251) in font
 > 'LatinModernMath-Regular-4' with id 10: missing

Well, you are switching before setting up a body font.

I don’t know whether this might be a bug in ConTeXt (see previous
report), but I would set up the body font always first:

     \definefontfamily[face][rm][dejavuserif]
     \definefontfamily[deface][rm][dejavusans]
     \setupbodyfont[deface]
     \starttext a\switchtobodyfont[face, 24pt]ɑ\stoptext


Thanks, it works!

And I agree that it probably indicates the existence of a bug, since by 
changing "\setupbodyfont[deface]" to "\setupbodyfont[dejavu]" in your 
example, the problem reappears:


     \definefontfamily[face][rm][dejavuserif]
     \setupbodyfont[dejavu]
     \starttext a\switchtobodyfont[face, 24pt]ɑ\stoptext

when yyou use several bodyfonts you can do this before \starttext:

\usebodyfont[face,24pt]
\usebodyfont[deface]

\starttext
  
\stoptext


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
   tel: 038 477 53 69 | www.pragma-ade.nl | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont behaves differenctly with splitted parameters

2020-11-08 Thread Wolfgang Schuster

Sylvain Hubert schrieb am 08.11.2020 um 12:02:
On Sun, 8 Nov 2020 at 11:37, Pablo Rodriguez <mailto:oi...@gmx.es>> wrote:


On 11/8/20 11:18 AM, Sylvain Hubert wrote:
 > Hi Pablo,
 >
 > thanks for the suggestion. Here's the minimal example which shows the
 > difference:
 >
 >     \definefontfamily[face][rm][dejavuserif]
 >     \starttext\switchtobodyfont[face, 24pt]ɑ\stoptext
 >
 > this should warn:
 >
 >     fonts           > checking > char ɑ (U+00251) in font
 > 'LatinModernMath-Regular-4' with id 10: missing

Well, you are switching before setting up a body font.

I don’t know whether this might be a bug in ConTeXt (see previous
report), but I would set up the body font always first:

     \definefontfamily[face][rm][dejavuserif]
     \definefontfamily[deface][rm][dejavusans]
     \setupbodyfont[deface]
     \starttext a\switchtobodyfont[face, 24pt]ɑ\stoptext


Thanks, it works!

And I agree that it probably indicates the existence of a bug, since by 
changing "\setupbodyfont[deface]" to "\setupbodyfont[dejavu]" in your 
example, the problem reappears:


     \definefontfamily[face][rm][dejavuserif]


Add here: \definebodyfont[24pt]

Wolfgang
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont behaves differenctly with splitted parameters

2020-11-08 Thread Sylvain Hubert
On Sun, 8 Nov 2020 at 11:37, Pablo Rodriguez  wrote:

> On 11/8/20 11:18 AM, Sylvain Hubert wrote:
> > Hi Pablo,
> >
> > thanks for the suggestion. Here's the minimal example which shows the
> > difference:
> >
> > \definefontfamily[face][rm][dejavuserif]
> > \starttext\switchtobodyfont[face, 24pt]ɑ\stoptext
> >
> > this should warn:
> >
> > fonts   > checking > char ɑ (U+00251) in font
> > 'LatinModernMath-Regular-4' with id 10: missing
>
> Well, you are switching before setting up a body font.
>
> I don’t know whether this might be a bug in ConTeXt (see previous
> report), but I would set up the body font always first:
>
> \definefontfamily[face][rm][dejavuserif]
> \definefontfamily[deface][rm][dejavusans]
> \setupbodyfont[deface]
> \starttext a\switchtobodyfont[face, 24pt]ɑ\stoptext
>

Thanks, it works!

And I agree that it probably indicates the existence of a bug, since by
changing "\setupbodyfont[deface]" to "\setupbodyfont[dejavu]" in your
example, the problem reappears:

\definefontfamily[face][rm][dejavuserif]
\setupbodyfont[dejavu]
\starttext a\switchtobodyfont[face, 24pt]ɑ\stoptext

Sylvain
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont behaves differenctly with splitted parameters

2020-11-08 Thread Pablo Rodriguez
On 11/8/20 11:18 AM, Sylvain Hubert wrote:
> Hi Pablo,
>
> thanks for the suggestion. Here's the minimal example which shows the
> difference:
>
>     \definefontfamily[face][rm][dejavuserif]
>     \starttext\switchtobodyfont[face, 24pt]ɑ\stoptext
>
> this should warn:
>
>     fonts           > checking > char ɑ (U+00251) in font
> 'LatinModernMath-Regular-4' with id 10: missing

Well, you are switching before setting up a body font.

I don’t know whether this might be a bug in ConTeXt (see previous
report), but I would set up the body font always first:

\definefontfamily[face][rm][dejavuserif]
\definefontfamily[deface][rm][dejavusans]
    \setupbodyfont[deface]
\starttext a\switchtobodyfont[face, 24pt]ɑ\stoptext

> while
>
>     \definefontfamily[face][rm][dejavuserif]
>     \starttext\switchtobodyfont[face, 24pt]ɑ\stoptext
>
> produces the expected result despite a harmless warning.

I guess the command reads:

\switchtobodyfont[face]ɑ

This might also be related to the issue just reported.

Pablo
--
http://www.ousia.tk
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont behaves differenctly with splitted parameters

2020-11-08 Thread Sylvain Hubert
On Sun, 8 Nov 2020 at 11:18, Sylvain Hubert  wrote:

> Hi Pablo,
>
> thanks for the suggestion. Here's the minimal example which shows the
> difference:
>
> \definefontfamily[face][rm][dejavuserif]
> \starttext\switchtobodyfont[face, 24pt]ɑ\stoptext
>
> this should warn:
>
> fonts   > checking > char ɑ (U+00251) in font
> 'LatinModernMath-Regular-4' with id 10: missing
>
> while
>
> \definefontfamily[face][rm][dejavuserif]
> \starttext\switchtobodyfont[face, 24pt]ɑ\stoptext
>

sorry, this should read

    \definefontfamily[face][rm][dejavuserif]
\starttext\switchtobodyfont[face]\switchtobodyfont[24pt]ɑ\stoptext



> produces the expected result despite a harmless warning.
>
> Sylvain
>
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont behaves differenctly with splitted parameters

2020-11-08 Thread Sylvain Hubert
Hi Pablo,

thanks for the suggestion. Here's the minimal example which shows the
difference:

\definefontfamily[face][rm][dejavuserif]
\starttext\switchtobodyfont[face, 24pt]ɑ\stoptext

this should warn:

fonts   > checking > char ɑ (U+00251) in font
'LatinModernMath-Regular-4' with id 10: missing

while

\definefontfamily[face][rm][dejavuserif]
\starttext\switchtobodyfont[face, 24pt]ɑ\stoptext

produces the expected result despite a harmless warning.

Sylvain

On Sun, 8 Nov 2020 at 10:41, Pablo Rodriguez  wrote:

> On 11/8/20 2:35 AM, Sylvain Hubert wrote:
> > Dear List,
> >
> > after hours of debugging, I finally found out that
> > \switchtobodyfont[face, 20pt] does NOT behave the same with
> > \switchtobodyfont[face]\switchtobodyfont[20pt]. In my case the latter is
> > the correct one, while the former does nothing but falling back to
> > latinmodern.
> >
> > Does anyone know when or why \switchtobodyfont behaves differently with
> > splitted and joined parameters?
>
> Hi Sylvain,
>
> as a general rule, it helps when there is a minimal sample that provides
> the problematic behavior.
>
> I don’t get diffferent results:
>
>   \definefontfamily[mainface][rm][TeX Gyre Pagella]
>   \definefontfamily[face][rm][TeX Gyre Heros]
>   \setupbodyfont[mainface]
>   \startbuffer
>   In my case, the latter is the correct one, while the former does
>   nothing but falling back to latinmodern.\par
>   \stopbuffer
>
>   \starttext
>   \getbuffer
>   \switchtobodyfont[face]\switchtobodyfont[20pt]
>   \getbuffer
>   \switchtobodyfont[face, 20pt]
>   \getbuffer
>   \stoptext
>
> Correct the sample to show what I got wrong from your message.
>
> Pablo
> --
> http://www.ousia.tk
>
> ___
> If your question is of interest to others as well, please add an entry to
> the Wiki!
>
> maillist : ntg-context@ntg.nl /
> http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
> archive  : https://bitbucket.org/phg/context-mirror/commits/
> wiki : http://contextgarden.net
>
> ___
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont behaves differenctly with splitted parameters

2020-11-08 Thread Pablo Rodriguez
On 11/8/20 2:35 AM, Sylvain Hubert wrote:
> Dear List,
>
> after hours of debugging, I finally found out that
> \switchtobodyfont[face, 20pt] does NOT behave the same with
> \switchtobodyfont[face]\switchtobodyfont[20pt]. In my case the latter is
> the correct one, while the former does nothing but falling back to
> latinmodern.
>
> Does anyone know when or why \switchtobodyfont behaves differently with
> splitted and joined parameters?

Hi Sylvain,

as a general rule, it helps when there is a minimal sample that provides
the problematic behavior.

I don’t get diffferent results:

  \definefontfamily[mainface][rm][TeX Gyre Pagella]
  \definefontfamily[face][rm][TeX Gyre Heros]
  \setupbodyfont[mainface]
  \startbuffer
  In my case, the latter is the correct one, while the former does
  nothing but falling back to latinmodern.\par
  \stopbuffer

  \starttext
  \getbuffer
  \switchtobodyfont[face]\switchtobodyfont[20pt]
  \getbuffer
  \switchtobodyfont[face, 20pt]
  \getbuffer
  \stoptext

Correct the sample to show what I got wrong from your message.

Pablo
--
http://www.ousia.tk
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


[NTG-context] \switchtobodyfont behaves differenctly with splitted parameters

2020-11-07 Thread Sylvain Hubert
Dear List,

after hours of debugging, I finally found out that \switchtobodyfont[face,
20pt] does NOT behave the same with
\switchtobodyfont[face]\switchtobodyfont[20pt]. In my case the latter is
the correct one, while the former does nothing but falling back to
latinmodern.

Does anyone know when or why \switchtobodyfont behaves differently with
splitted and joined parameters?

Thanks.

Best,
Sylvain
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___


Re: [NTG-context] switchtobodyfont and dejavu

2017-04-01 Thread Henning Hraban Ramm
Am 2017-03-31 um 09:00 schrieb Kostirya :

> Hello.
> I found error at switchtobodyfont with dejavu font.
> 
> In the below example, switchtobodyfont not correctly  worked.
> 
> This is only observed when I switch from 16pt to 14pt.
> Switching must be  across a different font.
> 
> 
> The result is attached to the letter
> 
> \setupbodyfont[dejavu,16pt]
> \starttext
> \showbodyfont \blank
> 
> \switchtobodyfont[gentium]
> 
> \switchtobodyfont[dejavu,14pt]
> \showbodyfont
> \stoptext

While this behaviour is confusing, I guess it’s because TeX prefers serif (rm) 
fonts. At first, there’s none defined. After you load gentium, there is one.

You should just specify that you want to get a sans bodyfont:

\switchtobodyfont[dejavu,ss,14pt]


Greetlings, Hraban
---
http://www.fiee.net
http://wiki.contextgarden.net
GPG Key ID 1C9B22FD

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] startstop, narrower and switchtobodyfont gives strange interlinespace

2017-03-22 Thread Andres Conrado
This works for me, is probably not what you want, but at leat it's
consistent (it uses the interline of the main text).

\definestartstop[passus][
before={\startnarrower},
after={\stopnarrower},
style={\tfxx},
]

\starttext

\subject{It looks OK here:}
\input knuth

\startnarrower
\tfxx \input knuth
\stopnarrower

\subject{It does also here:}

\input knuth

\startpassus
\input knuth
\stoppassus


\stoptext


Andrés Conrado Montoya
http://chiquitico.org
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] startstop, narrower and switchtobodyfont gives strange interlinespace

2017-03-22 Thread Alan Braslau
On Wed, 22 Mar 2017 20:38:01 +0100
"Mikael P. Sundqvist"  wrote:

> What am I doing wrong? Any ideas to solve it

Add a \par:

\input knuth\par

Alan
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] startstop, narrower and switchtobodyfont gives strange interlinespace

2017-03-22 Thread Mikael P. Sundqvist
On Wed, Mar 22, 2017 at 8:38 PM, Mikael P. Sundqvist  wrote:
> Hi,
>
> with the latest standalone, the file below runs, but gives strange
> results. Look at the interline space in the last paragraph (starting
> with "But a system...") of the document. It is too big. Resulting pdf
> is attached.
>
> What am I doing wrong? Any ideas to solve it (i.e. to be able to
> define an environment with narrower smaller text, including a reduced
> interlinespace)?
>
> /Mikael
>
> \definestartstop[passus][
> before={\startnarrower},
> after={\stopnarrower},
> style={\switchtobodyfont[9pt]},
> ]
>
> \starttext
>
> \subject{It looks OK here:}
> \input knuth
>
> \startnarrower
> \switchtobodyfont[9pt]
> \input knuth
> \stopnarrower
>
> \subject{It does not here:}
>
> \input knuth
>
> \startpassus
> \input knuth
> \stoppassus
>
>
> \stoptext

OK, I just realized that if I add a \par after the \input knuth the
last lines also look OK. Sorry for the noise.

/MIkael
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

[NTG-context] startstop, narrower and switchtobodyfont gives strange interlinespace

2017-03-22 Thread Mikael P. Sundqvist
Hi,

with the latest standalone, the file below runs, but gives strange
results. Look at the interline space in the last paragraph (starting
with "But a system...") of the document. It is too big. Resulting pdf
is attached.

What am I doing wrong? Any ideas to solve it (i.e. to be able to
define an environment with narrower smaller text, including a reduced
interlinespace)?

/Mikael

\definestartstop[passus][
before={\startnarrower},
after={\stopnarrower},
style={\switchtobodyfont[9pt]},
]

\starttext

\subject{It looks OK here:}
\input knuth

\startnarrower
\switchtobodyfont[9pt]
\input knuth
\stopnarrower

\subject{It does not here:}

\input knuth

\startpassus
\input knuth
\stoppassus


\stoptext


ctx-listexample26.pdf
Description: Adobe PDF document
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://context.aanhet.net
archive  : https://bitbucket.org/phg/context-mirror/commits/
wiki : http://contextgarden.net
___

Re: [NTG-context] \switchtobodyfont issue, also with newotf

2015-08-22 Thread Hans Hagen

On 8/21/2015 11:50 PM, Rik Kabel wrote:

On 2015-08-21 09:10, Hans Hagen wrote:

mostly changed names of the fonts, a missing directive (i'll add a
fallback for that) and such ... patched in the next beta


Hans,

This morning's release fixed the newotf module problem, but not the font
face problem. Was that to be expected?


The font switching mechanism is quite optimized (for performance) and 
makes some assumptions about namespaces. When you define a font, 
normally each call will check the definition i.e. be dynamic, but a 
bodyfont assumes a more frozen use.


Specially with in-document typescripts that can have side effects. In 
your case, just say


 \setupbodyfont [Secondary,10pt]

before the modern one, as it will then define Secondary in its own 
namespace and also not have a local/global mix side effects that comes 
from a first call to a bodyfont switch inside a group. Such a global 
initialization also has the effect of more efficient definitions of 
related bodyfont environments.


It's also good to add a math font definition:

\starttypescript[Secondary]
   \definetypeface[Secondary][rm][serif][ebgaramond][default]
   \definetypeface[Secondary][mm][math][modern][default]

as some symbols might come from math.

Hans

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] \switchtobodyfont issue, also with newotf

2015-08-21 Thread Rik Kabel

On 2015-08-21 09:10, Hans Hagen wrote:
mostly changed names of the fonts, a missing directive (i'll add a 
fallback for that) and such ... patched in the next beta



Hans,

This morning's release fixed the newotf module problem, but not the font 
face problem. Was that to be expected?


--
Rik
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] \switchtobodyfont issue, also with newotf

2015-08-21 Thread Hans Hagen

On 8/20/2015 8:34 PM, Rik Kabel wrote:

While working to get italic smallcaps in a secondary font face, I came
across an issue with \switchbodyfont. When this is used in a certain
way, the \tf font-style is changed, but not the \it, \bf, and so on.

The example below compiles cleanly as presented, and the problem is not
present. Each test line shows the expected font name and text.

When the Oops! line is uncommented, the only test line for the test font
that is correct is the \tf line. Other lines use the default font face
in the specified font styles, but the font features are a mix (note that
some are onum, some lining, and that long-s t ligatures are inconsistent).

When the newotf module is enabled, the example fails to compile without
errors, but produces similar results to non-newotf when the errors are
ignored.

This is not a problem with individual fonts—I have tried a variety of
fonts both as default and secondary and get the same result.

%\usemodule[newotf]
  \setupwhitespace[medium]
  \define\testAlphabet{\purefontname\font\quad
 ABCDEFGHIJKLmnopqrsſtuvwxyz \& 012345789}
  \starttypescript[Secondary]
\definetypeface[Secondary][rm][serif][ebgaramond][default]
% \definetypeface[Secondary][rm][serif][palatino][default]
% \definetypeface[Secondary][rm][serif][libertine][default]
  \stoptypescript
  \setupbodyfont [modern, 10pt]
%\setupbodyfont [palatino, 10pt]
  \starttext
% {\switchtobodyfont[Secondary]Oops!\par}%  Oops!
   Default tf: {\tf \testAlphabet}\par
   Default bf: {\bf \testAlphabet}\par
   Default it: {\it \testAlphabet}\par
   Default sl: {\sl \testAlphabet}\par
   Default bi: {\bi \testAlphabet}\par
   Default bs: {\bs \testAlphabet}\par
   Default sc: {\sc \testAlphabet}\par
   Default xx: {\it\setff{smallcaps}\testAlphabet}\par
   \switchtobodyfont[Secondary]
   Secondary tf: {\tf \testAlphabet}\par
   Secondary bf: {\bf \testAlphabet}\par
   Secondary it: {\it \testAlphabet}\par
   Secondary sl: {\sl \testAlphabet}\par
   Secondary bi: {\bi \testAlphabet}\par
   Secondary bs: {\bs \testAlphabet}\par
   Secondary sc: {\sc \testAlphabet}\par
   Secondary xx: {\it\setff{smallcaps}\testAlphabet}\par
\stoptext

Have I failed to properly specify the secondary typeface? Do I need a


mostly changed names of the fonts, a missing directive (i'll add a 
fallback for that) and such ... patched in the next beta


Hans


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

[NTG-context] \switchtobodyfont issue, also with newotf

2015-08-20 Thread Rik Kabel
While working to get italic smallcaps in a secondary font face, I came 
across an issue with \switchbodyfont. When this is used in a certain 
way, the \tf font-style is changed, but not the \it, \bf, and so on.


The example below compiles cleanly as presented, and the problem is not 
present. Each test line shows the expected font name and text.


When the Oops! line is uncommented, the only test line for the test font 
that is correct is the \tf line. Other lines use the default font face 
in the specified font styles, but the font features are a mix (note that 
some are onum, some lining, and that long-s t ligatures are inconsistent).


When the newotf module is enabled, the example fails to compile without 
errors, but produces similar results to non-newotf when the errors are 
ignored.


This is not a problem with individual fonts—I have tried a variety of 
fonts both as default and secondary and get the same result.


   %\usemodule[newotf]
 \setupwhitespace[medium]
 \define\testAlphabet{\purefontname\font\quad
ABCDEFGHIJKLmnopqrsſtuvwxyz \& 012345789}
 \starttypescript[Secondary]
   \definetypeface[Secondary][rm][serif][ebgaramond][default]
   % \definetypeface[Secondary][rm][serif][palatino][default]
   % \definetypeface[Secondary][rm][serif][libertine][default]
 \stoptypescript
 \setupbodyfont [modern, 10pt]
   %\setupbodyfont [palatino, 10pt]
 \starttext
   % {\switchtobodyfont[Secondary]Oops!\par}%  Oops!
  Default tf: {\tf \testAlphabet}\par
  Default bf: {\bf \testAlphabet}\par
  Default it: {\it \testAlphabet}\par
  Default sl: {\sl \testAlphabet}\par
  Default bi: {\bi \testAlphabet}\par
  Default bs: {\bs \testAlphabet}\par
  Default sc: {\sc \testAlphabet}\par
  Default xx: {\it\setff{smallcaps}\testAlphabet}\par
      \switchtobodyfont[Secondary]
  Secondary tf: {\tf \testAlphabet}\par
  Secondary bf: {\bf \testAlphabet}\par
  Secondary it: {\it \testAlphabet}\par
  Secondary sl: {\sl \testAlphabet}\par
  Secondary bi: {\bi \testAlphabet}\par
  Secondary bs: {\bs \testAlphabet}\par
  Secondary sc: {\sc \testAlphabet}\par
  Secondary xx: {\it\setff{smallcaps}\testAlphabet}\par
   \stoptext

Have I failed to properly specify the secondary typeface? Do I need a 
more complete typescript? Or is there a bug here?

--
Rik
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

[NTG-context] Making \setupinterlinespace work with \switchtobodyfont

2015-04-30 Thread Pavneet Arora
Thanks Pablo!

> Hi Paavnet,
>
> yes, you need a paragraph to make \setupinterlinespace work.

-- 

Pavneet Arora   m: 647.406.6843
Waroc Informatikt: 416.937.9276
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] Making \setupinterlinespace work with \switchtobodyfont

2015-04-30 Thread Pablo Rodriguez
On 04/30/2015 02:18 PM, Pavneet Arora wrote:
> Hello,
> 
> I am trying to have inter-line space change according to the current 
> size of the body font, which I modify with \switchtobodyfont, but I 
> cannot seem to affect the desired change as per the MWE below.  
> \setupinterlinespace seems to take its lead from the original 
> \setupbodyfont directive in the document, and does not revise it even 
> when font size is changed.
> 
> Is there a prescribed method to properly use \setupinterlinespace (or 
> for that matter \setupwhitespace when switching font sizes?

Hi Paavnet,

yes, you need a paragraph to make \setupinterlinespace work.

Your improved sample:

\setuppagenumbering[location=,state=stop]

\definefontfamily[mainface][rm][Pagella]
\definefontfamily[mainface][ss][Heros]
\definefontfamily[mainface][mm][Latin Modern Math]
\setupbodyfont[mainface,72pt]
\setupinterlinespace

\starttext
\startalignment[center]
The Title
\blank
{\switchtobodyfont[36pt]\setupinterlinespace%
Subtitle line 1\\
Subtitle line 2\par}
\blank
{\switchtobodyfont[18pt]\setupinterlinespace%
Sub-subtitle line 1\\
Sub-subtitle line 2\par}
\stopalignment
\stoptext

I hope it helps,


Pablo
-- 
http://www.ousia.tk
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

[NTG-context] Making \setupinterlinespace work with \switchtobodyfont

2015-04-30 Thread Pavneet Arora
Hello,

I am trying to have inter-line space change according to the current 
size of the body font, which I modify with \switchtobodyfont, but I 
cannot seem to affect the desired change as per the MWE below.  
\setupinterlinespace seems to take its lead from the original 
\setupbodyfont directive in the document, and does not revise it even 
when font size is changed.

Is there a prescribed method to properly use \setupinterlinespace (or 
for that matter \setupwhitespace when switching font sizes?

Many thanks.

>>>> MWE

\setuppagenumbering[location=,state=stop] 

\definefontfamily[mainface][rm][Pagella]
\definefontfamily[mainface][ss][Heros]
\definefontfamily[mainface][mm][Latin Modern Math]
\setupbodyfont[mainface,72pt]
\setupinterlinespace

\starttext
\startalignment[center]
The Title
\blank
{\switchtobodyfont[36pt]\setupinterlinespace%
Subtitle line 1\\
Subtitle line 2}
\blank
{\switchtobodyfont[18pt]\setupinterlinespace%
Sub-subtitle line 1\\
Sub-subtitle line 2}
\stopalignment
\stoptext

<<<<

-- 

Pavneet Arora   m: 647.406.6843
Waroc Informatikt: 416.937.9276
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] \switchtobodyfont fails to load font with some sizes

2014-02-28 Thread Joshua Krämer
On 2014-02-26, 22:57, Wolfgang Schuster wrote:

> Add \definebodyfontenvironment[50pt] before \starttext.

Thanks, that does the trick.

Kind regards, Joshua

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont fails to load font with some sizes

2014-02-26 Thread Wolfgang Schuster

Am 26.02.2014 um 18:10 schrieb Joshua Krämer :

> Dear list,
> 
> with some font sizes, \switchtobodyfont loads Latin Modern Roman
> instead of the specified typeface:
> 
> 
> \definefontfamily [firstfamily] [serif] [TeX Gyre Bonum]
> \definefontfamily [secondfamily] [serif] [TeX Gyre Termes]
> 
> \setupbodyfont [firstfamily, 60pt]
> 
> \starttext
> 
> abc {\switchtobodyfont [secondfamily, 60pt] abc} abc
> 
> abc {\switchtobodyfont [secondfamily, 50pt] abc} abc
> 
> \stoptext

Add \definebodyfontenvironment[50pt] before \starttext.

Wolfgang
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] \switchtobodyfont fails to load font with some sizes

2014-02-26 Thread Joshua Krämer
Dear list,

with some font sizes, \switchtobodyfont loads Latin Modern Roman
instead of the specified typeface:


\definefontfamily [firstfamily] [serif] [TeX Gyre Bonum]
\definefontfamily [secondfamily] [serif] [TeX Gyre Termes]

\setupbodyfont [firstfamily, 60pt]

\starttext

abc {\switchtobodyfont [secondfamily, 60pt] abc} abc

abc {\switchtobodyfont [secondfamily, 50pt] abc} abc

\stoptext


Kind regards,
Joshua Krämer


___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] extra line after switchtobodyfont

2013-05-07 Thread Hans Hagen

On 5/7/2013 10:11 PM, Hans Hagen wrote:

On 5/4/2013 6:59 PM, Wolfgang Schuster wrote:


Am 04.05.2013 um 09:21 schrieb Aditya Mahajan :


On 2013-05-03, at 7:36 PM, "Meer, H. van der" 
wrote:


Seems finally solved (sigh). I cleaned out all files loading
typescripts on the fly.
- typescript macros ending in ] at the end of a line have now ]% at
the end of the line
- empty lines have been removed for clarity
- all files now have \endinput at the end.

The files changed fit in a 54KB zip and I can send them if
Hans/Wolfgang/.. wants to incorporate them in the next beta.


I haven't followed this thread in detail, but an alternative is to
redefine \starttypescript etc. to use a different catcode regime so
that new lines and spaces are ignores (similar to
\starttexdefinition, etc)



A better method is to ignore the endlinechar when typescript files are
loaded.

\newcount\savedendlinechar

\starttext

Line 1\crlf
\savedendlinechar\endlinechar \endlinechar\minusone
\switchtobodyfont[pagella]
\endlinechar\savedendlinechar
Line 2

\stoptext


in fact, that should happen automatically but maybe i messed up something


(1) i adapted \loadfoundtypescriptfile (order of things, more robust)
(2) i adapted type-imp-pagella (had series of two defs per line which 
introduced the spaces)



-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-07 Thread Hans Hagen

On 5/4/2013 6:59 PM, Wolfgang Schuster wrote:


Am 04.05.2013 um 09:21 schrieb Aditya Mahajan :


On 2013-05-03, at 7:36 PM, "Meer, H. van der"  wrote:


Seems finally solved (sigh). I cleaned out all files loading typescripts on the 
fly.
- typescript macros ending in ] at the end of a line have now ]% at the end of 
the line
- empty lines have been removed for clarity
- all files now have \endinput at the end.

The files changed fit in a 54KB zip and I can send them if Hans/Wolfgang/.. 
wants to incorporate them in the next beta.


I haven't followed this thread in detail, but an alternative is to redefine 
\starttypescript etc. to use a different catcode regime so that new lines and 
spaces are ignores (similar to \starttexdefinition, etc)



A better method is to ignore the endlinechar when typescript files are loaded.

\newcount\savedendlinechar

\starttext

Line 1\crlf
\savedendlinechar\endlinechar \endlinechar\minusone
\switchtobodyfont[pagella]
\endlinechar\savedendlinechar
Line 2

\stoptext


in fact, that should happen automatically but maybe i messed up something

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-04 Thread Wolfgang Schuster

Am 04.05.2013 um 09:21 schrieb Aditya Mahajan :

> On 2013-05-03, at 7:36 PM, "Meer, H. van der"  wrote:
> 
>> Seems finally solved (sigh). I cleaned out all files loading typescripts on 
>> the fly. 
>> - typescript macros ending in ] at the end of a line have now ]% at the end 
>> of the line
>> - empty lines have been removed for clarity
>> - all files now have \endinput at the end.
>> 
>> The files changed fit in a 54KB zip and I can send them if Hans/Wolfgang/.. 
>> wants to incorporate them in the next beta.
> 
> I haven't followed this thread in detail, but an alternative is to redefine 
> \starttypescript etc. to use a different catcode regime so that new lines and 
> spaces are ignores (similar to \starttexdefinition, etc)


A better method is to ignore the endlinechar when typescript files are loaded.

\newcount\savedendlinechar

\starttext

Line 1\crlf
\savedendlinechar\endlinechar \endlinechar\minusone
\switchtobodyfont[pagella]
\endlinechar\savedendlinechar
Line 2

\stoptext

Wolfgang
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-04 Thread Sietse Brouwer
Hi Hans, everybody,

Hans van der Meer wrote:
> Would be nice. But doing this is left to other
> people than me, I feel not qualified to tinker
> with that code. You would like to challenge Hans
> Hagen?

Last week's thread about ligatures got unpleasantly close to flaming
at times; so, just in case, I'd like to ask that this one stays calm.
That last sentence sounded a bit more antagonistic than you intended,
perhaps. Aditya was simply making a suggestion, not ‘challenging’ Hans
(either of the Hanses ^_^).

Also: thank you for the work you put into removing/commenting out all
spaces in typescript files; a 54 kB zip is nothing to sneeze at.

My best wishes to everybody in Bachotek / at BachoTeX — I hope the
weather is as fine there as it is here in Leiden.

Cheers,
Sietse
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] extra line after switchtobodyfont

2013-05-04 Thread Meer, H. van der


On 4 May 2013, at 9:21 AM, Aditya Mahajan  wrote:

> On 2013-05-03, at 7:36 PM, "Meer, H. van der"  wrote:
> 
>> Seems finally solved (sigh). I cleaned out all files loading typescripts on 
>> the fly. 
>> - typescript macros ending in ] at the end of a line have now ]% at the end 
>> of the line
>> - empty lines have been removed for clarity
>> - all files now have \endinput at the end.
>> 
>> The files changed fit in a 54KB zip and I can send them if Hans/Wolfgang/.. 
>> wants to incorporate them in the next beta.
> 

> I haven't followed this thread in detail, but an alternative is to redefine 
> \starttypescript etc. to use a different catcode regime so that new lines and 
> spaces are ignores (similar to \starttexdefinition, etc)

Would be nice. But doing this is left to other people than me, I feel not 
qualified to tinker with that code. You would like to challenge Hans Hagen?

Hans van der Meer

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-04 Thread Aditya Mahajan
On 2013-05-03, at 7:36 PM, "Meer, H. van der"  wrote:

> Seems finally solved (sigh). I cleaned out all files loading typescripts on 
> the fly. 
> - typescript macros ending in ] at the end of a line have now ]% at the end 
> of the line
> - empty lines have been removed for clarity
> - all files now have \endinput at the end.
> 
> The files changed fit in a 54KB zip and I can send them if Hans/Wolfgang/.. 
> wants to incorporate them in the next beta.

I haven't followed this thread in detail, but an alternative is to redefine 
\starttypescript etc. to use a different catcode regime so that new lines and 
spaces are ignores (similar to \starttexdefinition, etc)

Aditya
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-03 Thread Meer, H. van der
Seems finally solved (sigh). I cleaned out all files loading typescripts on the 
fly. 
- typescript macros ending in ] at the end of a line have now ]% at the end of 
the line
- empty lines have been removed for clarity
- all files now have \endinput at the end.

The files changed fit in a 54KB zip and I can send them if Hans/Wolfgang/.. 
wants to incorporate them in the next beta.

Hans van der Meer


On 3 May 2013, at 9:43 AM, Wolfgang Schuster 
 wrote:

> The spaces in the output come from the line ending after the 
> \definefontsynonym entry in the typescript and extra line in your other 
> example from the empty lines between the typescript blocks and not from the 
> macro above.
> 

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-03 Thread Meer, H. van der
This might be interesting. The example I gave before was now typeset with 
type-imp-euler.mkiv cannibalized to \endinput in the very first line. Then 
there are no spurious spaces and 5 executions of the recursive loop from 
\t_font_typescripts.
Thus, even though in type-imp-euler.mkiv all empty lines were removed, all 
intermediate spaces removed, all macros ended in ]% en texgyre not loaded, 
there is still spurious space. From the log I see that there are requests for 
[mono][modern] etc.

In order to locate these I have reduced the euler file to one define:
\starttypescript[euler]%
\definetypeface[euler][\s!mm][\s!math][euler][\s!default]%
\quittypescriptscanning
\stoptypescript

Now I get one  or possibly two spurious spaces. But I cannot easily find which 
typescript file is involved. Do you know this? Exerpt from the log:

>
fonts   > request: [euler] [] []
fonts   > auto load typescript file 1: [euler]
fonts   > request: [euler] [] []
(/Users/hansm/TeX/texmf/tex/context/base/type-imp-euler.mkiv)
fonts   > match: [euler]
fonts   > define: [euler] [mm] [math] [euler]
fonts   > request: [math] [euler] [name]
fonts   > auto load typescript file 2: [euler]
fonts   > request: [math] [euler] [name]
fonts   > request: [math] [default] [size]
fonts   > match: [math] [default] [size]
fonts   > defining > font with asked name 'unknown' is not found using 
lookup 'file'
fonts   > defining > unknown font 'unknown', loading aborted
fonts   > defining > unable to define 'unknown' as 'euler-10pt-mm-mb--3'
fonts   > defining > font with asked name 'unknown' is not found using 
lookup 'file'
fonts   > defining > unknown font 'unknown', loading aborted
fonts   > defining > unable to define 'unknown' as 'euler-10pt-mm-mb--2'
fonts   > defining > font with asked name 'unknown' is not found using 
lookup 'file'
fonts   > defining > unknown font 'unknown', loading aborted
fonts   > defining > unable to define 'unknown' as 'euler-10pt-mm-mb--1'
>


By the way. Is it correct that alone \definetypeface, \definefontsynonym, 
\starttypescriptcollection must be closed by ]% while for example 
\starttypescript[] seems to do no harm?

Hans van der Meer



On 3 May 2013, at 1:06 PM, "Meer, H. van der" 
mailto:h.vanderm...@uva.nl>> wrote:


On 3 May 2013, at 12:28 PM, Wolfgang Schuster 
mailto:schuster.wolfg...@gmail.com>>
wrote:
Do you mean the missing % after \doifsomething etc.? These lines don’t need a % 
because TeX gobbles the spaces between the arguments.

I wasn't aware of that, but will remember.

Any idea how further? More from \loadfontgoodies[lm]? To what file does that 
resolve?

The commands loads lm.lfg


The somewhat simpleminded idea of adding \ignorespaces at the end of the 
\definetypeface macro and friends, will not work I am afraid.
Is there a possibilty to remove all whitespace from the tokens in 
\t_font_typescripts or prevent them from entering? Perhaps in the lua end?
Or is it possible to assign to all whitespace characters (space, tab, newline) 
a category code 9 when reading/processing the typescript definitions?

Hans van der Meer



___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] extra line after switchtobodyfont

2013-05-03 Thread Meer, H. van der

On 3 May 2013, at 12:28 PM, Wolfgang Schuster 
 wrote:
> Do you mean the missing % after \doifsomething etc.? These lines don’t need a 
> % because TeX gobbles the spaces between the arguments.

I wasn't aware of that, but will remember.
> 
>> Any idea how further? More from \loadfontgoodies[lm]? To what file does that 
>> resolve? 
> 
> The commands loads lm.lfg
> 

The somewhat simpleminded idea of adding \ignorespaces at the end of the 
\definetypeface macro and friends, will not work I am afraid.
Is there a possibilty to remove all whitespace from the tokens in 
\t_font_typescripts or prevent them from entering? Perhaps in the lua end?
Or is it possible to assign to all whitespace characters (space, tab, newline) 
a category code 9 when reading/processing the typescript definitions?

Hans van der Meer
 

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-03 Thread Wolfgang Schuster

Am 03.05.2013 um 11:19 schrieb "Meer, H. van der" :

> I did some more experiments. In the macro below delete ABC and replace D by ! 
> then the output of the test will match.
> example1 is made with the type-imp-euler.mkiv as given below. I removed every 
> space in it, ended every ] with a % and commented [texgyre] out. In the log 
> can be seen that --as far as I am aware-- just that euler file is loaded and 
> processed.
> For further testing I added a blank line before the starttypescript[euler]% 
> line and the example2 results. There is indeed an effect from the intervening 
> newline.
> Also removed space from type-imp-latinmodern.mkiv and type-imp-lmnames.mkiv.
> But I still cannot explain where the remaining spaces do come from. There are 
> a few places in type-ini.mkvi with space after an } in a macro, but I have 
> patched these in my system.

Do you mean the missing % after \doifsomething etc.? These lines don’t need a % 
because TeX gobbles the spaces between the arguments.

> Any idea how further? More from \loadfontgoodies[lm]? To what file does that 
> resolve? 

The commands loads lm.lfg

Wolfgang

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-03 Thread Meer, H. van der
I did some more experiments. In the macro below delete ABC and replace D by ! 
then the output of the test will match.
example1 is made with the type-imp-euler.mkiv as given below. I removed every 
space in it, ended every ] with a % and commented [texgyre] out. In the log can 
be seen that --as far as I am aware-- just that euler file is loaded and 
processed.
For further testing I added a blank line before the starttypescript[euler]% 
line and the example2 results. There is indeed an effect from the intervening 
newline.
Also removed space from type-imp-latinmodern.mkiv and type-imp-lmnames.mkiv.
But I still cannot explain where the remaining spaces do come from. There are a 
few places in type-ini.mkvi with space after an } in a macro, but I have 
patched these in my system.
Any idea how further? More from \loadfontgoodies[lm]? To what file does that 
resolve?
I am willing to clean up the existing typescript files and sending them where 
they can be incorporated. But if that is not al…

Hans van der Meer

Minimal Tex code:
\setuppapersize[A5][A5]
%\usetypescriptfile[euler]\usetypescript[euler]
\tracetypescriptstrue
\setupbodyfont[lmodern,10pt]
\starttext 
Before\writestatus{}{}\switchtobodyfont[euler,10pt]\writestatus{}{}Fontswitch\stoptext

Sample from type-imp-euler.mkiv
%\loadtypescriptfile[texgyre]%
\starttypescriptcollection[pagella-euler]%
\starttypescript[\s!math][euler]%
\definefontsynonym[EulerMath][\s!file:euler.otf]%
\stoptypescript
\starttypescript[\s!math][euler][\s!name]%

Relevant part of the log:
>
fonts   > request: [euler] [] []
fonts   > auto load typescript file 1: [euler]
fonts   > request: [euler] [] []
(/Users/hansm/TeX/texmf/tex/context/base/type-imp-euler.mkiv)
fonts   > match: [euler]
fonts   > define: [euler] [rm] [serif] [euler]
fonts   > request: [serif] [euler] [name]
fonts   > match: [serif] [euler] [name]
fonts   > request: [serif] [default] [size]
fonts   > match: [serif] [default] [size]
fonts   > define: [euler] [tt] [mono] [modern]
fonts   > request: [mono] [modern] [name]
fonts   > match: [mono] [modern,latin-modern-designsize,latin-modern] 
[name]
fonts   > match: [mono] 
[modern,latin-modern,modern-variable,latin-modern-variable,modern-condensed,latin-modern-condensed]
fonts   > request: [mono] [default] [size]
fonts   > match: [mono] [default] [size]
fonts   > define: [euler] [mm] [math] [euler]
fonts   > request: [math] [euler] [name]
fonts   > match: [math] [euler]
fonts   > match: [math] [euler] [name]
fonts   > request: [math] [default] [size]
fonts   > match: [math] [default] [size]
 [cid:70BCE0AE-8EE4-4E82-B545-913CB0DE816F@fritz.box]>

[cid:58DBF4D7-539A-4FE8-A799-2BEAED31F7DE@fritz.box]


On 3 May 2013, at 9:43 AM, Wolfgang Schuster 
mailto:schuster.wolfg...@gmail.com>> wrote:


Am 03.05.2013 um 09:34 schrieb "Meer, H. van der" 
mailto:h.vanderm...@uva.nl>>:

There is more to it then a preference for \crlf, typescript loading introduces 
a lot of spurious white, that not always can be made to disappear. I tracked it 
down to a macro in type-ini.mkvi:

\def\font_typescript_process_typescript_file_and_store
 
{*\expandafter\let\expandafter\t_font_typescripts\csname\??typescriptfiles\currenttypefile\endcsname
  A\ifx\t_font_typescripts\relax
B\font_typescript_process_typescript_store_indeed
  C\fi
  D\the\t_font_typescripts}

The ABCD*'s were added to see what happens. See the screen shot from one of my 
tests ( results in \crlf but does not sit between text and fontswitch 
\switchtobodyfont). My guess is that the token register \t_font_typescripts is 
the source of the spaces, but I am not further than that. I have already mailed 
Hans Hagen about these findings.

The spaces in the output come from the line ending after the \definefontsynonym 
entry in the typescript and extra line in your other example from the empty 
lines between the typescript blocks and not from the macro above.

\starttext
A\crlf

B\crlf
\stoptext

Wolfgang


<><>___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] extra line after switchtobodyfont

2013-05-03 Thread Wolfgang Schuster

Am 03.05.2013 um 09:34 schrieb "Meer, H. van der" :

> There is more to it then a preference for \crlf […]


\setupwhitespace[line]

\starttext

\subject{Regular paragraphs}

Line 1\par
\start \switchtobodyfont[termes]
Line 2\par
\stop
Line 3

\subject{Packed paragraphs}

\startpacked
Line 4\par 
\start \switchtobodyfont[pagella]
Line 5 \par
\stop
Line 6
\stoppacked

\subject{Line breaks with \tex{crlf}}

Line 7 \crlf
\start \switchtobodyfont[euler]
Line 8 \crlf
\stop
Line 9

\stoptext

Wolfgang
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-03 Thread Wolfgang Schuster

Am 03.05.2013 um 09:34 schrieb "Meer, H. van der" :

> There is more to it then a preference for \crlf, typescript loading 
> introduces a lot of spurious white, that not always can be made to disappear. 
> I tracked it down to a macro in type-ini.mkvi:
> 
> \def\font_typescript_process_typescript_file_and_store
>   
> {*\expandafter\let\expandafter\t_font_typescripts\csname\??typescriptfiles\currenttypefile\endcsname
>A\ifx\t_font_typescripts\relax
>  B\font_typescript_process_typescript_store_indeed
>C\fi
>D\the\t_font_typescripts}
> 
> The ABCD*'s were added to see what happens. See the screen shot from one of 
> my tests ( results in \crlf but does not sit between text and fontswitch 
> \switchtobodyfont). My guess is that the token register \t_font_typescripts 
> is the source of the spaces, but I am not further than that. I have already 
> mailed Hans Hagen about these findings.

The spaces in the output come from the line ending after the \definefontsynonym 
entry in the typescript and extra line in your other example from the empty 
lines between the typescript blocks and not from the macro above.

\starttext
A\crlf

B\crlf
\stoptext

Wolfgang

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-03 Thread Meer, H. van der
There is more to it then a preference for \crlf, typescript loading introduces 
a lot of spurious white, that not always can be made to disappear. I tracked it 
down to a macro in type-ini.mkvi:

\def\font_typescript_process_typescript_file_and_store
  
{*\expandafter\let\expandafter\t_font_typescripts\csname\??typescriptfiles\currenttypefile\endcsname
   A\ifx\t_font_typescripts\relax
 B\font_typescript_process_typescript_store_indeed
   C\fi
   D\the\t_font_typescripts}

The ABCD*'s were added to see what happens. See the screen shot from one of my 
tests ( results in \crlf but does not sit between text and fontswitch 
\switchtobodyfont). My guess is that the token register \t_font_typescripts is 
the source of the spaces, but I am not further than that. I have already mailed 
Hans Hagen about these findings.

[cid:AE3D66B6-9CD5-4377-B68D-AED490D0487E@fritz.box]

Hans van der Meer

On 2 May 2013, at 11:17 PM, Wolfgang Schuster 
mailto:schuster.wolfg...@gmail.com>>
 wrote:


Am 02.05.2013 um 12:40 schrieb "Meer, H. van der" 
mailto:h.vanderm...@uva.nl>>:

A call to \switchtobodyfont introduces extra vertical spacing as can be seen in 
the example.
Is this intentional or is it something like a % missing somewhere in a macro?

Hans van der Meer

Sorry, flew accidentally to early away. Here the attached output.

\setuppapersize[A6][A6]
\setupbodyfont[lucidaot]
\starttext
First line.\crlf
\start
\switchtobodyfont[euler]
Font switch here.\crlf
\stop
Last line.
\hairline
First line.\crlf
\start
Font switch here.\crlf
\stop
Last line.
\stoptext

Is there a reason why you use \crlf to end the lines?

When you would end the paragraph after each line the additional line wouldn't 
appear.


<>___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] extra line after switchtobodyfont

2013-05-02 Thread Wolfgang Schuster

Am 02.05.2013 um 12:40 schrieb "Meer, H. van der" :

> A call to \switchtobodyfont introduces extra vertical spacing as can be seen 
> in the example.
> Is this intentional or is it something like a % missing somewhere in a macro?
> 
> Hans van der Meer
> 
> Sorry, flew accidentally to early away. Here the attached output.
> 
> \setuppapersize[A6][A6]
> \setupbodyfont[lucidaot]
> \starttext
> First line.\crlf
> \start
> \switchtobodyfont[euler]
> Font switch here.\crlf
> \stop
> Last line.
> \hairline
> First line.\crlf
> \start
> Font switch here.\crlf
> \stop
> Last line.
> \stoptext

Is there a reason why you use \crlf to end the lines?

When you would end the paragraph after each line the additional line wouldn't 
appear.

Wolfgang
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-02 Thread Meer, H. van der
Indeed, adding \usetypescriptfile[euler]\usetypescript[euler] before \starttext 
makes the extra vertical spacing go away in a simple test file. But that 
doesn't solve my problem, because I am typesetting xml data wherein a font 
change can be dictated from the inside. See the example code (supporting 
modules not included):

\startbuffer[font]


First line.

Font switch here.

Last line.

\stopbuffer
\xmlprocessbuffer{root}{font}{}

There is no way to have the typescript loaded before the \starttext, because it 
is not known what fonts will be called up by the xml. And loading it from 
within the data processed is too late.
I therefore conclude that this typescript problem should be fundamentally 
solved, instead of resorting to a subterfuge as loading things beforehand to 
avoid - what seems to me - coding mistakes.

Hans van der Meer



On 2 May 2013, at 12:48 PM, Marco Patzer  wrote:

> On 2013–05–02 Meer, H. van der wrote:
> 
>> A call to \switchtobodyfont introduces extra vertical spacing as can be seen 
>> in the example.
>> Is this intentional or is it something like a % missing somewhere in a macro?
> 
> Loading the typescript in the setup area should get rid of the
> space.
> 
> See http://www.ntg.nl/pipermail/ntg-context/2013/072892.html
> 
> Marco
> ___
> If your question is of interest to others as well, please add an entry to the 
> Wiki!
> 
> maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
> archive  : http://foundry.supelec.fr/projects/contextrev/
> wiki : http://contextgarden.net
> ___

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-02 Thread Meer, H. van der
I see. But that means I have to load various typescript files beforehand and 
then switch at a later moment. It is possible of course, but unexpected and a 
pain in the ass - if I may say so. Could it be solved once and for all by going 
through the typescript files? If I can find time for it, I will look into the 
matter too.

Hans van der Meer



On 2 May 2013, at 12:48 PM, Marco Patzer 
 wrote:

> On 2013–05–02 Meer, H. van der wrote:
> 
>> A call to \switchtobodyfont introduces extra vertical spacing as can be seen 
>> in the example.
>> Is this intentional or is it something like a % missing somewhere in a macro?
> 
> Loading the typescript in the setup area should get rid of the
> space.
> 
> See http://www.ntg.nl/pipermail/ntg-context/2013/072892.html
> 

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] extra line after switchtobodyfont

2013-05-02 Thread Marco Patzer
On 2013–05–02 Meer, H. van der wrote:

> A call to \switchtobodyfont introduces extra vertical spacing as can be seen 
> in the example.
> Is this intentional or is it something like a % missing somewhere in a macro?

Loading the typescript in the setup area should get rid of the
space.

See http://www.ntg.nl/pipermail/ntg-context/2013/072892.html

Marco


signature.asc
Description: Digital signature
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

Re: [NTG-context] extra line after switchtobodyfont

2013-05-02 Thread Meer, H. van der
A call to \switchtobodyfont introduces extra vertical spacing as can be seen in 
the example.
Is this intentional or is it something like a % missing somewhere in a macro?

Hans van der Meer

Sorry, flew accidentally to early away. Here the attached output.

\setuppapersize[A6][A6]
\setupbodyfont[lucidaot]
\starttext
First line.\crlf
\start
\switchtobodyfont[euler]
Font switch here.\crlf
\stop
Last line.
\hairline
First line.\crlf
\start
Font switch here.\crlf
\stop
Last line.
\stoptext




fontswitch.pdf
Description: fontswitch.pdf
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___

[NTG-context] extra line after switchtobodyfont

2013-05-02 Thread Meer, H. van der
A call to \switchtobodyfont introduces extra vertical spacing as can be seen in 
the example.
Is this intentional or is it something like a % missing somewhere in a macro?

Hans van der Meer


\setuppapersize[A6][A6]
\setupbodyfont[lucidaot]
\starttext
First line.\crlf
\start
\switchtobodyfont[euler]
Font switch here.\crlf
\stop
Last line.
\hairline
First line.\crlf
\start
Font switch here.\crlf
\stop
Last line.
\stoptext


___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] problem with switchtobodyfont

2012-06-05 Thread Brian Landy
Hi, I decided to give the latest minimals a test (I had been using 2012.01.16, 
updated to 2012.06.05 today), and noticed that switchtobodyfont no longer seems 
to work properly.  Here is a small example:

\starttypescript [cleartype]
\definetypeface [\typescriptone] [rm] [serif] [constantia][default]
\definetypeface [\typescriptone] [ss] [sans]  [calibri]   [default]
\stoptypescript<


\usetypescript[cleartype]%
\starttext
{\switchtobodyfont[cleartype,serif,24pt]should be serif\par}
{\switchtobodyfont[cleartype,sans,24pt]should be sans\par}
\stoptext

The problem appears to be applying in a font size the first time the font is 
loaded.  For example, adding this line works:

% typescript
\starttext
{\switchtobodyfont[cleartype,serif]\switchtobodyfont[24pt]} % new line
{\switchtobodyfont[cleartype,serif,24pt]should be serif\par}
{\switchtobodyfont[cleartype,sans,24pt]should be sans\par}
\stoptext

The point sizes have to match for this to work.

It also works to add in \setupbodyfont[cleartype]; however, this isn’t helpful 
if there are multiple typescripts to use in the same document.

I didn’t notice any mention of this in the list (apologies if I overlooked it) 
so assume this is a bug?

Thanks!
Brian  
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont does not work inside of \startsetups layer ?

2011-02-18 Thread Vnpenguin
On Fri, Feb 18, 2011 at 20:11, Wolfgang Schuster
 wrote:
>
> Am 18.02.2011 um 19:08 schrieb Vnpenguin:
>
>> Wow, it works now.
>
> You can also separate the style and content of a layer with \setlayerframed, 
> e.g.
>
> \setlayerframed
>  [mylayer]
>  [x=...,
>   y=...,
>   frame=off,
>   style={\switchtobodyfont[10pt]}]
>  {text}
>

Thank you,
Regards
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont does not work inside of \startsetups layer ?

2011-02-18 Thread Wolfgang Schuster

Am 18.02.2011 um 19:08 schrieb Vnpenguin:

> Wow, it works now.

You can also separate the style and content of a layer with \setlayerframed, 
e.g.

\setlayerframed
  [mylayer]
  [x=...,
   y=...,
   frame=off,
   style={\switchtobodyfont[10pt]}]
  {text}

Wolfgang

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont does not work inside of \startsetups layer ?

2011-02-18 Thread Vnpenguin
On Fri, Feb 18, 2011 at 19:03, Wolfgang Schuster
 wrote:
>
> Am 18.02.2011 um 18:59 schrieb Vnpenguin:
>
>> \usetypescript[palatino]
>> \switchtobodyfont[palatino,20pt]
>
> Replace this (both lines) with
>
> \setupbodyfont[palatino,20pt]
>
> Wolfgang
>

Wow, it works now.
Thank you so much for your very quick help.

Cheers,
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont does not work inside of \startsetups layer ?

2011-02-18 Thread Wolfgang Schuster

Am 18.02.2011 um 18:59 schrieb Vnpenguin:

> \usetypescript[palatino]
> \switchtobodyfont[palatino,20pt]

Replace this (both lines) with

\setupbodyfont[palatino,20pt]

Wolfgang

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] \switchtobodyfont does not work inside of \startsetups layer ?

2011-02-18 Thread Vnpenguin
Hi,
I have a following test:
=
\setuppapersize[S8][S8]
\setuplayout
[width=fit,height=fit,
rightmargin=1.5cm,leftmargin=1.5cm,
backspace=15mm,topspace=23mm,top=10mm,
header=0mm,footer=0mm,bottom=5mm,
margin=0mm]
\usetypescript[palatino]
\switchtobodyfont[palatino,20pt]

\setupcolors[state=start]

\definelayer[myLayer]
[width=\paperwidth, height=\paperheight]

\startsetups layer
\setlayer[myLayer][preset=lefttop,x=0.9\paperwidth,y=0.96\paperheight]
{\switchtobodyfont[10pt]\pagenumber\ of \lastpage}
\stopsetups

\setupbackgrounds
[page]
[setups=layer,background={myLayer},state=start]


\starttext
\page
\setlayer[myLayer][preset=leftttop,x=7mm,y=6mm]%
{\switchtobodyfont[48pt]\bf Page One}
blah blah blah blah blah blah blah blah blah

\page
\setlayer[myLayer][preset=leftttop,x=7mm,y=6mm]%
{\switchtobodyfont[48pt]\bf Page Two}
blah blah blah

\stoptext


The command \switchtobodyfont[10pt] inside of my \startsetups layer
...\stopsetups does not work for me.
In the final PDF I have not page number at 10pt.

Here are the files:

http://dl.dropbox.com/u/7959896/context/test2/test2.tex
http://dl.dropbox.com/u/7959896/context/test2/test2.log
http://dl.dropbox.com/u/7959896/context/test2/test2.pdf

I use on WinXP :

E:\User>context --version

mtx-context | main context file:
C:/context/tex/texmf-context/tex/context/base/context.mkiv
mtx-context | current version: 2011.02.18 17:17

Any help ?

Thanks in advance,
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont

2010-11-09 Thread Hans Hagen

On 9-11-2010 8:49, Herbert Voss wrote:

Is this the default behaviour, that \switchtobodyfont works
like a \hfill??  | page |

\starttext
Latin Modern
\switchtobodyfont[pagella]Pagella--Palatino
\stoptext

| Latin ModernPag-|
| ella|

Latest minimal mkiv


btw, you can do:

Latin Modern \switchtobodyfont[pagella]\removeunwantedspaces\space 
Pagella--Palatino


but normally there will be a

\setupbodyfont[pagella]

at the top

-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] \switchtobodyfont

2010-11-09 Thread Hans Hagen

On 9-11-2010 8:49, Herbert Voss wrote:

Is this the default behaviour, that \switchtobodyfont works
like a \hfill??  | page |

\starttext
Latin Modern
\switchtobodyfont[pagella]Pagella--Palatino
\stoptext

| Latin ModernPag-|
| ella|

Latest minimal mkiv


in this case font definitions are loaded for the first time and as 
typescript (or whatever) can have spaces and newlines and since you do 
it in horizontal mode, you get something


Latin Modern ...Pagella

and space can stretch


-
  Hans Hagen | PRAGMA ADE
  Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
 | www.pragma-pod.nl
-
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] \switchtobodyfont

2010-11-09 Thread Herbert Voss
Is this the default behaviour, that \switchtobodyfont works
like a \hfill??  | page |

\starttext
Latin Modern
\switchtobodyfont[pagella]Pagella--Palatino
\stoptext

| Latin ModernPag-|
| ella|

Latest minimal mkiv

Herbert
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] setup/switchtobodyfont question

2008-11-26 Thread Wolfgang Schuster

Am 26.11.2008 um 12:43 schrieb Alan STONE:

> The main manual mentions (ch 5 Typography, pg 92):
>
> "In most cases, the command \setupbodyfont is only used once: in the  
> styledefinition.
> Fontswitching is done with \switchtobodyfont. Don't mix these two up  
> because this may
> lead to some rather strange but legitimate effects."
>
> What's recommended when using a product meta-structure  
> (standardmakeup-frontmatter-
> bodypart-appendices-backmatter) where the bodyfont (and in some  
> cases also the top,
> header, footer, bottom fonts change) from one to the other ?
>
> Declare one (1) setupbodyfont and switchtobodyfont from one meta- 
> structure element to the
> other or use a dedicated setupbodyfont for each ?

 From font-ini:

The next two macros are user ones. With \setupbodyfont
one can set the document bodyfont size, font family, style
and/or options defined in files, for example:

\setupbodyfont[cmr,ams,12pt,roman]

This command affects the document as a whole: text, headers
and footers. The second macro however affects only the text:

\switchtobodyfont[10pt]

Both macros look alike. The second one also has to take
all kind of keywords into account.

Wolfgang

___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] setup/switchtobodyfont question

2008-11-26 Thread Alan STONE
Same question related to setuplayout.

On Wed, Nov 26, 2008 at 12:43 PM, Alan STONE
<[EMAIL PROTECTED]>wrote:

> The main manual mentions (ch 5 Typography, pg 92):
>
> "In most cases, the command \setupbodyfont is only used once: in the
> styledefinition.
> Fontswitching is done with \switchtobodyfont. Don't mix these two up
> because this may
> lead to some rather strange but legitimate effects."
>
> What's recommended when using a product meta-structure
> (standardmakeup-frontmatter-
> bodypart-appendices-backmatter) where the bodyfont (and in some cases also
> the top,
> header, footer, bottom fonts change) from one to the other ?
>
> Declare one (1) setupbodyfont and switchtobodyfont from one meta-structure
> element to the
> other or use a dedicated setupbodyfont for each ?
>
> --
> Best,
> Alan
>
> * TeX engine = LuaTeX
> * ConTeXt minimal ver: 2008.11.10 21:40 MKIV  fmt: 2008.11.25  int:
> english/english
> * Ubuntu 8.04 Hardy Heron
>
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


[NTG-context] setup/switchtobodyfont question

2008-11-26 Thread Alan STONE
The main manual mentions (ch 5 Typography, pg 92):

"In most cases, the command \setupbodyfont is only used once: in the
styledefinition.
Fontswitching is done with \switchtobodyfont. Don't mix these two up because
this may
lead to some rather strange but legitimate effects."

What's recommended when using a product meta-structure
(standardmakeup-frontmatter-
bodypart-appendices-backmatter) where the bodyfont (and in some cases also
the top,
header, footer, bottom fonts change) from one to the other ?

Declare one (1) setupbodyfont and switchtobodyfont from one meta-structure
element to the
other or use a dedicated setupbodyfont for each ?

-- 
Best,
Alan

* TeX engine = LuaTeX
* ConTeXt minimal ver: 2008.11.10 21:40 MKIV  fmt: 2008.11.25  int:
english/english
* Ubuntu 8.04 Hardy Heron
___
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki : http://contextgarden.net
___


Re: [NTG-context] spurious line break in \switchtobodyfont

2006-04-26 Thread Mojca Miklavec
On 4/26/06, Hans Hagen wrote:
> Mojca Miklavec wrote:
> > Hello,
> >
> > there is a misterious linebreak in the second example:
> >
> > abc\switchtobodyfont[ss]def
> >
> > abc\switchtobodyfont[,,ss]def
> >
> > Is this ConTeXt's fault or mine?
> >
> lucky you:
>
> \def\dodosetfont#1#2%  #1 = set/switch state / test added to make it
> mojca proof
>  {\doifsomething{#2}{\dododosetfont{#1}{#2}{\showmessage\m!fonts4{#2
>
> Hans

Thanks! That was (at least partially) one of gnuplot's faults, not mine ;)

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


Re: [NTG-context] spurious line break in \switchtobodyfont

2006-04-26 Thread Hans Hagen
Mojca Miklavec wrote:
> Hello,
>
> there is a misterious linebreak in the second example:
>
> abc\switchtobodyfont[ss]def
>
> abc\switchtobodyfont[,,ss]def
>
> Is this ConTeXt's fault or mine?
>   
lucky you:

\def\dodosetfont#1#2%  #1 = set/switch state / test added to make it 
mojca proof
  {\doifsomething{#2}{\dododosetfont{#1}{#2}{\showmessage\m!fonts4{#2

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


[NTG-context] spurious line break in \switchtobodyfont

2006-04-25 Thread Mojca Miklavec
Hello,

there is a misterious linebreak in the second example:

abc\switchtobodyfont[ss]def

abc\switchtobodyfont[,,ss]def

Is this ConTeXt's fault or mine?

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