diff options
author | Karl Berry <karl@freefriends.org> | 2014-12-24 23:21:27 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2014-12-24 23:21:27 +0000 |
commit | ea75d0bfb820f1fea872bbdfb88fed8e77947698 (patch) | |
tree | faeed0817769c924420116818b34bf344f77d7a0 /Master/texmf-dist/tex/csplain/opmac/opmac.tex | |
parent | 17e3da100f9807511c04fdce7bfbaffe9b586a88 (diff) |
csplain (24dec14)
git-svn-id: svn://tug.org/texlive/trunk@35901 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/csplain/opmac/opmac.tex')
-rw-r--r-- | Master/texmf-dist/tex/csplain/opmac/opmac.tex | 40 |
1 files changed, 22 insertions, 18 deletions
diff --git a/Master/texmf-dist/tex/csplain/opmac/opmac.tex b/Master/texmf-dist/tex/csplain/opmac/opmac.tex index 62769a82fc9..767fa843c72 100644 --- a/Master/texmf-dist/tex/csplain/opmac/opmac.tex +++ b/Master/texmf-dist/tex/csplain/opmac/opmac.tex @@ -5,7 +5,7 @@ %% The history of versions is at the end of this file, after \endpinput \ifx\OPmacversion\undefined \else \endinput \fi -\def\OPmacversion{Dec. 2014} +\def\OPmacversion{Dec. 2014c} \immediate\write16{This is OPmac (Olsak's Plain macros), version <\OPmacversion>} %%%%%%%%%%%%%% Basic macros, sec. 3.1 in opmac-d.pdf @@ -41,7 +41,7 @@ \csname iftrue\expandafter\endcsname \fi}% end of \def\tmp \expandafter\tmp#1\endlistsep#2\end } -\long\def\isnextchar#1#2#3{\def\tmpa{#2}\def\tmpb{#3}% +\long\def\isnextchar#1#2#3{\begingroup\def\tmpa{\endgroup#2}\def\tmpb{\endgroup#3}% \let\tmp=#1\futurelet\next\isnextcharA } \def\isnextcharA{\ifx\tmp\next\expandafter\tmpa\else\expandafter\tmpb\fi} @@ -705,24 +705,24 @@ \fi } \def\dosorting{% - \message{Opmac: Sorting index...} + \message{Opmac: Sorting index...}% \def\act##1{\ifx##1\relax\else \global\addto\iilist{##1,}% - \expandafter\act\fi} + \expandafter\act\fi}% \expandafter\removeiilist \expandafter\act \iilist\relax \expandafter\removeiilist \expandafter\mergesort \iilist \end,\end } \def\removeiilist{\gdef\iilist{}} \def\mergesort #1#2,#3{% by Miroslav Olsak - \ifx,#1 % prazdna-skupina,neco, (#2=neco #3=pokracovani) - \addto\iilist{#2,} % dvojice skupin vyresena + \ifx,#1% % prazdna-skupina,neco, (#2=neco #3=pokracovani) + \addto\iilist{#2,}% % dvojice skupin vyresena \return{\fif\mergesort#3}% % \mergesort pokracovani \fi - \ifx,#3 % neco,prazna-skupina, (#1#2=neco #3=,) + \ifx,#3% % neco,prazna-skupina, (#1#2=neco #3=,) \addto\iilist{#1#2,}% % dvojice skupin vyresena \return{\fif\mergesort}% % \mergesort dalsi \fi - \ifx\end#3 % neco,konec (#1#2=neco) + \ifx\end#3% % neco,konec (#1#2=neco) \ifx\empty\iilist % neco=kompletni setrideny seznam \def\iilist{#1#2}% \return{\fif\fif\gobbletoend}% % koncim @@ -1179,11 +1179,10 @@ \def\rulewidthA{\edef\hrule{\orihrule height\the\tmpdim}% \edef\vrule{\orivrule width\the\tmpdim}} -\long\def\frame#1{\setbox0=\hbox{{#1}}\setbox1=\vbox{\hrule}% - \tmpdim=\dp0 \advance\tmpdim by\ht1 \advance\tmpdim by\hhkern - \vbox{\hrule\hbox{\vrule\kern\vvkern - \vbox{\kern\hhkern\box0\kern\hhkern}\kern\vvkern\vrule}% - \hrule\kern-\tmpdim\hbox{\vrule depth\tmpdim width0pt}}} +\long\def\frame#1{% + \hbox{\vrule\vtop{\vbox{\hrule\kern\vvkern{% + \hbox{\kern\hhkern#1\kern\hhkern}% + }}\kern\vvkern\hrule}\vrule}} %%%%%%%%%%%%%% \inspic -- sec. 3.20 in opmac-d.pdf @@ -1581,12 +1580,14 @@ } \def\rbmargin#1#2#3{\advance#1\pgwidth \advance#1-#2 \advance#1-#3} -\def\setpagedimens#1 {\isdefined{pgs:#1}\iftrue - \expandafter\expandafter\expandafter \setpagedimensA \csname pgs:#1\endcsname&% +\def\setpagedimens{\isnextchar({\setpagedimensB}{\setpagedimensA}} +\def\setpagedimensA#1 {\isdefined{pgs:#1}\iftrue + \expandafter\expandafter\expandafter\setpagedimensB \csname pgs:#1\expandafter\endcsname\space \else \opwarning{page specification "#1" is undefined}\fi} -\def\setpagedimensA (#1,#2)#3&{\pgwidth=#1\trueunit#3 \pgheight=#2\trueunit#3\relax +\def\setpagedimensB (#1,#2)#3 {\setpagedimensC\pgwidth=#1:#3 \setpagedimensC\pgheight=#2:#3 \ifx\pdfpagewidth\undefined \else \pdfpagewidth=\pgwidth \pdfpageheight=\pgheight \fi} +\def\setpagedimensC #1=#2:#3 {#1=#2\ifx^#3^\tmp\else#3\fi\relax} \sdef{pgs:a3}{(297,420)mm} \sdef{pgs:a4}{(210,297)mm} \sdef{pgs:a5}{(148,210)mm} \sdef{pgs:a3l}{(420,297)mm} \sdef{pgs:a4l}{(297,210)mm} \sdef{pgs:a5l}{(210,148)mm} @@ -1706,7 +1707,10 @@ Nov. 2014 \sortingdata corrected, \specsortingdata introduced. \bfshape used in \titfont and \Xchap \adef{ }{\ } in verbatim environment (instead \adef{ }[ }). \fnotemark+\fnotetext+\runningfnotes bug fixed. - \flushcolumns, \iiparams removed, \mullines introduced -Dec. 2014 Color features rewritten using \pdfcolorstack + \flushcolumns, \iiparams removed, \mullines introduced. +Dec. 2014 Color features rewritten using \pdfcolorstack. + Unwanted spaces in \dosorting removed. + Better definition of \frame. + \margins/\setpagedimens improved, \isnextchar: \bgroup\egroup added. %%%%%%%%%%%%%% End of opmac.tex |