From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/4104 Path: main.gmane.org!not-for-mail From: Hans Hagen Newsgroups: gmane.comp.tex.context Subject: Re: how to: switch to another font Date: Fri, 16 Feb 2001 17:53:45 +0100 Sender: owner-ntg-context@let.uu.nl Message-ID: <3.0.6.32.20010216175345.017ee510@server-1> References: <01021616565303.00577@bilbo> NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" X-Trace: main.gmane.org 1035394791 22907 80.91.224.250 (23 Oct 2002 17:39:51 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 23 Oct 2002 17:39:51 +0000 (UTC) Cc: ntg-context Original-To: "Uwe Koloska" In-Reply-To: <01021616565303.00577@bilbo> Xref: main.gmane.org gmane.comp.tex.context:4104 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:4104 At 04:56 PM 2/16/01 +0100, Uwe Koloska wrote: >Hello Hans, hello all, > >I have defined a font that shall only be used for some words (think of it >as a logo font). > \definefontsynonym[Batmos-Regular] [...] >Now I want to write "Hello this is {\switchFont{Batmos-Regular}cool stuff} >and ..." without defining an extra font with \definefont. Is this >possible, or do I have to explicitly define all fonts that I wann use in >the document. > >Now I have: > \def\setBatmosFont% > {\definefont[batmosFont][Batmos-Regular sa > \multiply\currentfontscale by 1.4]\batmosFont} >that switches to this particular font and honours the current fontsize. >Since the font has a smaller x-height, I have to scale it. > >If there is no easy way to say: "Switch to this font and honour the current >size" -- is my solution well defined? \definefont font is a rather raw command it does support dynamic filenames, so you can say: \definefontsynonym[blabla][bla] \definefont[blablala][blabla sa 1] and redefine the fontsynonym anywhere you want and \bablabla will follow. what do you mean with the scaling? sa 1.4 does follow the scale, doesn't it? You can also try: [somefont at 3ex] or alike. Or do you want something more tricky? Hans ------------------------------------------------------------------------- Hans Hagen | PRAGMA ADE | pragma@wxs.nl Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com -------------------------------------------------------------------------