Changes

Jump to navigation Jump to search
m
no edit summary
<texcode>
% Enable Unicode fonts
\enableregime[utf]
 
% Enable Capital Letter use
\setupcapitals[sc=yes]
% Define a script named [serif][nimbus]
\starttypescript [serif] [nimbus]
\definefontsynonym [Serif] [name:nimbusromno9lregu]
\stoptypescript
% Define a second script named [sans][nimbus]
\starttypescript [sans] [nimbus]
\definefontsynonym [Sans] [name:nimbussanlregu]
\stoptypescript
% Define the typeface nimbus; use serif for rm-fonts, sans serif for ss-fonts.
\definetypeface [nimbus] [rm] [serif] [nimbus]
\definetypeface [nimbus] [ss] [sans] [nimbus]
% Indicate the typeface to use.
\usetypescript[nimbus][uc]
\setupbodyfont[nimbus,rm,10pt]
</texcode>
Annotations:* The first two lines say: ** We only enter unicode ** We only use unicode Both scripts map the fonts* Thirds line names to the different (setupcapitalsexisting) say ConTeXt to use the Capital Letters defined in the fontsfont style. Usage is implemented as follows:* Two scripts are defined:*# 1. The {{cmd|setupbodyfont}} command calls the scripts named ''[serif][typeface nimbus]'' and.*# 1. The ''typeface nimbus'' calls the script named ''typescript [sansserif][nimbus]''* Both scripts map for the rm-fonts names to the different (existing) font style.* Both definetypeface-lines define the typeface , or ''typescript [sans][nimbus]''. The first defines the rm-fonts and the second for the ss-fonts. * setupbodyfont says to ConTeXt witch typeface to use with which parameters.
The chain starts with setupbodyfont: it calls the ''typeface nimbus''. Then the ''typeface nimbus''# calls the ''typescript [serif][nimbus]'' for the rm-fonts# calls the ''typescript [sans][nimbus]'' for the ss-fonts.And inside these scripts then map the fonts are mapped to the different font styles.
==Small extension==
419

edits

Navigation menu