From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/7009 Path: main.gmane.org!not-for-mail From: Hans Hagen Newsgroups: gmane.comp.tex.context Subject: Re: FAQ: fonts Date: Mon, 25 Feb 2002 17:24:36 +0100 Sender: owner-ntg-context@let.uu.nl Message-ID: <5.1.0.14.1.20020225165613.02b28720@server-1> References: <200202242231.g1OMVT201729@nathir.fiee.lan> <200202242231.g1OMVT201729@nathir.fiee.lan> NNTP-Posting-Host: coloc-standby.netfonds.no Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii"; format=flowed X-Trace: main.gmane.org 1035397505 15682 80.91.224.250 (23 Oct 2002 18:25:05 GMT) X-Complaints-To: usenet@main.gmane.org NNTP-Posting-Date: Wed, 23 Oct 2002 18:25:05 +0000 (UTC) Cc: ntg-context@ntg.nl Original-To: Taco Hoekwater In-Reply-To: <20020225140515.4511882f.taco@elvenkind.com> Xref: main.gmane.org gmane.comp.tex.context:7009 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:7009 At 02:05 PM 2/25/2002 +0100, Taco Hoekwater wrote: >- mtexfont.pdf and mfonts.pdf overlap eachother in areas where they shouldn't right, i will change this as soon as texfont.pl is finished >- mfonts.pdf explains *too much* (e.g. the section on \definefont, and the > stuff about the traditional system with \definebodyfont) once the typescripts are working as expected, that part will go to an appendix >- the FAQ is too terse and doesn't mention the nasty pitfalls (like the fact > that you *cannot* redefine a typescript collection) btw, you can overload one by a later accessed typescript >- There are too many 'example' files in the distribution that fairly unusable > in the real world (like type-buy.tex) they come from my personal real world -) >- the whole font subsystem is still backward compatible so all of the old > commands still function more ore less as they used to >- \starttypescript is an awful command. It does a lot of stuff depending > on 'special options', and the documentation for these options is incomplete actually, it's just a filtering command: \starttypescript [list a] [list b] [list c] \usetypescript [list a] [list b] [list c] the use command tries to match them and 'executes' everything in the matched script (i have plans to use this feature for other things as well). the keyword 'all' can be used to match anything >- The same is true for \definetypeface. apart from some font/command initializations this command just executes a series of typescripts (as you mention later); the ideas is that one can do things like: \definetypeface [abra] [rm] [serif] .... \definetypeface [cadabra] [rm] [serif] .... and so create multiple (quite complete) bodyfont rm/ss/tt/.. definitions; since each typeface (collection of rm,ss,tt defs) has its own namespace, one can, in one document, for instance mix different collections, each with different encodings and relative scaling etc. >In order to create some sort of logic: > >There should be aliases defined for at least the following commands, and the >documentation should stick to using these names instead of the basic command. > >This will make the documentation and usage much clearer without introducing >extra overhead in the ConTeXt core. > >\definefontsynonym >------------------ >Is used for two different things: >- Mapping generic names to font family names, as in > \definefontsynonym [Serif] [TimesRoman] >- Mapping font family names to disk file names, as in > \definefontsynonym [TimesRoman] [tir] [encoding=texnansi] > >The second usage needs an alias (I propose \definefontfile), so that the above >can be written as: > > \definefontsynonym [Serif] [TimesRoman] > \definefontfile [TimesRoman] [tir] [encoding=texnansi] i have no problem with providing you \definefontfile (just a \let) but keep in mind that the third arg (encoding, mapping, handling, etc) can come at any level in the font (file)name expansion chain. >\starttypescript >---------------- >Is used for *a lot* of different things. > >\starttypescript [map] >********************* > >First, here is one call I do not fully understand: > > \starttypescript[map][texnansi] > \loadmapfile [texnansi-urw-times.map] > \stoptypescript > >Assuming I get it right, this is what should happen: > >- Context internally has defined a very very special typescript called map. no, this typescript is as the others, so: \usetypescript[map][texnansi] will execute all typescripts marked as such, while \usetypescript[map][all] will load all typescripts that have a first [map] spec. The \loadmapfile will add the names mentioned to an internal list; keep in min dthat this loading of map files is still suboptimal (i have to discuss this with thanh). >- This is not 'really' a typescript, but behaves more like a list. A list of > pdftex map files, in fact. the \loadmapfile indeed adds to a list; actually anything can happen in a typescript, so \starttypescript[taco] \def\Taco{Taco Hoekwater} \stoptypescript is pretty valid. >- Whenever anybody calls *any* typescript, this special typescript is >automatically > activated as well. no, only when asked for; it happens that it is asked for frequently >- the net result of that is that all of the map files (in the correct >encoding) > are loaded by pdftex at every typescript change. right, \starttypescript [map] [palatino] [texnansi] or so would provide more granularity [the problem currently si that one needs to load map files at the first page (after that pdftex ignores \pdfmapfile; this may change (i hope)) >If I get this right, the whole thing is an attempt to make pdftex read map >files dynamically at runtime instead of statically preloading all of the >map files as soon as the executable starts. right, this is needed because otherwise one cannot overload entries; unfortunately in tex distributions everything goes into this big psfonts,map file (with all side effects, like problems with embedded pdf files). >Sadly, this won't work correctly until pdftex is patched to accept map >files during >a run (in the current situation, pdftex only allows dynamic loading of map >files >before the first page is shipped out, not afterwards). right again -) >Anyway, this is *ugly* when used in a call to \starttypescript. It would >be much >nicer to have a new command: > > \definetypescriptencodingmapfile [texnansi] [texnansi-urw-times.map] > >(or even \defineencodingmapfile, since there is no real relation to any >specific typescript name, only to the encoding) > > >\starttypescript [*] [*] [size] >******************************* > >Why not call this \starttypescriptsizes ? > > >\starttypescript [*] [*] [name] >******************************* > >Why not call this \starttypescriptnames ? once i got the feeling that typescripts are stable i will look into that, probably something \starttypefacesize is more accurate >\starttypescript (in general) >**************** > >The exact usage of the options to this command is incredibly >confusing. If I understand it all correctly, then what is generally >used as the *first* argument in the documentation (serif|sans|mono|math) >is more optional than the second (the typescript name | default). At the >same time, I get the impression from the documentation that the order >is not important at all (mfonts.pdf page 8). This is clearly not true. this is only true for the ones called for by \definettypeface, but as said, one can use typescripts for more purposes \usetypescript >************** > >I think it is a little odd that documents now start with: > > \usetypescriptfile[type-mytimes] > \usetypescript[mytimes] > >Hans, do you think it is possible to add the file loading/checking >code to \usetypescript? hm, it could be done, but would slow down things (much more file opening and so). What i do here, is put every local thing in a file called typeface.tex and load that one always >If I understand this correctly, then \usetypescript basically has the >same arguments as \starttypescript. It follows that if you use this command >in a typescript definition file, it only functions as a shortcut to get >to (parts of) another typescript. Hans, is this correct? right >\definetypeface >*************** > >At one point in time I understood what this command does. But not any >longer. For one, I don't understand how it is possible that it appears >*inside* a typescript definition. I thought it was a way to map a number >of definebodyfonts into a single command. But then again, this is also what >typescripts do. So how can one be part of the other? think of the one defining the typeface as being the top (root) of a tree; it will not load itself [i agree that typescripts are a bit fuzzy and i hope that some day i will have them reworked in some way (for instance as you propose with more dedicated commands), but given the diversity of fonts, i wanted a mechanism that i could experiment with; for instance, i will probably clean up some encoding filtering (otherwise the third args will grow too long).] [sorry for being confusing] 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 ------------------------------------------------------------------------- fall-back web server: www.pragma-pod.nl -------------------------------------------------------------------------