File: showenc

package info (click to toggle)
texlive-lang 2012.20120611-2
  • links: PTS
  • area: main
  • in suites: wheezy
  • size: 531,364 kB
  • sloc: perl: 29,862; ansic: 3,234; sh: 1,324; makefile: 1,291; python: 824; ruby: 576; lisp: 485; awk: 431; sed: 138; xml: 57; cs: 2
file content (18 lines) | stat: -rw-r--r-- 490 bytes parent folder | download | duplicates (35)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#!/bin/sh
# sample usage:
#   showenc T2A
#   showenc OT1 '\setint{monowidth}{1}'

latex << EOF | perl -ne 'next if (!s/^SLOT: //); s,\n,\0,; $q.=$_;
  END { $_=$q; s,\0\[LIG] ([^\0]*), L $1,g; s,\0,\n,g; print }'
\input fontinst.sty
\catcode\`\_=11
$2
\def\setint#1#2{}
\def\setslot#1{\edef\slot_name{#1}\do_slot
  \typeout{SLOT: \the\slot_number\space\slot_name\space;}}
\def\ligature#1#2#3{\typeout{SLOT: [#1] #2 #3 ;}\vpl_ligature{#1}{#2}{#3}}
\inputetx{$1}
\bye
EOF
rm -f fontinst.log