summaryrefslogtreecommitdiff
path: root/info/maketexwork/ex-06-09
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
committerNorbert Preining <norbert@preining.info>2019-09-02 13:46:59 +0900
commite0c6872cf40896c7be36b11dcc744620f10adf1d (patch)
tree60335e10d2f4354b0674ec22d7b53f0f8abee672 /info/maketexwork/ex-06-09
Initial commit
Diffstat (limited to 'info/maketexwork/ex-06-09')
-rw-r--r--info/maketexwork/ex-06-0933
1 files changed, 33 insertions, 0 deletions
diff --git a/info/maketexwork/ex-06-09 b/info/maketexwork/ex-06-09
new file mode 100644
index 0000000000..0852abdb0c
--- /dev/null
+++ b/info/maketexwork/ex-06-09
@@ -0,0 +1,33 @@
+% use any IBM OEM encoded fixed width font!
+\font\screenfont=ncrr-ibm at 7pt
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% These macros are derived from The TeXbook pg 380-381
+\def\uncatcodespecials{\def\do##1{\catcode`##1=12 }\dospecials}
+\def\setupverbatim{\screenfont%
+ \def\par{\leavevmode\endgraf\relax}%
+ \obeylines\uncatcodespecials%
+ \catcode`\\=0\catcode`\{=1\catcode`\}=2\obeyspaces}
+{\obeyspaces\global\let =\ } % let active space be a control space
+\def\screenlisting#1{\par\begingroup%
+ \def\c##1{\char##1}\setupverbatim\input{#1}%
+ \endgroup}
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\def\screenbox#1{%
+ \vbox{\offinterlineskip%
+ \parskip=0pt\parindent=0pt%
+ \screenlisting{#1}}}
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% Input converted file '#1' and set it inside a box with '#2' padding
+% space around the image.
+\def\screendump#1#2{%
+ \hbox{\vrule%
+ \vbox{\hrule%
+ \hbox{\hskip#2%
+ \vbox{\vskip#2%
+ \def\twentyxs{xxxxxxxxxxxxxxxxxxxx}%
+ \setbox0=\hbox{\screenfont\twentyxs\twentyxs\twentyxs\twentyxs}%
+ \hbox to \wd0{\screenbox{#1}\hss}%
+ \vskip#2}%
+ \hskip#2}%
+ \hrule}%
+ \vrule\hss}}