Debian Codegraph @

texmf-dist/source/latex/fistrum/fistrum.ins

raw
1 %%
2 %% Copyright (C) 2014-2019 by Patrick Happel (lipsum)
3 %% Copyright (C) 2021 by Phelype Oleinik (lipsum)
4 %% Copyright (C) 2023 by David Davó (fistrum)
5 %%
6 %% This file may be distributed and/or modified under the
7 %% conditions of the LaTeX Project Public License, either
8 %% version 1.3 of this license or (at your option) any later
9 %% version. The latest version of this license is in:
10 %%
11 %% http://www.latex-project.org/lppl.txt
12 %%
13 %% and version 1.3 or later is part of all distributions of
14 %% LaTeX version 2005/12/01 or later.
15 %%
16 \input docstrip.tex
17 \askforoverwritefalse
18 \keepsilent
19 \preamble
20
21 This file is part of the package fistrum for use with LaTeX2e.
22
23 Function: Access to 150 paragraphs of pecadorrr text.
24
25 This program may be distributed and/or modified under the
26 conditions of the LaTeX Project Public License, either version 1.3
27 of this license or (at your option) any later version.
28 The latest version of this license is in
29 http://www.latex-project.org/lppl.txt
30 and version 1.3 or later is part of all distributions of LaTeX
31 version 2005/12/01 or later.
32
33 Please send error reports and suggestions for improvements to
34 https://github.com/daviddavo/fistrum
35
36 \endpreamble
37 \postamble
38 \endpostamble
39
40 \generate{\file{fistrum.sty}{\from{fistrum.dtx}{package}}}
41
42 \newread\fistread
43 \newread\fistwrite
44 \newcount\parno
45 \newif\ifinpar
46 \def\empty{}%
47 \def\line{}%
48 \edef\lb{\string{}%
49 \edef\rb{\string}}%
50 \begingroup\lccode`\?=`\%
51 \lowercase{\endgroup\def\pc{?}}%
52 \def\wline{\immediate\write\fistwrite}%
53 \def\genfistrum#1#2#3{%
54 \begingroup
55 \def\inFileName{fistrum-#1.txt}%
56 \def\outFileName{#2.ftd.tex}%
57 \openin\fistread\inFileName\space
58 \immediate\openout\fistwrite\outFileName\space
59 \inparfalse
60 \parno=0
61 \endlinechar=-1
62 \def\~{ }%
63 \def\ReferenceLines{%
64 \MetaPrefix ^^J%
65 \MetaPrefix\~The original source files were:^^J%
66 \MetaPrefix ^^J%
67 \MetaPrefix\~\inFileName^^J}%
68 \immediate\write\fistwrite{\defaultpreamble}%
69 \immediate\write\fistwrite{\string\SetFistrumLanguage{#3}}%
70 \genfistrumaux\genfistrumaux
71 \closein\fistread
72 \immediate\closeout\fistwrite
73 \endgroup}
74 \def\genfistrumaux#1\genfistrumaux{%
75 \ifeof\fistread\let\line\empty
76 \else \read\fistread to \line \fi
77 \toks0{#1}%
78 \ifx\line\empty
79 \ifinpar
80 \wline{\the\toks0 \rb\pc^^J\pc}%
81 \inparfalse
82 \fi
83 \else
84 \ifinpar
85 \wline{\the\toks0 }%
86 \else
87 \inpartrue
88 \advance\parno by 1
89 \wline{\string\NewFistrumPar\lb\pc\~{\the\parno}}%
90 \fi
91 \fi
92 \ifeof\fistread\expandafter\genfistrumend\fi
93 \expandafter\genfistrumaux\line\genfistrumaux}
94 \def\genfistrumend#1\genfistrumaux#2\genfistrumaux{}
95
96 \genfistrum{la}{fistrum-la}{latin}
97 \genfistrum{es}{fistrum-es}{spanish}
98
99 \catcode`\ =13 \edef {\space}%
100 \Msg{****************************************************}
101 \Msg{* *}
102 \Msg{* To finish the installation you have to move the *}
103 \Msg{* following files into a directory searched *}
104 \Msg{* by TeX: *}
105 \Msg{* *}
106 \Msg{* fistrum.sty *}
107 \Msg{* fistrum-es.ftd.tex *}
108 \Msg{* fistrum-la.ftd.tex *}
109 \Msg{* *}
110 \Msg{* To produce the documentation run the file *}
111 \Msg{* fistrum.dtx through XeLaTeX or LuaLaTeX. *}
112 \Msg{* *}
113 \Msg{* Happy TeXing! *}
114 \Msg{* *}
115 \Msg{****************************************************}
116
117 \endbatchfile