summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/csquotes
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2010-09-22 00:09:53 +0000
committerKarl Berry <karl@freefriends.org>2010-09-22 00:09:53 +0000
commitfadc35429e479153067f694a93f8cd10f6c934e5 (patch)
treea05f872d1ba32da629880facb56bb10c78f25da0 /Master/texmf-dist/tex/latex/csquotes
parent03799d65499299079bb659eb8897228076096ce6 (diff)
csquotes 5.0c (21sep10)
git-svn-id: svn://tug.org/texlive/trunk@19835 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/csquotes')
-rw-r--r--Master/texmf-dist/tex/latex/csquotes/csq-compat.def4
-rw-r--r--Master/texmf-dist/tex/latex/csquotes/csquotes.cfg2
-rw-r--r--Master/texmf-dist/tex/latex/csquotes/csquotes.def5
-rw-r--r--Master/texmf-dist/tex/latex/csquotes/csquotes.sty262
4 files changed, 154 insertions, 119 deletions
diff --git a/Master/texmf-dist/tex/latex/csquotes/csq-compat.def b/Master/texmf-dist/tex/latex/csquotes/csq-compat.def
index d787fe51902..c530a7e89a0 100644
--- a/Master/texmf-dist/tex/latex/csquotes/csq-compat.def
+++ b/Master/texmf-dist/tex/latex/csquotes/csq-compat.def
@@ -1,7 +1,7 @@
-% $Id: csq-compat.def,v 5.0b 2010/08/06 18:16:03 lehman stable $
+% $Id: csq-compat.def,v 5.0c 2010/09/21 18:17:28 lehman stable $
\ProvidesFile{csquotes.def}
-[\csq@rcsid $Id: csq-compat.def,v 5.0b 2010/08/06 18:16:03 lehman stable $
+[\csq@rcsid $Id: csq-compat.def,v 5.0c 2010/09/21 18:17:28 lehman stable $
csquotes backwards compatibility]
\def\csq@getversion#1{%
diff --git a/Master/texmf-dist/tex/latex/csquotes/csquotes.cfg b/Master/texmf-dist/tex/latex/csquotes/csquotes.cfg
index 39953d0b3b1..616515b3f13 100644
--- a/Master/texmf-dist/tex/latex/csquotes/csquotes.cfg
+++ b/Master/texmf-dist/tex/latex/csquotes/csquotes.cfg
@@ -1,4 +1,4 @@
-% $Id: csquotes.cfg,v 5.0b 2010/08/06 18:16:03 lehman stable $
+% $Id: csquotes.cfg,v 5.0c 2010/09/21 18:17:28 lehman stable $
\ProvidesFile{csquotes.cfg}
diff --git a/Master/texmf-dist/tex/latex/csquotes/csquotes.def b/Master/texmf-dist/tex/latex/csquotes/csquotes.def
index f5611ca08e8..ce1a04725ef 100644
--- a/Master/texmf-dist/tex/latex/csquotes/csquotes.def
+++ b/Master/texmf-dist/tex/latex/csquotes/csquotes.def
@@ -1,7 +1,7 @@
-% $Id: csquotes.def,v 5.0b 2010/08/06 18:16:03 lehman stable $
+% $Id: csquotes.def,v 5.0c 2010/09/21 18:17:28 lehman stable $
\ProvidesFile{csquotes.def}
-[\csq@rcsid $Id: csquotes.def,v 5.0b 2010/08/06 18:16:03 lehman stable $
+[\csq@rcsid $Id: csquotes.def,v 5.0c 2010/09/21 18:17:28 lehman stable $
csquotes generic definitions]
% Set defaults
@@ -228,7 +228,6 @@
\DeclareQuoteAlias{brazilian}{brazil}
\DeclareQuoteAlias{british}{UKenglish}
\DeclareQuoteAlias{british}{ukenglish}
-\DeclareQuoteAlias{french}{frenchb}
\DeclareQuoteAlias{german}{ngerman}
\DeclareQuoteAlias{austrian}{naustrian}
\DeclareQuoteAlias{norwegian}{norsk}
diff --git a/Master/texmf-dist/tex/latex/csquotes/csquotes.sty b/Master/texmf-dist/tex/latex/csquotes/csquotes.sty
index a29534c45f3..9faf582a3c8 100644
--- a/Master/texmf-dist/tex/latex/csquotes/csquotes.sty
+++ b/Master/texmf-dist/tex/latex/csquotes/csquotes.sty
@@ -1,4 +1,4 @@
-% $Id: csquotes.sty,v 5.0b 2010/08/06 18:16:03 lehman stable $
+% $Id: csquotes.sty,v 5.0c 2010/09/21 18:17:28 lehman stable $
% Copyright (c) 2003-2010 Philipp Lehman.
%
@@ -16,9 +16,9 @@
\def\csq@rcsid$#1: #2 #3 #4 #5${#4 v#3}
-\NeedsTeXFormat{LaTeX2e}
+\NeedsTeXFormat{LaTeX2e}[2005/12/01]
\ProvidesPackage{csquotes}
-[\csq@rcsid $Id: csquotes.sty,v 5.0b 2010/08/06 18:16:03 lehman stable $
+[\csq@rcsid $Id: csquotes.sty,v 5.0c 2010/09/21 18:17:28 lehman stable $
context-sensitive quotations]
\def\csq@version$#1: #2.#3 ${#2#3}
@@ -72,9 +72,10 @@
%% Category codes
-\def\csq@docatcodes{\do\~\do\&\do\:\do\"\do\<\do\>}
-\def\do#1{\noexpand\do\noexpand#1{\the\catcode`#1}}
-\edef\csq@docatcodes{\csq@docatcodes}
+\def\csq@catcodes{\do\~\do\&\do\:\do\"\do\<\do\>}
+\def\do#1{\catcode\number`#1=\the\catcode`#1\relax}
+\edef\csq@catcodes{\csq@catcodes}
+\let\do\noexpand
\catcode`\~=\active
\catcode`\&=3
@@ -83,11 +84,14 @@
\@makeother\<
\@makeother\>
-%% General things
+%% General
-\newtoggle{csq@block}
+\newtoggle{csq@temp}
\newtoggle{csq@quiet}
\newtoggle{csq@active}
+\newtoggle{csq@block}
+\newtoggle{csq@parbox}
+\newbool{csdisplay}
\newcount\csq@reset
\newcount\csq@gtype
@@ -447,6 +451,9 @@
%% Closing marks
\protected\def\csq@qclose{%
+ \csq@qclose@i{}}
+
+\def\csq@qclose@i{%
\ifnum\csq@qlevel=\z@
\csq@mismatch{%
Cannot close any quote. The current level is 0}%
@@ -455,13 +462,13 @@
\csq@eqerror
\else
\expandafter\expandafter
- \expandafter\csq@qclose@i
+ \expandafter\csq@qclose@ii
\fi
\fi}
-\def\csq@qclose@i{%
+\def\csq@qclose@ii#1{%
\ifdim\lastkern=\csq@omitmarker
- \csq@eqgroup
+ #1\csq@eqgroup
\else
\csq@addkern@close
\ifodd\csq@qlevel
@@ -472,6 +479,7 @@
\let\csq@kernchar@i\csq@thequote@iclose
\fi
\csq@setmarker@close
+ \ifblank{#1}{}{\expandafter#1}%
\expandafter\csq@eqgroup
\expandafter\def
\expandafter\csq@kernchar@i
@@ -511,9 +519,9 @@
\csq@tempa}
\appto\@parboxrestore{%
- \let\csq@bquote@i\csq@bquote@ii
\let\csq@theeverypar\@empty
\csq@qlevel\z@
+ \toggletrue{csq@parbox}%
\togglefalse{csq@block}}
%% Restore kerning
@@ -774,13 +782,15 @@
\def\csq@resetlang{%
\ifdef\csq@mainlang
- {\csuse{otherlanguage*}{\csq@mainlang}}
+ {\csuse{otherlanguage*}{\csq@mainlang}}% FIXME
{}}
\protected\long\def\csq@switchlang#1{%
\ifdef\csq@mainlang
{\begingroup
- \csuse{otherlanguage*}{\csq@mainlang}#1%
+ \csuse{otherlanguage*}{\csq@mainlang}%
+ #1%
+ \csuse{endotherlanguage*}%
\endgroup}
{#1}}
@@ -789,6 +799,8 @@
\def\csq@lang#1{%
\csq@savelang
\lowercase{\csuse{otherlanguage*}{#1}}}
+\def\csq@endlang{%
+ \csuse{endotherlanguage*}}
\def\csq@nolang#1{%
\begingroup
@@ -799,6 +811,7 @@
\def\csq@hyph#1{%
\csq@savelang
\lowercase{\csq@hyphenrules{#1}}}
+\let\csq@endhyph\@empty
\def\csq@nohyph#1{%
\begingroup
@@ -851,8 +864,11 @@
\csq@warn@multilang{Cannot adjust default style}%
\fi
\csq@reset\z@
- \let\csq@lang\csq@nolang
\let\csq@hyph\csq@nohyph
+ \let\csq@endhyph\@empty
+ \let\csq@lang\csq@nolang
+ \let\csq@endlang\@empty
+ \let\csq@switchlang\@firstofone
\def\csq@resetqstyle{%
\csq@warn@multilang{Cannot enable multilingual quotes}}}
@@ -955,26 +971,28 @@
% Plain quotes
\newrobustcmd*{\enquote}{%
- \@ifstar{\csq@quote@ii{}}{\csq@quote@i{}}}
+ \@ifstar{\csq@quote@ii{}{}}{\csq@quote@i{}{}}}
+
+% {<init>}{<endinit>}{<text>}
-\long\def\csq@quote@i#1#2{%
- \csq@bqgroup #1\csq@oqopen@i #2\csq@qclose}
-\long\def\csq@quote@ii#1#2{%
- \csq@bqgroup #1\csq@iqopen@i #2\csq@qclose}
+\long\def\csq@quote@i#1#2#3{%
+ \csq@bqgroup#1\csq@oqopen@i#3\csq@qclose@i{#2}}
+\long\def\csq@quote@ii#1#2#3{%
+ \csq@bqgroup#1\csq@iqopen@i#3\csq@qclose@i{#2}}
% Plain quotes + language switching
\newrobustcmd*{\foreignquote}{%
\@ifstar\csq@fquote@ii\csq@fquote@i}
-\def\csq@fquote@i#1{\csq@quote@i{\csq@lang{#1}}}
-\def\csq@fquote@ii#1{\csq@quote@ii{\csq@lang{#1}}}
+\def\csq@fquote@i#1{\csq@quote@i{\csq@lang{#1}}{\csq@endlang}}
+\def\csq@fquote@ii#1{\csq@quote@ii{\csq@lang{#1}}{\csq@endlang}}
\newrobustcmd*{\hyphenquote}{%
\@ifstar\csq@hquote@ii\csq@hquote@i}
-\def\csq@hquote@i#1{\csq@quote@i{\csq@hyph{#1}}}
-\def\csq@hquote@ii#1{\csq@quote@ii{\csq@hyph{#1}}}
+\def\csq@hquote@i#1{\csq@quote@i{\csq@hyph{#1}}{\csq@endhyph}}
+\def\csq@hquote@ii#1{\csq@quote@ii{\csq@hyph{#1}}{\csq@endhyph}}
% PDF strings
@@ -1010,30 +1028,30 @@
\newrobustcmd*{\textquote}{%
\@ifstar
- {\csq@getcargs{\csq@tquote{}{\csq@iqopen}}}
- {\csq@getcargs{\csq@tquote{}{\csq@oqopen}}}}
+ {\csq@getcargs{\csq@tquote{}{}{\csq@iqopen@i}}}
+ {\csq@getcargs{\csq@tquote{}{}{\csq@oqopen@i}}}}
-% {<init>}{<qopen>}{<citehook>}{<cite>}{<punct>}{<text>}
+% {<init>}{<endinit>}{<qopen>}{<citehook>}{<cite>}{<punct>}{<text>}
-\long\def\csq@tquote#1#2#3#4#5#6{%
- \csq@getpunct{\csq@tquote@i{#1}{#2}{#3}{#4}{#5}{#6}}}
+\long\def\csq@tquote#1#2#3#4#5#6#7{%
+ \csq@getpunct{\csq@tquote@i{#1}{#2}{#3}{#4}{#5}{#6}{#7}}}
-% {<init>}{<qopen>}{<citehook>}{<cite>}{<punct>}{<text>}{<apunct>}<tpunct>
+% {<init>}{<endinit>}{<qopen>}{<citehook>}{<cite>}{<punct>}{<text>}{<apunct>}<tpunct>
-\long\def\csq@tquote@i#1#2#3#4#5#6#7#8{%
+\long\def\csq@tquote@i#1#2#3#4#5#6#7#8#9{%
\begingroup
\csq@setsfcodes
\edef\csq@tempa{%
\unexpanded{%
\mktextquote
- {#2}%
- {#6}%
- {\csq@qclose}%
- {#5}{#7}}%
- {\ifblank{#4}
+ {#3}%
+ {#7}%
+ {\csq@qclose@i{#2}}%
+ {#6}{#8}}%
+ {\ifblank{#5}
{}
- {\unexpanded{\csq@switchlang{#3{#4}}}}}}%
- #1\csq@tempa#8%
+ {\unexpanded{\csq@switchlang{#4{#5}}}}}}%
+ \csq@bqgroup#1\csq@tempa#9%
\endgroup}
% {<qopen>}{<text>}{<qclose>}{<punct>}{<apunct>}{<cite>}
@@ -1046,24 +1064,24 @@
\@ifstar\csq@ftquote@ii\csq@ftquote@i}
\def\csq@ftquote@i#1{%
- \csq@getcargs{\csq@tquote{\csq@lang{#1}}{\csq@oqopen}}}
+ \csq@getcargs{\csq@tquote{\csq@lang{#1}}{\csq@endlang}{\csq@oqopen@i}}}
\def\csq@ftquote@ii#1{%
- \csq@getcargs{\csq@tquote{\csq@lang{#1}}{\csq@iqopen}}}
+ \csq@getcargs{\csq@tquote{\csq@lang{#1}}{\csq@endlang}{\csq@iqopen@i}}}
\newrobustcmd*{\hyphentextquote}{%
\@ifstar\csq@htquote@ii\csq@htquote@i}
\def\csq@htquote@i#1{%
- \csq@getcargs{\csq@tquote{\csq@hyph{#1}}{\csq@oqopen}}}
+ \csq@getcargs{\csq@tquote{\csq@hyph{#1}}{\csq@endhyph}{\csq@oqopen@i}}}
\def\csq@htquote@ii#1{%
- \csq@getcargs{\csq@tquote{\csq@hyph{#1}}{\csq@iqopen}}}
+ \csq@getcargs{\csq@tquote{\csq@hyph{#1}}{\csq@endhyph}{\csq@iqopen@i}}}
% Integrated text quotes
\newrobustcmd*{\textcquote}{%
\@ifstar
- {\csq@getccargs{\csq@tquote{}{\csq@iqopen}}}
- {\csq@getccargs{\csq@tquote{}{\csq@oqopen}}}}
+ {\csq@getccargs{\csq@tquote{}{}{\csq@iqopen@i}}}
+ {\csq@getccargs{\csq@tquote{}{}{\csq@oqopen@i}}}}
% Integrated text quotes + language switching
@@ -1071,17 +1089,17 @@
\@ifstar\csq@ftcquote@ii\csq@ftcquote@i}
\def\csq@ftcquote@i#1{%
- \csq@getccargs{\csq@tquote{\csq@lang{#1}}{\csq@oqopen}}}
+ \csq@getccargs{\csq@tquote{\csq@lang{#1}}{\csq@endlang}{\csq@oqopen@i}}}
\def\csq@ftcquote@ii#1{%
- \csq@getccargs{\csq@tquote{\csq@lang{#1}}{\csq@iqopen}}}
+ \csq@getccargs{\csq@tquote{\csq@lang{#1}}{\csq@endlang}{\csq@iqopen@i}}}
\newrobustcmd*{\hyphentextcquote}{%
\@ifstar\csq@htcquote@ii\csq@htcquote@i}
\def\csq@htcquote@i#1{%
- \csq@getccargs{\csq@tquote{\csq@hyph{#1}}{\csq@oqopen}}}
+ \csq@getccargs{\csq@tquote{\csq@hyph{#1}}{\csq@endhyph}{\csq@oqopen@i}}}
\def\csq@htcquote@ii#1{%
- \csq@getccargs{\csq@tquote{\csq@hyph{#1}}{\csq@iqopen}}}
+ \csq@getccargs{\csq@tquote{\csq@hyph{#1}}{\csq@endhyph}{\csq@iqopen@i}}}
% PDF strings
@@ -1096,44 +1114,50 @@
% Block quotes
\newrobustcmd*{\blockquote}{%
- \csq@getcargs{\csq@bquote{}}}
+ \csq@getcargs{\csq@bquote{}{}}}
-% {<init>}{<citehook>}{<cite>}{<punct>}{<text>}
+% {<init>}{<endinit>}{<citehook>}{<cite>}{<punct>}{<text>}
-\long\def\csq@bquote#1#2#3#4#5{%
+\long\def\csq@bquote#1#2#3#4#5#6{%
\csq@ifnested
{\csq@err@nbquote}
{\csq@getpunct{%
- \ifbool{inner}{\csq@bquote@ii}{\csq@bquote@i}%
- {#1}{#2}{#3}{#4}{#5}}}}
+ \ifbool{inner}
+ {\csq@bquote@ii}
+ {\ifbool{csdisplay}
+ {\csq@bquote@i}
+ {\iftoggle{csq@parbox}\csq@bquote@ii\csq@bquote@i}}%
+ {#1}{#2}{#3}{#4}{#5}{#6}}}}
-% {<init>}{<citehook>}{<cite>}{<punct>}{<text>}{<apunct>}<tpunct>
+% {<init>}{<endinit>}{<citehook>}{<cite>}{<punct>}{<text>}{<apunct>}<tpunct>
-\long\def\csq@bquote@i#1#2#3#4#5{%
+\long\def\csq@bquote@i#1#2#3#4#5#6{%
\begingroup
\@blockquote@prehook
\@fileswfalse
\let\csq@bslash\\%
\let\csq@newline\newline
- \togglefalse{csq@block}%
- \def\csq@isblock{\toggletrue{csq@block}}%
+ \togglefalse{csq@temp}%
\setbox\@tempboxa=\vbox{%
- \def\par{\aftergroup\csq@isblock\@par}%
- \def\\{\aftergroup\csq@isblock\let\\\csq@bslash\\}%
- \def\newline{\aftergroup\csq@isblock
+ \def\par{%
+ \global\toggletrue{csq@temp}\@par}%
+ \def\\{%
+ \global\toggletrue{csq@temp}%
+ \let\\\csq@bslash\\}%
+ \def\newline{%
+ \global\toggletrue{csq@temp}%
\let\newline\csq@newline\newline}%
- \parfillskip\z@ \@plus 1fil\relax
- \parindent\z@
- \vrule \@height1\baselineskip \@width\z@ #1#5#4}%
+ \parfillskip\z@\@plus 1fil\relax\parindent\z@
+ \vrule\@height1\baselineskip\@width\z@ #1#6#5#2}%
\ifdim\ht\@tempboxa>\csq@tshold\baselineskip
- \toggletrue{csq@block}%
+ \toggletrue{csq@temp}%
\fi
- \iftoggle{csq@block}
+ \iftoggle{csq@temp}
{\aftergroup\@firstoftwo}
{\aftergroup\@secondoftwo}%
\@blockquote@posthook
\endgroup
- \csq@bquote@iii\csq@bquote@ii{#1}{#2}{#3}{#4}{#5}}
+ \csq@bquote@iii\csq@bquote@ii{#1}{#2}{#3}{#4}{#5}{#6}}
\newrobustcmd*{\BlockquoteDisable}{%
\gappto\@blockquote@prehook}
@@ -1158,23 +1182,25 @@
\let\csq@nbgobble\@firstofone
-% {<init>}{<citehook>}{<cite>}{<punct>}{<text>}{<apunct>}<tpunct>
+% {<init>}{<endinit>}{<citehook>}{<cite>}{<punct>}{<text>}{<apunct>}<tpunct>
+
+\def\csq@bquote@ii#1#2{\csq@tquote@i{#1}{#2}{\csq@oqopen@i}}
-\def\csq@bquote@ii#1{\csq@tquote@i{#1}{\csq@oqopen}}
+% {<init>}{<endinit>}{<citehook>}{<cite>}{<punct>}{<text>}{<apunct>}<tpunct>
-\long\def\csq@bquote@iii#1#2#3#4#5#6#7{%
+\long\def\csq@bquote@iii#1#2#3#4#5#6#7#8{%
\begin{\csq@blockenvironment}%
- \csq@setsfcodes
\toggletrue{csq@block}%
+ \csq@setsfcodes
\edef\csq@tempa{%
\unexpanded{%
\mkblockquote
- {#5}%
- {#4}{#6}}%
- {\ifblank{#3}
+ {#6}%
+ {#5}{#7}}%
+ {\ifblank{#4}
{}
- {\unexpanded{\csq@switchlang{#2{#3}}}}}}%
- #1\csq@tempa#7%
+ {\unexpanded{\csq@switchlang{#3{#4}}}}}}%
+ #1\csq@tempa#8#2%
\end{\csq@blockenvironment}}
% {<text>}{<punct>}{<apunct>}{<cite>}
@@ -1184,31 +1210,35 @@
% Block quotes + language switching
\newrobustcmd*{\foreignblockquote}[1]{%
- \csq@getcargs{\csq@bquote{\csq@lang{#1}}}}
+ \csq@getcargs{\csq@bquote{\csq@lang{#1}}{\csq@endlang}}}
\newrobustcmd*{\hyphenblockquote}[1]{%
- \csq@getcargs{\csq@bquote{\csq@hyph{#1}}}}
+ \csq@getcargs{\csq@bquote{\csq@hyph{#1}}{\csq@endhyph}}}
\newrobustcmd*{\hybridblockquote}[1]{%
- \csq@getcargs{\csq@bquote{%
- \iftoggle{csq@block}\csq@lang\csq@hyph{#1}}}}
+ \csq@getcargs{%
+ \csq@bquote
+ {\iftoggle{csq@block}{\csq@lang}{\csq@hyph}{#1}}
+ {\iftoggle{csq@block}{\csq@endlang}{\csq@endhyph}}}}
% Integrated block quotes
\newrobustcmd*{\blockcquote}{%
- \csq@getccargs{\csq@bquote{}}}
+ \csq@getccargs{\csq@bquote{}{}}}
% Integrated block quotes + language switching
\newrobustcmd*{\foreignblockcquote}[1]{%
- \csq@getccargs{\csq@bquote{\csq@lang{#1}}}}
+ \csq@getccargs{\csq@bquote{\csq@lang{#1}}{\csq@endlang}}}
\newrobustcmd*{\hyphenblockcquote}[1]{%
- \csq@getccargs{\csq@bquote{\csq@hyph{#1}}}}
+ \csq@getccargs{\csq@bquote{\csq@hyph{#1}}{\csq@endhyph}}}
\newrobustcmd*{\hybridblockcquote}[1]{%
- \csq@getccargs{\csq@bquote{%
- \iftoggle{csq@block}\csq@lang\csq@hyph{#1}}}}
+ \csq@getccargs{%
+ \csq@bquote
+ {\iftoggle{csq@block}{\csq@lang}{\csq@hyph}{#1}}
+ {\iftoggle{csq@block}{\csq@endlang}{\csq@endhyph}}}}
% PDF strings
@@ -1223,25 +1253,24 @@
% Display quotes
\newenvironment*{displayquote}
- {\csq@getcargs{\csq@bdquote{}}}
+ {\csq@getcargs{\csq@bdquote{}{}}}
{\csq@edquote}
-% {<init>}{<citehook>}{<cite>}{<punct>}
+% {<init>}{<endinit>}{<citehook>}{<cite>}{<punct>}
-\def\csq@bdquote#1#2#3#4{%
+\def\csq@bdquote#1#2#3#4#5{%
\csuse{\csq@blockenvironment}%
- \csq@setsfcodes
\toggletrue{csq@block}%
- #1\ifblank{#3}
- {\def\csq@tempb{\mkenddispquote{#4}{}}%
- \mkbegdispquote{#4}{}}
- {\def\csq@tempb{\mkenddispquote{#4}{\csq@switchlang{#2{#3}}}}%
- \mkbegdispquote{#4}{\csq@switchlang{#2{#3}}}}%
+ \csq@setsfcodes
+ #1\ifblank{#4}
+ {\def\csq@tempb{\mkenddispquote{#5}{}#2}%
+ \mkbegdispquote{#5}{}}
+ {\def\csq@tempb{\mkenddispquote{#5}{\csq@switchlang{#3{#4}}}#2}%
+ \mkbegdispquote{#5}{\csq@switchlang{#3{#4}}}}%
\ignorespaces}
\def\csq@edquote{%
- \unspace
- \csq@tempb
+ \unspace\csq@tempb
\csuse{end\csq@blockenvironment}}
\providerobustcmd*{\unspace}{%
@@ -1261,27 +1290,27 @@
% Display quotes + language switching
\newenvironment*{foreigndisplayquote}[1]
- {\csq@getcargs{\csq@bdquote{\csq@lang{#1}}}}
+ {\csq@getcargs{\csq@bdquote{\csq@lang{#1}}{\csq@endlang}}}
{\csq@edquote}
\newenvironment*{hyphendisplayquote}[1]
- {\csq@getcargs{\csq@bdquote{\csq@hyph{#1}}}}
+ {\csq@getcargs{\csq@bdquote{\csq@hyph{#1}}{\csq@endhyph}}}
{\csq@edquote}
% Integrated display quotes
\newenvironment*{displaycquote}
- {\csq@getccargs{\csq@bdquote{}}}
+ {\csq@getccargs{\csq@bdquote{}{}}}
{\csq@edquote}
% Integrated display quotes + language switching
\newenvironment*{foreigndisplaycquote}[1]
- {\csq@getccargs{\csq@bdquote{\csq@lang{#1}}}}
+ {\csq@getccargs{\csq@bdquote{\csq@lang{#1}}{\csq@endlang}}}
{\csq@edquote}
\newenvironment*{hyphendisplaycquote}[1]
- {\csq@getccargs{\csq@bdquote{\csq@hyph{#1}}}}
+ {\csq@getccargs{\csq@bdquote{\csq@hyph{#1}}{\csq@endhyph}}}
{\csq@edquote}
% Hooks
@@ -1388,7 +1417,7 @@
\let\csq@mkpdfstrings\@empty
\appto\csq@hook@hyperref{\csq@mkpdfstrings}
-\ifdef\inpenc@prehook % inputenc 2006/05/05 v1.1b
+\ifdef\inpenc@prehook
{\AtBeginDocument{%
\addto@hook\inpenc@prehook{%
\csq@info{Input encoding change}%
@@ -1678,7 +1707,7 @@
{\csq@err@char
\@gobbletwo}}}
-\ifundef\inputencodingname % inputenc >= 2006/05/05 v1.1b, inputenx
+\ifundef\inputencodingname
{\def\csq@ifutfenc{%
\csq@ifucs
{\csq@err@ucs\@secondoftwo}
@@ -1803,7 +1832,9 @@
\csq@addspecial{#3}
{\csq@bqgroup\csq@lang{#2}#1}
{\csq@pdf@ooqmark}{}%
- \csq@addspecial{#4}{\csq@qclose}{\csq@pdf@coqmark}{}}
+ \csq@addspecial{#4}
+ {\csq@qclose@i{\csq@endlang}}
+ {\csq@pdf@coqmark}{}}
\newrobustcmd*{\MakeHyphenQuote}{%
\@ifstar
@@ -1813,22 +1844,26 @@
\csq@addspecial{#3}
{\csq@bqgroup\csq@hyph{#2}#1}
{\csq@pdf@ooqmark}{}%
- \csq@addspecial{#4}{\csq@qclose}{\csq@pdf@coqmark}{}}
+ \csq@addspecial{#4}
+ {\csq@qclose@i{\csq@endhyph}}
+ {\csq@pdf@coqmark}{}}
\newrobustcmd*{\MakeBlockQuote}[3]{%
- \csq@addbspecial{#1}{#2}{#3}{\csq@bquote{}{\mkcitation}}}
+ \csq@addbspecial{#1}{#2}{#3}{\csq@bquote{}{}{\mkcitation}}}
\newrobustcmd*{\MakeForeignBlockQuote}[4]{%
\csq@addbspecial{#2}{#3}{#4}%
- {\csq@bquote{\csq@lang{#1}}{\mkcitation}}}
+ {\csq@bquote{\csq@lang{#1}}{\csq@endlang}{\mkcitation}}}
\newrobustcmd*{\MakeHyphenBlockQuote}[4]{%
\csq@addbspecial{#2}{#3}{#4}%
- {\csq@bquote{\csq@hyph{#1}}{\mkcitation}}}
+ {\csq@bquote{\csq@hyph{#1}}{\csq@endhyph}{\mkcitation}}}
\newrobustcmd*{\MakeHybridBlockQuote}[4]{%
\csq@addbspecial{#2}{#3}{#4}%
- {\csq@bquote{\iftoggle{csq@block}\csq@lang\csq@hyph{#1}}%
+ {\csq@bquote
+ {\iftoggle{csq@block}{\csq@lang}{\csq@hyph}{#1}}
+ {\iftoggle{csq@block}{\csq@endlang}{\csq@endhyph}}
{\mkcitation}}}
\newrobustcmd*{\EnableQuotes}{}
@@ -2223,7 +2258,7 @@
\csq@reset4\relax}
\define@key{csq}{babel}[true]{%
- \csq@warning{%
+ \csq@info{%
Option 'babel' depreciated.\MessageBreak
Using 'autostyle'}%
\setkeys{csq}{autostyle=#1}}
@@ -2239,6 +2274,9 @@
{\input{csq-compat.def}}%
\csq@getversion{#1}}
+\define@key{csq}{csdisplay}[true]{%
+ \setbool{csdisplay}{#1}}
+
%% Initial setup
% Provide 'quote' environment
@@ -2312,10 +2350,8 @@
% Restore catcodes
-\def\do#1#2{\catcode`#1=#2\relax}
-\csq@docatcodes
-\undef\csq@docatcodes
-\let\do\noexpand
+\csq@catcodes
+\undef\csq@catcodes
% Load predefined styles