summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/koma-script/scrjura.sty
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2013-12-26 23:18:36 +0000
committerKarl Berry <karl@freefriends.org>2013-12-26 23:18:36 +0000
commit9b219d1b664067729034647a4b37626cf2bf5e26 (patch)
tree00708467b44f90736dc32ed1bebb95e9c4710139 /Master/texmf-dist/tex/latex/koma-script/scrjura.sty
parentc00c8298eb6913b74270a36c1f1018f1e9946f7b (diff)
koma-script (26dec13)
git-svn-id: svn://tug.org/texlive/trunk@32489 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/koma-script/scrjura.sty')
-rw-r--r--Master/texmf-dist/tex/latex/koma-script/scrjura.sty294
1 files changed, 171 insertions, 123 deletions
diff --git a/Master/texmf-dist/tex/latex/koma-script/scrjura.sty b/Master/texmf-dist/tex/latex/koma-script/scrjura.sty
index 1492ea66856..10862f91b46 100644
--- a/Master/texmf-dist/tex/latex/koma-script/scrjura.sty
+++ b/Master/texmf-dist/tex/latex/koma-script/scrjura.sty
@@ -7,7 +7,7 @@
%% scrjura.dtx (with options: `package')
%% scrlogo.dtx (with options: `logo')
%%
-%% Copyright (c) 2007-2012
+%% Copyright (c) 2007-2013
%% Markus Kohm and any individual authors listed elsewhere in this file.
%%
%% This file was generated from file(s) of the KOMA-Script bundle.
@@ -38,10 +38,10 @@
%% LaTeX2.09 Script family created by Frank Neukam 1993 and the LaTeX2e
%% standard classes created by The LaTeX3 Project 1994-1996.
%%
-%%% From File: scrjura.dtx
+%%% From File: $Id: scrjura.dtx 1562 2013-12-19 07:51:16Z mjk $
\NeedsTeXFormat{LaTeX2e}[1995/06/01]
\ProvidesPackage{scrjura}
- [2011/09/30 v0.6 KOMA-Script for jurists
+ [2013/11/04 v0.7 KOMA-Script for jurists
(package)%
]
\@ifpackageloaded{hyperref}{%
@@ -53,45 +53,45 @@
hyperref\MessageBreak
behind the loading of package scrjura.}%
}
-\RequirePackage{scrkbase}
+\RequirePackage{scrkbase}[2013/03/26]
+\RequirePackage{tocbasic}
\DeclareOption{contract}{%
\g@addto@macro\document\contract%
}
\newcounter{juratoclevel}\setcounter{juratoclevel}{\@M}
\KOMA@key{juratotoc}[true]{%
\begingroup
- \newif\if@setjuratoclevel\@setjuratocleveltrue
- \let\juratoclevel@@FamilyUnknownKeyValue\FamilyUnknownKeyValue
- \renewcommand*{\FamilyUnknownKeyValue}[4]{%
- \setcounter{juratoclevel}{#1}%
- \@setjuratoclevelfalse
- }%
\KOMA@set@ifkey{juratoclevel}{@tempswa}{#1}%
- \if@setjuratoclevel
+ \ifx\FamilyKeyState\FamilyKeyStateProcessed
\if@tempswa
\setcounter{juratoclevel}{2}%
\else
\setcounter{juratoclevel}{\@M}%
\fi
+ \else
+ \setcounter{juratoclevel}{#1}%
+ \FamilyKeyStateProcessed
\fi
\endgroup
}
+\providecommand*{\toclevel@cpar}{\arabic{juratoclevel}}
\newcommand*{\cpar@numberwidth}{2em}
\newcommand*{\cpar@indent}{1.5em}
\KOMA@key{juratocnumberwidth}{%
\begingroup\setlength{\@tempdima}{#1}\endgroup
\renewcommand*{\cpar@numberwidth}{#1}%
+ \FamilyKeyStateProcessed
}
\KOMA@key{juratocindent}{%
\begingroup\setlength{\@tempdima}{#1}\endgroup
\renewcommand*{\cpar@indent}{#1}%
+ \FamilyKeyStateProcessed
}
\KOMA@ifkey{juratitlepagebreak}{@juratitlepagebreak}
\newif\ifparnumber
\KOMA@key{parnumber}[true]{%
- \ifstr{#1}{auto}{\AutoPar}{%
- \ifstr{#1}{manual}{\ManualPar}{%
- \def\FamilyElseValue{, `auto', `semi'}%
+ \ifstr{#1}{auto}{\AutoPar\FamilyKeyStateProcessed}{%
+ \ifstr{#1}{manual}{\ManualPar\FamilyKeyStateProcessed}{%
\KOMA@set@ifkey{parnumber}{parnumber}{#1}%
}%
}%
@@ -106,31 +106,35 @@
{right}{3},%
{both}{4}%
}{#1}%
- \ifcase\number\@tempa
- \endgroup
- \let\Paragraphmark\@gobble
- \or
- \endgroup
- \renewcommand*{\Paragraphmark}[1]{%
- \markright{\csname MakeMarkcase\endcsname{##1}}}%
- \or
- \endgroup
- \renewcommand*{\Paragraphmark}[1]{%
- \markboth{\csname MakeMarkcase\endcsname{##1}}%
- {\csname MakeMarkcase\endcsname{##1}}}%
- \or
- \endgroup
- \renewcommand*{\Paragraphmark}[1]{%
- \ifx
- \@mkboth\@gobbletwo
- \else
- \markright{\csname MakeMarkcase\endcsname{##1}}%
- \fi}%
- \or
- \endgroup
- \renewcommand*{\Paragraphmark}[1]{%
- \@mkboth{\csname MakeMarkcase\endcsname{##1}}%
- {\csname MakeMarkcase\endcsname{##1}}}%
+ \ifx\FamilyKeyState\FamilyKeyStateProcessed
+ \ifcase\number\@tempa
+ \endgroup
+ \let\Paragraphmark\@gobble
+ \or
+ \endgroup
+ \renewcommand*{\Paragraphmark}[1]{%
+ \markright{\csname MakeMarkcase\endcsname{##1}}}%
+ \or
+ \endgroup
+ \renewcommand*{\Paragraphmark}[1]{%
+ \markboth{\csname MakeMarkcase\endcsname{##1}}%
+ {\csname MakeMarkcase\endcsname{##1}}}%
+ \or
+ \endgroup
+ \renewcommand*{\Paragraphmark}[1]{%
+ \ifx
+ \@mkboth\@gobbletwo
+ \else
+ \markright{\csname MakeMarkcase\endcsname{##1}}%
+ \fi}%
+ \or
+ \endgroup
+ \renewcommand*{\Paragraphmark}[1]{%
+ \@mkboth{\csname MakeMarkcase\endcsname{##1}}%
+ {\csname MakeMarkcase\endcsname{##1}}}%
+ \else
+ \endgroup
+ \fi
\else
\endgroup
\fi
@@ -156,39 +160,41 @@
{paragraphonly}{44},{onlyparagraph}{44},%
{ParagraphOnly}{44},{OnlyParagraph}{44}%
}{#1}%
- \@tempcnta=\@tempa\relax
- \@tempcntb=\z@
- \@whilenum \@tempcnta>9 \do{%
- \advance\@tempcnta -10\relax
- \advance\@tempcntb \@ne\relax
- }%
- \ifcase \@tempcnta
- \or
- \aftergroup\def\aftergroup\parcite@format
- \aftergroup{\aftergroup0\aftergroup}%
- \or
- \aftergroup\def\aftergroup\parcite@format
- \aftergroup{\aftergroup1\aftergroup}%
- \or
- \aftergroup\def\aftergroup\parcite@format
- \aftergroup{\aftergroup2\aftergroup}%
- \or
- \aftergroup\def\aftergroup\parcite@format
- \aftergroup{\aftergroup-\aftergroup1\aftergroup}%
- \fi
- \ifcase \@tempcntb
- \or
- \aftergroup\def\aftergroup\sentencecite@format
- \aftergroup{\aftergroup0\aftergroup}%
- \or
- \aftergroup\def\aftergroup\sentencecite@format
- \aftergroup{\aftergroup1\aftergroup}%
- \or
- \aftergroup\def\aftergroup\sentencecite@format
- \aftergroup{\aftergroup2\aftergroup}%
- \or
- \aftergroup\def\aftergroup\sentencecite@format
- \aftergroup{\aftergroup-\aftergroup1\aftergroup}%
+ \ifx\FamilyKeyState\FamilyKeyStateProcessed
+ \@tempcnta=\@tempa\relax
+ \@tempcntb=\z@
+ \@whilenum \@tempcnta>9 \do{%
+ \advance\@tempcnta -10\relax
+ \advance\@tempcntb \@ne\relax
+ }%
+ \ifcase \@tempcnta
+ \or
+ \aftergroup\def\aftergroup\parcite@format
+ \aftergroup{\aftergroup0\aftergroup}%
+ \or
+ \aftergroup\def\aftergroup\parcite@format
+ \aftergroup{\aftergroup1\aftergroup}%
+ \or
+ \aftergroup\def\aftergroup\parcite@format
+ \aftergroup{\aftergroup2\aftergroup}%
+ \or
+ \aftergroup\def\aftergroup\parcite@format
+ \aftergroup{\aftergroup-\aftergroup1\aftergroup}%
+ \fi
+ \ifcase \@tempcntb
+ \or
+ \aftergroup\def\aftergroup\sentencecite@format
+ \aftergroup{\aftergroup0\aftergroup}%
+ \or
+ \aftergroup\def\aftergroup\sentencecite@format
+ \aftergroup{\aftergroup1\aftergroup}%
+ \or
+ \aftergroup\def\aftergroup\sentencecite@format
+ \aftergroup{\aftergroup2\aftergroup}%
+ \or
+ \aftergroup\def\aftergroup\sentencecite@format
+ \aftergroup{\aftergroup-\aftergroup1\aftergroup}%
+ \fi
\fi
\endgroup
}
@@ -196,6 +202,22 @@
\KOMA@DeclareDeprecatedOption[scrjura]{sentencecitename}{ref=sentencelong}
\KOMAProcessOptions\relax
\newcommand*{\jura@env@type}{}
+\newcommand*{\ellipsispar}[1][1]{%
+ \begingroup
+ \KOMAoptions{parnumber=manual}\parellipsis\par
+ \addtocounter{par}{#1}%
+ \protected@write\@auxout{}{%
+ \string\newmaxpar{\jura@env@type}%
+ {\thecontractAbsoluteParagraph}%
+ {\thepar}%
+ }%
+ \endgroup
+ \addtocounter{par}{-1}\refstepcounter{par}%
+ \ignorespaces
+}
+\newcommand*{\parellipsis}{%
+ \scr@ifundefinedorrelax{textellipsis}{\dots}{\textellipsis}%
+}
\newcommand*{\contract}{%
\ifx\jura@env@type\@empty
\let\@doendpe\contract@doendpe
@@ -222,12 +244,13 @@
\newcounter{contractParagraph}
\renewcommand*{\thecontractParagraph}{%
{\contract@Paragraphformat{\arabic{contractParagraph}}}}
-\DeclareRobustCommand*{\contract@Paragraphformat}[1]{\paragraphformat{#1}}
-\newcommand*{\paragraphformat}[1]{\S~#1}
+\DeclareRobustCommand*{\contract@Paragraphformat}[1]{\Paragraphformat{#1}}
+\newcommand*{\Paragraphformat}[1]{\S~#1}
\newcounter{contractSubParagraph}
\@addtoreset{SubParagraph}{Paragraph}
\renewcommand*{\thecontractSubParagraph}{%
{\theParagraph\alph{contractSubParagraph}}}
+\newcounter{contractAbsoluteParagraph}
\define@key{contract}{title}{%
\def\contract@title{#1}%
\ifx\contract@entry\relax\def\contract@entry{\contract@title}\fi
@@ -264,6 +287,7 @@
\newcommand*{\theHParagraph}{\theH@AbsParagraph}
\newcommand*{\theHSubParagraph}{\theH@AbsParagraph}
\newcommand*{\contract@paragraph}[1]{%
+ \stepcounter{contractAbsoluteParagraph}%
\ManualPar\parnumbertrue
\let\contract@title\relax
\let\contract@entry\relax
@@ -272,6 +296,7 @@
\contract@dummyfalse
\ifx\relax#1\relax\else\setkeys{contract}{#1}\fi
\ifcontract@dummy\else
+ \par
\@afterindentfalse
\addvspace{\contract@preskip}%
\fi
@@ -284,7 +309,7 @@
\let\@elt\@stpelt
\cl@Paragraph
\endgroup
- \protected@edef\theParagraph{\S~\contract@number}%
+ \protected@edef\theParagraph{\contract@Paragraphformat{\contract@number}}%
\protected@edef\@currentlabel{\theParagraph}%
\fi
\stepcounter{@AbsParagraph}%
@@ -302,15 +327,12 @@
\ifcontract@dummy\else
\begingroup
\if@juratitlepagebreak\else\interlinepenalty\@M\fi
- \contract@paragraph@font \theParagraph
- \ifx\contract@title\relax\else\enskip\contract@title\fi
+ \contract@paragraph@font{\theParagraph
+ \ifx\contract@title\relax\else\enskip\fi}%
+ \contract@title
\ifx\contract@entry\relax\else
- \addcontentsline{toc}{cpar}{%
- \protect\numberline{\theParagraph}\contract@entry
- }%
- \addcontentsline{cpa}{cpar}{%
- \protect\numberline{\theParagraph}\contract@entry
- }%
+ \addxcontentsline{toc}{cpar}[\theParagraph]\contract@entry
+ \addxcontentsline{cpa}{cpar}[\theParagraph]\contract@entry
\fi
\ifx\contract@head\relax\else
\expandafter\Paragraphmark\expandafter{%
@@ -322,6 +344,7 @@
\fi
}
\newcommand*{\contract@subparagraph}[1]{%
+ \stepcounter{contractAbsoluteParagraph}%
\ManualPar\parnumbertrue
\let\contract@title\relax
\let\contract@entry\relax
@@ -330,6 +353,7 @@
\contract@dummyfalse
\ifx\relax#1\relax\else\setkeys{contract}{#1}\fi
\ifcontract@dummy\else
+ \par
\@afterindentfalse
\vskip\contract@preskip
\fi
@@ -359,15 +383,12 @@
\ifcontract@dummy\else
\begingroup
\if@juratitlepagebreak\else\interlinepenalty\@M\fi
- \contract@paragraph@font \theSubParagraph
- \ifx\contract@title\relax\else\enskip\contract@title\fi
+ \contract@paragraph@font{\theSubParagraph
+ \ifx\contract@title\relax\else\enskip\fi}%
+ \contract@title
\ifx\contract@entry\relax\else
- \addcontentsline{toc}{cpar}{%
- \protect\numberline{\theSubParagraph}\contract@entry
- }%
- \addcontentsline{cpa}{cpar}{%
- \protect\numberline{\theSubParagraph}\contract@entry
- }%
+ \addxcontentsline{toc}{cpar}[\theSubParagraph]\contract@entry
+ \addxcontentsline{cpa}{cpar}[\theSubParagraph]\contract@entry
\fi
\ifx\contract@head\relax\else
\expandafter\Paragraphmark\expandafter{%
@@ -441,26 +462,57 @@
\renewcommand*{\thepar}{\arabic{par}}
\newcommand*{\theHpar}{\theH@AbsParagraph-\Roman{par}}
\newcommand*{\parformat}{(\thepar)}
+\newkomafont{parnumber}{}
\renewcommand*\p@par{{\jura@usetype{\jura@env@type}\theSubParagraph\jura@separator{\nobreakspace}}}
\@addtoreset{par}{Paragraph}
\@addtoreset{par}{SubParagraph}
\newcommand*{\contract@everypar}{%
\ifparnumber
- \refstepcounter{par}%
- \refstepcounter{sentence}%
+ \ifx\scrjura@special@par\relax
+ \ifx\scrjura@special@reset@par\relax\else
+ \global\let\thepar\scrjura@special@reset@par
+ \global\let\scrjura@special@reset@par\relax
+ \fi
+ \refstepcounter{par}%
+ \refstepcounter{sentence}%
+ \else
+ \ifx\scrjura@special@reset@par\relax
+ \global\let\scrjura@special@reset@par\thepar
+ \fi
+ \global\let\thepar\scrjura@special@par
+ \global\let\scrjura@special@par\relax
+ \setcounter{sentence}{0}\refstepcounter{sentence}%
+ \fi
\begingroup
\protected@write\@auxout{\let\contract@Paragraphformat\@firstofone}{%
- \string\newmaxpar{contract}{\theSubParagraph}{\arabic{par}}}%
- \getmaxpar\@tempa{contract}{\theSubParagraph}%
+ \string\newmaxpar{contract}%
+ {\thecontractAbsoluteParagraph}%
+ {\thepar}}%
+ \getmaxpar\@tempa{contract}{\thecontractAbsoluteParagraph}%
\typeout{Stored max is \@tempa}%
- \ifnum \@tempa>\@ne
- \parformat\nobreakspace
+ \def\reserved@a##1\@nnil{\def\@tempa{##1}}%
+ \afterassignment\reserved@a\@tempcnta=0\@tempa\relax\@nnil
+ \ifnum \@tempcnta>\@ne
+ {\usekomafont{parnumber}{\parformat\nobreakspace}}%
+ \else
+ \def\reserved@a{\relax}%
+ \ifx\@tempa\reserved@a
+ \else
+ {\usekomafont{parnumber}{\parformat\nobreakspace}}%
+ \fi
\fi
\endgroup
\else
- \setcounter{sentence}{0}\refstepcounter{sentence}%
+ \setcounter{sentence}{-1}\refstepcounter{sentence}%
\fi
}
+\newcommand*{\thisparnumber}[1]{%
+ \def\scrjura@special@par{#1}%
+}
+\newcommand*{\scrjura@special@par}{}
+\let\scrjura@special@par\relax
+\newcommand*{\scrjura@special@reset@par}{}
+\let\scrjura@special@reset@par\relax
\newcommand*{\refL}{\@ifstar {\ref@L*}{\ref@L{}}}
\newcommand*{\ref@L}[2]{%
\begingroup
@@ -519,7 +571,7 @@
}
\newcommand*{\ref@ParagraphN}[2]{%
\begingroup
- \let\paragraphformat\relax
+ \let\Paragraphformat\relax
\ref@Paragraph{#1}{#2}%
\endgroup
}
@@ -683,43 +735,39 @@
\newcommand*{\sentencenumericformat}[1]{\@arabic{\number #1\relax}.}
\newcommand*{\parname}{Paragraph}
\AtBeginDocument{%
- \providecaptionname{german}\parname{Absatz}%
- \providecaptionname{german}\parshortname{Abs.}%
- \providecaptionname{german}\sentencename{Satz}%
- \providecaptionname{german}\sentenceshortname{S.}%
- \providecaptionname{ngerman}\parname{Absatz}%
- \providecaptionname{ngerman}\parshortname{Abs.}%
- \providecaptionname{ngerman}\sentencename{Satz}%
- \providecaptionname{ngerman}\sentenceshortname{S.}%
- \providecaptionname{austrian}\parname{Absatz}%
- \providecaptionname{austrian}\parshortname{Abs.}%
- \providecaptionname{austrian}\sentencename{Satz}%
- \providecaptionname{austrian}\sentenceshortname{S.}%
- \providecaptionname{naustrian}\parname{Absatz}%
- \providecaptionname{naustrian}\parshortname{Abs.}%
- \providecaptionname{naustrian}\sentencename{Satz}%
- \providecaptionname{naustrian}\sentenceshortname{S.}%
+ \providecaptionname{german,ngerman,austrian,naustrian}\parname{Absatz}%
+ \providecaptionname{german,ngerman,austrian,naustrian}\parshortname{Abs.}%
+ \providecaptionname{german,ngerman,austrian,naustrian}\sentencename{Satz}%
+ \providecaptionname{german,ngerman,austrian,naustrian}\sentenceshortname{S.}%
+ \providecaptionname{english,american,british,canadian,USenglish,UKenglish}\parname{paragraph}%
+ \providecaptionname{english,american,british,canadian,USenglish,UKenglish}\parshortname{par.}%
+ \providecaptionname{english,american,british,canadian,USenglish,UKenglish}\sentencename{sentence}%
+ \providecaptionname{english,american,british,canadian,USenglish,UKenglish}\sentenceshortname{sent.}%
}
\providecommand*{\parname}{\scrjura@lang@error{\parname}}
\providecommand*{\parshortname}{\scrjura@lang@error{\parshortname}}
\providecommand*{\sentencename}{\scrjura@lang@error{\sentencename}}
\providecommand*{\sentenceshortname}{\scrjura@lang@error{\sentenceshortname}}
\newcommand*{\scrjura@lang@error}[1]{%
- \PackageErrorNoLine{scrjura}{%
+ \PackageError{scrjura}{%
current language not supported%
}{%
- Currently scrjura only supports languages `german',
- `ngerman', `austrian', and `naustrian'.\MessageBreak
- It seems, that you are using another language (maybe
- \languagename).\MessageBreak
- Because of this you have to define \string#1\space by
- yourself!\MessageBreak
+ Currently scrjura only supports languages `german', `ngerman',
+ `austrian',\MessageBreak
+ `naustrian', `english', `american', `british', `canadian', `USenglish',
+ and\MessageBreak
+ `UKenglish'.\MessageBreak
+ It seems, that you are using another language (maybe `\languagename') or
+ that\MessageBreak
+ your language selection isn't compatible to package `babel'.\MessageBreak
+ Because of this you have to define `\string#1' by yourself!\MessageBreak
It would be nice if you'll send your definitions to the author.%
}%
\textbf{??}%
}
\newcommand*{\newmaxpar}[3]{%
\begingroup
+ \expandafter\let\csname #1@Paragraphformat\endcsname\@firstofone
\protected@edef\@tempa{#2}\@onelevel@sanitize\@tempa
\expandafter\xdef\csname max@#1@\@tempa\endcsname{#3}%
\endgroup
@@ -737,7 +785,7 @@
\fi
\@tempa
}
-%%% From File: scrlogo.dtx
+%%% From File: $Id: scrlogo.dtx 1380 2013-10-01 15:31:55Z mjk $
\@ifundefined{KOMAScript}{%
\DeclareRobustCommand{\KOMAScript}{\textsf{K\kern.05em O\kern.05em%
M\kern.05em A\kern.1em-\kern.1em Script}}}{}