diff options
author | Karl Berry <karl@freefriends.org> | 2007-01-15 00:54:14 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2007-01-15 00:54:14 +0000 |
commit | a01b17e3ec55cada8f1442852382a500e8e3afa2 (patch) | |
tree | e65565e60481fca3067f2c994e092659296e183e /Master/texmf-dist/tex/latex/preview/preview.sty | |
parent | cb2261b95e9e7188fd39818ba6727b387ef9cc1b (diff) |
preview update (13jan07)
git-svn-id: svn://tug.org/texlive/trunk@3486 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/preview/preview.sty')
-rw-r--r-- | Master/texmf-dist/tex/latex/preview/preview.sty | 78 |
1 files changed, 24 insertions, 54 deletions
diff --git a/Master/texmf-dist/tex/latex/preview/preview.sty b/Master/texmf-dist/tex/latex/preview/preview.sty index e3a7a47625f..0969a17790f 100644 --- a/Master/texmf-dist/tex/latex/preview/preview.sty +++ b/Master/texmf-dist/tex/latex/preview/preview.sty @@ -21,35 +21,17 @@ %% original source files, as listed above, are part of the %% same distribution. (The sources need not necessarily be %% in the same archive or directory.) -%%\iffalse -%% preview.dtx for extracting previews from LaTeX documents. Part of -%% the preview-latex package. -%% Copyright (C) 2001, 2002, 2003, 2004, 2005 Free Software Foundation -%% -%% This program is free software; you can redistribute it and/or modify -%% it under the terms of the GNU General Public License as published by -%% the Free Software Foundation; either version 2 of the License, or -%% (at your option) any later version. -%% -%% This program is distributed in the hope that it will be useful, -%% but WITHOUT ANY WARRANTY; without even the implied warranty of -%% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -%% GNU General Public License for more details. -%% -%% You should have received a copy of the GNU General Public License -%% along with this program; if not, write to the -%% Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, -%% Boston, MA 02110-1301 USA -%%\fi +%% The preview style for extracting previews from LaTeX documents. +%% Developed as part of AUCTeX <URL:http://www.gnu.org/software/auctex>. \NeedsTeXFormat{LaTeX2e} \def\reserved@a #1#2$#3: #4${\xdef#1{\reserved@c #2#4 $}} \def\reserved@c #1 #2${#1} \begingroup \catcode`\_=12 -\reserved@a\pr@version $Name: release_11_83 $ \ifx\pr@version\@empty -\reserved@a\pr@version CVS-$Revision: 1.115 $ \endgroup \else +\reserved@a\pr@version $Name: release_11_84 $ \ifx\pr@version\@empty +\reserved@a\pr@version CVS-$Revision: 1.122 $ \endgroup \else \def\next release_{} \lccode`\_=`. \edef\next{\lowercase{\endgroup \def\noexpand\pr@version{\expandafter\next\pr@version}}} \next \fi -\reserved@a\next $Date: 2006/05/25 19:28:52 $ +\reserved@a\next $Date: 2006/08/25 10:34:36 $ \edef\next{\noexpand\ProvidesPackage{preview}% [\next\space \pr@version\space (AUCTeX/preview-latex)]} \next @@ -70,7 +52,9 @@ \let\preview@delay\@firstofone} \long\def\pr@adviseii#1#2#3{\preview@delay{% \ifx#1\relax \let#1#2\fi - \toks@{#3#1}\long\edef#2{\the\toks@}}} + \toks@{#3#1}% + \ifx\@undefined\protected \else \protected\fi + \long\edef#2{\the\toks@}}} \DeclareOption{delayed}{% \ifPreview \def\preview@delay{\AtBeginDocument}\fi } @@ -122,7 +106,8 @@ \preview@delay{\ifx#1\@undefined \let#1=$%$ \fi\catcode`\$=\active \ifx\xyreuncatcodes\@undefined\else - \makeatother\xyreuncatcodes\makeatletter\fi}% + \edef\next{\catcode`@=\the\catcode`@\relax}% + \makeatother\expandafter\xyreuncatcodes\next\fi}% \pr@advise@ship\(\pr@endaftergroup{}% \) \pr@advise@ship#1{\@firstoftwo{\let#1=#2% \futurelet\reserved@a\pr@textmathcheck}}{}}% @@ -161,7 +146,8 @@ Please complain to your document class author}% \expandafter\next\csname endfigure*\expandafter\endcsname \csname endtable*\endcsname \DeclareOption{sections}{% - \PreviewMacro[!!!!!!*[!]{\@startsection}%] + \PreviewMacro[!!!!!!*[[!]{\@startsection}%]] + \PreviewMacro[*[[!]{\chapter}%]] } \DeclareOption* {\InputIfFileExists{pr\CurrentOption.def}{}{\OptionNotUsed}} @@ -225,26 +211,8 @@ Please complain to your document class author}% \newenvironment{nopreview}{\ignorespaces}{\ifhmode\unskip\fi} \ProcessOptions\relax \ifPreview\else\expandafter\endinput\fi -%%\iffalse -%% preview.dtx for extracting previews from LaTeX documents. Part of -%% the preview-latex package. -%% Copyright (C) 2001, 2002, 2003, 2004, 2005 Free Software Foundation -%% -%% This program is free software; you can redistribute it and/or modify -%% it under the terms of the GNU General Public License as published by -%% the Free Software Foundation; either version 2 of the License, or -%% (at your option) any later version. -%% -%% This program is distributed in the hope that it will be useful, -%% but WITHOUT ANY WARRANTY; without even the implied warranty of -%% MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -%% GNU General Public License for more details. -%% -%% You should have received a copy of the GNU General Public License -%% along with this program; if not, write to the -%% Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, -%% Boston, MA 02110-1301 USA -%%\fi +%% The preview style for extracting previews from LaTeX documents. +%% Developed as part of AUCTeX <URL:http://www.gnu.org/software/auctex>. \newif\ifpr@outer \pr@outertrue \newcount\pr@snippet @@ -319,7 +287,9 @@ Please complain to your document class author}% \pr@cleanup } \let\pr@shipout=\shipout -\def\shipout{\deadcycles\z@\setbox\z@\box\voidb@x\setbox\z@} +\def\shipout{\deadcycles\z@\bgroup\setbox\z@\box\voidb@x + \afterassignment\pr@shipoutegroup\setbox\z@} +\def\pr@shipoutegroup{\ifvoid\z@ \expandafter\aftergroup\fi \egroup} \def\pr@parseit#1{\csname pr@parse#1\endcsname} \let\pr@endparse=\@percentchar \def\next#1{% @@ -387,13 +357,13 @@ Please complain to your document class author}% {\ifhmode\unskip\fi\endgroup} \renewenvironment{nopreview}{\pr@outerfalse\ignorespaces}% {\ifhmode\unskip\fi} -\output{\def\@elt#1{\global\setbox#1=\box\voidb@x}% - \@currlist - \@elt{255}% - \let\@elt\relax - \xdef\@freelist{\@currlist\@freelist}% - \global\let\@currlist\@empty - \deadcycles\z@} +\newtoks\pr@output +\pr@output\output +\output{% + \pr@outerfalse + \let\@begindvi\@empty + \the\pr@output} +\let\output\pr@output \def\pr@typeinfos{\typeout{Preview: Fontsize \f@size pt}% \ifnum\mag=\@m\else\typeout{Preview: Magnification \number\mag}\fi \ifx\pdfoutput\@undefined \else |