diff options
Diffstat (limited to 'Master/texmf-dist/doc/fontinst/base/test')
19 files changed, 1808 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/fontinst/base/test/comparemetrics.sty b/Master/texmf-dist/doc/fontinst/base/test/comparemetrics.sty new file mode 100644 index 00000000000..7864da89731 --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/comparemetrics.sty @@ -0,0 +1,941 @@ +% We start by making some default catcode assignments, in case we are +% using ini\TeX{}. +% \begin{macrocode} +%<*pkg> +\catcode`\{=1 +\catcode`\}=2 +\catcode`\#=6 +\catcode`\^=7 +%</pkg> +% \end{macrocode} +% +% \package{fontinst} uses some unusual, but convenient, settings of +% |\catcode|. |@| and |_| are made letters, |~| is made a space, and +% space and newline are ignored. Before setting those however, we save +% the current values of the catcodes, so that they can be restored at +% the end of \texttt{fontinst.sty}. +% +% \begin{macrocode} +%<*pkg> +\edef\spacecatcode{\the\catcode`\ } +\edef\nlcatcode{\the\catcode`\^^M} +\edef\atcatcode{\the\catcode`\@} +\edef\underscorecatcode{\the\catcode`\_} +\edef\tildecatcode{\the\catcode`\~} +% \end{macrocode} +% +% \begin{macrocode} +\catcode`\ =9 +\catcode`\^^M=9 +\catcode`\@=11 +\catcode`\_=11 +\catcode`\~=10 +%</pkg> +% \end{macrocode} +% + + +\newlinechar=`\^^J + +% \begin{macro}{\a_read} +% \begin{macro}{\b_read} +% \begin{macro}{\a_filelineno} +% \begin{macro}{\b_filelineno} +% These control sequences are used for keeping track of the ``physical'' +% side of the two input files. |\a_read| and |\b_read| are the stream +% numbers. |\a_filelineno| and |\b_filelineno| are the respective +% line numbers of the lines most recently read from these files. +% \begin{macrocode} +\newread\a_read +\newread\b_read +\newcount\a_filelineno +\newcount\b_filelineno +% \end{macrocode} +% \end{macro}\end{macro}\end{macro}\end{macro} +% +% \begin{macro}{\a_lineno} +% \begin{macro}{\b_lineno} +% \begin{macro}{\a_bufbase} +% \begin{macro}{\b_bufbase} +% \begin{macro}{\a_bufmid} +% \begin{macro}{\b_bufmid} +% \begin{macro}{\a_buftop} +% \begin{macro}{\b_buftop} +% These count registers are used for managing the buffert of lines +% that are read from the input files when a match between lines is +% being looked for. This buffert consists of lines which are saved in +% the macros +% \begin{quote} +% |\|\meta{letter}|_saved-|\meta{ofs} +% \end{quote} +% where \meta{letter} is |a| or |b| and \meta{ofs} is an integer, +% being the index into the buffert. |\a_bufbase| and |\b_bufbase| +% contain the \meta{ofs} of the first line currently in the buffert, +% whereas |\a_buftop| and |\b_buftop| contain the \meta{ofs} of the +% last such line. |\a_bufmid| and |\b_bufmid| hold the buffert +% positions of the lines which are currently considered the next by +% |\get_next_line|. If \(\mathtt{buftop}<\mathtt{bufmid}\) then the +% buffert is empty. |\a_lineno| and |\b_lineno| are the respective +% line numbers of the |\a_bufbase| and |\b_bufbase| lines. +% +% All these registers should be set globally. +% \begin{macrocode} +\newcount\a_lineno \newcount\b_lineno +\newcount\a_bufbase \newcount\b_bufbase +\newcount\a_bufmid \newcount\b_bufmid +\newcount\a_buftop \newcount\b_buftop +% \end{macrocode} +% \end{macro}\end{macro}\end{macro}\end{macro}\end{macro}\end{macro} +% \end{macro}\end{macro} + + +% \begin{macro}{\get_next_line} +% The |\get_next_line| macro is called as +% \begin{quote} +% |\get_next_line|\marg{letter} +% \end{quote} +% where \meta{letter} is |a| or |b|. This sets the +% |\|\meta{letter}|_line| macro to the next line of that file and +% updates the value of |\|\meta{letter}|_lineno|. +% +% The ``next line'' is normally read from input stream +% |\|\meta{letter}|_read|, but if a line mismatch recently occured +% then it might happen that the next line has already been read from +% the file, and in that case it is taken from one of the +% |\|\meta{letter}|_saved-|\meta{ofs} macros. +% \begin{macrocode} +\def\get_next_line#1{ + \ifnum \csname#1_buftop\endcsname<\csname#1_bufmid\endcsname + \ifeof \csname#1_read\endcsname + \x_cs\let{#1_line}\end_of_file_line + \else + \read\csname#1_read\endcsname t\x_cs{o}{#1_line} + \global\advance \csname#1_filelineno\endcsname \@ne + \fi + \else + \expandafter\let \csname#1_line\expandafter\endcsname + \csname#1_saved-\the\csname#1_bufmid\endcsname\endcsname + \fi +} +% \end{macrocode} +% \end{macro} + +% \begin{macro}{\end_of_file_line} +% This macro expands to the text \verb*|(ENDOFFILE) | with the +% catcodes it would have if read from an input file. It is used as an +% end-of-file marker. +% \begin{macrocode} +\begingroup + \catcode`\(=13 + \catcode`\)=13 + \gdef\end_of_file_line{(ENDOFFILE)~} +\endgroup +% \end{macrocode} +% \end{macro} + +% \begin{macro}{\the_line} +% The |\the_line| macro is called as +% \begin{quote} +% |\the_line|\marg{letter}\marg{ofs} +% \end{quote} +% where \meta{letter} is |a| or |b|, and \meta{ofs} is a \TeX\ number. +% It expands to the control sequence |\|\meta{letter}|_saved-|^^A +% \meta{ofs}. +% \begin{macrocode} +\def\the_line#1#2{\csname#1_saved-\number#2\endcsname} +% \end{macrocode} +% \end{macro} + +% \begin{macro}{\initialise_search} +% The |\initialise_search| macro sets everything up for a search for +% a match between lines. +% +% \begin{macrocode} +\def\initialise_search{ + \global\a_bufbase=\a_bufmid + \global\b_bufbase=\b_bufmid + \add_to_buffert{a} + \add_to_buffert{b} + \global\advance \a_bufmid \@ne + \global\advance \b_bufmid \@ne +} +% \end{macrocode} +% \end{macro} + +% \begin{macro}{\add_to_buffert} +% The |\add_to_buffert| macro is called as +% \begin{quote} +% |\add_to_buffert|\marg{letter} +% \end{quote} +% It adds the line returned by |\get_next_line| to the corresponding +% buffert (if it wasn't already there) and updates the counters for +% that buffert. After this, the line following the line being put into +% the buffert will be the line that |\get_next_line| returns. +% \begin{macrocode} +\def\add_to_buffert#1{ + \ifnum \csname#1_buftop\endcsname<\csname#1_bufmid\endcsname + \expandafter\let + \csname#1_saved-\the\csname#1_bufmid\endcsname + \expandafter\endcsname + \csname#1_line\endcsname + \global\advance \csname#1_buftop\endcsname \@ne + \fi +} +% \end{macrocode} +% \end{macro} + + + +\newcount\first_integer +\newcount\second_integer + +% \begin{macro}{\match_lines} +% The |\match_lines| macro tests if two lines can be considered the +% same (up to metrics changes, which need not be small). It is called as +% \begin{quote} +% |\match_lines|\marg{line a}\marg{line b} +% \end{quote} +% \meta{line a} and \meta{line b} may be any amount of text which +% eventually expands to the lines in question. |\match_lines| returns +% its answer by setting the |_a_| switch to |false| (if the lines +% match) or |true| (if the lines don't match). +% +% |\match_lines| also causes the |\first_dimen| and |\second_dimen| +% registers, as well as the |_histogram_dimen_| switch to be updated, +% so it can be immediately followed by a test of the metrics. +% \begin{macrocode} +\def\match_lines#1#2{ + \first_integer=\z@ + \second_integer=\z@ + \first_dimen=\z@ + \second_dimen=\z@ + \x_cs\let{string-+}\empty_command + \x_cs\let{string--}\empty_command +% \end{macrocode} +% \begin{macrocode} + \def\sign{+} + #1\line_stop + \def\sign{-} + #2\line_stop +% \end{macrocode} +% \begin{macrocode} + \_a_false + \expandafter\ifx \csname cmd-+ \expandafter\endcsname + \csname cmd--\endcsname + \else \_a_true \fi + \ifnum \first_integer=\z@ \else \_a_true \fi + \ifnum \second_integer=\z@ \else \_a_true \fi + \expandafter\ifx \csname string-+ \expandafter\endcsname + \csname string--\endcsname + \else \_a_true \fi +} +% \end{macrocode} +% \end{macro} + +% \begin{macro}{\try_matching} +% \begin{macro}{\a_bufP} +% \begin{macro}{\b_bufP} +% The |\try_matching| descends through the buffert until the |_a_| +% switch gets |false| or it has tried the bottommost lines in the +% buffert. Since |\body| is already defined by the |\loop| in +% |\process_lines|, |\try_matching| uses an explicit end recursion to +% make the loop. +% \begin{macrocode} +\newcount\a_bufP +\newcount\b_bufP +\def\try_matching{ + \global\advance \a_bufP \m@ne + \global\advance \b_bufP \m@ne +% % Begin debug +% \wlog{a_bufbase:~\the\a_bufbase\space\space\space +% b_bufbase:~\the\b_bufbase} +% \wlog{a_bufmid:~\the\a_bufmid\space\space\space +% b_bufmid:~\the\b_bufmid} +% \wlog{a_buftop:~\the\a_buftop\space\space\space +% b_buftop:~\the\b_buftop} +% \wlog{a_bufP:~\the\a_bufP\space\space\space +% b_bufP:~\the\b_bufP} +% \begingroup +% \def\do_left_paren{(}\def\do_right_paren{)} +% \wlog{a_line:~\a_line} +% \wlog{b_buf_line:~\the_line{b}{\b_bufP}} +% \wlog{b_line:~\b_line} +% \wlog{a_buf_line:~\the_line{a}{\a_bufP}^^J} +% \endgroup +% % End debug + \match_lines{\a_line}{\the_line{b}{\b_bufP}} + \if_a_ + \match_lines{\the_line{a}{\a_bufP}}{\b_line} + \if_a_ \else + \global\a_bufmid=\a_bufP + \fi + \else + \global\b_bufmid=\b_bufP + \fi + \ifnum \a_bufP>\a_bufbase \if_a_ + \expandafter\expandafter\expandafter\try_matching + \fi \fi +} +% \end{macrocode} +% \end{macro} + +% \begin{macro}{\report_mismatch} +% The |\report_mismatch| macro does precisely what it says. It also increases +% the \texttt{bufbase} and \texttt{lineno} registers to point at the +% matching lines. +% \begin{macrocode} +\def\report_mismatch{ + \begingroup + \def\do_left_paren{(} + \def\do_right_paren{)} + \wlog{Mismatch~in~first~file~(at~\the\a_lineno):} + \loop + \wlog{\the_line{a}{\a_bufbase}} + \ifnum \a_bufbase<\a_bufmid + \global\advance \a_bufbase \@ne + \global\advance \a_lineno \@ne + \repeat + \wlog{Match~found~at~line~\the\a_lineno.} + \wlog{Mismatch~in~second~file~(at~\the\b_lineno):} + \loop + \wlog{\the_line{b}{\b_bufbase}} + \ifnum \b_bufbase<\b_bufmid + \global\advance \b_bufbase \@ne + \global\advance \b_lineno \@ne + \repeat + \wlog{Match~found~at~line~\the\b_lineno.} + \endgroup + \glyphified_location + \ifnum 4>\compared_status + \global\chardef\compared_status=4 + \fi +} +% \end{macrocode} +% \end{macro} + +\def\glyphified_location{ + \ifx \encoding_name\empty_command + \ifnum \m@ne<\last_character + \wlog{This~is~related~to~slot~\the\last_character.^^J} + \else + \wlog{This~is~in~the~header.^^J} + \fi + \else + \if_undefined{name-\encoding_name-\the\last_character}\then + \ifnum \last_character=\m@ne + \wlog{This~is~in~the~header.^^J} + \else + \wlog{This~is~related~to~slot~\the\last_character\space + (unencoded).^^J} + \fi + \else + \wlog{This~is~related~to~the~glyph~ + \csname name-\encoding_name-\the\last_character\endcsname + .^^J} + \fi + \fi +} +% \begin{macro}{\compared_status} +% |\compared_status| is a \meta{chardef token} which stores the +% current status of the comparision, according to the following table +% \begin{enumerate} +% \item[0] The property lists are equal---there may be checksum +% differences, but nothing else. +% \item[1] The property lists are almost equal---there are +% differences in the metrics, but these are within the |\tolerance| +% level. +% \item[2] The property lists are essentially equal---there are +% differences in the metrics, but these are within the |\tolerance| +% level, with the exception of some \texttt{CHARHT}, +% \texttt{CHARDP}, and \texttt{CHARIC} values. +% \item[3] The property lists have metric differences---there are +% metric differences not with category 2. +% \item[4] The property lists are not completely matched. +% \end{enumerate} +% \end{macro} + +% \begin{macro}{\step_linenos} +% The |\step_linenos| macro increments the |_lineno| line numbers. If +% the current line was fetched from the buffert, then it also +% increments the |_bufmid| and |_bufbase| registers, and checks +% whether the buffert ended (in which case it is normalized to its +% starting position, to conserve hash table space). +% \begin{macrocode} +\def\step_linenos{ + \global\advance \a_lineno \@ne + \ifnum \a_bufmid=\a_buftop + \global\a_bufbase=\z@ + \global\a_bufmid=\z@ + \global\a_buftop=\m@ne + \else\ifnum \a_bufmid<\a_buftop + \global\advance \a_bufmid \@ne + \global\advance \a_bufbase \@ne + \fi\fi + \global\advance \b_lineno \@ne + \ifnum \b_bufmid=\b_buftop + \global\b_bufbase=\z@ + \global\b_bufmid=\z@ + \global\b_buftop=\m@ne + \else\ifnum \b_bufmid<\b_buftop + \global\advance \b_bufmid \@ne + \global\advance \b_bufbase \@ne + \fi\fi +} +% \end{macrocode} +% \end{macro} + + +\newdimen\first_dimen +\newdimen\second_dimen +\newcount\ht_hist_i +\newcount\ht_hist_ii +\newcount\ht_hist_iii +\newcount\ht_hist_iv +\newcount\dp_hist_i +\newcount\dp_hist_ii +\newcount\dp_hist_iii +\newcount\dp_hist_iv +\newcount\ic_hist_i +\newcount\ic_hist_ii +\newcount\ic_hist_iii +\newcount\ic_hist_iv + +% \begin{macro}{\clear_histograms} +% This macro clears all the histograms. +% \begin{macrocode} +\def\clear_histograms{ + \global\ht_hist_i=\z@ + \global\ht_hist_ii=\z@ + \global\ht_hist_iii=\z@ + \global\ht_hist_iv=\z@ + \global\dp_hist_i=\z@ + \global\dp_hist_ii=\z@ + \global\dp_hist_iii=\z@ + \global\dp_hist_iv=\z@ + \global\ic_hist_i=\z@ + \global\ic_hist_ii=\z@ + \global\ic_hist_iii=\z@ + \global\ic_hist_iv=\z@ +} +% \enc{macrocode} +% \end{macro} + +% \begin{macro}{\present_histograms} +% This macro writes the histogram data to the log file. +% \begin{macrocode} +\def\present_histograms{ + \wlog{\string\tolerance*~\space CHARHT~\space CHARDP~\space CHARIC} + \wlog{~\space\space 1--~\space\space 10\hist_to_eight{ht}{i} + \hist_to_eight{dp}{i}\hist_to_eight{ic}{i}} + \wlog{~\space 10--~\space 100\hist_to_eight{ht}{ii} + \hist_to_eight{dp}{ii}\hist_to_eight{ic}{ii}} + \wlog{~100--~1000\hist_to_eight{ht}{iii}\hist_to_eight{dp}{iii} + \hist_to_eight{ic}{iii}} + \wlog{1000--10000\hist_to_eight{ht}{iv}\hist_to_eight{dp}{iv} + \hist_to_eight{ic}{iv}} +} +\def\hist_to_eight#1#2{\x_cs\hist_to_eight_i{#1_hist_#2}} +\def\hist_to_eight_i#1{ + \ifnum #1<\@M + \four_spaces + \ifnum #1<\one_hundred + \space\space + \ifnum 10>#1 ~\fi + \else \ifnum #1<\one_thousand \space\fi \fi + \else + \ifnum 1000000>#1 + \space\space + \ifnum 100000>#1 ~\fi + \else \ifnum 1000000>#1 ~\fi \fi + \fi + \the#1 +} +% \end{macrocode} +% \end{macro} + + +% \begin{macro}{\metric_statistics} +% \begin{macro}{\metric_origin} +% The |\metric_statistics| macro takes care of comparing the metrics +% by inspecting the values of |\first_dimen| and |\second_dimen|. It +% has four classes of differences, which are represented by +% |\compared_status| values 0--3: no difference, tolerable (almost no) +% difference, histogrammed (essentially no) difference, and +% non-tolerable difference. If a non-tolerable difference is found, +% then the current lines are written to the log file. Histogrammed +% differences causes the corresponding +% |\|\meta{type}|_hist_|\meta{group} register to be incremented, and +% tolerable differences only affect the value of |\compared_status|. +% +% The |\metric_origin| macro contains the \meta{type} of the metric +% data. It is usually empty, but PL properties with metrics that have +% histograms set it so that the correct histogram is updated. +% +% \begin{macrocode} +\def\metric_statistics{ + \_a_false + % + \ifdim \first_dimen<\z@ \first_dimen=-\first_dimen \fi + \ifdim \first_dimen=\z@ + \else\ifdim \first_dimen<\tolerance + \ifnum 1>\compared_status + \global\chardef\compared_status=1 + \fi + \else\ifx \metric_origin\empty_command + \_a_true + \else + \a_count=\@ne + \def\a_macro{10} + \loop\ifdim \a_macro\tolerance<\first_dimen + \edef\a_macro{\a_macro 0} + \advance \a_count \@ne + \repeat + \if_undefined{\metric_origin _hist_ \romannumeral\a_count}\then + \_a_true + \else + \global\advance \csname \metric_origin _hist_ + \romannumeral\a_count \endcsname \@ne + \ifnum 2>\compared_status + \global\chardef\compared_status=2 + \fi + \fi + \fi\fi\fi + % + \ifdim \second_dimen<\z@ \second_dimen=-\second_dimen \fi + \ifdim \second_dimen=\z@ + \else\ifdim \second_dimen<\tolerance + \ifnum 1>\compared_status + \global\chardef\compared_status=1 + \fi + \else\ifx \metric_origin\empty_command + \_a_true + \else + \a_count=\@ne + \def\a_macro{10} + \loop\ifdim \a_macro\tolerance<\second_dimen + \edef\a_macro{\a_macro 0} + \advance \a_count \@ne + \repeat + \if_undefined{\metric_origin _hist_ \romannumeral\a_count}\then + \_a_true + \else + \global\advance \csname \metric_origin _hist_ + \romannumeral\a_count \endcsname \@ne + \ifnum 2>\compared_status + \global\chardef\compared_status=2 + \fi + \fi + \fi\fi\fi + % + \if_a_ + \ifnum 3>\compared_status + \global\chardef\compared_status=3 + \fi + \begingroup + \def\do_left_paren{(} + \def\do_right_paren{)} + \wlog{Metric~differences~at~lines~\the\a_lineno\space + and~\the\b_lineno\space respectively:} + \wlog{\a_line} + \wlog{\b_line} + \endgroup + \glyphified_location + \fi +} +% \end{macrocode} +% \end{macro}\end{macro} + + + + +\newif\if_b_ + +% \begin{macro}{\process_lines} +% The |\process_lines| macro is the cheif executive in the comparision. +% Its normal mode of operation is to retrive the next two lines from +% the input files, match them, and update the metric differences +% statistics. If the lines do not match, however, it starts building a +% buffert of lines in which it searches for two matching lines. When +% these two lines are found the mismatching portions of the files are +% written to the log file, and the metric difference statistics are +% updated for the two lines that matched. +% +% \begin{macrocode} +\def\process_lines{ + \get_next_line{a} + \get_next_line{b} + \match_lines{\a_line}{\b_line} + \if_a_ +% \end{macrocode} +% Now the process of trying to find a match begins. At each step of +% the search for a match, it tries all possible matches with the +% lines read so far that haven't been tried at an earlier step. +% \begin{macrocode} +% \tracingmacros=\@ne\tracingcommands=\tw@ % DEBUG + \initialise_search + \loop + \get_next_line{a} + \get_next_line{b} + \add_to_buffert{a} + \add_to_buffert{b} + \match_lines{\a_line}{\b_line} + \if_a_ + \global\a_bufP=\a_bufmid + \global\b_bufP=\b_bufmid + \try_matching + \fi + \if_a_ + \global\advance \a_bufmid \@ne + \global\advance \b_bufmid \@ne + \ifnum \a_bufmid>\sixt@@n + \errmessage{Big~buffert.~\the\a_lineno[\the\a_filelineno]: + \the\b_lineno[\the\b_filelineno]} + \fi % DEBUG + \repeat + \report_mismatch +% \tracingcommands=\z@\tracingmacros=\z@ % DEBUG +% \end{macrocode} +% \begin{macrocode} + \fi + \metric_statistics + \step_linenos + \par % DEBUG + \if \ifx \a_line\end_of_file_line + \ifx \b_line\end_of_file_line 1\else 0\fi\else 0\fi 0 + % then + \expandafter\process_lines + \fi +} +% \end{macrocode} +% \end{macro} + +\def\loadencoding#1{{ + \def\do_slot{\x_cs\xdef{name-#1-\the\slot_number}{\slot_name}} + \inputetx{#1} +}} + +% \begin{macro}{\comparePLs} +% The |\comparePLs| command compares two property lists files. It is +% geared against verifying that two different such files are as good +% as equal, and it might take a very long time before it gives up on +% trying to find any resemblance between them. It is furthermore only +% meant to be used on (V)PL files generated by \package{TFtoPL} or +% \package{VFtoVP}, because it assumes the property lists follow a +% stricter syntax than \package{PLtoTF} and \package{VPtoVF} requires +% them to. Finally it needs to be said that the comparision is rather +% stupid in many respects, as it is completely line-oriented and +% takes no notice of what kind of property list it is reading. This +% may in some cases cause it to find ``matches'' between lines which +% for syntactical reasons alone cannot match. +% +% |\comparePLs| is called as +% \begin{quote} +% |\comparePLs|\marg{first PL}\marg{second PL}\marg{encoding} +% \end{quote} +% where \meta{first PL} and \meta{second PL} are the complete names +% (including extensions) of the files to compare. \meta{encoding} is +% the name of the encoding to use when translating slots to glyph +% names; leave it empty if you don't want to specify one. (One could +% use the \texttt{CODINGSCHEME} property to determine the encoding in +% that case, but this is not currently done). The slot to glyph +% translation is only done to make it easier to locate the position of +% some mismatch; it has not effect on the actual comparision. +% \begin{macrocode} +\newcount\last_character +\def\comparePLs#1#2#3{{ + \def\encoding_name{#3} + \last_character=\m@ne + \openin\a_read=#1\x_relax + \openin\b_read=#2\x_relax + \immediate\write\sixt@@n{#1~and^^J #2} + \pl_catcodes + \let\do_left_paren=\do_property + \let\do_right_paren=\empty_command + \global\chardef\compared_status=\z@ + \clear_histograms + \global\a_filelineno=\@ne + \global\b_filelineno=\@ne + \global\a_lineno=\@ne + \global\b_lineno=\@ne + \global\a_bufbase=\z@ + \global\b_bufbase=\z@ + \global\a_bufmid=\z@ + \global\b_bufmid=\z@ + \global\a_buftop=\m@ne + \global\b_buftop=\m@ne + \process_lines + \closein\a_read + \closein\b_read + \ifcase \compared_status + \immediate\write\sixt@@n{are~equal.^^J} + \or + \immediate\write\sixt@@n{are~almost~equal.^^J} + \or + \immediate\write\sixt@@n{are~essentially~equal.} + \or + \immediate\write\sixt@@n{have~non-tolerated~metric~differences.} + \or + \immediate\write\sixt@@n{do~not~completely~match.} + \else + \immediate\write\sixt@@n{could~not~be~matched!} + \fi + \ifnum 1<\compared_status + \immediate\write\sixt@@n{See~log~file~for~specification.} + \present_histograms + \immediate\write\sixt@@n{} + \fi +}} +% \end{macrocode} +% \end{macro} + + +\begingroup + \catcode`\(=13 \catcode`\)=13 + \gdef\pl_catcodes{ + \catcode`\(=13 \def({\do_left_paren} + \catcode`\)=13 \def){\do_right_paren} + } +\endgroup + +\def\do_property#1~{ + \x_cs\edef{cmd-\sign}{#1} + \let\metric_origin=\empty_command + \x_cs\ifx{pl-#1}\x_relax + \expandafter\ignore_parens + \else + \csname pl-#1 \expandafter\endcsname + \fi +} +\def\pl_def_s#1(#2){\x_cs\def{pl-#1}#2~} +\begingroup + \catcode`\!=13\lccode`\!=`\) +\lowercase{\endgroup + \def\pl_def_p#1(#2){\x_cs\def{pl-#1}#2!} +} +\def\pl_let#1#2{ + \expandafter\let + \csname pl-#1 \expandafter\endcsname \csname pl-#2 \endcsname +} + + + +\newdimen\tolerance \tolerance=110sp + +% The following is for gobbling to the next unmatched right parenthesis. +% The |\catcode| trick used by the PL-to-MTX converter's +% |\ignore_parens| cannot be used since the characters are already +% tokenized, but one can do something similar with an |\edef| since one +% does not have to worry about the PL files containing material which +% expands in an undesirable way. +% +% The |\line_stop| is so that linebreaks in the parenthesis being +% gobbled will not cause total havok (although the parenthesis won't be +% gobbled completely). It inserts end-of-group tokens until the |\edef| +% is terminated, and then the |\afterassignment| token will close the +% group and restore the normal definition. + +\def\ignore_parens{ + \begingroup + \def\do_left_paren{{\iffalse}\fi} + \def\do_right_paren{\iffalse{\fi}} + \def\line_stop{\do_right_paren\line_stop} + \afterassignment\endgroup + \edef\a_macro{\iffalse}\fi +} +\def\line_stop{\x_relax} +% \end{macrocode} +% +\begingroup + \catcode`\(=1 + \catcode`\)=2 + \gdef\pl_string{ + \begingroup + \def\do_left_paren{(\iffalse)\fi} + \def\do_right_paren{\iffalse(\fi)} + \def\line_stop{\iffalse{\fi}\line_stop} + \afterassignment\pl_string_i + \edef\a_macro{\iffalse}\fi + } +\endgroup +\def\pl_string_i{ + \expandafter\endgroup \expandafter\def + \csname string-\sign \expandafter\endcsname + \expandafter{\a_macro} +} + +\def\pl_real#1{\sign#1\hundred_pt} +\newdimen\hundred_pt \hundred_pt=100pt + +% Convert a PL int to a \TeX{} int, assuming it's prefixed +% by |C|, |D|, |O|, or |H|. +% +% \begin{macrocode} +\def\pl_int#1#2{ + \sign \ifx#1C `#2 + \else\ifx#1D #2 + \else\ifx#1O '#2 + \else\ifx#1H "#2 + \else -1\errmessage{Unknown~PL~number~prefix~`#1'} + \fi\fi\fi\fi +} +% \end{macrocode} + + +% \begin{macrocode} +\pl_def_p{NEXTLARGER}(#1~#2){\advance \first_integer \pl_int{#1}{#2}} +\pl_let{BOUNDARYCHAR}{NEXTLARGER} +% \end{macrocode} +% +% +% \begin{macrocode} +\x_cs\let{pl-VTITLE}=\pl_string +\pl_let{FONTNAME}{VTITLE} +\pl_let{FONTAREA}{VTITLE} +% \pl_let{CHECKSUM}{VTITLE} +% % Not really a string, but unsigned numbers can become too large for TeX. +% \pl_let{FONTCHECKSUM}{CHECKSUM} +% Commented out since checksums vary too much. +\pl_def_p{FONTAT}(R~#1){\advance \first_dimen \pl_real{#1}} +\pl_let{FONTDSIZE}{FONTAT} +\pl_let{SELECTFONT}{NEXTLARGER} +\pl_let{SETCHAR}{NEXTLARGER} +\pl_def_p{SETRULE}(R~#1~R~#2){ + \advance \first_dimen \pl_real{#1} + \advance \second_dimen \pl_real{#2} +} +\x_cs\let{pl-POP}\empty_command +\pl_let{PUSH}{POP} +\pl_let{MOVERIGHT}{FONTAT} +\pl_let{MOVELEFT}{FONTAT} +\pl_let{MOVEUP}{FONTAT} +\pl_let{MOVEDOWN}{FONTAT} +\pl_let{SPECIAL}{VTITLE} +\pl_let{SPECIALHEX}{VTITLE} +% \end{macrocode} +% +% + +\pl_let{CODINGSCHEME}{VTITLE} +\pl_let{DESIGNSIZE}{FONTAT} + +\def\pl_parameter#1#2#3{ + \advance \first_integer \pl_int{#1}{#2} + \advance \first_dimen \pl_real{#3} +} + +\pl_def_p{PARAMETER}(#1~#2~R~#3){\pl_parameter{#1}{#2}{#3}} + +\pl_def_p{SLANT}(R~#1){\pl_parameter{D}{1}{#1}} +\pl_def_p{SPACE}(R~#1){\pl_parameter{D}{2}{#1}} +\pl_def_p{STRETCH}(R~#1){\pl_parameter{D}{3}{#1}} +\pl_def_p{SHRINK}(R~#1){\pl_parameter{D}{4}{#1}} +\pl_def_p{XHEIGHT}(R~#1){\pl_parameter{D}{5}{#1}} +\pl_def_p{QUAD}(R~#1){\pl_parameter{D}{6}{#1}} +\pl_def_p{EXTRASPACE}(R~#1){\pl_parameter{D}{7}{#1}} + +\pl_def_p{NUM1}(R~#1){\pl_parameter{D}{8}{#1}} +\pl_def_p{NUM2}(R~#1){\pl_parameter{D}{9}{#1}} +\pl_def_p{NUM3}(R~#1){\pl_parameter{D}{10}{#1}} +\pl_def_p{DENOM1}(R~#1){\pl_parameter{D}{11}{#1}} +\pl_def_p{DENOM2}(R~#1){\pl_parameter{D}{12}{#1}} +\pl_def_p{SUP1}(R~#1){\pl_parameter{D}{13}{#1}} +\pl_def_p{SUP2}(R~#1){\pl_parameter{D}{14}{#1}} +\pl_def_p{SUP3}(R~#1){\pl_parameter{D}{15}{#1}} +\pl_def_p{SUB1}(R~#1){\pl_parameter{D}{16}{#1}} +\pl_def_p{SUB2}(R~#1){\pl_parameter{D}{17}{#1}} +\pl_def_p{SUPDROP}(R~#1){\pl_parameter{D}{18}{#1}} +\pl_def_p{SUBDROP}(R~#1){\pl_parameter{D}{19}{#1}} +\pl_def_p{DELIM1}(R~#1){\pl_parameter{D}{20}{#1}} +\pl_def_p{DELIM2}(R~#1){\pl_parameter{D}{21}{#1}} +\pl_def_p{AXISHEIGHT}(R~#1){\pl_parameter{D}{22}{#1}} + +\pl_let{DEFAULTRULETHICKNESS}{NUM1} +\pl_let{BIGOPSPACING1}{NUM2} +\pl_let{BIGOPSPACING2}{NUM3} +\pl_let{BIGOPSPACING3}{DENOM1} +\pl_let{BIGOPSPACING4}{DENOM2} +\pl_let{BIGOPSPACING5}{SUP1} + +\def\boundarychar_name{BOUNDARYCHAR} +\pl_def_s{LABEL}(#1){ + \def\a_macro{#1} + \ifx \a_macro\boundarychar_name + \x_cs\let{string-\sign}\a_macro + \else + \def\a_macro{\csname pl-LABEL(i\endcsname #1~} + \expandafter\a_macro + \fi +} +\pl_def_p{LABEL(i}(#1~#2){ + \last_character=\first_integer + \advance \first_integer \pl_int{#1}{#2} +} +\pl_def_p{LIG}(#1~#2~#3~#4){ + \advance \first_integer \pl_int{#1}{#2} + \advance \second_integer \pl_int{#3}{#4} +} +\pl_let{/LIG}{LIG} +\pl_let{/LIG>}{LIG} +\pl_let{LIG/}{LIG} +\pl_let{LIG/>}{LIG} +\pl_let{/LIG/}{LIG} +\pl_let{/LIG/>}{LIG} +\pl_let{/LIG/>>}{LIG} + +\pl_let{HEADER}{LIG} + +% \def\pl_lig#1~#2~#3~#4~#5~{ +% \x_cs\def{string-\sign}{#1} +% \def\LIG#1~{ +% \if\ifx #1C 0 +% \else\ifx #1D 0 +% \else\ifx #1H 0 +% \else\ifx #1O 0 \else 1\fi\fi\fi\fi 0 +% % then +% \expandafter\both_of_two +% \else +% \expandafter\first_of_two +% \fi{\pl_lig LIG}{~}#1~ +% } +% \def\/{\pl_lig/} + +\pl_let{KRN}{PARAMETER} +\pl_let{SKIP}{NEXTLARGER} + +\pl_def_s{CHARACTER}(#1~#2){ + \last_character=\first_integer + \advance \first_integer \pl_int{#1}{#2} +} +\pl_let{CHARWD}{FONTAT} +\pl_def_p{CHARHT}(R~#1){ + \def\metric_origin{ht} + \advance \first_dimen \pl_real{#1} +} +\pl_def_p{CHARDP}(R~#1){ + \def\metric_origin{dp} + \advance \first_dimen \pl_real{#1} +} +\pl_def_p{CHARIC}(R~#1){ + \def\metric_origin{ic} + \advance \first_dimen \pl_real{#1} +} + +\pl_let{TOP}{NEXTLARGER} +\pl_let{MID}{NEXTLARGER} +\pl_let{BOT}{NEXTLARGER} +\pl_let{REP}{NEXTLARGER} + +\pl_let{FONTDIMEN}{POP} +\pl_let{LIGTABLE}{POP} +\pl_let{VARCHAR}{POP} +\pl_def_s{MAPFONT}(#1~#2){\advance \first_integer \pl_int{#1}{#2}} +\pl_let{MAP}{POP} + + +% \begin{macrocode} +\catcode`\@=\atcatcode +\catcode`\^^M=\nlcatcode +\catcode`\ =\spacecatcode +\catcode`\~=\tildecatcode +\catcode`\_=\underscorecatcode +% \end{macrocode} diff --git a/Master/texmf-dist/doc/fontinst/base/test/comparepls.tex b/Master/texmf-dist/doc/fontinst/base/test/comparepls.tex new file mode 100644 index 00000000000..a735a34ed79 --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/comparepls.tex @@ -0,0 +1,73 @@ +\input fontinst.sty +\input comparemetrics.sty + +% % \tracingmacros=1\tracingcommands=2 +% \comparePLs{cmr5.pl}{cmr5.pl} +% +% \bye + +\tracingstats=1 + +\def\oldf{::efficiency:saved:v1.912:} +\def\newf{::efficiency:saved:v1.913:} + +\loadencoding{t1} +\loadencoding{ot1} +\loadencoding{ts1} +\loadencoding{8r} + +\comparePLs{\oldf padb7t.vpl}{\newf padb7t.vpl}{ot1} %OK 11sp +\comparePLs{\oldf padb8c.vpl}{\newf padb8c.vpl}{ts1} %OK 11sp +\comparePLs{\oldf padb8t.vpl}{\newf padb8t.vpl}{t1} %OK 11sp +\comparePLs{\oldf padbc7t.vpl}{\newf padbc7t.vpl}{ot1} %OK 11sp +\comparePLs{\oldf padbc8t.vpl}{\newf padbc8t.vpl}{t1} +\comparePLs{\oldf padbi7t.vpl}{\newf padbi7t.vpl}{ot1} +\comparePLs{\oldf padbi8c.vpl}{\newf padbi8c.vpl}{ts1} +\comparePLs{\oldf padbi8t.vpl}{\newf padbi8t.vpl}{t1} +\comparePLs{\oldf padbo7t.vpl}{\newf padbo7t.vpl}{ot1} %OK 11sp +\comparePLs{\oldf padbo8c.vpl}{\newf padbo8c.vpl}{ts1} %OK 11sp +\comparePLs{\oldf padbo8t.vpl}{\newf padbo8t.vpl}{t1} +\comparePLs{\oldf padr7t.vpl}{\newf padr7t.vpl}{ot1} %OK 11sp +\comparePLs{\oldf padr8c.vpl}{\newf padr8c.vpl}{ts1} %OK 11sp +\comparePLs{\oldf padr8t.vpl}{\newf padr8t.vpl}{t1} %OK 11sp +\comparePLs{\oldf padrc7t.vpl}{\newf padrc7t.vpl}{ot1} %OK 11sp +\comparePLs{\oldf padrc8t.vpl}{\newf padrc8t.vpl}{t1} %OK 11sp +\comparePLs{\oldf padri7t.vpl}{\newf padri7t.vpl}{ot1} +\comparePLs{\oldf padri8c.vpl}{\newf padri8c.vpl}{ts1} %OK 11sp +\comparePLs{\oldf padri8t.vpl}{\newf padri8t.vpl}{t1} +\comparePLs{\oldf padro7t.vpl}{\newf padro7t.vpl}{ot1} %OK 11sp +\comparePLs{\oldf padro8c.vpl}{\newf padro8c.vpl}{ts1} %OK 11sp +\comparePLs{\oldf padro8t.vpl}{\newf padro8t.vpl}{t1} +\comparePLs{\oldf pads7t.vpl}{\newf pads7t.vpl}{ot1} +\comparePLs{\oldf pads8c.vpl}{\newf pads8c.vpl}{ts1} +\comparePLs{\oldf pads8t.vpl}{\newf pads8t.vpl}{t1} +\comparePLs{\oldf padsc7t.vpl}{\newf padsc7t.vpl}{ot1} +\comparePLs{\oldf padsc8t.vpl}{\newf padsc8t.vpl}{t1} %OK 11sp +\comparePLs{\oldf padsi7t.vpl}{\newf padsi7t.vpl}{ot1} +\comparePLs{\oldf padsi8c.vpl}{\newf padsi8c.vpl}{ts1} %OK 11sp +\comparePLs{\oldf padsi8t.vpl}{\newf padsi8t.vpl}{t1} +\comparePLs{\oldf padso7t.vpl}{\newf padso7t.vpl}{ot1} +\comparePLs{\oldf padso8c.vpl}{\newf padso8c.vpl}{ts1} +\comparePLs{\oldf padso8t.vpl}{\newf padso8t.vpl}{t1} + +\comparePLs{\oldf padb8a.pl}{\newf padb8a.pl}{} +\comparePLs{\oldf padb8r.pl}{\newf padb8r.pl}{8r} +\comparePLs{\oldf padbi8a.pl}{\newf padbi8a.pl}{} +\comparePLs{\oldf padbi8r.pl}{\newf padbi8r.pl}{8r} +\comparePLs{\oldf padbo8r.pl}{\newf padbo8r.pl}{8r} +\comparePLs{\oldf padr8a.pl}{\newf padr8a.pl}{} +\comparePLs{\oldf padr8r.pl}{\newf padr8r.pl}{8r} +\comparePLs{\oldf padrc8a.pl}{\newf padrc8a.pl}{} +\comparePLs{\oldf padrc8r.pl}{\newf padrc8r.pl}{8r} +\comparePLs{\oldf padri8a.pl}{\newf padri8a.pl}{} +\comparePLs{\oldf padri8r.pl}{\newf padri8r.pl}{8r} +\comparePLs{\oldf padro8r.pl}{\newf padro8r.pl}{8r} +\comparePLs{\oldf pads8a.pl}{\newf pads8a.pl}{} +\comparePLs{\oldf pads8r.pl}{\newf pads8r.pl}{8r} +\comparePLs{\oldf padsc8a.pl}{\newf padsc8a.pl}{} +\comparePLs{\oldf padsc8r.pl}{\newf padsc8r.pl}{8r} +\comparePLs{\oldf padsi8a.pl}{\newf padsi8a.pl}{} +\comparePLs{\oldf padsi8r.pl}{\newf padsi8r.pl}{8r} +\comparePLs{\oldf padso8r.pl}{\newf padso8r.pl}{8r} + +\bye
\ No newline at end of file diff --git a/Master/texmf-dist/doc/fontinst/base/test/scaledtest.tex b/Master/texmf-dist/doc/fontinst/base/test/scaledtest.tex new file mode 100644 index 00000000000..f5e9dd03a2d --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/scaledtest.tex @@ -0,0 +1,8 @@ +%&Plain +\input fontinst.sty + +\installfonts + \installfont{foo}{scaledtest scaled 300}{ot1}{OT1}{zzz}{m}{n}{} +\endinstallfonts + +\bye
\ No newline at end of file diff --git a/Master/texmf-dist/doc/fontinst/base/test/speedtest1.tex b/Master/texmf-dist/doc/fontinst/base/test/speedtest1.tex new file mode 100644 index 00000000000..a92823e7210 --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/speedtest1.tex @@ -0,0 +1,62 @@ +\input fontinst.sty + +\edef\spacecatcode{\the\catcode`\ } +\edef\nlcatcode{\the\catcode`\^^M} +\edef\atcatcode{\the\catcode`\@} +\edef\underscorecatcode{\the\catcode`\_} +\edef\tildecatcode{\the\catcode`\~} +\catcode`\ =9 +\catcode`\^^M=9 +\catcode`\@=11 +\catcode`\_=11 +\catcode`\~=10 + +\def\Mtxtopl#1#2{{ + \open_out{#2.pl} + \top_of_pl_hook + \out_line{(COMMENT~raw~font~#2~created~by~fontinst~ + v\fontinstversion)} + \out_line{} + \out_line{(COMMENT~Filename:~#2.pl)} + \out_line{(COMMENT~Created~by:~tex~\jobname)} + \out_line{(COMMENT~Created~using:~\string\mtxtopl{#1}{#2})} + \out_line{} + \out_line{(COMMENT~This~file~can~be~turned~into~a~ligless~TeX~font~ + with)} + \out_line{(COMMENT~pltotfm~#2.pl~#2.tfm)} + \out_line{} + \out_line{(COMMENT~THIS~FILE~CAN~THEN~BE~DELETED.)} + \out_line{} + \out_line{(DESIGNSIZE~R~10.0)} + \out_line{} + \let\setglyph=\iffalse + \let\endsetglyph=\fi + \let\setkern=\gobble_three + \let\setrawglyph=\Pl_raw_glyph + \inputmtx{#1} + \out_line{} + \out_line{(COMMENT~END~OF~FILE~#2.pl)} + \close_out{Raw~font} +}} +\def\Pl_raw_glyph#1#2#3#4#5#6#7#8{ + \a_count=#4 + \out_line{(CHARACTER~\vpl_int\a_count\space(COMMENT~#1)} + \out_lline{(CHARWD~R~\make_factor{#5})} + \out_lline{(CHARHT~R~\make_factor{#6})} + \out_lline{(CHARDP~R~\make_factor{#7})} + \out_lline{(CHARIC~R~\make_factor{#8})} + \out_lline{)} +} + + +\catcode`\@=\atcatcode +\catcode`\^^M=\nlcatcode +\catcode`\ =\spacecatcode +\catcode`\~=\tildecatcode +\catcode`\_=\underscorecatcode + +\batchmode +\for(n){1}{500}{1}\Mtxtopl{cmr5}{cmr5.new}\endfor(n) + +\bye + diff --git a/Master/texmf-dist/doc/fontinst/base/test/testfont.tex b/Master/texmf-dist/doc/fontinst/base/test/testfont.tex new file mode 100644 index 00000000000..544642aae45 --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/testfont.tex @@ -0,0 +1,208 @@ +% A testbed for font evaluation (see The METAFONTbook, Appendix H) + +\tracinglostchars=0 +\tolerance=1000 +\raggedbottom +\nopagenumbers +\parindent=0pt +\newlinechar=`@ +\hyphenpenalty=200 +\doublehyphendemerits=30000 +\hyphenation{prom-i-nent} + +\newcount\m \newcount\n \newcount\p \newdimen\dim +\chardef\other=12 + +\def\today{\ifcase\month\or + January\or February\or March\or April\or May\or June\or + July\or August\or September\or October\or November\or December\fi + \space\number\day, \number\year} +\def\hours{\n=\time \divide\n 60 + \m=-\n \multiply\m 60 \advance\m \time + \twodigits\n\twodigits\m} +\def\twodigits#1{\ifnum #1<10 0\fi \number#1} + +\def\init{\message{@Name of the font to test = } + \read-1 to\fontname \startfont + \message{Now type a test command (\string\help\space for help):}} +\def\startfont{\font\testfont=\fontname \spaceskip=0pt + \leftline{\sevenrm Test of \fontname\unskip\ on \today\ at \hours} + \medskip + \testfont \setbaselineskip + \ifdim\fontdimen6\testfont<10pt \rightskip=0pt plus 20pt + \else\rightskip=0pt plus 2em \fi + \spaceskip=\fontdimen2\testfont % space between words (\raggedright) + \xspaceskip=\fontdimen2\testfont \advance\xspaceskip by\fontdimen7\testfont} + +{\catcode`\|=0 \catcode`\\=\other +|gdef|help{|message{% +\init switches to another font;@% +\end or \bye finishes the run;@% +\table prints the font layout in tabular format;@% +\text prints a sample text, assuming TeX text font conventions;@% +\sample combines \table and \text;@% +\mixture mixes a background character with a series of others;@% +\alternation interleaves a background character with a series;@% +\alphabet prints all lowercase letters within a given background;@% +\ALPHABET prints all uppercase letters within a given background;@% +\series prints a series of letters within a given background;@% +\lowers prints a comprehensive test of lowercase;@% +\uppers prints a comprehensive test of uppercase;@% +\digits prints a comprehensive test of numerals;@% +\math prints a comprehensive test of TeX math italic;@% +\names prints a text that mixes upper and lower case;@% +\punct prints a punctuation test;@% +\bigtest combines many of the above routines;@% +\help repeats this message;@% +and you can use ordinary TeX commands (e.g., to \input a file).}}} + +\def\setbaselineskip{\setbox0=\hbox{\n=0 +\loop\char\n \ifnum \n<255 \advance\n 1 \repeat} +\baselineskip=6pt \advance\baselineskip\ht0 \advance\baselineskip\dp0 } + +\def\setchar#1{{\escapechar-1\message{\string#1 character = }% + \def\do##1{\catcode`##1=\other}\dospecials + \read-1 to\next + \expandafter\finsetchar\next\next#1}} +\def\finsetchar#1#2\next#3{\global\chardef#3=`#1 + \ifnum #3=`\# \global\chardef#3=#2 \fi} +\def\promptthree{\setchar\background + \setchar\starting \setchar\ending} + +\def\mixture{\promptthree \domix\mixpattern} +\def\alternation{\promptthree \domix\altpattern} +\def\mixpattern{\0\1\0\0\1\1\0\0\0\1\1\1\0\1} +\def\altpattern{\0\1\0\1\0\1\0\1\0\1\0\1\0\1\0\1\0} +\def\domix#1{\par\chardef\0=\background \n=\starting + \loop \chardef\1=\n #1\endgraf + \ifnum \n<\ending \advance\n 1 \repeat} + +\def\!{\discretionary{\background}{\background}{\background}} +\def\series{\promptthree \!\doseries\starting\ending\par} +\def\doseries#1#2{\n=#1\loop\char\n\!\ifnum\n<#2\advance\n 1 \repeat} +\def\complower{\!\doseries{`a}{`z}\doseries{'31}{'34}\par} +\def\compupper{\!\doseries{`A}{`Z}\doseries{'35}{'37}\par} +\def\compdigs{\!\doseries{`0}{`9}\par} +\def\alphabet{\setchar\background\complower} +\def\ALPHABET{\setchar\background\compupper} + +\def\lowers{\docomprehensive\complower{`a}{`z}{'31}{'34}} +\def\uppers{\docomprehensive\compupper{`A}{`Z}{'35}{'37}} +\def\digits{\docomprehensive\compdigs{`0}{`4}{`5}{`9}} +\def\docomprehensive#1#2#3#4#5{\par\chardef\background=#2 + \loop{#1} \ifnum\background<#3\m=\background\advance\m 1 + \chardef\background=\m \repeat \chardef\background=#4 + \loop{#1} \ifnum\background<#5\m=\background\advance\m 1 + \chardef\background=\m \repeat} + +\def\names{ {\AA}ngel\aa\ Beatrice Claire + Diana \'Erica Fran\c{c}oise Ginette H\'el\`ene Iris + Jackie K\=aren {\L}au\.ra Mar{\'\i}a N\H{a}ta{\l}{\u\i}e {\O}ctave + Pauline Qu\^eneau Roxanne Sabine T\~a{\'\j}a Ur\v{s}ula + Vivian Wendy Xanthippe Yv{\o}nne Z\"azilie\par} +\def\punct{\par\dopunct{min}\dopunct{pig}\dopunct{hid} + \dopunct{HIE}\dopunct{TIP}\dopunct{fluff} + \$1,234.56 + 7/8 = 9\% @ \#0\par} +\def\dopunct#1{#1,\ #1:\ #1;\ `#1'\ ?`#1?\ !`#1!\ (#1)\ [#1]\ #1*\ #1.\par} + +\def\bigtest{\sample + hamburgefonstiv HAMBURGEFONSTIV\par + \names \punct \lowers \uppers \digits} + +\def\math{\textfont1=\testfont \skewchar\testfont=\skewtrial + \mathchardef\Gamma="100 \mathchardef\Delta="101 + \mathchardef\Theta="102 \mathchardef\Lambda="103 \mathchardef\Xi="104 + \mathchardef\Pi="105 \mathchardef\Sigma="106 \mathchardef\Upsilon="107 + \mathchardef\Phi="108 \mathchardef\Psi="109 \mathchardef\Omega="10A + \def\ii{i} \def\jj{j} + \def\\##1{|##1|+}\mathtrial + \def\\##1{##1_2+}\mathtrial + \def\\##1{##1^2+}\mathtrial + \def\\##1{##1/2+}\mathtrial + \def\\##1{2/##1+}\mathtrial + \def\\##1{##1,{}+}\mathtrial + \def\\##1{d##1+}\mathtrial + \let\ii=\imath \let\jj=\jmath \def\\##1{\hat##1+}\mathtrial} +\newcount\skewtrial \skewtrial='177 +\def\mathtrial{$\\A \\B \\C \\D \\E \\F \\G \\H \\I \\J \\K \\L \\M \\N \\O + \\P \\Q \\R \\S \\T \\U \\V \\W \\X \\Y \\Z \\a \\b \\c \\d \\e \\f \\g + \\h \\\ii \\\jj \\k \\l \\m \\n \\o \\p \\q \\r \\s \\t \\u \\v \\w \\x \\y + \\z \\\alpha \\\beta \\\gamma \\\delta \\\epsilon \\\zeta \\\eta \\\theta + \\\iota \\\kappa \\\lambda \\\mu \\\nu \\\xi \\\pi \\\rho \\\sigma \\\tau + \\\upsilon \\\phi \\\chi \\\psi \\\omega \\\vartheta \\\varpi \\\varphi + \\\Gamma \\\Delta \\\Theta \\\Lambda \\\Xi \\\Pi \\\Sigma \\\Upsilon + \\\Phi \\\Psi \\\Omega \\\partial \\\ell \\\wp$\par} +\def\mathsy{\begingroup\skewtrial='060 % for math symbol font tests + \def\mathtrial{$\\A \\B \\C \\D \\E \\F \\G \\H \\I \\J \\K \\L + \\M \\N \\O \\P \\Q \\R \\S \\T \\U \\V \\W \\X \\Y \\Z$\par} + \math\endgroup} + +\def\oct#1{\hbox{\rm\'{}\kern-.2em\it#1\/\kern.05em}} % octal constant +\def\hex#1{\hbox{\rm\H{}\tt#1}} % hexadecimal constant +\def\setdigs#1"#2{\gdef\h{#2}% \h=hex prefix; \0\1=corresponding octal + \m=\n \divide\m by 64 \xdef\0{\the\m}% + \multiply\m by-64 \advance\m by\n \divide\m by 8 \xdef\1{\the\m}} +\def\testrow{\setbox0=\hbox{\penalty 1\def\\{\char"\h}% + \\0\\1\\2\\3\\4\\5\\6\\7\\8\\9\\A\\B\\C\\D\\E\\F% + \global\p=\lastpenalty}} % \p=1 if none of the characters exist +\def\oddline{\cr + \noalign{\nointerlineskip} + \multispan{19}\hrulefill& + \setbox0=\hbox{\lower 2.3pt\hbox{\hex{\h x}}}\smash{\box0}\cr + \noalign{\nointerlineskip}} +\newif\ifskipping +\def\evenline{\loop\skippingfalse + \ifnum\n<256 \m=\n \divide\m 16 \chardef\next=\m + \expandafter\setdigs\meaning\next \testrow + \ifnum\p=1 \skippingtrue \fi\fi + \ifskipping \global\advance\n 16 \repeat + \ifnum\n=256 \let\next=\endchart\else\let\next=\morechart\fi + \next} +\def\morechart{\cr\noalign{\hrule\penalty5000} + \chartline \oddline \m=\1 \advance\m 1 \xdef\1{\the\m} + \chartline \evenline} +\def\chartline{&\oct{\0\1x}&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&\:&&} +\def\chartstrut{\lower4.5pt\vbox to14pt{}} +\def\table{$$\global\n=0 + \halign to\hsize\bgroup + \chartstrut##\tabskip0pt plus10pt& + &\hfil##\hfil&\vrule##\cr + \lower6.5pt\null + &&&\oct0&&\oct1&&\oct2&&\oct3&&\oct4&&\oct5&&\oct6&&\oct7&\evenline} +\def\endchart{\cr\noalign{\hrule} + \raise11.5pt\null&&&\hex 8&&\hex 9&&\hex A&&\hex B& + &\hex C&&\hex D&&\hex E&&\hex F&\cr\egroup$$\par} +\def\:{\setbox0=\hbox{\char\n}% + \ifdim\ht0>7.5pt\reposition + \else\ifdim\dp0>2.5pt\reposition\fi\fi + \box0\global\advance\n 1 } +\def\reposition{\setbox0=\vbox{\kern2pt\box0}\dim=\dp0 + \advance\dim 2pt \dp0=\dim} +\def\centerlargechars{ + \def\reposition{\setbox0=\hbox{$\vcenter{\kern2pt\box0\kern2pt}$}}} + +\def\text{{\advance\baselineskip-4pt +\setbox0=\hbox{abcdefghijklmnopqrstuvwxyz} +\ifdim\hsize>2\wd0 \ifdim 15pc>2\wd0 \hsize=15pc \else \hsize=2\wd0 \fi\fi +On November 14, 1885, Senator \& Mrs.~Leland Stanford called +together at their San Francisco mansion the 24~prominent men who had +been chosen as the first trustees of The Leland Stanford Junior University. +They handed to the board the Founding Grant of the University, which they +had executed three days before. This document---with various amendments, +legislative acts, and court decrees---remains as the University's charter. +In bold, sweeping language it stipulates that the objectives of the University +are ``to qualify students for personal success and direct usefulness in life; +and to promote the publick welfare by exercising an influence in behalf of +humanity and civilization, teaching the blessings of liberty regulated by +law, and inculcating love and reverence for the great principles of +government as derived from the inalienable rights of man to life, liberty, +and the pursuit of happiness.'' \moretext +(!`THE DAZED BROWN FOX QUICKLY GAVE 12345--67890 JUMPS!)\par}} +\def\moretext{?`But aren't Kafka's Schlo{\ss} and {\AE}sop's {\OE}uvres +often na{\"\i}ve vis-\`a-vis the d{\ae}monic ph{\oe}nix's official r\^ole +in fluffy souffl\'es? } +\def\omitaccents{\let\moretext=\relax} + +\def\sample{\table\text} + +\ifx\noinit!\else\init\fi diff --git a/Master/texmf-dist/doc/fontinst/base/test/testsc.tex b/Master/texmf-dist/doc/fontinst/base/test/testsc.tex new file mode 100644 index 00000000000..c54452d45e1 --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/testsc.tex @@ -0,0 +1,41 @@ +\input fontinst.sty + +\transformfont{padr8r} {\reencodefont{8r}{\fromafm{padr8a}}} +\transformfont{padrc8r}{\reencodefont{8r}{\fromafm{padrc8a}}} +\transformfont{pads8r} {\reencodefont{8r}{\fromafm{pads8a}}} +\transformfont{padsc8r}{\reencodefont{8r}{\fromafm{padsc8a}}} +\fromafm{padr8x} +\fromafm{pads8x} + +\installfonts + +\installfamily{T1}{pad} {} +\installfamily{T1}{padx}{} +\installfamily{T1}{padj}{} + +\installfont{padrc8t}{padrc8r,latin} + {T1}{T1}{pad}{m}{sc}{} +\installfont{padrc9e} + {kernoff,padr8r,padr8x,kernon,glyphoff,padrc8r,glyphon, + resetsc,latinsc} + {T1c}{T1}{padx}{m}{sc}{} +\installfont{padrc9d} + {kernoff,padr8r,padr8x,kernon,glyphoff,padrc8r,glyphon, + resetosf,resetsc,latinsc} + {T1cj}{T1}{padj}{m}{sc}{} + +\installfont{padsc8t}{padsc8r,latin} + {T1}{T1}{pad}{m}{sc}{} +\installfont{padsc9e} + {kernoff,pads8r,pads8x,kernon,glyphoff,padsc8r,glyphon, + resetsc,latinsc} + {T1c}{T1}{padx}{sb}{sc}{} +\installfont{padsc9d} + {kernoff,pads8r,pads8x,kernon,glyphoff,padrc8r,glyphon, + resetosf,resetsc,latinsc} + {T1cj}{T1}{padj}{sb}{sc}{} + +\endinstallfonts +\bye + + diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1901test.tex b/Master/texmf-dist/doc/fontinst/base/test/v1901test.tex new file mode 100644 index 00000000000..81a6218f679 --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1901test.tex @@ -0,0 +1,214 @@ +% Test of fontinst v1.901. +% Started 1999/03/13. +\input fontinst.sty + +% Part one---test of pooled file allocation. +\catcode`\_=11 +\catcode`\@=11 + +\def\show_out_filenames{% + \immediate\write16{\string\count17=\the\count17}% + \for(i){-1}{16}{1}% + \immediate\write16{Stream \strint{i}: + \x_cs\meaning{out_filename-\strint{i}}% + }% + \endfor(i)% +} + +% %1 Standard usage +% \show_out_filenames +% \open_pout\tF{\jobname.out} +% \show_out_filenames +% \pout_line\tF{Hello world!} +% \close_pout\tF{Test output} +% \show_out_filenames +% % Seems to work fine. + +% %2 Allocating LOTS of files. +% \newcount\j_count +% \newcount\k_count +% \j_count=0 +% \k_count=1 +% \for(o){1}{48}{1} +% \x_cs\open_pout{F-\strint{o}}{\jobname.\strint{o}}% +% \ifodd \int{o} \else +% \x_cs\pout_line{F-\the\k_count}{% +% open=\strint{o} close=\the\j_count\space write=\the\k_count +% }% +% \multiply \k_count \thr@@ +% \advance \k_count \@ne +% \d_count=\k_count +% \divide \d_count \int{o}% +% \multiply \d_count \int{o}% +% \advance \k_count -\d_count +% \advance \k_count \@ne +% \advance \j_count \@ne +% \x_cs\close_pout{F-\the\j_count}{Test data}% +% \fi +% \d_count=\int{o}% +% \divide \d_count 8% +% \multiply \d_count 8% +% \advance \d_count -\int{o}% +% \ifnum 0=\d_count \show_out_filenames \fi +% \endfor(o) +% % Seems to work fine as well. + + +%% Part two---test of reimplemented \transformfont stuff +%% Part two B---test of \recordtransforms stuff + +\recordtransforms{mapfrags.tex} +\transformfont{v1901test1}{ + \xscalefont{2000}{\reencodefont{t1c}{\frommtx{v1901test}}} +} +\transformfont{v1901test2}{ + \yscalefont{500}{\xscalefont{2000}{\frommtx{v1901test}}} +} +\transformfont{v1901test3}{ + \reencodefont{t1}{\slantfont{100}{\frommtx{v1901test}}} +} +\endrecordtransforms + + +\bye + +%% Part three---test of reglyphing + +\reglyphfonts + \resetcommand\iftokeep#1\then{\ifnum 0<#1} + % This means that an AFM command will survive the conversion only if + % it refers to at least one renamed glyph and not refer to any killed + % glyph. + +% \offmtxcommand\setrawglyph +% \offmtxcommand\setglyph +% % This reglyphing file is inteded for extracting information from the +% % AFM file of a Caps, Small caps, and Oldstyle figures fonts--with the +% % intention to build a corresponding virtual font with glyphs that are +% % present in the Regular and Expert Regular variants instead. Hence +% % there is no need for \setrawglyph or \setglyph commands (the +% % dimensions of the characters are known from the Reg. and Exp.Reg. +% % AFM's), but the \setkern commands are most interesting (since 8x +% % fonts don't contain any upper case letters, and hence has no kerning +% % pairs between these and the small caps either). + + + \renameglyph{dollaroldstyle}{dollar} + \renameglyph{ampersandsmall}{ampersand} + + \renameglyph{zerooldstyle}{zero} + \renameglyph{oneoldstyle}{one} + \renameglyph{twooldstyle}{two} + \renameglyph{threeoldstyle}{three} + \renameglyph{fouroldstyle}{four} + \renameglyph{fiveoldstyle}{five} + \renameglyph{sixoldstyle}{six} + \renameglyph{sevenoldstyle}{seven} + \renameglyph{eigtholdstyle}{eight} + \renameglyph{nineoldstyle}{nine} + + \renameglyph{Asmall}{a} + \renameglyph{Bsmall}{b} + \renameglyph{Csmall}{c} + \renameglyph{Dsmall}{d} + \renameglyph{Esmall}{e} + \renameglyph{Fsmall}{f} + \renameglyph{Gsmall}{g} + \renameglyph{Hsmall}{h} + \renameglyph{Ismall}{i} + \renameglyph{Jsmall}{j} + \renameglyph{Ksmall}{k} + \renameglyph{Lsmall}{l} + \renameglyph{Msmall}{m} + \renameglyph{Nsmall}{n} + \renameglyph{Osmall}{o} + \renameglyph{Psmall}{p} + \renameglyph{Qsmall}{q} + \renameglyph{Rsmall}{r} + \renameglyph{Ssmall}{s} + \renameglyph{Tsmall}{t} + \renameglyph{Usmall}{u} + \renameglyph{Vsmall}{v} + \renameglyph{Wsmall}{w} + \renameglyph{Xsmall}{x} + \renameglyph{Ysmall}{y} + \renameglyph{Zsmall}{z} + + \renameglyph{centoldstyle}{cent} + + % \renameglyph{FIsmall}{fi} + % \renameglyph{FLsmall}{fl} + % These two aren't really necessary, since the ligature `fi' looks + % exactly as the letters `f'`i' next to each others. + \killglyph{fi} + \killglyph{fl} + + \renameglyph{Gravesmall}{grave} + \renameglyph{Acutesmall}{acute} + \renameglyph{Circumflexsmall}{circumflex} + \renameglyph{Tildesmall}{tilde} + \renameglyph{Macronsmall}{macron} + \renameglyph{Brevesmall}{breve} + \renameglyph{Dotaccentsmall}{dotaccent} + \renameglyph{Dieresissmall}{dieresis} + \renameglyph{Ringsmall}{ring} + \renameglyph{Cedillasmall}{cedilla} + \renameglyph{Ogoneksmall}{ogonek} + \renameglyph{Caronsmall}{caron} + + \renameglyph{AEsmall}{ae} + \renameglyph{dotlessIsmall}{dotlessi} + \renameglyph{Lslashsmall}{lslash} + \renameglyph{Oslashsmall}{oslash} + \renameglyph{OEsmall}{oe} + % \renameglyph{SSsmall}{germandbls} + % This isn't really needed in the AGaramond font family, since `SSsmall' + % looks exactly like `Ssmall'`Ssmall' + \killglyph{germandbls} + + \renameglyph{Oacutesmall}{oacute} + \renameglyph{Odieresissmall}{odieresis} + \renameglyph{Ucircumflexsmall}{ucircumflex} + + \renameglyph{Uacutesmall}{uacute} + \renameglyph{Eacutesmall}{eacute} + \renameglyph{Iacutesmall}{iacute} + \renameglyph{Icircumflexsmall}{icircumflex} + + \renameglyph{Thornsmall}{thorn} + \renameglyph{Yacutesmall}{yacute} + + \renameglyph{Ocircumflexsmall}{ocircumflex} + \renameglyph{Otildesmall}{otilde} + \renameglyph{Ntildesmall}{ntilde} + \renameglyph{Ydieresissmall}{ydieresis} + \renameglyph{Ethsmall}{eth} + \renameglyph{Acircumflexsmall}{acircumflex} + \renameglyph{Aringsmall}{aring} + \renameglyph{Ccedillasmall}{ccedilla} + + \renameglyph{Ugravesmall}{ugrave} + \renameglyph{Zcaronsmall}{zcaron} + \renameglyph{Idieresissmall}{idieresis} + \renameglyph{Agravesmall}{agrave} + + \renameglyph{Ogravesmall}{ograve} + + \renameglyph{Udieresissmall}{udieresis} + \renameglyph{Edieresissmall}{edieresis} + \renameglyph{Aacutesmall}{aacute} + \renameglyph{Igravesmall}{igrave} + \renameglyph{Idieresissmall}{idieresis} + \renameglyph{Adieresissmall}{adieresis} + + \renameglyph{Scaronsmall}{scaron} + \renameglyph{Egravesmall}{egrave} + \renameglyph{Atildesmall}{atilde} + \renameglyph{Ecircumflexsmall}{ecircumflex} + + \reglyphfont{K-padrc}{gdsc} + \reglyphfont{K-padsc}{padsc8a} +\endreglyphfonts + + +\bye
\ No newline at end of file diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1902test.tex b/Master/texmf-dist/doc/fontinst/base/test/v1902test.tex new file mode 100644 index 00000000000..7274fb76597 --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1902test.tex @@ -0,0 +1,11 @@ +\input fontinst.sty + +\generalpltomtx{cmr5}{cmr5;1}{pl}{OT1} +\generalpltomtx{padr9d}{padr9d;1}{vpl}{} +\generalpltomtx{padr9d}{padr9d;2}{vpl}{OT1} + +\transformfont{cmr5;2}{\fromplgivenetx{cmr5}{OT1}} +\transformfont{padr9d;3}{\fromvpl{padr9d}} +\transformfont{padr9d;4}{\fromvplgivenetx{padr9d}{OT1}} + +\bye
\ No newline at end of file diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1905test.tex b/Master/texmf-dist/doc/fontinst/base/test/v1905test.tex new file mode 100644 index 00000000000..47117acc5fb --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1905test.tex @@ -0,0 +1,22 @@ +\input fontinst.sty +\catcode`\_=11\catcode`\ =9\catcode`\^^M=9 +\catcode`\~=10\catcode`\@=11 + +\fontinst_error{Hungarian}{ + I~will~not~buy~this~record,\message_break + it~is~scratched +}\error_help_a + +\fontinst_warning{Hungarian}{Your~hovercraft~is~full~of~eels} + +\fontinst_info{Hungarian}{That~will~be~six~pence,~please} + +\fontinst_warning_no_line{Hungarian}{ + Do~you~want~to~come~home~to~my~place\message_break + and~pantsy~pantsy? +} + + + + +\bye
\ No newline at end of file diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1906test.tex b/Master/texmf-dist/doc/fontinst/base/test/v1906test.tex new file mode 100644 index 00000000000..92ed6281198 --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1906test.tex @@ -0,0 +1,12 @@ +%&Plain +% Test of fontinst v1.906. +% Begun 1999/08/01. +\input fontinst.sty + +\installfonts + \installfamily{U}{ztest1}{} + \installfont{v1906test}{v1906test}{v1906test}{U}{ztest1}{m}{n}{} +\endinstallfonts + +\bye + diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1913test.tex b/Master/texmf-dist/doc/fontinst/base/test/v1913test.tex new file mode 100644 index 00000000000..b9382cdf898 --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1913test.tex @@ -0,0 +1,21 @@ +\input fontinst.sty + +\recordtransforms{v1913test.recs} + +\transformfont{padr8r}{\reencodefont{8r}{\fromafm{padr8a}}} +\transformfont{padr8r-ys}{\yscalefont{\div{397000}{663}}{\frommtx{padr8r}}} +\reglyphfonts + \renameglyph{oneoldstyle}{one} + \reglyphfont{padr8r-ys2}{padr8r-ys} +\endreglyphfonts + +\installfonts + \installfamily{T1}{pad}{} + \installfamily{8r}{pad}{} + \installfont{padr9d}{padr8r,padr8r-ys2,padr8x,latin}{t1j}{T1}{pad}{m}{n}{} + \installrawfont{padr8r2}{padr8r-ys}{8r}{8r}{pad}{m}{n}{} +\endinstallfonts + +\endrecordtransforms + +\bye
\ No newline at end of file diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1914test.tex b/Master/texmf-dist/doc/fontinst/base/test/v1914test.tex new file mode 100644 index 00000000000..73b271b986c --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1914test.tex @@ -0,0 +1,50 @@ +\input fontinst.sty + +%1 +\recordtransforms{v1914test.recs} + +\transformfont{padr8r}{\reencodefont{8r}{\fromafm{padr8a}}} +\for(x){0}{2}{1} + \for(y){0}{2}{1} + \transformfont{p-ad-rr--8r--\strint{x}=\strint{y}}{ + \xscalefont{\add{\mul{\int{x}}{300}}{700}}{ + \yscalefont{\add{\mul{\int{y}}{300}}{700}}{ + \frommtx{padr8r}}}} + \endfor(y) +\endfor(x) + +\installfonts + \installfamily{T1}{padxy}{} + \installfamily{8r}{padxy}{} + \for(x){0}{2}{1} + \for(y){0}{2}{1} + \installfont{p-ad-rr--8t--\strint{x}=\strint{y}} + {p-ad-rr--8r--\strint{x}=\strint{y},latin} + {t1}{T1}{padxy}{m\strint{x}\strint{y}}{n}{} + \installrawfont{p-ad-rr--8r--\strint{x}=\strint{y}} + {p-ad-rr--8r--\strint{x}=\strint{y},8r} + {8r}{8r}{padxy}{m\strint{x}\strint{y}}{n}{} + \endfor(y) + \endfor(x) +\endinstallfonts + +\endrecordtransforms + +% % \tracingmacros=1\tracingcommands=2 +% %2 +% \installfonts +% \installrawfont{cmr5}{cmr5,\metrics +% \resetint{xheight}{\mul{\int{xheight}}{2}},kernoff}{ot1}{OT1} +% {cmr}{m}{n}{5} +% \installfont{padr18t}{padr8r scaled 856,% +% \metrics \message{% +% \ifisint{rawscale}\then\strint{rawscale}\else None\fi +% }% +% \expandafter\show \csname g-A\endcsname +% ,latin,% +% \metrics \message{% +% \ifisint{rawscale}\then\strint{rawscale}\else None\fi +% }}{t1}{T1}{pad}{m}{ns}{} +% \endinstallfonts + +\bye
\ No newline at end of file diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1914testmap.tex b/Master/texmf-dist/doc/fontinst/base/test/v1914testmap.tex new file mode 100644 index 00000000000..17dd9c2375d --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1914testmap.tex @@ -0,0 +1,9 @@ +\input finstmsc.sty +\AssumeLWFN +\adddriver{dvips}{v1914test.map} +\adddriver{debug}{v1914test.debug} +\debugvalue{PS_font_file} +\adddriver{pltotf}{v1914test.sh} % v1.915 feature, actually +\input v1914test.recs +\donedrivers +\bye diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1915test.tex b/Master/texmf-dist/doc/fontinst/base/test/v1915test.tex new file mode 100644 index 00000000000..b60946a402b --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1915test.tex @@ -0,0 +1,25 @@ +\input fontinst.sty + +% %1: Catcodes +% \def\do#1{Catcode of `\string#1 = \the\catcode`#1 ^^J} +% \def\showcatcodes{\message{\do{\ }\do{\^^M}\do{\@}\do{\_}\do{\~}}} +% +% \showcatcodes +% \show\fontinstcc +% \fontinstcc +% \showcatcodes +% \show\normalcc +% \normalcc +% \showcatcodes + +%2: Aliased glyphs +\input Knuth:fontinst:New.fontinst:cyrfinst:etc:fnstcorr.tex +\transformfont{padsc8r}{\reencodefont{8r}{\fromafm{padsc8a}}} +\def\renameglyph#1#2{\galias{#1}{#2}} +\input csc2x.tex +\transformfont{padscx8r}{\reencodefont{8r}{\fromafm{padsc8a}}} +% När glyfnamnen har tagits bort från de omkodade PL-filerna så är +% de i allt väsentligt lika. Sålunda tycks det fungera! + + +\bye
\ No newline at end of file diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1915testmap.tex b/Master/texmf-dist/doc/fontinst/base/test/v1915testmap.tex new file mode 100644 index 00000000000..7e83526cd40 --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1915testmap.tex @@ -0,0 +1,9 @@ +\input finstmsc.sty +\adddriver{pltotf}{v1915test.sh} +\input v1914test.recs +\donedrivers +\setstr{TFMfileprefix}{:a:b:c:} +\adddriver{pltotf}{v1915test.sh2} +\input v1913test.recs +\donedrivers +\bye diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1916test.tex b/Master/texmf-dist/doc/fontinst/base/test/v1916test.tex new file mode 100644 index 00000000000..56f26a51b0f --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1916test.tex @@ -0,0 +1,14 @@ +% v1916test.tex + +\input fontinst.sty + +% \half and \otherhalf +\fontinstcc +\for(i){-5}{5}{1} + \eval_expr_to\b_count{\half{\int{i}}} + \eval_expr{\otherhalf{\int{i}}} + \immediate\write16{\strint{i}:~\the\b_count \space+~ \the\result} +\endfor(i) +\normalcc + +\bye diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1916test2.tex b/Master/texmf-dist/doc/fontinst/base/test/v1916test2.tex new file mode 100644 index 00000000000..8cc954f2615 --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1916test2.tex @@ -0,0 +1,27 @@ +%&Plain +\input fontinst.sty + +% %1 \ifareglyphs +% +% \setrawglyph{f}{xfont}{10pt}{102}{375}{750}{375}{50} +% \setrawglyph{g}{xfont}{10pt}{102}{375}{750}{375}{50} +% \setrawglyph{h}{xfont}{10pt}{102}{375}{750}{375}{50} +% +% \ifareglyphs{}\then True \else False \fi +% \ifareglyphs{a}\then True \else False \fi +% \ifareglyphs{f}\then True \else False \fi +% \ifareglyphs{f,a}\then True \else False \fi +% \ifareglyphs{a,f}\then True \else False \fi +% \ifareglyphs{f,g}\then True \else False \fi +% \ifareglyphs{f,g,a}\then True \else False \fi + +%2 \setfontdimen +\generalpltomtx{ecrm1000}{ecrm1000}{pl}{t1draft} +\generalpltomtx{ecss1000}{ecss1000}{pl}{t1draft} +\transformfont{ecdh-shrunk}{% + \yscalefont{500}{\fromplgivenetx{ecdh1000}{t1draft}}% +} + +\bye + + diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1923test.tex b/Master/texmf-dist/doc/fontinst/base/test/v1923test.tex new file mode 100644 index 00000000000..5115f93b373 --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1923test.tex @@ -0,0 +1,43 @@ +%&Plain + +\input fontinst.sty + +% %1 +% \transformfont{padr8r}{\reencodefont{8r}{\fromafm{padr8a}}} +% \transformfont{padri8r}{\reencodefont{8r}{\fromafm{padri8a}}} +% +% \installfonts +% \installfamily{T1}{pad2}{} +% \installfont{zpad2i8t}{padri8r scaled 1009,% +% padr8r scaled 999 suffix -upright scaled 1009,\metrics +% % \expandafter\show \csname r-T-upright\endcsname +% \unsetglyph{parenleft} +% \setglyph{parenleft} +% \glyph{parenleft-upright}{1000} +% \endsetglyph +% \resetglyph{parenright} +% \glyph{parenright-upright}{1000} +% \endresetglyph,latin}{t1}{T1}{pad2}{m}{it}{} +% \endinstallfonts + +% %2 +% +% \installfonts +% \installfamily{U}{fad}{} +% \installfont{fadrr}{fadrr}{textfdim,fadrr mtxasetx}{U}{fad}{m}{n}{} +% \endinstallfonts + +% %3 +% \transformfont{pagk8r}{\reencodefont{8r}{\fromafm{pagk8a}}} +% \installfonts +% \installfont{pagk8t}{pagk8r,newlatin}{t1}{T1}{pag}{m}{n}{} +% \endinstallfonts + +%4 +\installfonts + \installfont{test}{rsfs10 encoding rsfs,cmsy10}{oms}{OMS}{xxx}{m}{n}{} +\endinstallfonts + + +\bye + diff --git a/Master/texmf-dist/doc/fontinst/base/test/v1927test.tex b/Master/texmf-dist/doc/fontinst/base/test/v1927test.tex new file mode 100644 index 00000000000..b21f16bf60e --- /dev/null +++ b/Master/texmf-dist/doc/fontinst/base/test/v1927test.tex @@ -0,0 +1,18 @@ +%&Plain + +\input finstmsc.sty + +% %1 +% \etxtoenc{ot1}{temp} + +%2 +\storemapdata{a}{\fromafm{a}{XX}}{} +\storemapdata{a}{\fromafm{a}{XX}}{} +\storemapdata{a}{\fromafm{a}{XY}}{} +\storemapdata{a}{\fromafm{a}{XX}}{} +\storemapdata{a}{\fromafm{a}{XX}}{\reencodefont{8r}} + + + +\bye + |