diff options
author | Karl Berry <karl@freefriends.org> | 2009-08-28 17:52:47 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2009-08-28 17:52:47 +0000 |
commit | 9574391f1c92725d497fa2a84962aee68b5cbf25 (patch) | |
tree | 8c6a92468e9c6da565ed5da07c13c0c01187875f /Master/texmf-dist/tex/fontinst | |
parent | 227ebe2cb5e11abb7e12b88ba66adc7735fa9570 (diff) |
fontinst 1.933 (24aug09)
git-svn-id: svn://tug.org/texlive/trunk@14924 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/fontinst')
-rw-r--r-- | Master/texmf-dist/tex/fontinst/base/cfntinst.sty | 230 | ||||
-rw-r--r-- | Master/texmf-dist/tex/fontinst/base/finstmsc.sty | 70 | ||||
-rw-r--r-- | Master/texmf-dist/tex/fontinst/base/fontinst.sty | 230 | ||||
-rw-r--r-- | Master/texmf-dist/tex/fontinst/base/multislot.sty | 234 | ||||
-rw-r--r-- | Master/texmf-dist/tex/fontinst/base/xfntinst.sty | 230 | ||||
-rw-r--r-- | Master/texmf-dist/tex/fontinst/latinetx/t1.etx | 44 | ||||
-rw-r--r-- | Master/texmf-dist/tex/fontinst/latinmtx/lsbuild.mtx | 12 | ||||
-rw-r--r-- | Master/texmf-dist/tex/fontinst/latinmtx/lsfake.mtx | 74 | ||||
-rw-r--r-- | Master/texmf-dist/tex/fontinst/latinmtx/ltcmds.mtx | 5 | ||||
-rw-r--r-- | Master/texmf-dist/tex/fontinst/latinmtx/lubuild.mtx | 10 | ||||
-rw-r--r-- | Master/texmf-dist/tex/fontinst/smbletx/ts1.etx | 6 | ||||
-rw-r--r-- | Master/texmf-dist/tex/fontinst/smblmtx/textcomp.mtx | 6 |
12 files changed, 954 insertions, 197 deletions
diff --git a/Master/texmf-dist/tex/fontinst/base/cfntinst.sty b/Master/texmf-dist/tex/fontinst/base/cfntinst.sty index ec2ee057ba1..033e21175d7 100644 --- a/Master/texmf-dist/tex/fontinst/base/cfntinst.sty +++ b/Master/texmf-dist/tex/fontinst/base/cfntinst.sty @@ -7,6 +7,7 @@ %% fibasics.dtx (with options: `pkg') %% ficommon.dtx (with options: `pkg') %% fimain.dtx (with options: `pkg,boundaryCompability') +%% fitrig.dtx (with options: `pkg') %% ficonv.dtx (with options: `pkg') %% filtfam.dtx (with options: `pkg,textcomp,debug') %% fimapgen.dtx (with options: `pkg') @@ -32,13 +33,13 @@ \catcode`\}=2 \catcode`\#=6 \catcode`\^=7 -\def\fontinstversion{1.929} +\def\fontinstversion{1.933} \ifx\ProvidesPackage\undefined \def\NeedsTeXFormat#1{} \def\ProvidesPackage#1[#2]{} \fi \ProvidesPackage{fontinst} -[2005/02/05 v\fontinstversion\space +[2007/01/23 v\fontinstversion\space fontinst installation package] \def\a_macro#1{\catcode\number`#1=\the\catcode`#1 } \edef\normalcc{% @@ -82,9 +83,6 @@ \mathchardef\max_mathchardef="7FFF \mathchardef\two_thousand=2000 \newdimen\half_point \half_point=0.5pt -\let\@tempdima\a_dimen -\let\@tempdimb\b_dimen -\input trig.sty \def\x_cs#1#2{\expandafter#1\csname#2\endcsname} \let\x_relax=\relax \def\g_let{\global\let} @@ -1190,12 +1188,17 @@ \moveup{#3} \glyph{\glyph_name_modifier{#1}}{\one_thousand} \pop + \else\ifisglyph{\glyph_name_modifier{#1}-not}\then + \fontinstwarning{\string\glyphpcc}{ + Base~glyph~`\glyph_name_modifier{#1}'~not~appended,\messagebreak + because~it~is~so~far~unencoded~in~the~glyph~base + } \else \fontinsterror{\string\glyphpcc}{ - Base~glyph~not~set.\messagebreak - This~could~be~a~sign~that~the~AFM~file~is~buggy + Base~glyph~not~set.\messagebreak + This~could~be~a~sign~that~the~AFM~file~is~buggy }\error_help_a - \fi + \fi\fi } \def\glyphbboxright{\max\glyph_width\glyph_maxhpos} \def\samesize#1{ @@ -1992,14 +1995,18 @@ \fi \fi } -\def\substitutesilent#1#2{ - \x_cs\def{sub-#2}{#1} - \x_cs\def{typ-#2}{ssub} -} -\def\substitutenoisy#1#2{ - \x_cs\def{sub-#2}{#1} - \x_cs\def{typ-#2}{sub} +\def\substitute_generic#1#2#3{ + \edef\a_macro{#2} + \edef\b_macro{#3} + \ifx \a_macro \b_macro + \x_cs\let{sub-#3}\undefined_command + \else + \x_cs\let{sub-#3}\a_macro + \x_cs\def{typ-#3}{#1} + \fi } +\def\substitutesilent{\substitute_generic{ssub}} +\def\substitutenoisy{\substitute_generic{sub}} \substitutesilent{bx}{b} \substitutesilent{b}{bx} \substitutesilent{b}{sb} @@ -2064,6 +2071,89 @@ \out_line{\percent_char~Created~whilst~debugging~fontinst.} \close_out{Test~file} } +%%% From file: fitrig.dtx +\chardef\nin@ty=90 +\chardef\@clxxx=180 +\chardef\@lxxi=71 +\mathchardef\@mmmmlxviii=4068 +\chardef\@coeffz=72 +\chardef\@coefb=42 +\mathchardef\@coefc=840 +\mathchardef\@coefd=5040 +\def\TG@rem@pt#1{\expandafter\lose_measure\the#1\space} +\def\TG@term#1{ + \dimen@\@tempb\dimen@ + \advance\dimen@ #1\p@ +} +\def\TG@series{ + \dimen@\@lxxi\dimen@ + \divide \dimen@ \@mmmmlxviii + \edef\@tempa{\TG@rem@pt\dimen@} + \dimen@\@tempa\dimen@ + \edef\@tempb{\TG@rem@pt\dimen@} + \divide\dimen@\@coeffz + \advance\dimen@\m@ne\p@ + \TG@term\@coefb + \TG@term{-\@coefc}% + \TG@term\@coefd + \dimen@\@tempa\dimen@ + \divide\dimen@ \@coefd +} +\def\CalculateSin#1{{% + \if_undefined{sin(\number#1)}\then + \dimen@=#1\p@ + \TG@@sin + \x_cs\xdef{sin(\number#1)}{\TG@rem@pt\dimen@} + \fi +}} +\def\CalculateCos#1{{% + \if_undefined{cos(\number#1)}\then + \dimen@=\nin@ty\p@ + \advance \dimen@ -#1\p@ + \TG@@sin + \x_cs\xdef{cos(\number#1)}{\TG@rem@pt\dimen@} + \fi +}} +\def\TG@@sin{% + \ifdim\TG@reduce>+% + \else\ifdim\TG@reduce<-% + \else\TG@series\fi\fi +} +\def\TG@reduce#1#2{ + \dimen@#1#2\nin@ty\p@ + \advance\dimen@#2-\@clxxx\p@ + \dimen@-\dimen@ + \TG@@sin +} +\def\UseSin#1{\csname sin(\number#1)\endcsname} +\def\UseCos#1{\csname cos(\number#1)\endcsname} +\chardef\z@num\z@ +\x_cs\let{sin(0)} \z@num +\x_cs\let{cos(0)} \@ne +\x_cs\let{sin(90)} \@ne +\x_cs\let{cos(90)} \z@num +\x_cs\let{sin(-90)}\m@ne +\x_cs\let{cos(-90)}\z@num +\x_cs\let{sin(180)}\z@num +\x_cs\let{cos(180)}\m@ne +\def\CalculateTan#1{{% + \if_undefined{tan(\number#1)}\then + \CalculateSin{#1}% + \CalculateCos{#1}% + \a_dimen\UseCos{#1}\p@ + \divide \a_dimen \@iv + \b_dimen\UseSin{#1}\p@ + \b_dimen\two@fourteen\b_dimen + \divide\b_dimen\a_dimen + \x_cs\xdef{tan(\number#1)}{\TG@rem@pt\b_dimen} + \fi +}} +\def\UseTan#1{\csname tan(\number#1)\endcsname} +\mathchardef\two@fourteen=16384 +\chardef\@iv=4 +\x_cs\def{tan(90)}{\errmessage{Infinite tan !}} +\expandafter\let + \csname tan(-90)\expandafter\endcsname \csname tan(90)\endcsname %%% From file: ficonv.dtx \def\afmtomtx#1#2{{ \let\setsomething_global=\x_relax @@ -2117,8 +2207,9 @@ \def\afm_command#1~{\csname~afm-#1\endcsname\gobble_one_line} \def\gobble_one_line#1\end_of_line{} \x_cs\def{afm-EndFontMetrics}#1\afm_line{\endinput} -\def\afm_def#1(#2)#3{\x_cs\def{afm-#1} - \gobble_one_line#2\end_of_line{#3}} +\def\afm_def#1(#2)#3{ + \x_cs\def{afm-#1}\gobble_one_line#2\end_of_line{#3} +} \def\afm_let#1#2{ \expandafter\let \csname afm-#1\expandafter\endcsname \csname afm-#2\endcsname @@ -2162,15 +2253,16 @@ \if\first_char#2=.\else \afm_length\a_count{#3} \ifnum \a_count>\minimum_kern - \out_line{\string\setkern{#1}{#2}{\the\a_count}} + \afm_write_setkern{#1}{#2}{\the\a_count} \else\ifnum \a_count<-\minimum_kern - \out_line{\string\setkern{#1}{#2}{\the\a_count}} + \afm_write_setkern{#1}{#2}{\the\a_count} \fi\fi \fi\fi } \afm_let{KPX}{KP} +\def\afm_write_setkern#1#2#3{\out_line{\string\setkern{#1}{#2}{#3}}} \afm_def{C}(#1~;#2){\init_afm{#1}\do_list[#2]\afm_char} -\afm_let{CH}{C} +\afm_def{CH}(<#1>~;#2){\uppercase{\init_afm{"#1}}\do_list[#2]\afm_char} \afm_def{CC}(#1~#2~;#3){\init_cc{#1}\do_list[#3]\cc_char} \newcount\char_slot \newcount\char_x_width @@ -2190,7 +2282,6 @@ \let\char_name=\empty_command } \def\afm_char{ - \a_count=-\bbox_lly \eval_expr{ \italcorr_expression\x_width\bbox_llx\bbox_urx\bbox_lly\bbox_ury } @@ -2206,7 +2297,7 @@ {\the\char_slot} {\the\x_width} {\the\bbox_ury} - {\the\a_count} + {\number -\bbox_lly} {\the\result} } } @@ -2257,6 +2348,76 @@ \afm_length\b_count{#3} \out_lline{\string\glyphpcc{#1}{\the\a_count}{\the\b_count}} } +\def\definealias#1#2#3{ + \expandafter\def \csname GN-#1 \expandafter\endcsname + \expandafter{ \csname g-#2 \expandafter\endcsname + \csname i-#3\endcsname} +} +\def\glyph_alias#1{ + \expandafter\expandafter \expandafter\glyph_alias_i + \csname GN-#1\endcsname +} +\def\glyph_alias_i#1#2{ + \expandafter\gobble_three \string#1 +} +\let\charnameprefix\empty +\def\charnamealias#1{ + \if_defined{GN-\charnameprefix#1}\then + \glyph_alias{\charnameprefix#1} + \else\if_defined{GN-#1}\then + \glyph_alias{#1} + \else + #1 + \fi\fi +} +\def\alias_incr#1{ + \expandafter\expandafter \expandafter\alias_incr_i + \csname GN-#1\endcsname +} +\def\alias_incr_i#1#2{ + \ifx#2\x_relax + \mathchardef#2=\@ne + \else + \a_count=#2 + \advance\a_count\@ne + \mathchardef#2=\a_count + \fi +} +\def\alias_char_name#1{ + \if_defined{GN-\charnameprefix#1}\then + \edef\char_name{ + \string\aliased{#1}{\glyph_alias{\charnameprefix#1}} + } + \alias_incr{\charnameprefix#1} + \else\if_defined{GN-#1}\then + \edef\char_name{ + \string\aliased{#1}{\glyph_alias{#1}} + } + \alias_incr{#1} + \else + \edef\char_name{#1} + \fi\fi +} +\def\autoaliasafm{ + \begingroup + \list_def{N}(##1){\alias_char_name{##1}} + \def\afm_write_setkern##1##2##3{ + \out_line{ + \string\setkern{\charnamealias{##1}}{\charnamealias{##2}}{##3} + } + } + \def\init_cc##1{% + \edef\char_name{\charnamealias{##1}} + \out_line{\string\setglyph{\char_name}} + } + \list_def{PCC}(##1~##2~##3){ + \afm_length\a_count{##2} + \afm_length\b_count{##3} + \out_lline{\string\glyphpcc + {\charnamealias{##1}}{\the\a_count}{\the\b_count}} + } +} +\def\endautoaliasafm{\endgroup} \def\generalpltomtx#1#2#3#4{{ \let\setsomething_global=\x_relax \let\setfontdimen=\pl_setfontdimen @@ -2645,14 +2806,7 @@ \resetstr{etx-name}{#1} } \def\mtxtomtx#1#2{{ - \ifisstr{etx-name}\then - \def\do_slot{\x_cs\edef{slots-\slot_name}{\the\slot_number}} - \directfalse - \inputetx{\str{etx-name}} - \edef\a_macro{\string\reencodefont{\str{etx-name}}} - \else - \let\a_macro=\empty_command - \fi + \let\a_macro=\empty_command \_a_true \ifnum \int{x-scale}=\int{y-scale} \ifnum \int{slant-scale}=\z@ @@ -2682,6 +2836,20 @@ \out_line{} \out_line{\string\needsfontinstversion{\fontinstversion}} \out_line{} + \ifisstr{etx-name}\then + \def\do_slot{\x_cs\edef{slots-\slot_name}{\the\slot_number}} + \def\declarepsencoding##1##2##3{ + \a_toks={{##1}{##2}{##3}} + \out_line{\string\providepsencoding\the\a_toks} + \ifnum \transform_record_file=\closed_stream \else + \pout_line\transform_record_file + {\string\providepsencoding\the\a_toks} + \fi + } + \directfalse + \inputetx{\str{etx-name}} + \edef\a_macro{\a_macro\string\reencodefont{\str{etx-name}}} + \fi \record_transform{#2}{\string\frommtx{#1}}{\a_macro}\iftrue \out_line{} \mtxtomtx_redefinitions @@ -3494,6 +3662,8 @@ \pout_line\transform_record_file{\string\makemapentry{#1}} \fi } +\let\declarepsencoding=\gobble_three +\let\providepsencoding=\gobble_three %%% From file: fibasics.dtx \def\needsfontinstversion#1{{ \a_dimen=#1pt diff --git a/Master/texmf-dist/tex/fontinst/base/finstmsc.sty b/Master/texmf-dist/tex/fontinst/base/finstmsc.sty index 170464cd0e9..d2fd613cef0 100644 --- a/Master/texmf-dist/tex/fontinst/base/finstmsc.sty +++ b/Master/texmf-dist/tex/fontinst/base/finstmsc.sty @@ -31,13 +31,13 @@ \catcode`\}=2 \catcode`\#=6 \catcode`\^=7 -\def\fontinstversion{1.929} +\def\fontinstversion{1.933} \ifx\ProvidesPackage\undefined \def\NeedsTeXFormat#1{} \def\ProvidesPackage#1[#2]{} \fi \ProvidesPackage{fontinst} -[2005/02/05 v\fontinstversion\space +[2007/01/23 v\fontinstversion\space fontinst installation package] \def\a_macro#1{\catcode\number`#1=\the\catcode`#1 } \edef\normalcc{% @@ -81,9 +81,6 @@ \mathchardef\max_mathchardef="7FFF \mathchardef\two_thousand=2000 \newdimen\half_point \half_point=0.5pt -\let\@tempdima\a_dimen -\let\@tempdimb\b_dimen -\input trig.sty \def\x_cs#1#2{\expandafter#1\csname#2\endcsname} \let\x_relax=\relax \def\g_let{\global\let} @@ -806,25 +803,33 @@ \catcode`\/=\active \catcode`\]=\active \def/##1[{ + \encname_to_etx ##1~{#1}{#2} \a_count=0 \global\missingslotsfalse - \def/####1~{ - \csname~o-####1\endcsname{ - \ifmissingslots - \out_line{\string\nextslot{\the\a_count}} - \fi - \global\missingslotsfalse - \out_line{\string\setslot{####1}} - \out_line{\string\endsetslot} - \out_line{} - } - \advance\a_count by 1 - } + \let/=\encslot_to_etx } \def]~def{} \make_etx{#1}{#2} }} } +\def\encname_to_etx#1~#2#3{ + \out_line{\percent_char\space REMOVE~THE~FOLLOWING~LINE~IF~ + THIS~FILE~IS~MODIFIED~OR~RENAMED.} + \out_line{\string\declarepsencoding{#3}{#1}{\string\download{#2.enc}}} + \out_line{} +} +\def\encslot_to_etx#1~{ + \csname o-#1\endcsname{ + \ifmissingslots + \out_line{\string\nextslot{\the\a_count}} + \fi + \global\missingslotsfalse + \out_line{\string\setslot{#1}} + \out_line{\string\endsetslot} + \out_line{} + } + \advance\a_count by 1 +} \def\make_etx#1#2{ \open_out{\temp_prefix#2.etx} \out_line{\percent_char~Filename:~#2.etx} @@ -841,13 +846,13 @@ \out_line{\string\relax} \out_line{} \out_line{\string\documentclass[twocolumn]{article}} - \out_line{\string\usepackage{fontdoc}} + \out_line{\string\usepackage{fontdoc}[2005/05/13]} \out_line{} \out_line{\string\begin{document}} \out_line{} \out_line{This~document~describes~the~#1~encoding.} \out_line{It~was~automatically~generated~by~the} - \out_line{{\string\tt\space~fontinst}~package.} + \out_line{\string\texttt{fontinst}~package.} \out_line{} \out_line{\string\encoding} \out_line{} @@ -858,7 +863,7 @@ \out_line{\string\end encoding} \out_line{} \out_line{\string\end{document}} - \close_out{Encoding~vector} + \close_out{Encoding} } \def\notdef_name{.notdef} \def\etxtoenc#1#2{\begingroup @@ -1231,9 +1236,15 @@ Check~the~output~file(s)--some~data~was~considered~uncertain} } \def\declarepsencoding#1#2#3{\x_cs\gdef{pse-#1}{{#2}{#3}}} +\def\providepsencoding#1#2#3{ + \if_undefined{pse-#1}\then + \declarepsencoding{#1}{#2}{#3} + \fi +} \let\download=\gobble_one \def\fulldownload#1{\download{#1}} -\declarepsencoding{8r}{TeXBase1Encoding}{\download{8r.enc}} +\def\encodingdownload#1{\download{#1}} +\declarepsencoding{8r}{TeXBase1Encoding}{\encodingdownload{8r.enc}} \declarepsencoding{8a}{StandardEncoding}{} \def\specifypsfont#1#2{\x_cs\def{psf-#1}{#2}} \def\AssumeLWFN{\let\get_PS_font_file\LWFN_get_PS_font_file} @@ -1322,13 +1333,20 @@ \let\debug_values_hook\empty_command \debugvalue{PS_font_name} \newtoks\downloads_list -\def\append_download#1{ - \downloads_list=\expandafter{ \the\downloads_list \download{#1} } +\def\append_download#1#2{ + \edef\a_macro{ + \downloads_list = + \noexpand\expandafter{ \noexpand\the \downloads_list + \noexpand#1 {#2} } + } + \a_macro } \def\make_dvips{ \downloads_list={} \let\postscript_code\empty_command - \let\download\append_download + \def\download{\append_download\download} + \def\fulldownload{\append_download\fulldownload} + \def\encodingdownload{\append_download\encodingdownload} \ifx \reencode_etx\empty_command \else \if_undefined{pse-\reencode_etx}\then \etxtoenc{\reencode_etx}{\reencode_etx} @@ -1366,12 +1384,14 @@ \fi\fi \if_a_ \ifx \PS_font_file\unknown_str \get_PS_font_file \fi - \append_download{\PS_font_file} + \append_download\download{\PS_font_file} \ifx \PS_font_file\clueless_str \includewarning\warn_undecided_data \fi \fi \def\download##1{~<##1} + \def\fulldownload##1{~<<##1} + \def\encodingdownload##1{~<[##1} \pout_line\output_dvips{ \TeX_font_name\space\PS_font_name \expandafter\empty_command \the\downloads_list diff --git a/Master/texmf-dist/tex/fontinst/base/fontinst.sty b/Master/texmf-dist/tex/fontinst/base/fontinst.sty index a15f50fb7c6..c19adcf8386 100644 --- a/Master/texmf-dist/tex/fontinst/base/fontinst.sty +++ b/Master/texmf-dist/tex/fontinst/base/fontinst.sty @@ -7,6 +7,7 @@ %% fibasics.dtx (with options: `pkg') %% ficommon.dtx (with options: `pkg') %% fimain.dtx (with options: `pkg') +%% fitrig.dtx (with options: `pkg') %% ficonv.dtx (with options: `pkg') %% filtfam.dtx (with options: `pkg,textcomp,debug') %% fimapgen.dtx (with options: `pkg') @@ -32,13 +33,13 @@ \catcode`\}=2 \catcode`\#=6 \catcode`\^=7 -\def\fontinstversion{1.929} +\def\fontinstversion{1.933} \ifx\ProvidesPackage\undefined \def\NeedsTeXFormat#1{} \def\ProvidesPackage#1[#2]{} \fi \ProvidesPackage{fontinst} -[2005/02/05 v\fontinstversion\space +[2007/01/23 v\fontinstversion\space fontinst installation package] \def\a_macro#1{\catcode\number`#1=\the\catcode`#1 } \edef\normalcc{% @@ -82,9 +83,6 @@ \mathchardef\max_mathchardef="7FFF \mathchardef\two_thousand=2000 \newdimen\half_point \half_point=0.5pt -\let\@tempdima\a_dimen -\let\@tempdimb\b_dimen -\input trig.sty \def\x_cs#1#2{\expandafter#1\csname#2\endcsname} \let\x_relax=\relax \def\g_let{\global\let} @@ -1190,12 +1188,17 @@ \moveup{#3} \glyph{\glyph_name_modifier{#1}}{\one_thousand} \pop + \else\ifisglyph{\glyph_name_modifier{#1}-not}\then + \fontinstwarning{\string\glyphpcc}{ + Base~glyph~`\glyph_name_modifier{#1}'~not~appended,\messagebreak + because~it~is~so~far~unencoded~in~the~glyph~base + } \else \fontinsterror{\string\glyphpcc}{ - Base~glyph~not~set.\messagebreak - This~could~be~a~sign~that~the~AFM~file~is~buggy + Base~glyph~not~set.\messagebreak + This~could~be~a~sign~that~the~AFM~file~is~buggy }\error_help_a - \fi + \fi\fi } \def\glyphbboxright{\max\glyph_width\glyph_maxhpos} \def\samesize#1{ @@ -1980,14 +1983,18 @@ \fi \fi } -\def\substitutesilent#1#2{ - \x_cs\def{sub-#2}{#1} - \x_cs\def{typ-#2}{ssub} -} -\def\substitutenoisy#1#2{ - \x_cs\def{sub-#2}{#1} - \x_cs\def{typ-#2}{sub} +\def\substitute_generic#1#2#3{ + \edef\a_macro{#2} + \edef\b_macro{#3} + \ifx \a_macro \b_macro + \x_cs\let{sub-#3}\undefined_command + \else + \x_cs\let{sub-#3}\a_macro + \x_cs\def{typ-#3}{#1} + \fi } +\def\substitutesilent{\substitute_generic{ssub}} +\def\substitutenoisy{\substitute_generic{sub}} \substitutesilent{bx}{b} \substitutesilent{b}{bx} \substitutesilent{b}{sb} @@ -2052,6 +2059,89 @@ \out_line{\percent_char~Created~whilst~debugging~fontinst.} \close_out{Test~file} } +%%% From file: fitrig.dtx +\chardef\nin@ty=90 +\chardef\@clxxx=180 +\chardef\@lxxi=71 +\mathchardef\@mmmmlxviii=4068 +\chardef\@coeffz=72 +\chardef\@coefb=42 +\mathchardef\@coefc=840 +\mathchardef\@coefd=5040 +\def\TG@rem@pt#1{\expandafter\lose_measure\the#1\space} +\def\TG@term#1{ + \dimen@\@tempb\dimen@ + \advance\dimen@ #1\p@ +} +\def\TG@series{ + \dimen@\@lxxi\dimen@ + \divide \dimen@ \@mmmmlxviii + \edef\@tempa{\TG@rem@pt\dimen@} + \dimen@\@tempa\dimen@ + \edef\@tempb{\TG@rem@pt\dimen@} + \divide\dimen@\@coeffz + \advance\dimen@\m@ne\p@ + \TG@term\@coefb + \TG@term{-\@coefc}% + \TG@term\@coefd + \dimen@\@tempa\dimen@ + \divide\dimen@ \@coefd +} +\def\CalculateSin#1{{% + \if_undefined{sin(\number#1)}\then + \dimen@=#1\p@ + \TG@@sin + \x_cs\xdef{sin(\number#1)}{\TG@rem@pt\dimen@} + \fi +}} +\def\CalculateCos#1{{% + \if_undefined{cos(\number#1)}\then + \dimen@=\nin@ty\p@ + \advance \dimen@ -#1\p@ + \TG@@sin + \x_cs\xdef{cos(\number#1)}{\TG@rem@pt\dimen@} + \fi +}} +\def\TG@@sin{% + \ifdim\TG@reduce>+% + \else\ifdim\TG@reduce<-% + \else\TG@series\fi\fi +} +\def\TG@reduce#1#2{ + \dimen@#1#2\nin@ty\p@ + \advance\dimen@#2-\@clxxx\p@ + \dimen@-\dimen@ + \TG@@sin +} +\def\UseSin#1{\csname sin(\number#1)\endcsname} +\def\UseCos#1{\csname cos(\number#1)\endcsname} +\chardef\z@num\z@ +\x_cs\let{sin(0)} \z@num +\x_cs\let{cos(0)} \@ne +\x_cs\let{sin(90)} \@ne +\x_cs\let{cos(90)} \z@num +\x_cs\let{sin(-90)}\m@ne +\x_cs\let{cos(-90)}\z@num +\x_cs\let{sin(180)}\z@num +\x_cs\let{cos(180)}\m@ne +\def\CalculateTan#1{{% + \if_undefined{tan(\number#1)}\then + \CalculateSin{#1}% + \CalculateCos{#1}% + \a_dimen\UseCos{#1}\p@ + \divide \a_dimen \@iv + \b_dimen\UseSin{#1}\p@ + \b_dimen\two@fourteen\b_dimen + \divide\b_dimen\a_dimen + \x_cs\xdef{tan(\number#1)}{\TG@rem@pt\b_dimen} + \fi +}} +\def\UseTan#1{\csname tan(\number#1)\endcsname} +\mathchardef\two@fourteen=16384 +\chardef\@iv=4 +\x_cs\def{tan(90)}{\errmessage{Infinite tan !}} +\expandafter\let + \csname tan(-90)\expandafter\endcsname \csname tan(90)\endcsname %%% From file: ficonv.dtx \def\afmtomtx#1#2{{ \let\setsomething_global=\x_relax @@ -2105,8 +2195,9 @@ \def\afm_command#1~{\csname~afm-#1\endcsname\gobble_one_line} \def\gobble_one_line#1\end_of_line{} \x_cs\def{afm-EndFontMetrics}#1\afm_line{\endinput} -\def\afm_def#1(#2)#3{\x_cs\def{afm-#1} - \gobble_one_line#2\end_of_line{#3}} +\def\afm_def#1(#2)#3{ + \x_cs\def{afm-#1}\gobble_one_line#2\end_of_line{#3} +} \def\afm_let#1#2{ \expandafter\let \csname afm-#1\expandafter\endcsname \csname afm-#2\endcsname @@ -2150,15 +2241,16 @@ \if\first_char#2=.\else \afm_length\a_count{#3} \ifnum \a_count>\minimum_kern - \out_line{\string\setkern{#1}{#2}{\the\a_count}} + \afm_write_setkern{#1}{#2}{\the\a_count} \else\ifnum \a_count<-\minimum_kern - \out_line{\string\setkern{#1}{#2}{\the\a_count}} + \afm_write_setkern{#1}{#2}{\the\a_count} \fi\fi \fi\fi } \afm_let{KPX}{KP} +\def\afm_write_setkern#1#2#3{\out_line{\string\setkern{#1}{#2}{#3}}} \afm_def{C}(#1~;#2){\init_afm{#1}\do_list[#2]\afm_char} -\afm_let{CH}{C} +\afm_def{CH}(<#1>~;#2){\uppercase{\init_afm{"#1}}\do_list[#2]\afm_char} \afm_def{CC}(#1~#2~;#3){\init_cc{#1}\do_list[#3]\cc_char} \newcount\char_slot \newcount\char_x_width @@ -2178,7 +2270,6 @@ \let\char_name=\empty_command } \def\afm_char{ - \a_count=-\bbox_lly \eval_expr{ \italcorr_expression\x_width\bbox_llx\bbox_urx\bbox_lly\bbox_ury } @@ -2194,7 +2285,7 @@ {\the\char_slot} {\the\x_width} {\the\bbox_ury} - {\the\a_count} + {\number -\bbox_lly} {\the\result} } } @@ -2245,6 +2336,76 @@ \afm_length\b_count{#3} \out_lline{\string\glyphpcc{#1}{\the\a_count}{\the\b_count}} } +\def\definealias#1#2#3{ + \expandafter\def \csname GN-#1 \expandafter\endcsname + \expandafter{ \csname g-#2 \expandafter\endcsname + \csname i-#3\endcsname} +} +\def\glyph_alias#1{ + \expandafter\expandafter \expandafter\glyph_alias_i + \csname GN-#1\endcsname +} +\def\glyph_alias_i#1#2{ + \expandafter\gobble_three \string#1 +} +\let\charnameprefix\empty +\def\charnamealias#1{ + \if_defined{GN-\charnameprefix#1}\then + \glyph_alias{\charnameprefix#1} + \else\if_defined{GN-#1}\then + \glyph_alias{#1} + \else + #1 + \fi\fi +} +\def\alias_incr#1{ + \expandafter\expandafter \expandafter\alias_incr_i + \csname GN-#1\endcsname +} +\def\alias_incr_i#1#2{ + \ifx#2\x_relax + \mathchardef#2=\@ne + \else + \a_count=#2 + \advance\a_count\@ne + \mathchardef#2=\a_count + \fi +} +\def\alias_char_name#1{ + \if_defined{GN-\charnameprefix#1}\then + \edef\char_name{ + \string\aliased{#1}{\glyph_alias{\charnameprefix#1}} + } + \alias_incr{\charnameprefix#1} + \else\if_defined{GN-#1}\then + \edef\char_name{ + \string\aliased{#1}{\glyph_alias{#1}} + } + \alias_incr{#1} + \else + \edef\char_name{#1} + \fi\fi +} +\def\autoaliasafm{ + \begingroup + \list_def{N}(##1){\alias_char_name{##1}} + \def\afm_write_setkern##1##2##3{ + \out_line{ + \string\setkern{\charnamealias{##1}}{\charnamealias{##2}}{##3} + } + } + \def\init_cc##1{% + \edef\char_name{\charnamealias{##1}} + \out_line{\string\setglyph{\char_name}} + } + \list_def{PCC}(##1~##2~##3){ + \afm_length\a_count{##2} + \afm_length\b_count{##3} + \out_lline{\string\glyphpcc + {\charnamealias{##1}}{\the\a_count}{\the\b_count}} + } +} +\def\endautoaliasafm{\endgroup} \def\generalpltomtx#1#2#3#4{{ \let\setsomething_global=\x_relax \let\setfontdimen=\pl_setfontdimen @@ -2633,14 +2794,7 @@ \resetstr{etx-name}{#1} } \def\mtxtomtx#1#2{{ - \ifisstr{etx-name}\then - \def\do_slot{\x_cs\edef{slots-\slot_name}{\the\slot_number}} - \directfalse - \inputetx{\str{etx-name}} - \edef\a_macro{\string\reencodefont{\str{etx-name}}} - \else - \let\a_macro=\empty_command - \fi + \let\a_macro=\empty_command \_a_true \ifnum \int{x-scale}=\int{y-scale} \ifnum \int{slant-scale}=\z@ @@ -2670,6 +2824,20 @@ \out_line{} \out_line{\string\needsfontinstversion{\fontinstversion}} \out_line{} + \ifisstr{etx-name}\then + \def\do_slot{\x_cs\edef{slots-\slot_name}{\the\slot_number}} + \def\declarepsencoding##1##2##3{ + \a_toks={{##1}{##2}{##3}} + \out_line{\string\providepsencoding\the\a_toks} + \ifnum \transform_record_file=\closed_stream \else + \pout_line\transform_record_file + {\string\providepsencoding\the\a_toks} + \fi + } + \directfalse + \inputetx{\str{etx-name}} + \edef\a_macro{\a_macro\string\reencodefont{\str{etx-name}}} + \fi \record_transform{#2}{\string\frommtx{#1}}{\a_macro}\iftrue \out_line{} \mtxtomtx_redefinitions @@ -3482,6 +3650,8 @@ \pout_line\transform_record_file{\string\makemapentry{#1}} \fi } +\let\declarepsencoding=\gobble_three +\let\providepsencoding=\gobble_three %%% From file: fibasics.dtx \def\needsfontinstversion#1{{ \a_dimen=#1pt diff --git a/Master/texmf-dist/tex/fontinst/base/multislot.sty b/Master/texmf-dist/tex/fontinst/base/multislot.sty new file mode 100644 index 00000000000..fac72144059 --- /dev/null +++ b/Master/texmf-dist/tex/fontinst/base/multislot.sty @@ -0,0 +1,234 @@ +% multislot.sty +% +% Second version + + +\needsfontinstversion{1.900} +% Relies heavily on _etx_pass_hook commands. + + +%%%%%%%%%%%%%%% RESOURCES USED %%%%%%%%%%%%%%% +% +% The following classes of control sequences are used by the multislot +% routines, in addition to the ones defined below and the ones fontinst +% normally uses: +% +% \name-NUM +% +% where NUM is a number consisting of one, two, or three decimal digits. +% These are also used by \pltomtx, so they probably already exist as +% hash table entries. + + + +%%%%%%%%%%%%%%% SAVE CATCODES %%%%%%%%%%%%%%% +% +% Save the current values of the catcodes of space, @, NL, ~ and _. +% _ and @ are made letters, ~ is a space, and space and NL are ignored. + +\edef\spacecatcode{\the\catcode`\ } +\edef\atcatcode{\the\catcode`\@} +\edef\nlcatcode{\the\catcode`\^^M} +\edef\underscorecatcode{\the\catcode`\_} +\edef\tildecatcode{\the\catcode`\~} + +\catcode`\ =9 +\catcode`\^^M=9 +\catcode`\@=11 +\catcode`\_=11 +\catcode`\~=10 + + +%%%%%%%%%%%%%%% MULTIPLE SLOT COMMANDS %%%%%%%%%%%%%%% +% +% The user-level commands are quite simple. As usual, you can write +% +% \setslot{NAME} +% <slot commands> +% \endsetslot +% +% to assign a glyph to a slot. The difference is that if there are +% multiple \setslot commands for a slot, this will no longer cause +% strange results. Instead, only the first \setslot-\endsetslot pair +% for each slot will be used, the others are ignored. +% +% If you instead write +% +% \resetslot{NAME} +% <slot commands> +% \endsetslot +% +% then this will override any earlier occurences of \setslot or +% \resetslot. Finally, there is the command +% +% \unsetslot{NUMBER} +% +% which makes fontinst forget any earlier occurences of \setslot +% or \resetslot commands for that particular slot. + + +% The way this works is that every \setslot or \resetslot command is +% implicitly assigned an index, namely the number of such commands +% perviously encountered since the start of the ETX pass. The count +% register \slot_index is allocated to keep track of the current +% index: + +\newcount\slot_index +\def\clear_slot_index{\slot_index=\m@ne} +\add_to\pre_first_etx_pass_hook{\clear_slot_index} +\add_to\pre_second_etx_pass_hook{\clear_slot_index} +\add_to\pre_third_etx_pass_hook{\clear_slot_index} +\add_to\pre_fourth_etx_pass_hook{\clear_slot_index} + +% \setslot, \setleftboundary, and \setrightboundary increments the +% counter just before checking it. + + + +% The point of maintaining the index is that the index of the +% \setslot (or whatever) that actually sets a particular slot gets +% stored in the \name-SLOT control sequence (which is \mathchardef'ed +% to the index). After assignments are made, all a \setslot (or +% whatever) needs to do is to check whether the stored index matches +% the current one, and gobble itself if they don't. + +% The basic check is performed by the command \later_index_check. +% This has the syntax +% +% \later_index_check{SLOT}{<else-code>} +% +% and expands to nothing if this \setslot will be active, but to +% <else-code> if it will not. +\def\later_index_check#1{ + \x_cs\ifnum {name-#1}=\slot_index + \expandafter\gobble_one + \else + \expandafter\identity_one + \fi +} +% However, when deciding which \setslots will be active, the condition +% to test is slightly different: is the control sequence in question +% already defined to be a mathchar token? If it isn't, then this will +% be the active \setslot. +\def\setslot_index_check#1{\x_cs\setslot_index_check_i{name-#1}} +\def\temp_command#1{ + \def\setslot_index_check_ii##1#1##2\setslot_index_check_ii{##1} + \def\setslot_index_check_i##1{ + \expandafter\setslot_index_check_ii \expandafter\ifx + \expandafter$ \meaning##1 #1 0 \setslot_index_check_ii $ + \expandafter\identity_one + \else + \mathchardef##1=\slot_index + \expandafter\gobble_one + \fi + } +} +\expandafter\temp_command \expandafter{ \string\mathchar " } + +% The stated definition of \setslot_index_check should thus be in +% force during the first etx pass, but after that the +% \later_index_check definition should rule. +\add_to\post_first_etx_pass_hook{ + \let\setslot_index_check=\later_index_check +} + +% The following is used to ignore a \setslot--\endsetslot or +% \setleftboundary--\endsetleftboundary construction; the argument is +% the command which marks the end. The reason not to use +% \gobble_setslot is that it still executes \end_do_slot, which is +% quite wrong for the kind of ignoring done here. +\def\ignore_to_end#1{ + \bgroup + \let#1=\fi + \expandafter + \egroup + \iffalse +} + + +% The \setslot, \setleftboundary, and \setrightboundary commands must +% be equipped with checks at the start. +\def\checked_setslot{ + \advance \slot_index \@ne + \setslot_index_check{\the\slot_number}{ + \advance \slot_number \@ne + \ignore_to_end\endsetslot + } + \unchecked_setslot +} + +\def\checked_setleftboundary{ + \advance \slot_index \@ne + \setslot_index_check{leftboundary}{\ignore_to_end\endsetleftboundary} + \unchecked_setleftboundary +} + +\def\checked_setrightboundary#1{ + \advance \slot_index \@ne + \setslot_index_check{\the\slot_number}{ + \advance \slot_number \@ne + \gobble_two + } + \unchecked_setrightboundary{#1} +} +\add_to\pre_first_etx_pass_hook{ + \let\unchecked_setslot=\setslot + \let\setslot=\checked_setslot + \let\unchecked_setleftboundary=\setleftboundary + \let\setleftboundary=\checked_setleftboundary + \let\unchecked_setrightboundary=\setrightboundary + \let\setrightboundary=\checked_setrightboundary +} +% But that's it, as far as the \set... commands are concerned. + + +% What about \unsetslot? In principle, it _should_ just be a matter of +\def\unsetslot#1{ + \eval_expr{#1} + \x_cs\let{name-\the\result}\undefined_command +} +\add_to\post_first_etx_pass_hook{\let\unsetslot=\gobble_one} +% given which \resetslot is simply +\def\resetslot{\unsetslot\slot_number \setslot} +% and this sort-of works, but not quite. +% +% The problem is that the ordinary slot assignment table, which is +% used for ligature and kerning instructions, is not updated by +% \unsetslot. Hence ligatures and kerns will be generated as if all +% glyphs that have been set for a slot are present there; after +% +% \nextslot{108} +% \setslot{l} \endsetslot +% +% \nextslot{108} +% \resetslot{lambda} \endsetslot +% +% the effect will be as if one had given the command +% +% \setleftkerning{lambda}{l}{1000} +% +% and moreover the same happens for ligatures, so an f + l -> fl +% ligature will also work as an f + lambda -> fl ligature. +% +% This is of course a BUG, and there doesn't seem to be any way +% around it, short of adding another pass of reading ETX files. Doing +% so would probably not be worth the effort, since the usefulness of +% a \resetslot command is not clear; unlike \resetglyph, it cannot be +% used to amend an existing \set..., but only to override it. + + + +%%%%%%%%%%%%%%% RESTORE CATCODES %%%%%%%%%%%%%%% +% +% Restore the catcodes that were changed. + +\catcode`\@=\atcatcode +\catcode`\^^M=\nlcatcode +\catcode`\ =\spacecatcode +\catcode`\~=\tildecatcode +\catcode`\_=\underscorecatcode + +%%%%%%%%%%%%%%% THE END %%%%%%%%%%%%%%% + +\endinput + diff --git a/Master/texmf-dist/tex/fontinst/base/xfntinst.sty b/Master/texmf-dist/tex/fontinst/base/xfntinst.sty index c969deab6b3..d13e9746234 100644 --- a/Master/texmf-dist/tex/fontinst/base/xfntinst.sty +++ b/Master/texmf-dist/tex/fontinst/base/xfntinst.sty @@ -7,6 +7,7 @@ %% fibasics.dtx (with options: `pkg') %% ficommon.dtx (with options: `pkg') %% fimain.dtx (with options: `pkg') +%% fitrig.dtx (with options: `pkg') %% ficonv.dtx (with options: `pkg') %% filtfam.dtx (with options: `pkg,textcomp,debug,oldstyle') %% fimapgen.dtx (with options: `pkg') @@ -32,13 +33,13 @@ \catcode`\}=2 \catcode`\#=6 \catcode`\^=7 -\def\fontinstversion{1.929} +\def\fontinstversion{1.933} \ifx\ProvidesPackage\undefined \def\NeedsTeXFormat#1{} \def\ProvidesPackage#1[#2]{} \fi \ProvidesPackage{fontinst} -[2005/02/05 v\fontinstversion\space +[2007/01/23 v\fontinstversion\space fontinst installation package] \def\a_macro#1{\catcode\number`#1=\the\catcode`#1 } \edef\normalcc{% @@ -82,9 +83,6 @@ \mathchardef\max_mathchardef="7FFF \mathchardef\two_thousand=2000 \newdimen\half_point \half_point=0.5pt -\let\@tempdima\a_dimen -\let\@tempdimb\b_dimen -\input trig.sty \def\x_cs#1#2{\expandafter#1\csname#2\endcsname} \let\x_relax=\relax \def\g_let{\global\let} @@ -1190,12 +1188,17 @@ \moveup{#3} \glyph{\glyph_name_modifier{#1}}{\one_thousand} \pop + \else\ifisglyph{\glyph_name_modifier{#1}-not}\then + \fontinstwarning{\string\glyphpcc}{ + Base~glyph~`\glyph_name_modifier{#1}'~not~appended,\messagebreak + because~it~is~so~far~unencoded~in~the~glyph~base + } \else \fontinsterror{\string\glyphpcc}{ - Base~glyph~not~set.\messagebreak - This~could~be~a~sign~that~the~AFM~file~is~buggy + Base~glyph~not~set.\messagebreak + This~could~be~a~sign~that~the~AFM~file~is~buggy }\error_help_a - \fi + \fi\fi } \def\glyphbboxright{\max\glyph_width\glyph_maxhpos} \def\samesize#1{ @@ -1980,14 +1983,18 @@ \fi \fi } -\def\substitutesilent#1#2{ - \x_cs\def{sub-#2}{#1} - \x_cs\def{typ-#2}{ssub} -} -\def\substitutenoisy#1#2{ - \x_cs\def{sub-#2}{#1} - \x_cs\def{typ-#2}{sub} +\def\substitute_generic#1#2#3{ + \edef\a_macro{#2} + \edef\b_macro{#3} + \ifx \a_macro \b_macro + \x_cs\let{sub-#3}\undefined_command + \else + \x_cs\let{sub-#3}\a_macro + \x_cs\def{typ-#3}{#1} + \fi } +\def\substitutesilent{\substitute_generic{ssub}} +\def\substitutenoisy{\substitute_generic{sub}} \substitutesilent{bx}{b} \substitutesilent{b}{bx} \substitutesilent{b}{sb} @@ -2052,6 +2059,89 @@ \out_line{\percent_char~Created~whilst~debugging~fontinst.} \close_out{Test~file} } +%%% From file: fitrig.dtx +\chardef\nin@ty=90 +\chardef\@clxxx=180 +\chardef\@lxxi=71 +\mathchardef\@mmmmlxviii=4068 +\chardef\@coeffz=72 +\chardef\@coefb=42 +\mathchardef\@coefc=840 +\mathchardef\@coefd=5040 +\def\TG@rem@pt#1{\expandafter\lose_measure\the#1\space} +\def\TG@term#1{ + \dimen@\@tempb\dimen@ + \advance\dimen@ #1\p@ +} +\def\TG@series{ + \dimen@\@lxxi\dimen@ + \divide \dimen@ \@mmmmlxviii + \edef\@tempa{\TG@rem@pt\dimen@} + \dimen@\@tempa\dimen@ + \edef\@tempb{\TG@rem@pt\dimen@} + \divide\dimen@\@coeffz + \advance\dimen@\m@ne\p@ + \TG@term\@coefb + \TG@term{-\@coefc}% + \TG@term\@coefd + \dimen@\@tempa\dimen@ + \divide\dimen@ \@coefd +} +\def\CalculateSin#1{{% + \if_undefined{sin(\number#1)}\then + \dimen@=#1\p@ + \TG@@sin + \x_cs\xdef{sin(\number#1)}{\TG@rem@pt\dimen@} + \fi +}} +\def\CalculateCos#1{{% + \if_undefined{cos(\number#1)}\then + \dimen@=\nin@ty\p@ + \advance \dimen@ -#1\p@ + \TG@@sin + \x_cs\xdef{cos(\number#1)}{\TG@rem@pt\dimen@} + \fi +}} +\def\TG@@sin{% + \ifdim\TG@reduce>+% + \else\ifdim\TG@reduce<-% + \else\TG@series\fi\fi +} +\def\TG@reduce#1#2{ + \dimen@#1#2\nin@ty\p@ + \advance\dimen@#2-\@clxxx\p@ + \dimen@-\dimen@ + \TG@@sin +} +\def\UseSin#1{\csname sin(\number#1)\endcsname} +\def\UseCos#1{\csname cos(\number#1)\endcsname} +\chardef\z@num\z@ +\x_cs\let{sin(0)} \z@num +\x_cs\let{cos(0)} \@ne +\x_cs\let{sin(90)} \@ne +\x_cs\let{cos(90)} \z@num +\x_cs\let{sin(-90)}\m@ne +\x_cs\let{cos(-90)}\z@num +\x_cs\let{sin(180)}\z@num +\x_cs\let{cos(180)}\m@ne +\def\CalculateTan#1{{% + \if_undefined{tan(\number#1)}\then + \CalculateSin{#1}% + \CalculateCos{#1}% + \a_dimen\UseCos{#1}\p@ + \divide \a_dimen \@iv + \b_dimen\UseSin{#1}\p@ + \b_dimen\two@fourteen\b_dimen + \divide\b_dimen\a_dimen + \x_cs\xdef{tan(\number#1)}{\TG@rem@pt\b_dimen} + \fi +}} +\def\UseTan#1{\csname tan(\number#1)\endcsname} +\mathchardef\two@fourteen=16384 +\chardef\@iv=4 +\x_cs\def{tan(90)}{\errmessage{Infinite tan !}} +\expandafter\let + \csname tan(-90)\expandafter\endcsname \csname tan(90)\endcsname %%% From file: ficonv.dtx \def\afmtomtx#1#2{{ \let\setsomething_global=\x_relax @@ -2105,8 +2195,9 @@ \def\afm_command#1~{\csname~afm-#1\endcsname\gobble_one_line} \def\gobble_one_line#1\end_of_line{} \x_cs\def{afm-EndFontMetrics}#1\afm_line{\endinput} -\def\afm_def#1(#2)#3{\x_cs\def{afm-#1} - \gobble_one_line#2\end_of_line{#3}} +\def\afm_def#1(#2)#3{ + \x_cs\def{afm-#1}\gobble_one_line#2\end_of_line{#3} +} \def\afm_let#1#2{ \expandafter\let \csname afm-#1\expandafter\endcsname \csname afm-#2\endcsname @@ -2150,15 +2241,16 @@ \if\first_char#2=.\else \afm_length\a_count{#3} \ifnum \a_count>\minimum_kern - \out_line{\string\setkern{#1}{#2}{\the\a_count}} + \afm_write_setkern{#1}{#2}{\the\a_count} \else\ifnum \a_count<-\minimum_kern - \out_line{\string\setkern{#1}{#2}{\the\a_count}} + \afm_write_setkern{#1}{#2}{\the\a_count} \fi\fi \fi\fi } \afm_let{KPX}{KP} +\def\afm_write_setkern#1#2#3{\out_line{\string\setkern{#1}{#2}{#3}}} \afm_def{C}(#1~;#2){\init_afm{#1}\do_list[#2]\afm_char} -\afm_let{CH}{C} +\afm_def{CH}(<#1>~;#2){\uppercase{\init_afm{"#1}}\do_list[#2]\afm_char} \afm_def{CC}(#1~#2~;#3){\init_cc{#1}\do_list[#3]\cc_char} \newcount\char_slot \newcount\char_x_width @@ -2178,7 +2270,6 @@ \let\char_name=\empty_command } \def\afm_char{ - \a_count=-\bbox_lly \eval_expr{ \italcorr_expression\x_width\bbox_llx\bbox_urx\bbox_lly\bbox_ury } @@ -2194,7 +2285,7 @@ {\the\char_slot} {\the\x_width} {\the\bbox_ury} - {\the\a_count} + {\number -\bbox_lly} {\the\result} } } @@ -2245,6 +2336,76 @@ \afm_length\b_count{#3} \out_lline{\string\glyphpcc{#1}{\the\a_count}{\the\b_count}} } +\def\definealias#1#2#3{ + \expandafter\def \csname GN-#1 \expandafter\endcsname + \expandafter{ \csname g-#2 \expandafter\endcsname + \csname i-#3\endcsname} +} +\def\glyph_alias#1{ + \expandafter\expandafter \expandafter\glyph_alias_i + \csname GN-#1\endcsname +} +\def\glyph_alias_i#1#2{ + \expandafter\gobble_three \string#1 +} +\let\charnameprefix\empty +\def\charnamealias#1{ + \if_defined{GN-\charnameprefix#1}\then + \glyph_alias{\charnameprefix#1} + \else\if_defined{GN-#1}\then + \glyph_alias{#1} + \else + #1 + \fi\fi +} +\def\alias_incr#1{ + \expandafter\expandafter \expandafter\alias_incr_i + \csname GN-#1\endcsname +} +\def\alias_incr_i#1#2{ + \ifx#2\x_relax + \mathchardef#2=\@ne + \else + \a_count=#2 + \advance\a_count\@ne + \mathchardef#2=\a_count + \fi +} +\def\alias_char_name#1{ + \if_defined{GN-\charnameprefix#1}\then + \edef\char_name{ + \string\aliased{#1}{\glyph_alias{\charnameprefix#1}} + } + \alias_incr{\charnameprefix#1} + \else\if_defined{GN-#1}\then + \edef\char_name{ + \string\aliased{#1}{\glyph_alias{#1}} + } + \alias_incr{#1} + \else + \edef\char_name{#1} + \fi\fi +} +\def\autoaliasafm{ + \begingroup + \list_def{N}(##1){\alias_char_name{##1}} + \def\afm_write_setkern##1##2##3{ + \out_line{ + \string\setkern{\charnamealias{##1}}{\charnamealias{##2}}{##3} + } + } + \def\init_cc##1{% + \edef\char_name{\charnamealias{##1}} + \out_line{\string\setglyph{\char_name}} + } + \list_def{PCC}(##1~##2~##3){ + \afm_length\a_count{##2} + \afm_length\b_count{##3} + \out_lline{\string\glyphpcc + {\charnamealias{##1}}{\the\a_count}{\the\b_count}} + } +} +\def\endautoaliasafm{\endgroup} \def\generalpltomtx#1#2#3#4{{ \let\setsomething_global=\x_relax \let\setfontdimen=\pl_setfontdimen @@ -2633,14 +2794,7 @@ \resetstr{etx-name}{#1} } \def\mtxtomtx#1#2{{ - \ifisstr{etx-name}\then - \def\do_slot{\x_cs\edef{slots-\slot_name}{\the\slot_number}} - \directfalse - \inputetx{\str{etx-name}} - \edef\a_macro{\string\reencodefont{\str{etx-name}}} - \else - \let\a_macro=\empty_command - \fi + \let\a_macro=\empty_command \_a_true \ifnum \int{x-scale}=\int{y-scale} \ifnum \int{slant-scale}=\z@ @@ -2670,6 +2824,20 @@ \out_line{} \out_line{\string\needsfontinstversion{\fontinstversion}} \out_line{} + \ifisstr{etx-name}\then + \def\do_slot{\x_cs\edef{slots-\slot_name}{\the\slot_number}} + \def\declarepsencoding##1##2##3{ + \a_toks={{##1}{##2}{##3}} + \out_line{\string\providepsencoding\the\a_toks} + \ifnum \transform_record_file=\closed_stream \else + \pout_line\transform_record_file + {\string\providepsencoding\the\a_toks} + \fi + } + \directfalse + \inputetx{\str{etx-name}} + \edef\a_macro{\a_macro\string\reencodefont{\str{etx-name}}} + \fi \record_transform{#2}{\string\frommtx{#1}}{\a_macro}\iftrue \out_line{} \mtxtomtx_redefinitions @@ -3581,6 +3749,8 @@ \pout_line\transform_record_file{\string\makemapentry{#1}} \fi } +\let\declarepsencoding=\gobble_three +\let\providepsencoding=\gobble_three %%% From file: fibasics.dtx \def\needsfontinstversion#1{{ \a_dimen=#1pt diff --git a/Master/texmf-dist/tex/fontinst/latinetx/t1.etx b/Master/texmf-dist/tex/fontinst/latinetx/t1.etx index 541211c8a14..e44ef1cdd1e 100644 --- a/Master/texmf-dist/tex/fontinst/latinetx/t1.etx +++ b/Master/texmf-dist/tex/fontinst/latinetx/t1.etx @@ -2,9 +2,9 @@ %%% @TeX-font-encoding-file{ %%% author = "Alan Jeffrey and Sebastian Rahtz and %%% Ulrik Vieth and Lars Hellstr{\"o}m", -%%% version = "1.923", -%%% date = "2002-10-29", -%%% time = "00:17:50 +01:00", +%%% version = "1.932", +%%% date = "2005-05-27", +%%% time = "16:17:50 +02:00", %%% filename = "t1.etx", %%% email = "fontinst@tug.org", %%% URL = "http://tug.org/applications/fontinst/", @@ -130,11 +130,11 @@ value of this variable is interpreted as follows: are the slots normally used for \texttt{c}, \texttt{f}, \texttt{s}, \texttt{i}, and \texttt{I}. \end{enumerate} -The default value is $0$ for monowidth fonts (because the ligature -glyphs in such fonts are often useless) and $1$ otherwise. The -negative values are useful when making fonts with a nonstandard -set of ligatures; the idea is that some other (smaller) encoding file -should set these remaining slots. +The default value is $0$ for monowidth or letterspaced fonts (because +the ligature glyphs in such fonts are often useless, or at least not +looking right) and $1$ otherwise. The negative values are useful when +making fonts with a nonstandard set of ligatures; the idea is that +some other (smaller) encoding file should set these remaining slots. \encoding @@ -151,15 +151,33 @@ should set these remaining slots. \setcommand\lctop#1#2{#2} \setcommand\uctop#1#2{#1} \setcommand\lclig#1#2{#2} +\ifisint{letterspacing}\then + \ifnumber{\int{letterspacing}}={0}\then \Else + \setcommand\uclig#1#2{#1spaced} + \comment{Here we set \verb|\uclig#1#2| to \verb|#1spaced|, but + you can't see it as \verb|\setcommand| commands are invisible in + the typeset output.} + \Fi +\Fi \setcommand\uclig#1#2{#1} \setcommand\digit#1{#1} + \ifisint{monowidth}\then \setint{ligaturing}{0} \Else + % The following empty line is *important* to get the formatting + % right here (sigh)! (Remember that it is a \par token.) + + \ifisint{letterspacing}\then + \ifnumber{\int{letterspacing}}={0}\then \Else + \setint{ligaturing}{0} + \Fi + \Fi \setint{ligaturing}{1} \Fi + \comment{The remaining code in this section sets various metric parameters for the font. Ideally, all these parameters should already have been set; the values computed here are merely crude guesses @@ -1416,7 +1434,7 @@ This is one of the files which have been with \textsf{fontinst} ``forever'', so a lot of the early changes where probably never recorded. The following are from the \texttt{CHANGES} file. -1994/06/01 (v\,1.327): Removed the f-liagatures for monowidth fonts. +1994/06/01 (v\,1.327): Removed the f-ligatures for monowidth fonts. (ASAJ) Sebastian spotted that one. 1994/11/29 (v\,1.401): Added \texttt{hyphen}${}*{}$\texttt{hyphenchar}% @@ -1447,6 +1465,14 @@ Changed definition of fontdimen 15 slightly---from ``the width of capital vertical stems'' to ``the dominant width of vertical stems'', which is provided in AFM files. (LH) +2005/05/27 (v\,1.932): Modified defaults for |\uclig| and +$\TypesetIntegerExpression{\int{ligaturing}}$ in fonts with +letterspacing, to use \texttt{spaced} glyphs and not make ligatures +respectively. (LH) Rationale (from discussion with Philipp Lehman): +The non-\texttt{spaced} and ready-made ligature glyphs are often +unnaturally cramped in comparison with other letterspaced character +sequences. The system is probably overly complicated, but can be kept +for historical reasons. \end{document} diff --git a/Master/texmf-dist/tex/fontinst/latinmtx/lsbuild.mtx b/Master/texmf-dist/tex/fontinst/latinmtx/lsbuild.mtx index 372ea4b4fdd..35220c773c2 100644 --- a/Master/texmf-dist/tex/fontinst/latinmtx/lsbuild.mtx +++ b/Master/texmf-dist/tex/fontinst/latinmtx/lsbuild.mtx @@ -70,17 +70,21 @@ have a look at \texttt{lsfake.mtx} instead. \Fi } \begincomment\medskip -A \textbf{Try: Set glyph} is an ordinary \textbf{Set glyph} which is +A ``\textbf{Try: Set glyph}'' is an ordinary \textbf{Set glyph} which is conditional on that a set of glyphs (those used to construct the -composite glyph) are available. It is technically e.g. +composite glyph) are available. Technically the command definitions +are \begin{quotation} + \verb|\setcsctopglyph|\textit{\#1\#2\#3\#4} $\mapsto$\\ \setcsctopglyph{\macroparameter{1}}{\macroparameter{2}}% {\macroparameter{3}}{\macroparameter{4}} + \par\medskip + + \verb|\setcscbotglyph|\textit{\#1\#2\#3\#4} $\mapsto$\\ \setcscbotglyph{\macroparameter{1}}{\macroparameter{2}}% {\macroparameter{3}}{\macroparameter{4}}\par \end{quotation} -(both of which are implemented in the code as simple four argument -commands), but in the list of commands below those two commands will +but in the list of commands below those two commands will be typeset as \resetcommand\setcsctopglyph#1#2#3#4{% \Aheading{Try: Set glyph `\TypesetStringExpression{#1}'} diff --git a/Master/texmf-dist/tex/fontinst/latinmtx/lsfake.mtx b/Master/texmf-dist/tex/fontinst/latinmtx/lsfake.mtx index ad942a87a7e..9062e376a1c 100644 --- a/Master/texmf-dist/tex/fontinst/latinmtx/lsfake.mtx +++ b/Master/texmf-dist/tex/fontinst/latinmtx/lsfake.mtx @@ -2,8 +2,8 @@ %%% @TeX-font-metrics-file{ %%% author = "Lars Hellstr{\"o}m", %%% version = "1.923", -%%% date = "2003-03-29", -%%% time = "16:17:30 +01:00", +%%% date = "2005-04-15", +%%% time = "12:13:38 +02:00", %%% filename = "lsfake.mtx", %%% email = "fontinst@tug.org", %%% URL = "http://www.tug.org/applications/fontinst/", @@ -55,7 +55,10 @@ diacritical marks (skrunk by the same factor as the letters), with names such as \texttt{Acutesmall}. These are meant to be used as accent characters in a font where the fake small capitals are used as small letters, so that clashes within a single character when \TeX's -\verb|\accent| primitive is used can be less pronounced. +\verb|\accent| primitive is used can be less pronounced. +\textsf{Fontinst} users should however be aware that this is not +necessarily the right thing to do; some fonts might look better with +the \texttt{acute} etc.\@ glyphs as \texttt{Acutesmall} and friends. \metrics @@ -305,65 +308,6 @@ but such an accent would be too low. The exact meaning of -\begincomment -\section{Miscellaneous glyphs} -\endcomment - - -\setglyph{dotlessIsmall} - \glyph{Ismall}{1000} -\endsetglyph -\setleftrightkerning{dotlessIsmall}{Ismall}{1000} - -\setglyph{dotlessJsmall} - \glyph{Jsmall}{1000} -\endsetglyph -\setleftrightkerning{dotlessJsmall}{Jsmall}{1000} - -\setglyph{FFsmall} - \glyph{Fsmall}{1000} - \movert{\kerning{Fsmall}{Fsmall}} - \glyph{Fsmall}{1000} -\endsetglyph - -\setglyph{FIsmall} - \glyph{Fsmall}{1000} - \movert{\kerning{Fsmall}{Ismall}} - \glyph{Ismall}{1000} -\endsetglyph - -\setglyph{FLsmall} - \glyph{Fsmall}{1000} - \movert{\kerning{Fsmall}{Lsmall}} - \glyph{Lsmall}{1000} -\endsetglyph - -\setglyph{FFIsmall} - \glyph{FFsmall}{1000} - \movert{\kerning{FFsmall}{Ismall}} - \glyph{Ismall}{1000} -\endsetglyph - -\setglyph{FFLsmall} - \glyph{FFsmall}{1000} - \movert{\kerning{FFsmall}{Lsmall}} - \glyph{Lsmall}{1000} -\endsetglyph - -\setglyph{IJsmall} - \glyph{Ismall}{1000} - \movert{\kerning{Ismall}{Jsmall}} - \glyph{Jsmall}{1000} -\endsetglyph - -\setglyph{SSsmall} - \glyph{Ssmall}{1000} - \movert{\kerning{Ssmall}{Ssmall}} - \glyph{Ssmall}{1000} -\endsetglyph - - - \endmetrics \section{Notes} @@ -393,6 +337,12 @@ purposes. 2003/01/02--05: File heavily reorganised. (LH) +2005/04/15: Removed section on \emph{Miscellaneous glyphs}, since +that should be handled by \texttt{lsmisc.mtx}, and moreover prevented +the code there from working correctly. (LH) Thanks to Michael Zedler +for drawing my attention to this error. + + \end{document} % Copyright 1993, 1994, 1995, 1996 Alan Jeffrey, diff --git a/Master/texmf-dist/tex/fontinst/latinmtx/ltcmds.mtx b/Master/texmf-dist/tex/fontinst/latinmtx/ltcmds.mtx index ffe2af0efd3..6e9f1455ba1 100644 --- a/Master/texmf-dist/tex/fontinst/latinmtx/ltcmds.mtx +++ b/Master/texmf-dist/tex/fontinst/latinmtx/ltcmds.mtx @@ -250,7 +250,6 @@ is equivalent to \setint{visiblespacedepth}{200} \setint{visiblespacewidth}{400} \setint{visiblespacesurround}{50} -\setint{capspacing}{0} \ifisglyph{parenleft}\then @@ -299,4 +298,8 @@ code by Walter Schmidt. 2004/08/07: Fixed typo in vertical symmetry axis code. (LH) +2005/05/21: Moved default for +$\TypesetIntegerExpression{\int{capspacing}}$ to \texttt{lubuild.mtx}, +which is where it is used. (LH) + \end{document} diff --git a/Master/texmf-dist/tex/fontinst/latinmtx/lubuild.mtx b/Master/texmf-dist/tex/fontinst/latinmtx/lubuild.mtx index e1e2f1bf9a4..c9603104bb8 100644 --- a/Master/texmf-dist/tex/fontinst/latinmtx/lubuild.mtx +++ b/Master/texmf-dist/tex/fontinst/latinmtx/lubuild.mtx @@ -477,6 +477,13 @@ $\TypesetIntegerExpression{\int{letterspacing}}$ equal to the $\TypesetIntegerExpression{\int{capspacing}}$. \endcomment +\ifisint{letterspacing}\then + \setint{capspacing}{\int{letterspacing}} +\Else + \setint{capspacing}{0} +\Fi + + \setglyph{FFspaced} \glyph{F}{1000} \movert{\add{\kerning{F}{F}}{\int{capspacing}}} @@ -642,5 +649,8 @@ conveys more information. (LH) 2003/03/29: Added some code (from \texttt{latin.mtx}) for all-caps glyphs that had been forgotten. (LH) +2005/05/21: Improved default for +$\TypesetIntegerExpression{\int{capspacing}}$. (LH) + \end{document} diff --git a/Master/texmf-dist/tex/fontinst/smbletx/ts1.etx b/Master/texmf-dist/tex/fontinst/smbletx/ts1.etx index 52b940e30df..4a28ab14601 100644 --- a/Master/texmf-dist/tex/fontinst/smbletx/ts1.etx +++ b/Master/texmf-dist/tex/fontinst/smbletx/ts1.etx @@ -3,8 +3,8 @@ %%% author = "Sebastian Rahtz and Ulrik Vieth and %%% Lars Hellstr{\"o}m", %%% version = "1.913", -%%% date = "2004-11-12", -%%% time = "16:53:13 +01:00", +%%% date = "2005-05-24", +%%% time = "15:45:46 +02:00", %%% filename = "ts1.etx", %%% email = "fontinst@cogs.susx.ac.uk", %%% URL = "http://www.thphy.uni-duesseldorf.de/~vieth/", @@ -311,9 +311,9 @@ This document describes the \TeX{} text companion encoding vector. \endsetslot \nextslot{79} +\setslot{bigcircle} \comment{A circle `\textbigcircle', big enough to enclose a letter as in `\textcopyright' or `\textregistered'.} -\setslot{bigcircle} \endsetslot \nextslot{87} diff --git a/Master/texmf-dist/tex/fontinst/smblmtx/textcomp.mtx b/Master/texmf-dist/tex/fontinst/smblmtx/textcomp.mtx index ac2216139f2..c4c0a17f27c 100644 --- a/Master/texmf-dist/tex/fontinst/smblmtx/textcomp.mtx +++ b/Master/texmf-dist/tex/fontinst/smblmtx/textcomp.mtx @@ -15,8 +15,8 @@ %%% author = "Sebastian Rahtz and Ulrik Vieth and %%% Walter Schmidt and Lars Hellstr{\"o}m", %%% version = "1.926", -%%% date = "2003-07-13", -%%% time = "23:34:04 +02:00", +%%% date = "2005-05-24", +%%% time = "22:30:49 +02:00", %%% filename = "textcomp.mtx", %%% email = "w-a-schmidt@arcor.de", %%% URL = "http://www.tug.org/applications/fontinst/", @@ -555,7 +555,7 @@ Commented out section on zero-depth accents. (LH) Rationale: 2003/07/13: Added some \verb|\resetitalic| commands. Added fakes for \texttt{interrobang} and \texttt{interrobangdown}. Using an -\verb|unfakableaccent| for unfakable accents. (LH) Rationale: +\verb|\unfakableaccent| for unfakable accents. (LH) Rationale: The result becomes much more readable. \end{document} |