2007/12/6, Mojca Miklavec
On 12/6/07, Steffen Wolfrum wrote:
Hi,
when in february 2006 I asked for an alternative to fontspec that could show me opentype features, Adam wrote:
I find that the lcdf typetools are a tremendous help: otfinfo -f ~/Library/Fonts/WarnockPro-Regular.otf and I can test the features with: \showfont["Warnock Pro: +smcp"]
Today this showfont-line doesn't work anymore:
\definetypeface[oneliner][rm][Xserif][Warnock Pro][default]
\starttext
\oneliner Test WQG 0196
\showfont["Warnock Pro: +smcp"]
\stoptext
Someone knows what to do?
(I wasn't aware of such usage ...)
In this specific case you could use \showfont[SerifCaps] (if your ConTeXt version is newer than 2007.10.29)
The general approach would be something like: \definefontfeature[mine][smcp=yes] \definefontsynonym[a][name:Warnock Pro][features=mine] \showfont[a] (grep the sources for definefontfeature)
One question for Hans: would it be possible (make sense) to make this work? \showfont[name:Iwona][features=mine]
I want such a feature for \setupbodyfont, e.g. \setupbodyfont[myfont] use the fonfeatures define in the typescript \setupbodyfont[myfont][features=oldstyle] choose oldstyle figures instead of the default setting in the typescript, this requires at the moment always a second typescript with oldstyle numerals. It would also nice to map \sc to \setfontfeature{smallcaps} because ConTeXts smallcaps fontsynonym works only for roman typeface and \os should use the oldstyle fontfeature, it use currently a math font except I use \variant or define a alternative typescript.
Perhaps there should be some kind of "raw" prefix introduced (again): \definefontsynonym[a][raw:Warnock Pro:mapping=tex-text;+smcp]
But generally, LuaTeX is much more suitable for such previews (only that there might be no "newshowfont" available yet - writing one is doable if you know what you're interested in).
My two cents: ConTeXt currenty uses smcp=yes,script=latn,onum=yes,liga=yes... while fontspec uses either Letters=SmallCaps Script=Latin Numbers=OldStyle Ligatures=Common or the same raw names as above. I would prefer the "human-readable" names as in fontspec, but ... well, the font calling mechanisms really need to improve in my opinion.
What fontspec achieves in one line like (copying from XeTeX list): \setmainfont[Script=Devanagari]{Sanskrit 2003} needs dozens of lines in ConTeXt (definefontfeature, define typescripts in two steps, ... brrrr)
So in case that some more features in XeTeX/LuaTeX change, do not be surprised too much ...
And even worse both engines have their own default values for fonts. Wolfgang