Jump to navigation Jump to search
726 bytes added ,  19:13, 13 November 2013
Removed a spam ad at the top of this page!
< [[From LaTeX to ConTeXt]]> == ConTeXt == The exact same thing can be done in ConTeXt, although the syntax is slightly more verbose.
\documentclass{article}definebodyfont [12pt] [tt] [bf=cmttb10 at 12pt]\definebodyfont [11pt] [tt] [bf=cmttb10 at 11pt]\DeclareFontShape{OT1}{cmtt}{bx}{n}{definebodyfont [10pt] [tt] [bf=cmttb10] <5><6><7><8><9><10><10.95><12><14.4><17.28><20.74><24.88>\definebodyfont [9pt] [tt] [bf=cmttb10}{}at 9pt]\begin{document}definebodyfont [8pt] [tt] [bf=cmttb10 at 8pt] \textttstarttext{\tt Normal and \textbf{bf bold Typewriter.}}\end{document}stoptext
However, instead of requiring that this be defined in each document, ConTeXt:Put this also provides the possibility of including it automatically as part of the default font setups. This can be done by putting the following typescript definitions in <code>/usr/share/texmf/tex/context/third/type-loc.tex</code> . The version shown here also uses the newer (and bolder) <code>cmbtt</code> family; to define use the bold typewriter older <code>cmttb10</code> fonts:, uncomment them and comment out the other set. 
\newif\ifVeryBoldTT % turn this on, if it's not bold enough:
\starttypescript [mono] [computer-modern] [size]
\ifVeryBoldTT% Newer, more-bold version of the bold typewriter fonts.
\definebodyfont [12pt] [tt] [bf=cmbtt10 at 12pt]
\definebodyfont [11pt] [tt] [bf=cmbtt10 at 11pt]
\definebodyfont [9pt] [tt] [bf=cmbtt9]
\definebodyfont [8pt] [tt] [bf=cmbtt8]
\else%% Older, less-bold version of the bold typewriter fonts. % \definebodyfont [12pt] [tt] [bf=cmttb10 at 12pt] % \definebodyfont [11pt] [tt] [bf=cmttb10 at 11pt] % \definebodyfont [10pt] [tt] [bf=cmttb10] % \definebodyfont [9pt] [tt] [bf=cmttb10 at 9pt] % \definebodyfont [8pt] [tt] [bf=cmttb10 at 8pt]\fi
<code>cmbtt[8,9,10]</code> is the more recent family of fonts and bolder than the older <code>cmttb10</code> font. Then, the fonts can be accessed without any additional setup in the documents, as in this example:
The support for bold typewriter exists also as a module:
(''But it would be great if those definitions were a part of [[source:type-siz.tex|type-siz.tex]]; --[[User:Mojca Miklavec|Mojca]]'')
[[Category:From LaTeX]]


Navigation menu