summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/biblatex-opcit-booktitle
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2016-09-14 22:25:04 +0000
committerKarl Berry <karl@freefriends.org>2016-09-14 22:25:04 +0000
commitca6d1ceb71368bca13dc008c6693b695be209e62 (patch)
tree62dfa16f925da6ee5826f099a15d2e6fdd6dfc7b /Master/texmf-dist/tex/latex/biblatex-opcit-booktitle
parent29202d8bd8aea1ad316566d9c8012ffee2eedb85 (diff)
biblatex-opcit-booktitle
git-svn-id: svn://tug.org/texlive/trunk@42071 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/biblatex-opcit-booktitle')
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-opcit-booktitle/biblatex-opcit-booktitle.sty36
1 files changed, 24 insertions, 12 deletions
diff --git a/Master/texmf-dist/tex/latex/biblatex-opcit-booktitle/biblatex-opcit-booktitle.sty b/Master/texmf-dist/tex/latex/biblatex-opcit-booktitle/biblatex-opcit-booktitle.sty
index 02a6d52a006..8f8994b1d61 100644
--- a/Master/texmf-dist/tex/latex/biblatex-opcit-booktitle/biblatex-opcit-booktitle.sty
+++ b/Master/texmf-dist/tex/latex/biblatex-opcit-booktitle/biblatex-opcit-booktitle.sty
@@ -15,9 +15,16 @@
%
% The Current Maintainer of this work is Maïeul Rouquette
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{biblatex-opcit-booktitle}[2016/06/12 v1.5.0a Manage op. cit. when using subentry]
+\ProvidesPackage{biblatex-opcit-booktitle}[2016/09/08 v1.6.0 Manage op. cit. when using subentry]
\RequirePackage{xpatch}
+% Declaration of the entry concerned. Some package could have already add their own entry
+\listadd\opcit@booktitle@entrytypes{inbook}
+\listadd\opcit@booktitle@entrytypes{incollection}
+\listadd\opcit@booktitle@entrytypes{inproceedings}
+\listadd\opcit@booktitle@entrytypes{bookinbook}
+
+
\DeclareFieldFormat{bibhypertarget:crossref}{%
\bibhypertarget{\iffootnote{f}{t}:\cbx@resetcount:\thefield{crossref}}{#1}}
@@ -67,10 +74,7 @@
\newbibmacro*{cite:test:ifrelated}%
{\ifboolexpr {%
test {\iffieldundef{crossref}}%
- or not (test {\ifentrytype{inbook}}%
- or test {\ifentrytype{incollection}}%
- or test {\ifentrytype{inproceedings}}%
- or test {\ifentrytype{bookinbook}})}%
+ or not (test {\xifinlist{\thefield{entrytype}}{\opcit@booktitle@entrytypes}})}%
{\usebibmacro{cite:full}%
\usebibmacro{cite:save}}%
{\ifrelatedunseen%
@@ -83,10 +87,7 @@
\newbibmacro*{cite:test:ifrelated:verbose-trad3}%
{\ifboolexpr {%
test {\iffieldundef{crossref}}%
- or not (test {\ifentrytype{inbook}}%
- or test {\ifentrytype{incollection}}%
- or test {\ifentrytype{inproceedings}}%
- or test {\ifentrytype{bookinbook}})}%
+ or not (test {\xifinlist{\thefield{entrytype}}{\opcit@booktitle@entrytypes}})}%
{\usebibmacro{cite:full}%
}%
{\ifrelatedunseen%
@@ -132,7 +133,8 @@
\newunit\newblock
\usebibmacro{in:}%
\printtext[bibhyperlink:crossref]{%
- \usebibmacro{maintitle+booktitle}%
+ \usebibmacro{inbook:rel:bookauthor}%
+ \usebibmacro{maintitle+booktitle}%
\newunit\newblock
\usebibmacro{byeditor+others}%
\newunit%
@@ -172,7 +174,8 @@
\newunit\newblock
\usebibmacro{in:}%
\printtext[bibhyperlink:crossref]{%
- \usebibmacro{maintitle+booktitle}%
+ \usebibmacro{inbook:rel:bookauthor}%
+ \usebibmacro{maintitle+booktitle}%
\newunit\newblock
\usebibmacro{byeditor+others}%
\newunit%
@@ -209,7 +212,8 @@
\newunit\newblock
\usebibmacro{in:}%
\printtext[bibhyperlink:crossref]{%
- \usebibmacro{maintitle+booktitle}%
+ \usebibmacro{inbook:rel:bookauthor}%
+ \usebibmacro{maintitle+booktitle}%
\newunit\newblock
\usebibmacro{byeditor+others}%
\newunit%
@@ -230,4 +234,12 @@
{}%
\usebibmacro{finentry}}
+\newbibmacro{inbook:rel:bookauthor}{%
+ \ifnameundef{bookauthor}%
+ {}
+ {%
+ \usebibmacro{bybookauthor}%
+ \setunit{\labelnamepunct}\newblock%
+ }%
+}
\endinput