summaryrefslogtreecommitdiff
path: root/Master/texmf-dist
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2012-02-22 23:31:50 +0000
committerKarl Berry <karl@freefriends.org>2012-02-22 23:31:50 +0000
commitf1ecfdedac68a0b0aff5e22b7b69fb42ce8067c5 (patch)
tree58262bcd7eeca307f743a8792e6edabe94103e48 /Master/texmf-dist
parent1310a1d48b5313b3c4031d440d999d744c1126ae (diff)
quoting (22feb12)
git-svn-id: svn://tug.org/texlive/trunk@25474 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist')
-rw-r--r--Master/texmf-dist/doc/latex/quoting/README8
-rw-r--r--Master/texmf-dist/doc/latex/quoting/quoting.pdfbin294508 -> 296924 bytes
-rw-r--r--Master/texmf-dist/source/latex/quoting/quoting.dtx67
-rw-r--r--Master/texmf-dist/source/latex/quoting/quoting.ins4
-rw-r--r--Master/texmf-dist/tex/latex/quoting/quoting.sty15
5 files changed, 69 insertions, 25 deletions
diff --git a/Master/texmf-dist/doc/latex/quoting/README b/Master/texmf-dist/doc/latex/quoting/README
index fa7a704dbb3..b3bcb5c6c7b 100644
--- a/Master/texmf-dist/doc/latex/quoting/README
+++ b/Master/texmf-dist/doc/latex/quoting/README
@@ -1,6 +1,6 @@
The quoting package
Thomas Titz
-2011/09/08
+2012/02/21
__________________
Overview
@@ -15,6 +15,10 @@ after the environment.
__________________
Change history
+Version 0.1b (2012/02/21)
+- Improved syntax of options "font" and "font+"
+- New options "begintext" and "endtext"
+
Version 0.1a (2011/09/08)
- New option "indentfirst"
@@ -24,7 +28,7 @@ Version 0.1 (2011/08/08)
__________________
License
-Copyright (C) 2011 by Thomas Titz <thomas.titz@chello.at>
+Copyright (C) 2011--2012 by Thomas Titz <thomas.titz@chello.at>
Permission is granted to distribute and/or modify this work under the
terms of the LaTeX Project Public License (LPPL), version 1.3c or
diff --git a/Master/texmf-dist/doc/latex/quoting/quoting.pdf b/Master/texmf-dist/doc/latex/quoting/quoting.pdf
index 85fa0e3fd6a..8442d3498de 100644
--- a/Master/texmf-dist/doc/latex/quoting/quoting.pdf
+++ b/Master/texmf-dist/doc/latex/quoting/quoting.pdf
Binary files differ
diff --git a/Master/texmf-dist/source/latex/quoting/quoting.dtx b/Master/texmf-dist/source/latex/quoting/quoting.dtx
index a89e3d8d9d1..e96027cd215 100644
--- a/Master/texmf-dist/source/latex/quoting/quoting.dtx
+++ b/Master/texmf-dist/source/latex/quoting/quoting.dtx
@@ -2,7 +2,7 @@
%
% This is file `quoting.dtx'.
%
-% Copyright (C) 2011 by Thomas Titz <thomas.titz@chello.at>
+% Copyright (C) 2011--2012 by Thomas Titz <thomas.titz@chello.at>
%
% Permission is granted to distribute and/or modify this work under the
% terms of the LaTeX Project Public License (LPPL), version 1.3c or
@@ -42,6 +42,7 @@
\def\quo/{\textsf{quoting}}
\def\quoa/{\textsf{quotation}}
\def\quoe/{\textsf{quote}}
+\widowpenalty=10000
\begin{document}
\DocInput{quoting.dtx}
\end{document}
@@ -49,7 +50,7 @@
%
% \fi
%
-% \CheckSum{154}
+% \CheckSum{168}
%
% \CharacterTable
% {Upper-case \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
@@ -113,7 +114,7 @@
%
% Why didn't Leslie Lamport, the initial developer of \LaTeX, implement
% a single environment for displayed text and provide control over its
-% first-line indentation by other means, e.\,g. the presence of a blank
+% first-line indentation by other means, e.g. the presence of a blank
% line (or a |\par| command) before the environment? The likely reason
% is that Lamport envisaged an additional application of the \quoe/
% environment, namely \blockcquote[p.~24]{Lam94}{a sequence of short
@@ -201,19 +202,36 @@
% pointing out \quo/'s behaviour with respect to \textsf{sloppypar},
% \textsf{center} \& friends.}
%
+% \changes{v0.1b}{2012/02/21}{Improved syntax of options \textsf{font}
+% and \textsf{font+}}
+%
% \item[font]\SpecialOptIndex{font} The font used for typesetting the
% contents of a \quo/ environment. Permitted values are the names
% (without preceding backslash) of \LaTeX's font-switching/formatting
% commands; e.\,g, use \textsf{font=itshape} to typeset quotes in
% italics. (By default, \quo/ uses the font/formatting of the
-% surrounding text.) To specify several font properties, invoke
-% \textsf{font+} in addition to \textsf{font}.
+% surrounding text.) To specify several font properties, use a
+% comma-separated list of font/formatting names, e.g.,
+% \textsf{font=\{itshape,raggedright\}} (note the surrounding
+% braces).\footnote{Before \quo/ v0.1b, \textsf{font+} had to be invoked
+% for specifying several font properties.}
%
% \item[font+]\SpecialOptIndex{font+} Font properties used for
% typesetting the contents of a \quo/ environment in addition to those
% properties specified by \textsf{font} (and previous calls of
% \textsf{font+}).
%
+% \changes{v0.1b}{2012/02/21}{New options \textsf{begintext}
+% and \textsf{endtext}}
+%
+% \item[begintext]\SpecialOptIndex{begintext} Additional text (e.g., an
+% opening quotation mark) to be typeset at the start of a \quo/
+% environment. By default, no text is added.
+%
+% \item[endtext]\SpecialOptIndex{endtext} Additional text (e.g., a
+% closing quotation mark) to be typeset at the end of a \quo/
+% environment. By default, no text is added.
+%
% \item[leftmargin]\SpecialOptIndex{leftmargin} The width of the
% environment's left-hand indentation relative to the surrounding text.
% The default value is |\leftmargin|.\footnote{Note that the value of
@@ -254,7 +272,7 @@
% \DescribeMacro{\quotingfont}
% The options \textsf{font} and \textsf{font+} do not accept values
% which itself take an argument. In such cases you must resort to
-% redefining the command |\quotingfont|, e.\,g. by including
+% redefining the command |\quotingfont|, e.g. by including
% |\renewcommand*{\quotingfont}{\setstretch{1.5}}| in your document
% preamble (with the \textsf{setspace} package loaded).
%
@@ -319,10 +337,10 @@
% \begin{macrocode}
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{quoting}
- [2011/09/08 v0.1a Consolidated environment for displayed text]
+ [2012/02/21 v0.1b Consolidated environment for displayed text]
% \end{macrocode}
% We require the packages \textsf{kvoptions} (to conveniently specify
-% options as key--value pairs) and \textsf{etoolbox} (e.\,g. for length
+% options as key--value pairs) and \textsf{etoolbox} (e.g. for length
% assignments and boolean switch handling).
% \begin{macrocode}
\RequirePackage{etoolbox,kvoptions}
@@ -353,29 +371,40 @@
% \end{macro}
% \begin{macro}{\quotingfont}
% The \textsf{keyval} command |\define@key| is used to define the keys
-% \textsf{font} and \textsf{font+}. We convert their value to a command
-% and use this command to define |\quotingfont| resp. to append its
-% definition.
+% \textsf{font} and \textsf{font+}. With the help of |\docsvlist|
+% (provided by \textsf{etoolbox}), we convert their comma-separated list
+% of values to commands and use these commands to define |\quotingfont|
+% resp. to append its definition.
% \begin{macrocode}
\newcommand*{\quotingfont}{}
\define@key{quo}{font}{%
- \def\quotingfont{\csname #1\endcsname}%
+ \def\quotingfont{}%
+ \renewcommand*{\do}[1]{\appto{\quotingfont}{\csname ##1\endcsname}}%
+ \docsvlist{#1}%
}
\define@key{quo}{font+}{%
- \appto{\quotingfont}{\csname #1\endcsname}%
+ \renewcommand*{\do}[1]{\appto{\quotingfont}{\csname ##1\endcsname}}%
+ \docsvlist{#1}%
}
% \end{macrocode}
% \end{macro}
+% \begin{macro}{\quo@begintext}
+% \begin{macro}{\quo@endtext}
% \begin{macro}{\quo@leftmargin}
% \begin{macro}{\quo@rightmargin}
-% We use \textsf{kvoptions} to define the keys \textsf{leftmargin} and
-% \textsf{rightmargin} and to set their default values.
+% We use \textsf{kvoptions} to define the keys \textsf{begintext},
+% \textsf{endtext}, \textsf{leftmargin}, and \textsf{rightmargin} and to
+% set default values for the latter two.
% \begin{macrocode}
+\DeclareStringOption{begintext}
+\DeclareStringOption{endtext}
\DeclareStringOption[\leftmargin]{leftmargin}
\DeclareStringOption[\quo@leftmargin]{rightmargin}
% \end{macrocode}
% \end{macro}
% \end{macro}
+% \end{macro}
+% \end{macro}
% \begin{macro}{\quo@toppartop}
% \begin{macro}{\quo@vskip}
% The length |\quo@toppartop| is set to the sum of |\topsep| and
@@ -552,7 +581,8 @@
% environment's first paragraph when indicated, and switch to
% |\quotingfont|. (With regard to orphans, we make use of |\@item|'s
% internal mechanism to prevent orphans directly after sectioning
-% commands \cite[p.~229]{Bra09}.)
+% commands \cite[p.~229]{Bra09}.) Lastly, we typeset the replacement
+% text of the \textsf{begintext} key.
% \begin{macrocode}
\item\relax
\ifbool{quo@noorphanfirst}{%
@@ -560,8 +590,10 @@
}{%
}%
\quotingfont
+ \quo@begintext\ignorespaces
% \end{macrocode}
-% At the end of \quo/, the following actions are taken:
+% At the end of \quo/ (and having typeset the replacement text of
+% \textsf{endtext}), the following actions are taken:
% \begin{itemize}
%
% \item The \LaTeX\ kernel switch |@endpe| is set to false (so that
@@ -577,6 +609,7 @@
% \end{itemize}
% \begin{macrocode}
}{%
+ \unskip\quo@endtext
\endlist
\boolfalse{@endpe}%
\ifbool{quo@noorphanafter}{%
diff --git a/Master/texmf-dist/source/latex/quoting/quoting.ins b/Master/texmf-dist/source/latex/quoting/quoting.ins
index a3bfa8d0751..1c6da2428d0 100644
--- a/Master/texmf-dist/source/latex/quoting/quoting.ins
+++ b/Master/texmf-dist/source/latex/quoting/quoting.ins
@@ -1,7 +1,7 @@
%%
%% This is file `quoting.ins'.
%%
-%% Copyright (C) 2011 by Thomas Titz <thomas.titz@chello.at>
+%% Copyright (C) 2011--2012 by Thomas Titz <thomas.titz@chello.at>
%%
%% Permission is granted to distribute and/or modify this work under the
%% terms of the LaTeX Project Public License (LPPL), version 1.3c or
@@ -19,7 +19,7 @@
\preamble
-Copyright (C) 2011 by Thomas Titz <thomas.titz@chello.at>
+Copyright (C) 2011--2012 by Thomas Titz <thomas.titz@chello.at>
Permission is granted to distribute and/or modify this work under the
terms of the LaTeX Project Public License (LPPL), version 1.3c or
diff --git a/Master/texmf-dist/tex/latex/quoting/quoting.sty b/Master/texmf-dist/tex/latex/quoting/quoting.sty
index 4d177b91d41..120ed1fed5b 100644
--- a/Master/texmf-dist/tex/latex/quoting/quoting.sty
+++ b/Master/texmf-dist/tex/latex/quoting/quoting.sty
@@ -6,7 +6,7 @@
%%
%% quoting.dtx (with options: `package')
%%
-%% Copyright (C) 2011 by Thomas Titz <thomas.titz@chello.at>
+%% Copyright (C) 2011--2012 by Thomas Titz <thomas.titz@chello.at>
%%
%% Permission is granted to distribute and/or modify this work under the
%% terms of the LaTeX Project Public License (LPPL), version 1.3c or
@@ -19,7 +19,7 @@
%%
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{quoting}
- [2011/09/08 v0.1a Consolidated environment for displayed text]
+ [2012/02/21 v0.1b Consolidated environment for displayed text]
\RequirePackage{etoolbox,kvoptions}
\SetupKeyvalOptions{family=quo,prefix=quo@}
\def\quo@in@false{\def\quo@indentfirsttype{0}}
@@ -35,11 +35,16 @@
\setkeys{quo}{indentfirst=auto}
\newcommand*{\quotingfont}{}
\define@key{quo}{font}{%
- \def\quotingfont{\csname #1\endcsname}%
+ \def\quotingfont{}%
+ \renewcommand*{\do}[1]{\appto{\quotingfont}{\csname ##1\endcsname}}%
+ \docsvlist{#1}%
}
\define@key{quo}{font+}{%
- \appto{\quotingfont}{\csname #1\endcsname}%
+ \renewcommand*{\do}[1]{\appto{\quotingfont}{\csname ##1\endcsname}}%
+ \docsvlist{#1}%
}
+\DeclareStringOption{begintext}
+\DeclareStringOption{endtext}
\DeclareStringOption[\leftmargin]{leftmargin}
\DeclareStringOption[\quo@leftmargin]{rightmargin}
\newlength{\quo@toppartop}
@@ -125,7 +130,9 @@
}{%
}%
\quotingfont
+ \quo@begintext\ignorespaces
}{%
+ \unskip\quo@endtext
\endlist
\boolfalse{@endpe}%
\ifbool{quo@noorphanafter}{%