summaryrefslogtreecommitdiff
path: root/Master
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2012-04-13 22:12:38 +0000
committerKarl Berry <karl@freefriends.org>2012-04-13 22:12:38 +0000
commita4f01148777f706bc0182da96daaebf2e7224c96 (patch)
tree36aca06a5845290f16e97eae64f7511457387191 /Master
parentebfea0e090398fb8c7a2c20a969250bf026efbee (diff)
standalone 1.0b (13apr12)
git-svn-id: svn://tug.org/texlive/trunk@25951 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master')
-rw-r--r--Master/texmf-dist/doc/latex/standalone/standalone.pdfbin253848 -> 253851 bytes
-rw-r--r--Master/texmf-dist/source/latex/standalone/standalone.dtx101
-rw-r--r--Master/texmf-dist/tex/latex/standalone/standalone.cfg4
-rw-r--r--Master/texmf-dist/tex/latex/standalone/standalone.cls65
-rw-r--r--Master/texmf-dist/tex/latex/standalone/standalone.sty4
5 files changed, 166 insertions, 8 deletions
diff --git a/Master/texmf-dist/doc/latex/standalone/standalone.pdf b/Master/texmf-dist/doc/latex/standalone/standalone.pdf
index 82c6a27c932..7dd307f5e9c 100644
--- a/Master/texmf-dist/doc/latex/standalone/standalone.pdf
+++ b/Master/texmf-dist/doc/latex/standalone/standalone.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/standalone/standalone.dtx b/Master/texmf-dist/source/latex/standalone/standalone.dtx
index 512188ed8da..5901d00fffa 100644
--- a/Master/texmf-dist/source/latex/standalone/standalone.dtx
+++ b/Master/texmf-dist/source/latex/standalone/standalone.dtx
@@ -25,10 +25,10 @@
\NeedsTeXFormat{LaTeX2e}
\ProvidesFile{standalone.dtx}[%
%<=*DATE>
- 2012/04/10
+ 2012/04/13
%<=/DATE>
%<=*VERSION>
- v1.0a
+ v1.0b
%<=/VERSION>
DTX file of the standalone bundle]
\documentclass[a4paper,11pt]{ydoc}
@@ -1194,10 +1194,12 @@
\newif\ifsa@multi
\newif\ifsa@varwidth
\newif\ifsa@ignorerest
+\newif\ifsa@ignoreempty
\newif\ifsa@tikz
\newif\ifsa@pstricks
\newif\ifsa@convert
\newif\ifsa@float
+\newif\ifsa@math
% \end{macrocode}
%
% The \cs{ifstandalonebeamer} switch is in the user-level.
@@ -1307,6 +1309,17 @@
% \end{key}
%
%
+% \begin{key}{standalone.cls}{ignoreempty}
+% Boolean to control if empty boxes/pages should be ignored.
+% This is intended mostly for the \opt{multi} option and currently only works with \opt{crop} but not with \opt{preview}.
+% \begin{macrocode}
+\sa@clsoption{ignoreempty}[true]{%
+ \sa@boolean{ignoreempty}{#1}%
+}
+% \end{macrocode}
+% \end{key}
+%
+%
% \begin{key}{standalone.cls}{multi}
% Boolean to control if multiple pages are used.
% \begin{macrocode}
@@ -1317,6 +1330,62 @@
% \end{key}
%
%
+% \begin{key}{standalone.cls}{math}
+% Boolean to control if multiple pages are used.
+% \begin{macrocode}
+\sa@clsoption{math}[true]{%
+ \sa@boolean{math}{#1}%
+ \ifsa@math
+ \setkeys{standalone.cls}{multi=true,ignoreempty=true,border=0.50001bp}%
+ \fi
+}
+\AtBeginDocument{\ifsa@math\sa@math\fi}
+% \end{macrocode}
+% \end{key}
+%
+% \begin{macro}{\sa@math}
+% Enables a simple support for multiple math equations.
+% Displaymath is typeset as in-text math but with \cs{displaystyle} in effect.
+% This allows \Macro\(, \Macro\), \Macro\[ and \Macro\] as well as \env{math} and \env{displaymath}.
+% To simply typeset multiple equations two environments \env{multimath} and \env{multidisplaymath}
+% are defined which use \Macro\\ as a delimiter. Every equation will be placed on a tight page on its own.
+% To allow a trailing \Macro\\ the \opt{ignoreempty} is automatically enabled.
+% \begin{macrocode}
+\def\sa@math{%
+ \standaloneenv{math}%
+ \def\({\begingroup\math}%
+ \def\){\endmath\endgroup}%
+ \def\[{\(\displaystyle}%
+ \def\]{\)}%
+ \def\displaymath{\math\displaystyle}%
+ \def\enddisplaymath{\endmath}%
+ \newcommand*\multimathsep{%
+ \endmath
+ \math
+ \let\\\multimathsep
+ }%
+ \newenvironment{multimath}{%
+ \math
+ \let\\\multimathsep
+ }{%
+ \endmath
+ }%
+ \newcommand*\multidisplaymathsep{%
+ \endmath
+ \math\displaystyle
+ \let\\\multidisplaymathsep
+ }%
+ \newenvironment{multidisplaymath}{%
+ \math\displaystyle
+ \let\\\multidisplaymathsep
+ }{%
+ \endmath
+ }%
+}
+% \end{macrocode}
+% \end{macro}
+%
+%
% \begin{key}{standalone.cls}{varwidth}
% Boolean to control if \pkg{varwidth} package should be used.
% If so the content will be placed in a \env{varwidth} environment to avoid extending it to the full line width if a
@@ -1595,6 +1664,23 @@
% \end{macrocode}
% \end{key}
%
+% \begin{key}{standalone.cls/convert}{command}
+% \begin{macrocode}
+\sa@convertoption{command}{%
+ \def\sa@convert@command{#1}%
+}
+% \end{macrocode}
+% \end{key}
+%
+% \begin{key}{standalone.cls/convert}{pdf2svg}
+% \begin{macrocode}
+\sa@convertoption{pdf2svg}[]{%
+ \def\sa@convert@command{pdf2svg \infile\space\outfile}%
+ \sa@convertvar{outext}{.svg}
+}
+% \end{macrocode}
+% \end{key}
+%
% \begin{key}{standalone.cls/convert}{imagemagick}
% \begin{macrocode}
\sa@convertoption{imagemagick}[]{%
@@ -2002,6 +2088,16 @@
% using the output format dependent \Macro\sa@placebox macro.
% \begin{macrocode}
\def\sa@handlebox{%
+ \ifcase
+ 0%
+ \ifsa@ignoreempty
+ \ifdim\wd\sa@box=\z@
+ \ifdim\ht\sa@box=\z@
+ \ifdim\dp\sa@box=\z@
+ 1%
+ \fi\fi\fi
+ \fi
+ \relax
\sbox\sa@box{%
% \end{macrocode}
% add left border
@@ -2030,6 +2126,7 @@
\hskip\sa@border@right
}%
\sa@placebox
+ \fi
}
% \end{macrocode}
% \end{macro}
diff --git a/Master/texmf-dist/tex/latex/standalone/standalone.cfg b/Master/texmf-dist/tex/latex/standalone/standalone.cfg
index bd047b7e624..ab1ffbbba25 100644
--- a/Master/texmf-dist/tex/latex/standalone/standalone.cfg
+++ b/Master/texmf-dist/tex/latex/standalone/standalone.cfg
@@ -1,7 +1,7 @@
\NeedsTeXFormat{LaTeX2e}
\ProvidesFile{standalone.cfg}[%
- 2012/04/10
- v1.0a
+ 2012/04/13
+ v1.0b
Default configuration file for 'standalone' class]%
%% Enabled the "varwidth" option if the "varwidth" package is available:
%%\IfFileExists{varwidth.sty}{%
diff --git a/Master/texmf-dist/tex/latex/standalone/standalone.cls b/Master/texmf-dist/tex/latex/standalone/standalone.cls
index d418be0450a..a60e7bf0fd5 100644
--- a/Master/texmf-dist/tex/latex/standalone/standalone.cls
+++ b/Master/texmf-dist/tex/latex/standalone/standalone.cls
@@ -17,8 +17,8 @@
%%
\NeedsTeXFormat{LaTeX2e}
\ProvidesClass{standalone}[%
- 2012/04/10
- v1.0a
+ 2012/04/13
+ v1.0b
Class to compile TeX sub-files standalone]
\newif\ifstandalone
\standalonetrue
@@ -112,10 +112,12 @@
\newif\ifsa@multi
\newif\ifsa@varwidth
\newif\ifsa@ignorerest
+\newif\ifsa@ignoreempty
\newif\ifsa@tikz
\newif\ifsa@pstricks
\newif\ifsa@convert
\newif\ifsa@float
+\newif\ifsa@math
\let\sa@beamertrue\standalonebeamertrue
\let\sa@beamerfalse\standalonebeamerfalse
\def\sa@clsoption{%
@@ -165,9 +167,50 @@
\sa@clsoption{ignorerest}[true]{%
\sa@boolean{ignorerest}{#1}%
}
+\sa@clsoption{ignoreempty}[true]{%
+ \sa@boolean{ignoreempty}{#1}%
+}
\sa@clsoption{multi}[true]{%
\sa@boolorvalue{multi}{#1}{\sa@multitrue\AtBeginDocument{\standaloneenv{#1}}}%
}
+\sa@clsoption{math}[true]{%
+ \sa@boolean{math}{#1}%
+ \ifsa@math
+ \setkeys{standalone.cls}{multi=true,ignoreempty=true,border=0.50001bp}%
+ \fi
+}
+\AtBeginDocument{\ifsa@math\sa@math\fi}
+\def\sa@math{%
+ \standaloneenv{math}%
+ \def\({\begingroup\math}%
+ \def\){\endmath\endgroup}%
+ \def\[{\(\displaystyle}%
+ \def\]{\)}%
+ \def\displaymath{\math\displaystyle}%
+ \def\enddisplaymath{\endmath}%
+ \newcommand*\multimathsep{%
+ \endmath
+ \math
+ \let\\\multimathsep
+ }%
+ \newenvironment{multimath}{%
+ \math
+ \let\\\multimathsep
+ }{%
+ \endmath
+ }%
+ \newcommand*\multidisplaymathsep{%
+ \endmath
+ \math\displaystyle
+ \let\\\multidisplaymathsep
+ }%
+ \newenvironment{multidisplaymath}{%
+ \math\displaystyle
+ \let\\\multidisplaymathsep
+ }{%
+ \endmath
+ }%
+}
\sa@clsoption{varwidth}[true]{%
\sa@boolorvalue{varwidth}{#1}{\sa@varwidthtrue\def\sa@width{#1}}%
\ifsa@varwidth
@@ -322,6 +365,13 @@
}
\@namedef{sa@gsdevice@.jpg}{jpeg}%
\@namedef{sa@gsdevice@.png}{png16m}%
+\sa@convertoption{command}{%
+ \def\sa@convert@command{#1}%
+}
+\sa@convertoption{pdf2svg}[]{%
+ \def\sa@convert@command{pdf2svg \infile\space\outfile}%
+ \sa@convertvar{outext}{.svg}
+}
\sa@convertoption{imagemagick}[]{%
\def\sa@convert@command{\convertexe\space -density \density\space \infile\space \ifx\size\empty\else -resize \size\fi\space -quality 90 \outfile}%
}
@@ -553,6 +603,16 @@
}%
\fi
\def\sa@handlebox{%
+ \ifcase
+ 0%
+ \ifsa@ignoreempty
+ \ifdim\wd\sa@box=\z@
+ \ifdim\ht\sa@box=\z@
+ \ifdim\dp\sa@box=\z@
+ 1%
+ \fi\fi\fi
+ \fi
+ \relax
\sbox\sa@box{%
\hskip\sa@border@left
\@tempdima=\ht\sa@box
@@ -566,6 +626,7 @@
\hskip\sa@border@right
}%
\sa@placebox
+ \fi
}
\ifcase0%
\ifpdf\else\ifluatex\else\ifxetex\else 1\fi\fi\fi
diff --git a/Master/texmf-dist/tex/latex/standalone/standalone.sty b/Master/texmf-dist/tex/latex/standalone/standalone.sty
index 01d7a1046e2..6a068a89654 100644
--- a/Master/texmf-dist/tex/latex/standalone/standalone.sty
+++ b/Master/texmf-dist/tex/latex/standalone/standalone.sty
@@ -18,8 +18,8 @@
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{standalone}[%
- 2012/04/10
- v1.0a
+ 2012/04/13
+ v1.0b
Package to include TeX sub-files with preambles]
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
\@ifundefined{ifstandalone}{%