\newdimen\lmd
\newdimen\lml
\newdimen\ldd
\newdimen\ldl
\font\ogon=cmmi7
\def\ogonlow{\lower0.74ex}
\def\ogonleft{\kern-0.25em}
\lmd=0.05ex
\lml=0.31em
\ldd=0.12ex
\ldl=0.68em


% DEFINICJE  WIELKOSCI CZCIONEK


\def\elevenpoint{
\font\elevenrm=cmr10 scaled\magstephalf
\font\elevenit=cmti10 scaled\magstephalf
\font\elevenbf=cmbx10 scaled\magstephalf
\font\eleveni=cmmi10 scaled\magstephalf
\font\eleventt=cmtt10 scaled\magstephalf
\font\ogon=cmmi7 scaled\magstephalf
\def\ogonlow{\lower0.75ex}%
\def\ogonleft{\kern-0.30em}%
\def\rm{%\fcm0
\elevenrm\lmd=0.06ex\lml=0.31em\ldd=0.12ex\ldl=0.60em}
\textfont0=\elevenrm \scriptfont0=\sevenrm \scriptscriptfont0=\fiverm
\textfont1=\eleveni \scriptfont1=\seveni \scriptscriptfont1=\fivei
\textfont2=\tensy \scriptfont2=\sevensy \scriptscriptfont2=\fivesy
\textfont3=\tenex \scriptfont3=\tenex \scriptscriptfont3=\tenex
\textfont\itfam=\elevenit  
\textfont\ttfam=\eleventt  
\textfont\bffam=\elevenbf \scriptfont\bffam=\sevenbf
\scriptscriptfont\bffam=\fivebf 
\def\bf{\fam\bffam\elevenbf\lmd=0.06ex\lml=0.31em\ldd=0.12ex\ldl=0.60em} 
\def\it{\fam\itfam\elevenit\lmd=0.04ex\lml=0.28em\ldd=0.12ex\ldl=0.61em}
\def\tt{\fam\ttfam\eleventt}  
\normalbaselineskip=13pt
\setbox\strutbox=\hbox{\vrule height9pt depth4pt width0pt}
 \normalbaselines\rm}


\def\tenpoint{
\font\ogon=cmmi7 
\def\ogonlow{\lower0.74ex}%
\def\ogonleft{\kern-0.25em}%
\def\rm{%\fcm0
\tenrm\lmd=0.04ex\lml=0.31em\ldd=0.12ex\ldl=0.68em}
\textfont0=\tenrm \scriptfont0=\sevenrm \scriptscriptfont0=\fiverm
\textfont1=\teni \scriptfont1=\seveni \scriptscriptfont1=\fivei
\textfont2=\tensy \scriptfont2=\sevensy \scriptscriptfont2=\fivesy
\textfont3=\tenex \scriptfont3=\tenex \scriptscriptfont3=\tenex
\textfont\itfam=\tenit     
\def\it{\fam\itfam\tenit\lmd=0.05ex\lml=0.25em\ldd=0.12ex\ldl=0.55em} 
\textfont\slfam=\tensl     
\def\sl{\fam\slfam\tensl\lmd=0.05ex\lml=0.30em\ldd=0.12ex\ldl=0.67em} 
\textfont\ttfam=\tentt     \def\tt{\fam\ttfam\tentt}  
\textfont\bffam=\tenbf \scriptfont\bffam=\sevenbf
\scriptscriptfont\bffam=\fivebf 
\def\bf{\fam\bffam\tenbf\lmd=0.04ex\lml=0.31em\ldd=0.12ex\ldl=0.59em} 
\normalbaselineskip=12pt
\setbox\strutbox=\hbox{\vrule height8.5pt depth3.5pt width0pt}
\normalbaselines\rm }
\def\tenmath{\tenpoint\fam-1 }

\def\ninepoint{
\font\ninerm=cmr9
\font\nineit=cmti9
\font\ninebf=cmbx9
\font\ninesl=cmsl9
\font\ninei=cmmi9
\font\ninesy=cmsy9
\font\ninett=cmtt9
\font\sixbf=cmbx6
\font\sixrm=cmr6
\font\sixsy=cmsy6
\font\sixi=cmmi6
\font\ogon=cmmi6 
\def\ogonlow{\lower0.75ex}%
\def\ogonleft{\kern-0.30em}%
\def\rm{\fam0\ninerm\lmd=0.04ex\lml=0.31em\ldd=0.12ex\ldl=0.65em}
\textfont0=\ninerm \scriptfont0=\sixrm \scriptscriptfont0=\fiverm
\textfont1=\ninei \scriptfont1=\sixi \scriptscriptfont1=\fivei
\textfont2=\ninesy \scriptfont2=\sixsy \scriptscriptfont2=\fivesy
\textfont3=\tenex \scriptfont3=\tenex \scriptscriptfont3=\tenex
\textfont\itfam=\nineit    
\def\it{\fam\itfam\nineit\lmd=0.04ex\lml=0.24em\ldd=0.12ex\ldl=0.59em} 
\textfont\slfam=\ninesl    
\def\sl{\fam\slfam\ninesl\lmd=0.04ex\lml=0.31em\ldd=0.12ex\ldl=0.65em}
\textfont\ttfam=\ninett    \def\tt{\fam\ttfam\ninett}  
\textfont\bffam=\ninebf \scriptfont\bffam=\sixbf
\scriptscriptfont\bffam=\fivebf 
\def\bf{\fam\bffam\ninebf\lmd=0.04ex\lml=0.31em\ldd=0.12ex\ldl=0.59em} 
\normalbaselineskip=11pt
\setbox\strutbox=\hbox{\vrule height8pt depth3pt width0pt}
\normalbaselines\rm }

\def\eightpoint{
\font\eightrm=cmr8
\font\eightit=cmti8
\font\eightbf=cmbx8
\font\eightsl=cmsl8
\font\eighti=cmmi8
\font\eightsy=cmsy8
\font\eighttt=cmtt8
\font\sixbf=cmbx6
\font\sixrm=cmr6
\font\sixsy=cmsy6
\font\sixi=cmmi6
\font\ogon=cmmi6
\def\ogonlow{\lower0.81ex}%
\def\ogonleft{\kern-0.29em}%
\def\rm{\fam0\eightrm\lmd=0.04ex\lml=0.30em\ldd=0.11ex\ldl=0.64em}
\textfont0=\eightrm \scriptfont0=\sixrm \scriptscriptfont0=\fiverm
\textfont1=\eighti \scriptfont1=\sixi \scriptscriptfont1=\fivei
\textfont2=\eightsy \scriptfont2=\sixsy \scriptscriptfont2=\fivesy
\textfont3=\tenex \scriptfont3=\tenex \scriptscriptfont3=\tenex
\textfont\itfam=\eightit   
\def\it{\fam\itfam\eightit\lmd=0.02ex\lml=0.22em\ldd=0.11ex\ldl=0.55em}
\textfont\slfam=\eightsl   
\def\sl{\fam\slfam\eightsl\lmd=0.03ex\lml=0.31em\ldd=0.11ex\ldl=0.64em}
\textfont\ttfam=\eighttt   \def\tt{\fam\ttfam\eighttt}  
\textfont\bffam=\eightbf \scriptfont\bffam=\sixbf
\scriptscriptfont\bffam=\fivebf 
\def\bf{\fam\bffam\eightbf\lmd=0.06ex\lml=0.33em\ldd=0.11ex\ldl=0.61em}
\normalbaselineskip=10pt
\setbox\strutbox=\hbox{\vrule height7.5pt depth2.5pt width0pt}
\normalbaselines\rm }


\def\sevenpoint{
\font\sevenit=cmti7
\font\ogon=cmmi5 
\def\ogonlow{\lower0.75ex}%
\def\ogonleft{\kern-0.30em}%
\def\rm{\fam0\sevenrm\lmd=0.04ex\lml=0.33em\ldd=0.15ex\ldl=0.66em}
\textfont0=\sevenrm \scriptfont0=\fiverm \scriptscriptfont0=\fiverm
\textfont1=\seveni \scriptfont1=\fivei \scriptscriptfont1=\fivei
\textfont2=\sevensy \scriptfont2=\fivesy \scriptscriptfont2=\fivesy
\textfont3=\tenex \scriptfont3=\tenex \scriptscriptfont3=\tenex
\textfont\itfam=\sevenit    
\def\it{\fam\itfam\sevenit\lmd=0.05ex\lml=0.25em\ldd=0.15ex\ldl=0.61em}
\textfont\bffam=\sevenbf \scriptfont\bffam=\fivebf
\scriptscriptfont\bffam=\fivebf 
\def\bf{\fam\bffam\sevenbf\lmd=0.03ex\lml=0.33em\ldd=0.15ex\ldl=0.62em}
\normalbaselineskip=9pt
\setbox\strutbox=\hbox{\vrule height6.5pt depth2.5pt width0pt}
\normalbaselines\rm }

\def\eleven#1 {\elevenpoint\normalbaselineskip#1pt\normalbaselines\rm}

\def\ten#1 {\tenpoint\normalbaselineskip#1pt\normalbaselines\rm}

\def\nine#1 {\ninepoint\normalbaselineskip#1pt\normalbaselines\rm}

\def\eight#1 {\eightpoint\normalbaselineskip#1pt\normalbaselines\rm}

\def\seven#1 {\sevenpoint\normalbaselineskip#1pt\normalbaselines\rm}


% DEFINICJE POLSKICH LITER (nie stosowac w math-modzie!)


\catcode`@\active
\def@{\leavevmode\futurelet\next\lettertest}
\def\lettertest
    {\ifx\next a\def\diacr{8}\else    
     \ifx\next A\def\diacr{7}\else
     \ifx\next c\def\diacr{0}\else
     \ifx\next C\def\diacr{0}\else
     \ifx\next e\def\diacr{6}\else
     \ifx\next E\def\diacr{5}\else
     \ifx\next l\def\diacr{3}\else
     \ifx\next L\def\diacr{4}\else
     \ifx\next n\def\diacr{0}\else
     \ifx\next N\def\diacr{0}\else
     \ifx\next o\def\diacr{0}\else
     \ifx\next O\def\diacr{0}\else
     \ifx\next r\def\diacr{1}\else
     \ifx\next R\def\diacr{2}\else
     \ifx\next s\def\diacr{0}\else
     \ifx\next S\def\diacr{0}\else
     \ifx\next z\def\diacr{0}\else
     \ifx\next Z\def\diacr{0}\else
     \def\diacr{9}\char"40
     \fi\fi\fi\fi\fi
     \fi\fi\fi\fi\fi
     \fi\fi\fi\fi\fi
     \fi\fi\fi
     \ifcase\diacr
{\setbox0=\hbox{\next}\setbox1=\hbox{\accent"13\next}%
\ht1=\ht0\dp1=\dp0\box1}\or%
{\accent"5Fz}\or%
{\setbox0=\hbox{Z}\setbox1=\hbox{\accent"5FZ}\ht1=\ht0\dp1=\dp0\box1}\or%
{\char'40l}\or
{\setbox0=\hbox{L}\hbox to\wd0{\hss\char'40L}}\or
%{\setbox0=\hbox{l}\setbox1=\hbox to \wd0{l\kern-\lml%
%\hbox{\lower\lmd\hbox{\char'40}\kern-0.2em\raise\lmd\hbox{\char'40}}\hss}%
%\ht1=\ht0\dp1=\dp0\box1}\or%
%{\setbox0=\hbox{L}\setbox1=\hbox to \wd0{L\kern-\ldl%
%\hbox{\lower\ldd\hbox{\char'40}\kern-0.1em\raise\ldd\hbox{\char'40}}\hss}%
%\ht1=\ht0\dp1=\dp0\box1}\or%
{\setbox0=\hbox{E}\setbox1=\hbox to \wd0{E\ogonleft\ogonlow%
  \hbox{\ogon\char"2C}\hss}\ht1=\ht0\dp1=\dp0\box1}\or%
{\setbox0=\hbox{e}\setbox1=\hbox to \wd0{e\ogonleft\ogonlow%
  \hbox{\ogon\char"2C}\hss}\ht1=\ht0\dp1=\dp0\box1}\or%
{\setbox0=\hbox{A}\setbox1=\hbox to \wd0{A\kern-0.24em\lower 0.72ex%
  \hbox{\ogon\char"2C}\hss}\ht1=\ht0\dp1=\dp0\box1}\or%
{\setbox0=\hbox{a}\setbox1=\hbox to \wd0{a\kern-0.21em\lower 0.75ex%
  \hbox{\ogon\char"2C}\hss}\ht1=\ht0\dp1=\dp0\box1}\or%
{\next}\fi%
\let\next}    

