Path: kuis!kuee!tsato
From: tsato@ibuki.kuee.kyoto-u.ac.jp (Toru Sato)
Newsgroups: fj.comp.texhax
Subject: Re: Genkou Youshi style ?
Message-ID: <TSATO.92Jul21214016@ibuki.kuee.kyoto-u.ac.jp>
Date: 21 Jul 92 12:40:16 GMT
References: <KAZU.92Jul9114757@ribbon.csrd.nkk.co.JP> <1ei.b365p@lab.ntt.jp>
Sender: news@kuee.kuee.kyoto-u.ac.jp
Distribution: fj
Organization: Dept. of Electr. Eng. II, Kyoto Univ., Kyoto, Japan
Lines: 451
In-reply-to: kazama@square.ntt.jp's message of 20 Jul 92 22:29:22 JST

$@:4F#!w5~Bg!%EE5$$G$9!#(J

In article <1ei.b365p@lab.ntt.jp> kazama@square.ntt.jp (Kazuhiro Kazama) writes:
 |$@Iw4V!w#N#T#T4pAC8&$G$9!#(J
 |In article <KAZU.92Jul9114757@ribbon.csrd.nkk.co.JP> kazu@csrd.nkk.co.JP (Kazunari "ISSEY" Nakamura) writes:
 | > $@2#=q$-$N869FMQ;f$r%(%_%e%l!<%7%g%s$9$k$h$&$J%9%?%$%k%U%!%$%k$rC5$7$F$$(J
 | > $@$^$9!#$=$s$J$b$N@$$NCf$KB8:_$9$k$N$G$7$g$&$+!)(J
 |$@!!L\E*$K$h$C$F0c$&$N$H!"$I$NDxEY$^$G$N=hM}$r4|BT$7$F$$$k$+$K$h$j$^$9$,!"(J
 |$@2#=q$-$G$b=D=q$-$G$b869FMQ;f$NKqL\$rKd$a$k$h$&$KJ8;z$rJB$Y$k$3$H$O(JNTT
 |JTeX$@$J$i$G$-$k$H;W$$$^$9!#(JASCII JTeX$@$G$O4A;z$N<h$j07$$$,0[$J$k$N$G!"$3(J
 |$@$N$h$&$J=hM}$O$G$-$^$;$s!#(J
$@$?$7$+$K!"IaDL$K$O$G$-$^$;$s$,!"I,MW$K$+$i$l$F:n$C$F$$$^$9!#$^$@(J
$@&A(J-version $@DxEY$G$9$,!"<{MW$,$"$k$h$&$J$N$G!"%]%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p$7$^$9$,!"7hDjHG$O$"$j$^$;$s!#$3$&$7$?$[$&$,(J
$@$&$^$/9T$/!"$H$$$&J}K!$r$4B8CN$G$"$l$P!"$<$R$*65$(2<$5$$!#(J

$@#1!K(J $@DL>o$NF|K\8l%U%)%s%H(J min10, goth10 $@Ey$N$+$o$j$K!"$9$Y$F$NA43QJ8;z$N(J
     $@I}$rF1$8$K$7$?%U%)%s%H(J gmin10, ggoth10 $@Ey$r;H$&!#$3$l$K$O(J .tfm $@%U%!%$%k(J
     $@$N$_$r=$@5$9$l$P$h$/!"%U%)%s%H$=$N$b$N$O(J min10 $@$J$I$r(Jalias$@$9$l$P(J
     $@$9$_$^$9!#(Jgenkou.sty $@$N!VI8=`!W$O$3$NJ}K!$G$9!#<j=g$O!"(J
     (1) $@2<$K$D$1$?(J gmin10.pl $@$H(J ggoth10.pl $@$r(J $@F|K\8l(JTeX$@$H0l=o$KG[I[$5$l$k(J
         pltogf $@$G(J .tfm $@$KJQ49$7$^$9!#!J(Jpltogf gmin10.pl gmin10.tfm$@!K(J
         $@B>$K(J gmin5, gmin6, gmin7, gmin8, gmin9 $@$bI,MW$G$9$,!"$3$l$i$O(J
         gmin10.pl $@$N(J (DESIGNSIZE R 10.0) $@$H$$$&9T$N(J 10.0 $@$r(J 5.0, 6.0 ...
         $@$KJQ$($k$@$1$G$9!#(Jggoth $@$bF1MM$G$9!#(J
     (2) $@$G$-$?(J .tfm $@%U%!%$%k$rB>$N(J .tfm $@$HF1$8%G%#%l%/%H%j(J
         $@!J(J/usr/local/lib/tex/fonts $@Ey!K$K0\$7$^$9!#(J
     (3) $@=PNO%G%P%$%9$K1~$8$?(J min10, goth10 $@Ey$N%U%)%s%H$r(J gmin10, ggoth10
         $@$J$I$K%3%T!<$^$?$O%7%s%\%j%C%/%j%s%/$7$^$9!#%W%l%S%e!<%"$K$D$$$F$b(J
         $@F1MM$K%U%)%s%H$r(Jalias$@$9$k$3$H$,I,MW$G$9!#(J

$@#2!K(J $@#1!K$NJ}K!$O!"F|K\8l(JMicroTeX$@$J$I$N$h$&$KF|K\8l%U%)%s%H$H$7$F=PNO%G%P(J
     $@%$%9FbB"$N$b$N$r;H$&%I%i%$%P%=%U%H$K$OE,MQ$G$-$J$$$3$H$,$"$j$^$9!#(J
     $@9M$($i$l$kBP:v$H$7$F$O!"(J
     (a) $@>e$NJ}K!$G:n@.$7$?(J .dvi $@%U%!%$%k$NCf$K4^$^$l$k(J gmin, ggoth $@$H$$$&(J
         $@J8;z$r!"%U%#%k%?!<$G$=$l$>$l(J min, goth $@$KCV$-49$($F=PNO$9$k!#(J
     (b) $@#1!K$G:n$C$?(J .tfm $@$r$b$H$NL>A0!J(Jmin10.tfm$@Ey!K$HF1$8$K$7!"JL$N(J
         $@%G%#%l%/%H%j$KCV$/!#(Jgenkou.sty $@$r;H$&;~$O!"(JLaTeX $@$,;H$&4D6-JQ?t(J
         TEXFONTS$@!J@_Dj$K$h$C$F$O8+$F$/$l$J$$$3$H$,$"$j$^$9!K$N:G=i$K(J
         $@$3$N%G%#%l%/%H%j$r$/$C$D$1$F;H$&!#$"$k$$$O@lMQ$N(JTeX$@$r%3%s%Q%$%k(J
         $@$9$k!#$J$*!"(Jgenkou.sty $@$N;O$a$K$"$k(J \font $@%3%^%s%I$O$9$Y$F:o=|(J
         $@$7$F$*$/!#(J
     $@$,$"$j$^$9$,!"$I$A$i$b%F%9%H$O$7$F$$$^$;$s!#(J

$@#3!K(J $@ImB0$N(J genkou.awk $@$r;H$C$F%F%-%9%H%U%!%$%k$r=$@5$7$F$+$i(J LaTeX $@$K(J
     $@$+$1$k!J(Jgawk -f genkou.awk ****.tex | jlatex$@!K!#F|K\8l$r07$($k(J
     awk $@!J(Jgawk $@Ey!K$,I,MW$G$9!#$^$?!"%Q%$%W$G(JLaTeX$@$KEO$9$H!"$G$-$k(J
     dvi$@%U%!%$%k$O!"(Jtexput.dvi $@$H$$$&L>A0$K$J$j$^$9!#>e$N#2!K$N(J(b)$@$H(J
     $@F1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6XB'=hM}$N$?$a$K>/$7<j$r2C$($F$"$j$^$9!K(J
$@$3$N%3%^%s%I$NA08e$KH>3Q6uGr$,F~$i$J$$$h$&$KCm0U$7$F2<$5$$!#$3$N>l9g$K(J
$@8B$i$:!"K\J8Cf$KM>J,$JH>3Q6uGr$,$"$k$HJ8;z$NG[Ns$,!v!vI,$:!v!v68$$$^$9!#(J

$@0J>e$N=`Hw$r$7$?>e$G(J genkou.sty $@$rIaDL$N%9%?%$%k%U%!%$%k$N$h$&$K;H$$$^$9!#(J
$@!J(Jgenkou.sty $@$O!"J8=q%U%!%$%k$HF1$8%G%#%l%/%H%j$+!"B>$N%9%?%$%k%U%!%$%k(J
  $@$HF1$8%G%#%l%/%H%j(J(/usr/local/lib/tex/inputs$@$J$I(J)$@$KCV$-$^$9!K(J

$@KqL\$r=q$+$;$k$?$a$K(JLaTeX$@$N=PNO%k!<%A%s(J\@outputpage$@$K0l9TDI2C$7$F$"$j$^$9!#(J
$@=PNO%k!<%A%s$^$o$j$rJQ99$9$k%9%?%$%k%U%!%$%k$H6&MQ$9$k>l9g$O$4Cm0U2<$5$$!#(J

$@$G$O!"%9%?%$%k%U%!%$%k$NK\BN$G$9!#(J
% genkou.sty ============================================================
% genkou.sty : $@869FMQ;f$N$?$a$N%9%?%$%k(J ($@&A(J-version: 1992/07/21)
%   $@;HMQK!!'(J
%       \documentstyle[12pt,genkou]{jarticle}
%       \topmargin= ***mm	% \textheight$@Ey$N@#K!$O!"J8;z$N>e2<(J
%	\headheight= ***mm	% $@$+$i$G$O$J$/!"869FMQ;f$NKqL\$N(J
%	\headsep= ***mm		% $@30<~$+$i7W$C$?@#K!$G;XDj$7$^$9!#(J
%       \textheight= ***mm	% $@KqL\$rIA$+$J$$>l9g$bF1$8$G$9!#(J
%       \oddsidemargin= ***mm	% $@!J$3$l$i$N@#K!$O(Jgenkou.sty$@$NCf$G(J
%       \textwidth= ***mm	%   $@JQ99$5$l$^$9!#!K(J
%	\masume		% $@$3$l$r;XDj$9$k$HKqL\$rIA$-$^$9!#(J
%       \setgenkou{$@#19T$NJ8;z?t(J}{$@#1%Z!<%8$N9T?t(J}
%       \begin{document}
%       ...
%   $@@)8B;v9`!'(J
%    $@!&(JASCII$@HG$G$7$+;H$($^$;$s!#(J
%    $@!&(Jgmin10, ggoth10 $@$J$I$N%U%)%s%H$,I,MW$G$9!#(J
%      $@$J$$>l9g$O!"0J2<$N(J \font $@%3%^%s%I$r$9$Y$F:o=|$7!"%F%-%9%H$r(J
%      genkou.awk $@$KDL$7$F$+$i(JLaTeX$@$7$F2<$5$$!#(J
%    $@!&(J\large, \small $@Ey$O;H$($^$;$s!#(J
%    $@!&H>3Q1Q?t;z!JNs!K$O(J \zwbox{$@J8;zNs(J} $@$H;XDj$9$kI,MW$,$"$j$^$9!#(J
%    $@!&6XB'=hM}$O$7$^$9$,!"$=$N>l9g!V!#!W$J$I$OKqL\$N30$K=P$^$9!#(J
%   $@$=$NB>!'(J
%    $@!&(J\section, \subsection $@Ey$OIaDL$K;H$($^$9!#?7$7$$(J \section $@$NA0$N$_(J
%      $@#19T$"$1$^$9!#(J
%    $@!&(Jitemize, enumerate, description $@$OIaDL$K;H$($^$9!#(J
%    $@!&?t<0!J(Jequation, eqnarray$@!K$O$=$l$>$l$N<0$N9b$5$,KqL\$N9b$5DxEY(J
%      $@0J2<$G$"$l$P9T4V$K$O1F6A$7$^$;$s!#Nc$($P!"@QJ,$OBg>fIW$G$9$,!"(J
%      $@J,?t<0$O$@$a$G$9!#(J
%    $@!&(Jtabular, table, figure $@$O<+J,$G6uGr$rD4@a$7$J$$$+$.$j;H$($^$;$s!#(J
%    $@!&KqL\$NI}$O(J \genkouskip, $@9T4V3V$O(J \genkoubaseline $@$H$$$&JQ?t$G(J
%      $@;2>H$G$-$^$9!#(J
%   $@%P%0!'(J
%    $@!&(J\zwbox$@$r%Q%i%0%i%U$N@hF,$G;H$&$HM>J,$J6uGr$,F~$C$F$=$N9T$NJ8;z(J
%      $@$,$9$Y$F>/$71&$K$:$l$^$9!#$=$N;~$O(J \zwnbox $@$r;H$C$F2<$5$$!#(J
%
\font\fivmin=gmin5
\font\sixmin=gmin6
\font\sevmin=gmin7
\font\egtmin=gmin8
\font\ninmin=gmin9
\font\tenmin=gmin10
\font\elvmin=gmin10 scaled \magstephalf
\font\twlmin=gmin10 scaled \magstep1
\font\frtnmin=gmin10 scaled \magstep2
\font\svtnmin=gmin10 scaled \magstep3
\font\twtymin=gmin10 scaled \magstep4
\font\twfvmin=gmin10 scaled \magstep5
\font\fivgt=ggoth5
\font\sixgt=ggoth6
\font\sevgt=ggoth7
\font\egtgt=ggoth8
\font\ningt=ggoth9
\font\tengt=ggoth10
\font\elvgt=ggoth10 scaled \magstephalf
\font\twlgt=ggoth10 scaled \magstep1
\font\frtngt=ggoth10 scaled \magstep2
\font\svtngt=ggoth10 scaled \magstep3
\font\twtygt=ggoth10 scaled \magstep4
\font\twfvgt=ggoth10 scaled \magstep5

\newdimen\genkouskip      % $@KqL\$NI}(J
\newdimen\genkoubaseline  % $@9T4V3V(J
\newdimen\@genkouyoffset
\newcount\@genkoux
\newcount\@genkouy

\def\setgenkou#1#2{ % #1=char/line, #2=line/page
 \@normalsize
 \@genkoux=#1\relax
 \@genkouy=#2\relax
%  genkouskip = textwidth/n-zh : $@KqL\$NI}(J
 \genkouskip=\textwidth\divide\genkouskip by \@genkoux
 \@tempdima=\genkouskip\advance\@tempdima by -1zw
 \kanjiskip=\@tempdima plus .002zw minus .002zw
 \xkanjiskip=\kanjiskip
 \mathsurround=\kanjiskip
 \advance\oddsidemargin by .5\@tempdima % $@KqL\Jd@5(J
 \advance\textwidth by -\@tempdima % $@KqL\Jd@5(J
 \parindent=\genkouskip
%  textheight = (2(m-1)textheight+m*zh)/(2m-1) : $@KqL\Jd@5(J
 \@tempcnta=\@genkouy\multiply\@tempcnta by 2\advance\@tempcnta by -1
 \divide\textheight by \@tempcnta
 \@tempdima=\@genkouy zh\divide\@tempdima by \@tempcnta
 \@tempcnta=\@genkouy\advance\@tempcnta by -1\multiply\@tempcnta by 2
 \advance\textheight by \@tempdima
 \multiply\textheight by \@tempcnta
%  genkoubaseline = (textheight-zh)/(m-1) : $@9T4V(J
 \genkoubaseline=\textheight
 \advance\genkoubaseline by -1zh
 \@tempcnta=\@genkouy\advance\@tempcnta by -1
 \divide\genkoubaseline by \@tempcnta\relax
%  @genkouyoffset = (genkoubaseline-zh)/4 : $@KqL\$NCf$NJ8;z$N>e2<$N6uGr(J
 \@genkouyoffset=\genkoubaseline\advance\@genkouyoffset by -1zh
 \divide\@genkouyoffset by 4
 \advance\topmargin by \@genkouyoffset % $@KqL\Jd@5(J

 \def\@listi{\leftmargin2\genkouskip\topsep 0pt\itemsep 0pt\parsep 0pt
 \partopsep 0pt}
 \def\@listii{\leftmargin2\genkouskip\topsep 0pt\itemsep 0pt\parsep 0pt
 \partopsep 0pt}
 \def\@listiii{\leftmargin2\genkouskip\topsep 0pt\itemsep 0pt\parsep 0pt
 \partopsep 0pt}

 \itemsep\genkouskip\advance\itemsep by -1zh\divide\itemsep by 2\relax
 \floatsep\genkoubaseline
 \textfloatsep\genkoubaseline
 \intextsep\genkoubaseline
 \tabcolsep0.5\genkouskip
}

\def\descriptionlabel#1{\hspace\labelsep \bf #1\hspace\genkouskip}
\def\description{\list{}{\labelwidth\z@ \itemindent-\leftmargin
 \let\makelabel\descriptionlabel}}

\abovedisplayskip 0pt
\belowdisplayskip 0pt
\abovedisplayshortskip 0pt
\belowdisplayshortskip 0pt
\jot 0pt

\def\section{\@startsection{section}{1}{\z@}%
{\baselineskip}{1sp}{\normalsize\bf}}
\def\subsection{\@startsection{subsection}{2}{\z@}{\z@}%
{1sp}{\normalsize\bf}}
\def\subsubsection{\@startsection{subsubsection}{3}{\z@}{\z@}%
{1sp}{\normalsize\bf}}

\def\@sect#1#2#3#4#5#6[#7]#8{\ifnum #2>\c@secnumdepth
     \def\@svsec{}\else 
     \refstepcounter{#1}\edef\@svsec{\csname the#1\endcsname}\fi % T.S.
     \@tempskipa #5\relax
      \ifdim \@tempskipa>\z@ 
        \begingroup #6\relax
         \@hangfrom{\zwnbox{\@svsec}\hskip\genkouskip}% T.S.
            {\interlinepenalty \@M #8\par}% T.S.
        \endgroup
       \csname #1mark\endcsname{#7}\addcontentsline
         {toc}{#1}{\ifnum #2>\c@secnumdepth \else
                      \protect\numberline{\csname the#1\endcsname}\fi
                    #7}\else
        \def\@svsechd{#6\hskip #3\@svsec #8\csname #1mark\endcsname
                      {#7}\addcontentsline
                           {toc}{#1}{\ifnum #2>\c@secnumdepth \else
                             \protect\numberline{\csname the#1\endcsname}\fi
                       #7}}\fi
     \@xsect{#5}}

\def\thesection       {\arabic{section}}
\def\thesubsection    {\thesection.\arabic{subsection}}
\def\thesubsubsection {\thesubsection.\arabic{subsubsection}}
\def\theparagraph     {\thesubsubsection.\arabic{paragraph}}

\ifcase\@ptsize
\def\@normalsize{\@setsize\normalsize\genkoubaseline\xpt\@xpt}
\or
\def\@normalsize{\@setsize\normalsize\genkoubaseline\xipt\@xipt}
\else
\def\@normalsize{\@setsize\normalsize\genkoubaseline\xiipt\@xiipt}
\fi
\@normalsize

\def\ZT#1{\@zwbox{\penalty10000}{#1}{\penalty-100}} %  $@9TF,6XB'(Jbox
\def\ZE#1{\@zwbox{\penalty-100}{#1}{\penalty10000}} %  $@9TKv6XB'(Jbox
\def\zwbox#1{\@zwbox{}{#1}{}}

\def\@zwbox#1#2#3{\inhibitglue#1%
\setbox\@tempboxa=\hbox{#2}%
\@tempdima=\wd\@tempboxa\advance\@tempdima by \kanjiskip%
\divide \@tempdima by \genkouskip%
\count99=\@tempdima\advance\count99 by 1%
\@tempdima=\count99\genkouskip\advance\@tempdima by -\kanjiskip%
\hspace{\kanjiskip}\protect\makebox[\@tempdima]{#2}%
\hspace{\kanjiskip}#3\inhibitglue%
\futurelet\temp@genkoub\temp@genkoua}

% zwnbox : zwbox at the top of a paragraph
\def\zwnbox#1{\inhibitglue%
\setbox\@tempboxa=\hbox{#1}%
\@tempdima=\wd\@tempboxa\advance\@tempdima by \kanjiskip%
\divide \@tempdima by \genkouskip%
\count99=\@tempdima\advance\count99 by 1%
\@tempdima=\count99\genkouskip\advance\@tempdima by -\kanjiskip%
\protect\makebox[\@tempdima]{#1}%
\hspace{\kanjiskip}\inhibitglue%
\futurelet\temp@genkoub\temp@genkoua}

\def\temp@genkoua{\ifx\temp@genkoub\ZT\hspace{-\kanjiskip}%
\else\ifx\temp@genkoub\ZE\hspace{-\kanjiskip}%
\else\ifx\temp@genkoub\zwbox\hspace{-\kanjiskip}\fi\fi\fi\ignorespaces}

% masume=========================================================
\newif\if@masume
\let\if@masume=\iffalse\relax
\def\masume{\let\if@masume=\iftrue\relax}

\def\@masume{\setlength{\unitlength}{1sp}%
% top left = (0.5kanjiskip, textheight+@genkouyoffset)
\@tempdima=0.5\kanjiskip%
\@tempdimb=\textheight\advance\@tempdimb by \@genkouyoffset%
\begin{picture}(0,0)(\number\@tempdima,\number\@tempdimb)
\@tempdima=\textwidth\advance\@tempdima by \kanjiskip
\multiput(0,0)(0,\number\genkoubaseline){\@genkouy}%
 {\line(1,0){\number\@tempdima}}
% masume height = \genkoubaseline -2@genkouyoffset
\@tempdimb=\genkoubaseline\advance\@tempdimb by -2\@genkouyoffset
\multiput(0,\number\@tempdimb)(0,\number\genkoubaseline){\@genkouy}%
 {\line(1,0){\number\@tempdima}}
\@tempcnta=\@genkoux\relax\advance\@tempcnta by 1%
\multiput(0,0)(0,\number\genkoubaseline){\@genkouy}%
 {\multiput(0,0)(\number\genkouskip,0)%
  {\number\@tempcnta}{\line(0,1){\number\@tempdimb}}}
\end{picture}}

\def\@outputpage{\begingroup\catcode`\ =10 
     \let\-\@dischyph \let\'\@acci \let\`\@accii \let\=\@acciii
    \if@specialpage 
     \global\@specialpagefalse\@nameuse{ps@\@specialstyle}\fi
     \if@twoside 
       \ifodd\count\z@ \let\@thehead\@oddhead \let\@thefoot\@oddfoot
            \let\@themargin\oddsidemargin
          \else \let\@thehead\@evenhead
          \let\@thefoot\@evenfoot \let\@themargin\evensidemargin
     \fi\fi
     \shipout
     \vbox{\normalsize \baselineskip\z@ \lineskip\z@ 
           \let\par\@@par %% 15 Sep 87
           \vskip \topmargin \moveright\@themargin
           \vbox{\setbox\@tempboxa
                   \vbox to\headheight{\vfil \hbox to\textwidth
                                       {\let\label\@gobble \let\index\@gobble
                                         \@thehead}} %% 22 Feb 87
                 \dp\@tempboxa\z@
                 \box\@tempboxa
                 \vskip \headsep
		 \if@masume\hbox to\textwidth{\@masume\hss}\fi% === T.S. ===
                 \box\@outputbox
                 \baselineskip\footskip
                 \hbox to\textwidth{\let\label\@gobble 
                           \let\index\@gobble  %% 22 Feb 87
                           \@thefoot}}}\global\@colht\textheight
           \endgroup\stepcounter{page}\let\firstmark\botmark}
%========================================================================

$@0J2<$O#3!K$NJ}K!$r;H$&>l9g$N$?$a$N(J awk $@%9%/%j%W%H$G$9!#LnHZ$=$N$b$N$G$9!#(J

% genkou.awk ============================================================
# genkou.awk: pre-processor for genkou.sty
# \ZT=$@9TF,6XB'(J, \ZE=$@9TKv6XB'(J \zwbox=$@0lHL(J
BEGIN { FS = "\n" }
{ 
gsub(/$@%C(J/,"\\ZT{$@%C(J}");gsub(/$@%c(J/,"\\ZT{$@%c(J}");
gsub(/$@%e(J/,"\\ZT{$@%e(J}");gsub(/$@%g(J/,"\\ZT{$@%g(J}");
gsub(/$@%!(J/,"\\ZT{$@%!(J}");gsub(/$@%#(J/,"\\ZT{$@%#(J}");
gsub(/$@%%(J/,"\\ZT{$@%%(J}");gsub(/$@%'(J/,"\\ZT{$@%'(J}");
gsub(/$@%)(J/,"\\ZT{$@%)(J}");gsub(/$@%n(J/,"\\ZT{$@%n(J}");
gsub(/$@%u(J/,"\\ZT{$@%u(J}");gsub(/$@%v(J/,"\\ZT{$@%v(J}");
gsub(/$@$C(J/,"\\ZT{$@$C(J}");gsub(/$@$c(J/,"\\ZT{$@$c(J}");
gsub(/$@$e(J/,"\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/$@!C(J/,"\\zwbox{$@!C(J}");
gsub(/$@!J(J/,"\\ZE{$@!J(J}");gsub(/$@!K(J/,"\\ZT{$@!K(J}");
gsub(/$@!L(J/,"\\ZE{$@!L(J}");gsub(/$@!M(J/,"\\ZT{$@!M(J}");
gsub(/$@!N(J/,"\\ZE{$@!N(J}");gsub(/$@!O(J/,"\\ZT{$@!O(J}");
gsub(/$@!P(J/,"\\ZE{$@!P(J}");gsub(/$@!Q(J/,"\\ZT{$@!Q(J}");
gsub(/$@!R(J/,"\\ZE{$@!R(J}");gsub(/$@!S(J/,"\\ZT{$@!S(J}");
gsub(/$@!T(J/,"\\ZE{$@!T(J}");gsub(/$@!U(J/,"\\ZT{$@!U(J}");
gsub(/$@!V(J/,"\\ZE{$@!V(J}");gsub(/$@!W(J/,"\\ZT{$@!W(J}");
gsub(/$@!X(J/,"\\ZE{$@!X(J}");gsub(/$@!Y(J/,"\\ZT{$@!Y(J}");
gsub(/$@!Z(J/,"\\ZE{$@!Z(J}");gsub(/$@![(J/,"\\ZT{$@![(J}");
gsub(/$@!H(J/,"\\ZE{$@!H(J}");gsub(/$@!I(J/,"\\ZT{$@!I(J}");
gsub(/$@!F(J/,"\\ZE{$@!F(J}");gsub(/$@!G(J/,"\\ZT{$@!G(J}");
print $0 }
%========================================================================

$@0J2<$OF|K\8l%U%)%s%H$N%a%H%j%C%/$G$9!#(Jpltogf $@$K$+$1$F(J .tfm $@$K$7$^$9!#(J
% gmin10.pl ==============================================================
(COMMENT THIS IS A KANJI FORMAT FILE)
(FAMILY MINCHO)
(FACE F MRR)
(CODINGSCHEME TEX KANJI TEXT)
(DESIGNSIZE R 10.0)
(COMMENT DESIGNSIZE IS IN POINTS)
(COMMENT OTHER SIZES ARE MULTIPLES OF DESIGNSIZE)
(SEVENBITSAFEFLAG TRUE)
(FONTDIMEN
   (SLANT R 0.0)
   (SPACE R 0.0)
   (STRETCH R 0.091641)
   (SHRINK R 0.0)
   (XHEIGHT R 0.916443)
   (QUAD R 0.962216)
   (EXTRASPACE R 0.229101)
   (EXTRASTRETCH R 0.183283)
   (EXTRASHRINK R 0.114551)
   )
(TYPE O 0
   (CHARWD R 0.962216)
   (CHARHT R 0.777588)
   (CHARDP R 0.138855)
   )
%=========================================================================

% ggoth10.pl ==============================================================
(COMMENT THIS IS A KANJI FORMAT FILE)
(FAMILY GOTHIC)
(FACE F BRR)
(CODINGSCHEME TEX KANJI TEXT)
(DESIGNSIZE R 10.0)
(COMMENT DESIGNSIZE IS IN POINTS)
(COMMENT OTHER SIZES ARE MULTIPLES OF DESIGNSIZE)
(SEVENBITSAFEFLAG TRUE)
(FONTDIMEN
   (SLANT R 0.0)
   (SPACE R 0.0)
   (STRETCH R 0.091641)
   (SHRINK R 0.0)
   (XHEIGHT R 0.916443)
   (QUAD R 0.962216)
   (EXTRASPACE R 0.229101)
   (EXTRASTRETCH R 0.183283)
   (EXTRASHRINK R 0.114551)
   )
(TYPE O 0
   (CHARWD R 0.962216)
   (CHARHT R 0.777588)
   (CHARDP R 0.138855)
   )
%=========================================================================




--
$@!!!!!!!!!!!!!!!!!!!!!!!!:4F#!!5|!wEE5$9)3XBhFs65<<!%5~ETBg3X(J
$@!!!!!!!!!!!!!!!!!!!!!!!!(Jtsato@kuee.kyoto-u.ac.jp

