summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex')
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-abnt/abnt-ibid.bbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-abnt/abnt-ibid.cbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-abnt/abnt-numeric.bbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-abnt/abnt-numeric.cbx386
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-abnt/abnt.bbx196
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-abnt/abnt.cbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-abnt/brazil-abnt.lbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-abnt/brazilian-abnt.lbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-abnt/english-abnt.lbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-abnt/portuges-abnt.lbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-abnt/portuguese-abnt.lbx2
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-abnt/spanish-abnt.lbx2
12 files changed, 438 insertions, 164 deletions
diff --git a/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-ibid.bbx b/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-ibid.bbx
index 7ef794856ad..40ce2a56d5b 100644
--- a/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-ibid.bbx
+++ b/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-ibid.bbx
@@ -13,7 +13,7 @@
%% The Current Maintainer of this work is Daniel Ballester Marques.
\ProvidesFile{abnt-ibid.bbx}
-[2017/11/09\space v3.2\space ABNT BibLaTeX citation style]%
+[2018/04/04\space v3.3\space ABNT BibLaTeX citation style]%
\RequireBibliographyStyle{abnt}
diff --git a/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-ibid.cbx b/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-ibid.cbx
index cff248116d2..e940bac5e87 100644
--- a/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-ibid.cbx
+++ b/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-ibid.cbx
@@ -13,7 +13,7 @@
%% The Current Maintainer of this work is Daniel Ballester Marques.
\ProvidesFile{abnt-ibid.cbx}%
-[2017/11/09\space v3.2\space ABNT BibLaTeX citation style]%
+[2018/04/04\space v3.3\space ABNT BibLaTeX citation style]%
% Init >>>1
diff --git a/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-numeric.bbx b/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-numeric.bbx
index e9abff8e976..a05b7ccdb4d 100644
--- a/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-numeric.bbx
+++ b/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-numeric.bbx
@@ -13,7 +13,7 @@
%% The Current Maintainer of this work is Daniel Ballester Marques.
\ProvidesFile{abnt-numeric.bbx}%
-[2017/11/09\space v3.2\space ABNT BibLaTeX citation style]%
+[2018/04/04\space v3.3\space ABNT BibLaTeX citation style]%
\RequireBibliographyStyle{abnt}
\ExecuteBibliographyOptions{labelnumber}
diff --git a/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-numeric.cbx b/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-numeric.cbx
index 4cf86a0cc19..1fb33a3be65 100644
--- a/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-numeric.cbx
+++ b/Master/texmf-dist/tex/latex/biblatex-abnt/abnt-numeric.cbx
@@ -13,89 +13,336 @@
%% The Current Maintainer of this work is Daniel Ballester Marques.
\ProvidesFile{abnt-numeric.cbx}%
-[2017/11/09\space v3.2\space ABNT BibLaTeX citation style]%
+[2018/04/04\space v3.3\space ABNT BibLaTeX citation style]%
-\RequireCitationStyle{numeric}
+% Init >>>1
+
+\RequireCitationStyle{numeric}%
+
+\newtoggle{comp}%
+\DeclareBibliographyOption{comp}[true]{%
+ \settoggle{comp}{#1}%
+}%
+
+% <<<1
+
+% Comp >>>1
+
+\providebool{bbx:subentry}%
+% \newbool{cbx:parens}%
+
+\newcounter{cbx@tempcnta}%
+\newcounter{cbx@tempcntb}%
+
+\DeclareFieldFormat{entrysetcount}{\mknumalph{#1}}%
+
+\newbibmacro*{cite:init}{%
+ \iftoggle{comp}{%
+ \global\boolfalse{cbx:parens}%
+ \global\undef\cbx@lasthash%
+ \global\undef\cbx@lastnumber%
+ \global\undef\cbx@lastprefix%
+ \setcounter{cbx@tempcnta}{0}%
+ \setcounter{cbx@tempcntb}{-2}%
+ }{}%
+}%
+
+\newbibmacro*{cite:comp}{%
+ \iftoggle{comp}{%
+ \addtocounter{cbx@tempcntb}{1}%
+ \iffieldundef{shorthand}%
+ {\ifbool{bbx:subentry}%
+ {\iffieldundef{entrysetcount}%
+ {\usebibmacro{cite:comp:comp}}%
+ {\usebibmacro{cite:comp:inset}}}%
+ {\usebibmacro{cite:comp:comp}}}%
+ {\usebibmacro{cite:comp:shand}}%
+ }{%
+ \usebibmacro{cite}%
+ }%
+}%
+
+\newbibmacro*{cite:comp:comp}{%
+ \ifboolexpr{%
+ ( test {\iffieldundef{labelprefix}} and test {\ifundef\cbx@lastprefix} )%
+ or%
+ test {\iffieldequals{labelprefix}{\cbx@lastprefix}}%
+ }%
+ {\ifnumequal{\thefield{labelnumber}}{\value{cbx@tempcntb}}%
+ {\savefield{entrykey}{\cbx@lastkey}%
+ \savefield{labelnumber}{\cbx@lastnumber}%
+ \addtocounter{cbx@tempcnta}{1}}%
+ {\ifnumequal{\thefield{labelnumber}}{\value{cbx@tempcntb}-1}%
+ {}%
+ {\usebibmacro{cite:dump}%
+ \ifnumgreater{\value{cbx@tempcntb}}{-1}%
+ {\multicitedelim}%
+ {}%
+ \printtext[bibhyperref]{%
+ \printfield{labelprefix}%
+ \printfield{labelnumber}}}}}%
+ {\usebibmacro{cite:comp:end}}%
+ \setcounter{cbx@tempcntb}{\thefield{labelnumber}}%
+ \savefield{labelprefix}{\cbx@lastprefix}}%
+
+\newbibmacro*{cite:comp:end}{%
+ \usebibmacro{cite:dump}%
+ \ifnumgreater{\value{cbx@tempcntb}}{-1}%
+ {\multicitedelim}%
+ {}%
+ \printtext[bibhyperref]{%
+ \printfield{labelprefix}%
+ \printfield{labelnumber}}}%
+
+\newbibmacro*{cite:comp:inset}{%
+ \usebibmacro{cite:dump}%
+ \ifnumgreater{\value{cbx@tempcntb}}{-1}%
+ {\multicitedelim}%
+ {}%
+ \printtext[bibhyperref]{%
+ \printfield{labelprefix}%
+ \printfield{labelnumber}%
+ \printfield{entrysetcount}}%
+ \setcounter{cbx@tempcntb}{-1}}%
+
+\newbibmacro*{cite:comp:shand}{%
+ \usebibmacro{cite:dump}%
+ \ifnumgreater{\value{cbx@tempcntb}}{-1}%
+ {\multicitedelim}%
+ {}%
+ \printtext[bibhyperref]{\printfield{shorthand}}%
+ \setcounter{cbx@tempcntb}{-1}}%
+
+\newbibmacro*{cite:dump}{%
+ \iftoggle{comp}{%
+ \ifnumgreater{\value{cbx@tempcnta}}{0}%
+ {\ifnumgreater{\value{cbx@tempcnta}}{1}%
+ {\bibrangedash}%
+ {\multicitedelim}%
+ \bibhyperref[\cbx@lastkey]{%
+ \ifdef\cbx@lastprefix%
+ {\printtext[labelprefix]{\cbx@lastprefix}}%
+ {}%
+ \printtext[labelnumber]{\cbx@lastnumber}}}%
+ {}%
+ \setcounter{cbx@tempcnta}{0}%
+ \global\undef\cbx@lastprefix%
+ }{}%
+}%
+
+% <<<1
\renewbibmacro*{name:family}[4]{% >>>1
- \ifuseprefix
+ \ifuseprefix%
{\usebibmacro{name:delim}{#3#1}%
\usebibmacro{name:hook}{#3#1}%
\ifdefvoid{#3}{}{%
- \ifcapital
- {\mkbibnameprefix{\MakeCapital{#3}}\isdot}
+ \ifcapital%
+ {\mkbibnameprefix{\MakeCapital{#3}}\isdot}%
{\mkbibnameprefix{#3}\isdot}%
\ifprefchar{}{\bibnamedelimc}}%
- \mkbibnamefamily{#1}\isdot
- \ifdefvoid{#4}{}{\bibnamedelimd\mkbibnamesuffix{#4}\isdot}}
+ \mkbibnamefamily{#1}\isdot%
+ \ifdefvoid{#4}{}{\bibnamedelimd\mkbibnamesuffix{#4}\isdot}}%
{\usebibmacro{name:delim}{#1}%
\usebibmacro{name:hook}{#1}%
- \mkbibnamefamily{#1}\isdot
+ \mkbibnamefamily{#1}\isdot%
\ifdefvoid{#4}{}{\bibnamedelimd\mkbibnamesuffix{#4}\isdot}}}% <<<1
% Cite commands >>>1
\DeclareCiteCommand{\cite}[\mkbibparens]% >>>2
- {\usebibmacro{prenote}}
+ {\usebibmacro{cite:init}%
+ \usebibmacro{prenote}}%
{\usebibmacro{citeindex}%
- \usebibmacro{cite}}
- {\multicitedelim}
- {\usebibmacro{postnote}}% <<<2
+ \usebibmacro{cite:comp}}%
+ {\iftoggle{comp}{}{\multicitedelim}}%
+ {\usebibmacro{cite:dump}%
+ \usebibmacro{postnote}}% <<<2
\DeclareCiteCommand{\parencite}[\mkbibparens]% >>>2
- {\usebibmacro{prenote}}
+ {\usebibmacro{cite:init}%
+ \usebibmacro{prenote}}%
+ {\usebibmacro{citeindex}%
+ \usebibmacro{cite:comp}}%
+ {\iftoggle{comp}{}{\multicitedelim}}%
+ {\usebibmacro{cite:dump}%
+ \usebibmacro{postnote}}% <<<2
+
+\DeclareCiteCommand{\footcite}[\mkbibfootnote]% >>>2
+ {\usebibmacro{cite:init}%
+ \usebibmacro{prenote}}%
{\usebibmacro{citeindex}%
- \usebibmacro{cite}}
- {\multicitedelim}
- {\usebibmacro{postnote}}% <<<2
+ \usebibmacro{cite:comp}}%
+ {\iftoggle{comp}{}{\multicitedelim}}%
+ {\usebibmacro{cite:dump}%
+ \usebibmacro{postnote}}% <<<2
+
+\DeclareCiteCommand{\footcitetext}[\mkbibfootnotetext]% >>>2
+ {\usebibmacro{cite:init}%
+ \usebibmacro{prenote}}%
+ {\usebibmacro{citeindex}%
+ \usebibmacro{cite:comp}}%
+ {\iftoggle{comp}{}{\multicitedelim}}%
+ {\usebibmacro{cite:dump}%
+ \usebibmacro{postnote}}% <<<2
\DeclareCiteCommand{\smartcite}[\iffootnote\mkbibparens\mkbibfootnote]% >>>2
- {\usebibmacro{prenote}}
+ {\usebibmacro{cite:init}%
+ \usebibmacro{prenote}}%
{\usebibmacro{citeindex}%
- \usebibmacro{cite}}
- {\multicitedelim}
- {\usebibmacro{postnote}}% <<<2
-
-\DeclareCiteCommand{\cbx@textcite}% >>>2
- {\usebibmacro{textcite:init}% Mudar \multinamedelim e \finalnamedelim.
- \boolfalse{cbx:parens}%
- \renewcommand*{\finalnamedelim}{\addspace\bibstring{and}\addspace}%
- \renewcommand*{\multinamedelim}{\addcomma\addspace}}%
+ \usebibmacro{cite:comp}}%
+ {\iftoggle{comp}{}{\multicitedelim}}%
+ {\usebibmacro{cite:dump}%
+ \usebibmacro{postnote}}% <<<2
+
+\DeclareCiteCommand{\supercite}[\mkbibsuperscript]% >>>2
+ {\usebibmacro{cite:init}%
+ \let\multicitedelim=\supercitedelim%
+ \iffieldundef{prenote}%
+ {}%
+ {\BibliographyWarning{Ignoring prenote argument}}%
+ \iffieldundef{postnote}%
+ {}%
+ {\BibliographyWarning{Ignoring postnote argument}}}%
{\usebibmacro{citeindex}%
- \usebibmacro{textcite}}
- {}
- {\usebibmacro{textcite:postnote}}% <<<2
+ \usebibmacro{cite:comp}}%
+ {}%
+ {\usebibmacro{cite:dump}}% <<<2
-\DeclareMultiCiteCommand{\cites}[\mkbibparens]{\cite}{\multicitedelim}
+% \textcite >>>2
-\DeclareMultiCiteCommand{\parencites}%
- [\mkbibparens]{\parencite}{\multicitedelim}
+ \renewcommand*{\iffinalcitedelim}{%
+ \ifnumequal{\value{textcitecount}}{\value{textcitetotal}-1}}%
-\DeclareMultiCiteCommand{\smartcites}%
- [\iffootnote\mkbibparens\mkbibfootnote]{\smartcite}{\multicitedelim}
+ \renewbibmacro*{textcite}{% >>>3
+ \iftoggle{comp}{%
+ \iffieldequals{namehash}{\cbx@lasthash}%
+ {\usebibmacro{cite:comp}}%
+ {\usebibmacro{cite:dump}%
+ \ifbool{cbx:parens}%
+ {\printtext{\bibcloseparen}\global\boolfalse{cbx:parens}}%
+ {}%
+ \iffirstcitekey%
+ {}%
+ {\textcitedelim}%
+ \usebibmacro{cite:init}%
+ \printtext[bibhyperref]{%
+ \ifnameundef{labelname}%
+ {\printfield[citetitle]{labeltitle}}%
+ {\printnames{labelname}}%
+ }
+ \setunit*{\printdelim{namelabeldelim}}%
+ \printtext{\bibopenparen}\global\booltrue{cbx:parens}%
+ \ifnumequal{\value{citecount}}{1}%
+ {\usebibmacro{prenote}}%
+ {}%
+ \usebibmacro{cite:comp}%
+ \stepcounter{textcitecount}%
+ \savefield{namehash}{\cbx@lasthash}}%
+ }{%
+ \iffieldequals{namehash}{\cbx@lasthash}%
+ {\setunit{\multicitedelim}}%
+ {\printtext[bibhyperref]{%
+ \ifnameundef{labelname}%
+ {\printfield[citetitle]{labeltitle}}%
+ {\printnames{labelname}
+ }}%
+ \setunit*{\printdelim{namelabeldelim}}%
+ \printtext{\bibopenparen}\global\booltrue{cbx:parens}%
+ \stepcounter{textcitecount}%
+ \savefield{namehash}{\cbx@lasthash}}%
+ \ifnumequal{\value{citecount}}{1}%
+ {\usebibmacro{prenote}}%
+ {}%
+ \usebibmacro{cite}%
+ \setunit{%
+ \ifbool{cbx:parens}%
+ {\bibcloseparen\global\boolfalse{cbx:parens}}%
+ {}%
+ \textcitedelim}%
+ }%
+ }% <<<3
-% <<<1
+ \renewbibmacro*{textcite:init}{% >>>3
+ \ifnumless{\value{multicitecount}}{2}%
+ {\global\boolfalse{cbx:parens}%
+ \global\undef\cbx@lasthash}%
+ {\global\undef\cbx@lasthash}}% <<<3
+
+ \renewbibmacro*{textcite:postnote}{% >>>3
+ \usebibmacro{postnote}%
+ \ifthenelse{\value{multicitecount}=\value{multicitetotal}}%
+ {\setunit{}%
+ \printtext{%
+ \ifbool{cbx:parens}%
+ {\bibcloseparen\global\boolfalse{cbx:parens}}%
+ {}}}%
+ {\setunit{%
+ \ifbool{cbx:parens}%
+ {\bibcloseparen\global\boolfalse{cbx:parens}}%
+ {}%
+ \textcitedelim}}}% <<<3
-\renewbibmacro*{textcite}{%% >>>1
- \iffieldequals{namehash}{\cbx@lasthash}
- {\setunit{\multicitedelim}}
- {\ifnameundef{labelname}
- {\printfield[citetitle]{labeltitle}}
- {\printnames{labelname}}%
- \setunit{%
- \global\booltrue{cbx:parens}%
- \printdelim{namelabeldelim}\bibopenparen}%
- \stepcounter{textcitecount}%
- \savefield{namehash}{\cbx@lasthash}}%
- \ifnumequal{\value{citecount}}{1}
- {\usebibmacro{prenote}}
+ \DeclareCiteCommand{\cbx@textcite}% >>>3
+ {\iftoggle{comp}{\usebibmacro{cite:init}}{\usebibmacro{textcite:init}}}%
+ {\usebibmacro{citeindex}%
+ \usebibmacro{textcite}}%
{}%
- \usebibmacro{cite}%
- \setunit{%
- \ifbool{cbx:parens}
- {\bibcloseparen\global\boolfalse{cbx:parens}}
+ {\iftoggle{comp}{%
+ \usebibmacro{cite:dump}%
+ \usebibmacro{postnote}%
+ \ifbool{cbx:parens}%
+ {\bibcloseparen\global\boolfalse{cbx:parens}}%
+ {}%
+ }{%
+ \usebibmacro{textcite:postnote}%
+ }}% <<<3
+
+ \DeclareCiteCommand{\textcite}[\cbx@textcite@init\cbx@textcite]% >>>3
+ {\gdef\cbx@savedkeys{}%
+ \citetrackerfalse%
+ \pagetrackerfalse%
+ \DeferNextCitekeyHook%
+ \iftoggle{comp}{\usebibmacro{cite:init}}{\usebibmacro{textcite:init}}}%
+ {\ifthenelse{\iffirstcitekey\AND\value{multicitetotal}>0}%
+ {\protected@xappto\cbx@savedcites{()(\thefield{multipostnote})}%
+ \global\clearfield{multipostnote}}%
{}%
- \textcitedelim}}% <<<1
+ \xappto\cbx@savedkeys{\thefield{entrykey},}%
+ \iffieldequals{namehash}{\cbx@lasthash}%
+ {}%
+ {\stepcounter{textcitetotal}%
+ \savefield{namehash}{\cbx@lasthash}}}%
+ {}%
+ {\protected@xappto\cbx@savedcites{%
+ [\thefield{prenote}][\thefield{postnote}]{\cbx@savedkeys}}}% <<<3
+
+ % textcite has nested \DeclareCiteCommand definitions for textcite and we want to use
+ % the normal textcite context
+ \DeclareDelimcontextAlias{cbx@textcite}{textcite}%
+
+ \renewrobustcmd{\cbx@textcite@init}[2]{%
+ \setcounter{textcitetotal}{0}%
+ \setcounter{textcitecount}{0}%
+ \def\cbx@savedcites{#1}#2\cbx@savedcites\empty}%
+
+ \DeclareMultiCiteCommand{\cbx@textcites}{\cbx@textcite}{}%
+ \DeclareMultiCiteCommand{\textcites}[\cbx@textcites@init\cbx@textcites]{\textcite}{}%
+
+ \let\cbx@textcites@init\cbx@textcite@init%
+ \pretocmd{\cbx@textcites@init}{\UseNextMultiCiteHook}{}{}%
+
+% <<<2
+
+\DeclareMultiCiteCommand{\cites}[\mkbibparens]{\cite}{\multicitedelim}%
+
+\DeclareMultiCiteCommand{\parencites}%
+ [\mkbibparens]{\parencite}{\multicitedelim}%
+
+\DeclareMultiCiteCommand{\smartcites}%
+ [\iffootnote\mkbibparens\mkbibfootnote]{\smartcite}{\multicitedelim}%
+
+% <<<1
% bibhyperref >>>1
@@ -104,17 +351,7 @@
\bibhyperref{#1}%
}% <<<2
-\DeclareFieldFormat{textcitehyperref}{%% >>>2
- \DeclareFieldAlias{bibhyperref}{noformat}% Avoid nested links
- \bibhyperref{%
- #1%
- \ifbool{cbx:parens}%
- {\bibcloseparen\global\boolfalse{cbx:parens}}%
- {}}%
-}% <<<2
-
\savebibmacro{cite}%
-\savebibmacro{textcite}%
\renewbibmacro*{cite}{%% >>>2
\printtext[citehyperref]{%
@@ -122,30 +359,9 @@
\usebibmacro{cite}}%
}% <<<2
-\renewbibmacro*{textcite}{%% >>>2
- \ifboolexpr{%
- (%
- not test {\iffieldundef{prenote}}%
- and%
- test {\ifnumequal{\value{citecount}}{1}}%
- )%
- or%
- (%
- not test {\iffieldundef{postnote}}%
- and%
- test {\ifnumequal{\value{citecount}}{\value{citetotal}}}%
- )%
- }%
- {\DeclareFieldAlias{textcitehyperref}{noformat}}%
- {}%
- \printtext[textcitehyperref]{%
- \restorebibmacro{textcite}%
- \usebibmacro{textcite}}%
-}% <<<2
-
% <<<1
-\endinput
+\endinput%
% vim: set foldmarker=\ >>>,\ <<< :
diff --git a/Master/texmf-dist/tex/latex/biblatex-abnt/abnt.bbx b/Master/texmf-dist/tex/latex/biblatex-abnt/abnt.bbx
index 5e91e59ef02..ae5449800c8 100644
--- a/Master/texmf-dist/tex/latex/biblatex-abnt/abnt.bbx
+++ b/Master/texmf-dist/tex/latex/biblatex-abnt/abnt.bbx
@@ -13,7 +13,7 @@
%% The Current Maintainer of this work is Daniel Ballester Marques.
\ProvidesFile{abnt.bbx}%
-[2017/11/09\space v3.2\space ABNT BibLaTeX citation style]%
+[2018/04/04\space v3.3\space ABNT BibLaTeX citation style]%
% Init >>>1
@@ -219,6 +219,14 @@
}%
% <<<2
+% Toggle backref per entry >>>2
+\newtoggle{backref}%
+\settoggle{backref}{true}%
+\DeclareEntryOption[boolean]{backref}[true]{%
+ \settoggle{backref}{#1}%
+}%
+% <<<2
+
% <<<1
@@ -293,6 +301,7 @@
\step[fieldset=sortkey, origfieldval]%
}%
\map[overwrite=false]{%
+ \pertype{thesis}%
\pertype{phdthesis}%
\pertype{mastersthesis}%
\pertype{monography}%
@@ -332,23 +341,21 @@
% <<<1
-% Formatting >>>1
+% Helper commands >>>1
-% Capitalization commands >>>2
-
-\newcommand\FirstWordUpper[1]{\@firstwordupper#1 \@nil}% >>>3
+\newcommand\FirstWordUpper[1]{\@firstwordupper#1 \@nil}% >>>2
\newcommand\@firstwordupper{}%
-\def\@firstwordupper#1 #2\@nil{\MakeUppercase{#1} #2\unskip}% <<<3
+\def\@firstwordupper#1 #2\@nil{\MakeUppercase{#1} #2\unskip}% <<<2
-\newcommand\FirstWordSC[1]{\@firstwordsc#1 \@nil}% >>>3
+\newcommand\FirstWordSC[1]{\@firstwordsc#1 \@nil}% >>>2
\newcommand\@firstwordsc{}%
-\def\@firstwordsc#1 #2\@nil{\textsc{#1} #2\unskip}% <<<3
+\def\@firstwordsc#1 #2\@nil{\textsc{#1} #2\unskip}% <<<2
-\newcommand\FirstWordLCSC[1]{\@firstwordlcsc#1 \@nil}% >>>3
+\newcommand\FirstWordLCSC[1]{\@firstwordlcsc#1 \@nil}% >>>2
\newcommand\@firstwordlcsc{}%
-\def\@firstwordlcsc#1 #2\@nil{\textsc{\MakeLowercase{#1}} #2\unskip}% <<<3
+\def\@firstwordlcsc#1 #2\@nil{\textsc{\MakeLowercase{#1}} #2\unskip}% <<<2
-% Helper macros >>>3
+% Helper macros >>>2
\long\def\addto#1#2{\expandafter\def\expandafter#1\expandafter{#1#2}}%
@@ -372,67 +379,90 @@
}%
\def\traceparamE\end{}%
-% <<<3
+% <<<2
-\def\smartuppercase#1{% >>>3
+\def\smartuppercase#1{% >>>2
\bgroup %
\traceparam{#1}%
\MakeUppercase{\paramL}%
\egroup%
-}% <<<3
+}% <<<2
-\def\smartlowercase#1{% >>>3
+\def\smartlowercase#1{% >>>2
\bgroup %
\traceparam{#1}%
\MakeLowercase{\paramL}%
\egroup%
-}% <<<3
+}% <<<2
-\def\smartlcsc#1{% >>>3
+\def\smartlcsc#1{% >>>2
\bgroup %
\traceparam{#1}%
\textsc{\MakeLowercase{\paramL}}%
\egroup%
-}% <<<3
+}% <<<2
-\def\smartsc#1{% >>>3
+\def\smartsc#1{% >>>2
\bgroup %
\traceparam{#1}%
\textsc{\paramL}%
\egroup%
-}% <<<3
+}% <<<2
-\renewcommand*{\mkbibacro}[1]{% >>>3
+\renewcommand*{\mkbibacro}[1]{% >>>2
\iftoggle{scbib}{%
\textsc{\MakeLowercase{#1}}%
}{\MakeUppercase{#1}}%
-}% <<<3
+}% <<<2
-\newcommand*{\UpperOrSC}[1]{% >>>3
+\newcommand*{\UpperOrSC}[1]{% >>>2
\let\MakeCapital\relax%
\iftoggle{scbib}{%
\textsc{\MakeLowercase{#1}}%
}{%
\MakeUppercase{#1}%
}%
-}% <<<3
+}% <<<2
-\newcommand*{\NormalOrSC}[1]{% >>>3
+\newcommand*{\NormalOrSC}[1]{% >>>2
\iftoggle{scbib}{%
\textsc{\MakeLowercase{#1}}%
}{%
#1%
}%
-}% <<<3
+}% <<<2
-% <<<2
+\newcommand{\iffieldendswith}[4]{% >>>2
+ \IfEndWith{\strfield{#1}}{#2}{#3}{#4}%
+}% <<<2
+
+\newcommand{\iffieldendswithpunct}[3]{% >>>2
+ \ifboolexpr{%
+ test {\iffieldendswith{#1}{.}}%
+ or%
+ test {\iffieldendswith{#1}{!}}%
+ or%
+ test {\iffieldendswith{#1}{?}}%
+ or%
+ test {\iffieldendswith{#1}{-}}%
+ or%
+ test {\iffieldendswith{#1}{:}}%
+ or%
+ test {\iffieldendswith{#1}{/}}%
+ }{#2}{#3}%
+}% <<<2
+
+% <<<1
+
+
+% Formatting >>>1
% \IfGivenIsInitial >>>2
\ExplSyntaxOn%
\ProvideDocumentCommand{\IfGivenIsInitial}{mm}{%
- \regex_match:nVTF {\w\.} \namepartgiven {#1} {#2}%
+ \regex_match:nVTF {\w\w} \namepartgiven {#2} {#1}%
}%
\cs_generate_variant:Nn \regex_match:nnTF { nV }%
@@ -877,9 +907,15 @@
}%
{\printfield[titlecase]{title}}%
{\printfield[normalfont]{title}}}%
- \normalfont{\setunit*{\subtitlepunct}%
- \printfield[normalfont]{subtitle}%
- \setunit{\addperiod\addspace}}}%
+ \normalfont{%
+ \iffieldendswithpunct{title}{%
+ \setunit*{\addspace}%
+ }{%
+ \setunit*{\subtitlepunct}%
+ }
+ \printfield[normalfont]{subtitle}%
+ \setunit{\addperiod\addspace}%
+ }}%
\newunit}}%
\printfield{titleaddon}%
}%% <<<3
@@ -915,7 +951,11 @@
}{%
\printfield[titlecase]{booktitle}%
}%
- \normalfont{\setunit*{\subtitlepunct}}%
+ \iffieldendswithpunct{booktitle}{%
+ \normalfont{\setunit*{\addspace}}%
+ }{%
+ \normalfont{\setunit*{\subtitlepunct}}%
+ }
\printfield[normalfont]{booksubtitle}}%
\newunit}%
\printfield{booktitleaddon}%
@@ -934,7 +974,11 @@
}{%
\printfield[titlecase]{maintitle}%
}%
- \normalfont{\setunit*{\subtitlepunct}}%
+ \iffieldendswithpunct{maintitle}{%
+ \normalfont{\setunit*{\addspace}}%
+ }{%
+ \normalfont{\setunit*{\subtitlepunct}}%
+ }
\printfield[normalfont]{mainsubtitle}}%
\newunit}%
\printfield{maintitleaddon}%
@@ -976,7 +1020,11 @@
{}%
{\printtext[journaltitle]{%
\printfield[titlecase]{journaltitle}%
- \setunit{\subtitlepunct}%
+ \iffieldendswithpunct{journaltitle}{%
+ \setunit{\addspace}%
+ }{%
+ \setunit{\subtitlepunct}%
+ }
\printfield[normalfont]{journalsubtitle}}}%
}%% <<<3
@@ -1001,18 +1049,22 @@
}%% <<<3
\renewbibmacro*{periodical}{%% >>>3
- \iffieldundef{title}%
- {}%
- {\iffieldundef{issue}{%
- \printtext[title]{%
- \unspace\printfield[upperfirst]{title}%
- \normalfont{\setunit*{\subtitlepunct}%
- \printfield[normalfont]{subtitle}}}%
- }%
- {\printtext[title]{%
- \printfield[titlecase]{title}%
- \normalfont{\setunit*{\subtitlepunct}%
- \printfield[normalfont]{subtitle}}}}%
+ \iffieldundef{title}{}{%
+ \printtext[title]{%
+ \iffieldundef{issue}{%
+ \unspace\printfield[upperfirst]{title}%
+ }{%
+ \printfield[titlecase]{title}%
+ }
+ \normalfont{%
+ \iffieldendswithpunct{title}{%
+ \setunit*{\addspace}%
+ }{%
+ \setunit*{\subtitlepunct}%
+ }
+ \printfield[normalfont]{subtitle}%
+ }%
+ }%
}%
}%% <<<3
@@ -1262,7 +1314,11 @@
{}%
{\printtext[issuetitle]{%
\printfield[upperfirst]{issuetitle}%
- \setunit*{\subtitlepunct}%
+ \iffieldendswithpunct{issuetitle}{%
+ \setunit*{\addspace}%
+ }{%
+ \setunit*{\subtitlepunct}%
+ }
\printfield[normalfont]{issuesubtitle}}}%
}%% <<<3
@@ -1393,33 +1449,35 @@
}%% <<<3
\renewbibmacro*{pageref}{% >>>3
- \iftoggle{citecount}{%
- \printunit{\addperiod\addspace}%
- \iflistundef{pageref}{%
- \bibstring{citecountnopage}%
- }{%
- \printtext{%
- \ifnumgreater{\value{pageref}}{1}{%
- \bibstring{citecountpages}\ppspace%
- }{%
- \bibstring{citecountpage}\ppspace%
+ \iftoggle{backref}{%
+ \iftoggle{citecount}{%
+ \printunit{\addperiod\addspace}%
+ \iflistundef{pageref}{%
+ \bibstring{citecountnopage}%
+ }{%
+ \printtext{%
+ \ifnumgreater{\value{pageref}}{1}{%
+ \bibstring{citecountpages}\ppspace%
+ }{%
+ \bibstring{citecountpage}\ppspace%
+ }%
+ \printlist[pageref][-\value{listtotal}]{pageref}%
}%
- \printlist[pageref][-\value{listtotal}]{pageref}%
}%
- }%
- }{%
- \iflistundef{pageref}{}{%
- \printunit{\addperiod\addspace}%
- \printtext{%
- \ifnumgreater{\value{pageref}}{1}{%
- \bibstring{backrefpages}\ppspace%
- }{%
- \bibstring{backrefpage}\ppspace%
+ }{%
+ \iflistundef{pageref}{}{%
+ \printunit{\addperiod\addspace}%
+ \printtext{%
+ \ifnumgreater{\value{pageref}}{1}{%
+ \bibstring{backrefpages}\ppspace%
+ }{%
+ \bibstring{backrefpage}\ppspace%
+ }%
+ \printlist[pageref][-\value{listtotal}]{pageref}%
}%
- \printlist[pageref][-\value{listtotal}]{pageref}%
}%
}%
- }%
+ }{}
}% <<<3
% <<<2
diff --git a/Master/texmf-dist/tex/latex/biblatex-abnt/abnt.cbx b/Master/texmf-dist/tex/latex/biblatex-abnt/abnt.cbx
index 91535ec688a..a7fd5e2bd3a 100644
--- a/Master/texmf-dist/tex/latex/biblatex-abnt/abnt.cbx
+++ b/Master/texmf-dist/tex/latex/biblatex-abnt/abnt.cbx
@@ -13,7 +13,7 @@
%% The Current Maintainer of this work is Daniel Ballester Marques.
\ProvidesFile{abnt.cbx}%
-[2017/11/09\space v3.2\space ABNT BibLaTeX citation style]%
+[2018/04/04\space v3.3\space ABNT BibLaTeX citation style]%
% Init >>>1
diff --git a/Master/texmf-dist/tex/latex/biblatex-abnt/brazil-abnt.lbx b/Master/texmf-dist/tex/latex/biblatex-abnt/brazil-abnt.lbx
index b119c7f6aa7..4966fcaad44 100644
--- a/Master/texmf-dist/tex/latex/biblatex-abnt/brazil-abnt.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-abnt/brazil-abnt.lbx
@@ -13,7 +13,7 @@
%% The Current Maintainer of this work is Daniel Ballester Marques.
\ProvidesFile{brazil-abnt.lbx}
-[2017/11/09\space v3.2\space ABNT BibLaTeX citation style]%
+[2018/04/04\space v3.3\space ABNT BibLaTeX citation style]%
\InheritBibliographyExtras{brazilian-abnt}
\InheritBibliographyStrings{brazilian-abnt}
diff --git a/Master/texmf-dist/tex/latex/biblatex-abnt/brazilian-abnt.lbx b/Master/texmf-dist/tex/latex/biblatex-abnt/brazilian-abnt.lbx
index be2de9ac3d6..8a16994bf8c 100644
--- a/Master/texmf-dist/tex/latex/biblatex-abnt/brazilian-abnt.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-abnt/brazilian-abnt.lbx
@@ -13,7 +13,7 @@
%% The Current Maintainer of this work is Daniel Ballester Marques.
\ProvidesFile{abnt-brazilian.lbx}%
-[2017/11/09\space v3.2\space ABNT BibLaTeX citation style]%
+[2018/04/04\space v3.3\space ABNT BibLaTeX citation style]%
% Init >>>
diff --git a/Master/texmf-dist/tex/latex/biblatex-abnt/english-abnt.lbx b/Master/texmf-dist/tex/latex/biblatex-abnt/english-abnt.lbx
index 52095dcb487..fe86ec7fa24 100644
--- a/Master/texmf-dist/tex/latex/biblatex-abnt/english-abnt.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-abnt/english-abnt.lbx
@@ -15,7 +15,7 @@
%% Tradução para o espanhol de Juan-Ernesto Sepúlveda. Obrigado!
\ProvidesFile{abnt-english.lbx}%
-2017/11/09\space v3.2\space ABNT BibLaTeX citation style]%
+[2018/04/04\space v3.3\space ABNT BibLaTeX citation style]%
% Init >>>
diff --git a/Master/texmf-dist/tex/latex/biblatex-abnt/portuges-abnt.lbx b/Master/texmf-dist/tex/latex/biblatex-abnt/portuges-abnt.lbx
index 0ed37774b08..3ffaafd4527 100644
--- a/Master/texmf-dist/tex/latex/biblatex-abnt/portuges-abnt.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-abnt/portuges-abnt.lbx
@@ -13,7 +13,7 @@
%% The Current Maintainer of this work is Daniel Ballester Marques.
\ProvidesFile{portuges-abnt.lbx}
-[2017/11/09\space v3.2\space ABNT BibLaTeX citation style]%
+[2018/04/04\space v3.3\space ABNT BibLaTeX citation style]%
\InheritBibliographyExtras{brazilian-abnt}
\InheritBibliographyStrings{brazilian-abnt}
diff --git a/Master/texmf-dist/tex/latex/biblatex-abnt/portuguese-abnt.lbx b/Master/texmf-dist/tex/latex/biblatex-abnt/portuguese-abnt.lbx
index 2d0b5aa8393..6c959948ce2 100644
--- a/Master/texmf-dist/tex/latex/biblatex-abnt/portuguese-abnt.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-abnt/portuguese-abnt.lbx
@@ -13,7 +13,7 @@
%% The Current Maintainer of this work is Daniel Ballester Marques.
\ProvidesFile{portuguese-abnt.lbx}
-[2017/11/09\space v3.2\space ABNT BibLaTeX citation style]%
+[2018/04/04\space v3.3\space ABNT BibLaTeX citation style]%
\InheritBibliographyExtras{brazilian-abnt}
\InheritBibliographyStrings{brazilian-abnt}
diff --git a/Master/texmf-dist/tex/latex/biblatex-abnt/spanish-abnt.lbx b/Master/texmf-dist/tex/latex/biblatex-abnt/spanish-abnt.lbx
index eb51559d359..f149e21ffa0 100644
--- a/Master/texmf-dist/tex/latex/biblatex-abnt/spanish-abnt.lbx
+++ b/Master/texmf-dist/tex/latex/biblatex-abnt/spanish-abnt.lbx
@@ -15,7 +15,7 @@
%% Tradução para o espanhol de Juan-Ernesto Sepúlveda. Obrigado!
\ProvidesFile{abnt-spanish.lbx}%
-[2017/11/09\space v3.2\space ABNT BibLaTeX citation style]%
+[2018/04/04\space v3.3\space ABNT BibLaTeX citation style]%
% Init >>>