summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/biblatex-philosophy/philosophy-modern.bbx
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2010-03-08 01:18:08 +0000
committerKarl Berry <karl@freefriends.org>2010-03-08 01:18:08 +0000
commit1f34a27c6763a52638a6442f777ec934f2253a29 (patch)
tree3595b0dd19920bc51786ef882029c77955a06be7 /Master/texmf-dist/tex/latex/biblatex-philosophy/philosophy-modern.bbx
parentf8781b660c74ce51709b40d75de1d58597a54eaa (diff)
new biblatex-philosophy 0.5 (7mar10)
git-svn-id: svn://tug.org/texlive/trunk@17376 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex/biblatex-philosophy/philosophy-modern.bbx')
-rw-r--r--Master/texmf-dist/tex/latex/biblatex-philosophy/philosophy-modern.bbx296
1 files changed, 296 insertions, 0 deletions
diff --git a/Master/texmf-dist/tex/latex/biblatex-philosophy/philosophy-modern.bbx b/Master/texmf-dist/tex/latex/biblatex-philosophy/philosophy-modern.bbx
new file mode 100644
index 00000000000..8f686073d13
--- /dev/null
+++ b/Master/texmf-dist/tex/latex/biblatex-philosophy/philosophy-modern.bbx
@@ -0,0 +1,296 @@
+ % $Id: philosophy-modern.bbx,v 0.4c 2010/02/27 Valbusa$
+% Copyright 2009-2010 Ivan Valbusa. This package is author-maintained.
+% Permission is granted to copy, distribute and/or modify this software under the
+% terms of the LaTeX Project Public License, version 1.3c
+% http://www.ctan.org/tex-archive/macros/latex/base/lppl.txt.
+
+
+\ProvidesFile{philosophy-modern.bbx}[philosophy-modern.bbx,v 0.4c 2010/02/27 valbusa beta$]
+
+\RequireBibliographyStyle{philosophy-classic}
+
+\newbool{bbx:yearleft}
+\DeclareBibliographyOption{yearleft}[true]{%
+ \csuse{bool#1}{bbx:yearleft}}
+
+\ExecuteBibliographyOptions{%
+yearleft=false%
+}
+
+%%---------------------------------------------------------------------------------------------
+%% new lengths
+%%---------------------------------------------------------------------------------------------
+
+
+\newlength{\yeartitle}
+\newlength{\postnamesep}
+\setlength{\yeartitle}{0.8em}%
+\setlength{\postnamesep}{0.5ex plus 2pt minus 1pt}
+\setlength{\bibitemsep}{\postnamesep}
+\setlength{\bibnamesep}{1.5ex plus 2pt minus 1pt}
+\setlength{\bibhang}{4\parindent}
+
+
+%%---------------------------------------------------------------------------------------------
+%% new commands
+%%---------------------------------------------------------------------------------------------
+
+\newcommand{\postsep}{\par\vspace*{\postnamesep}\hspace*{-\bibhang}\ignorespaces}
+
+%\renewcommand{\labelnamepunct}{%
+% \ifthenelse{\ifnameundef{author}}
+% {{\addspace}}{\unspace}}
+%\renewcommand{\entrysetpunct}{}
+\renewcommand{\labelnamepunct}{\unspace}
+
+%%---------------------------------------------------------------------------------------------
+% List of shorthands
+%%---------------------------------------------------------------------------------------------
+
+\AtBeginBibliography{
+ \ifbool{bbx:yearleft}{%
+ \setlength{\yeartitle}{\fill}}
+ {}%
+ }
+
+\AtBeginShorthands{%
+ \renewcommand{\postsep}{}
+ \renewcommand{\labelnamepunct}{\addcomma\space}
+\renewbibmacro*{commaloc}{%
+ \iflistundef{publisher}{}
+ {\printlist{publisher}}
+ \setunit*{\addcomma\space}%
+ \printlist{location}%
+ \setunit*{\space}%
+ \printtext{\printdateextra}%
+ \newunit}
+\renewbibmacro*{colonloc}{%
+ \printlist{location}%
+ \iflistundef{publisher}
+ {\setunit*{\addspace}}
+ {\setunit*{\addcolon\space}}%
+ \printlist{publisher}%
+ \setunit*{\addcomma\space}%
+ \printtext{\printdateextra}%
+ \newunit}
+\renewbibmacro*{date+extrayear}{}
+\renewbibmacro*{origfields}{%
+ \iflistundef{origlocation}%
+ {}
+ {\setunit{\addsemicolon\space}
+ \iffieldundef{reprinttitle}%
+ {\printtext{\bibstring{reprintas}}}
+ {\printtext{\bibstring{reprint}}\nopunct}
+ \setunit{\addspace}
+ \iffieldundef{reprinttitle}%
+ {\usebibmacro{origtitle}}
+ {\usebibmacro{reprinttitle}}
+ \newunit\newblock
+ \usebibmacro{origpublisher+origlocation+origdate}}
+}
+
+\renewbibmacro*{title}{%
+ \ifthenelse{\iffieldundef{title}\AND\iffieldundef{subtitle}}
+ {}%
+ {\printtext[title]{%
+ \printfield[titlecase]{title}%
+ \setunit{\subtitlepunct}%
+ \printfield[titlecase]{subtitle}}%
+ \newunit}%
+ \printfield{titleaddon}}
+}
+
+
+%%---------------------------------------------------------------------------------------------
+% Macro
+%%---------------------------------------------------------------------------------------------
+
+\renewbibmacro*{date+extrayear}{%
+ \iffieldundef{year}%
+ {}%
+ {\makebox[\bibhang][r]{%
+ \printtext{\printdateextra%
+ \hskip\yeartitle}}}}
+
+\renewbibmacro*{title}{%
+ \ifthenelse{\iffieldundef{title}\AND\iffieldundef{subtitle}}
+ {}%
+ {\iflistundef{origlocation}
+ {\iffieldundef{origdate}
+ {}
+ {\printtext[parens]{\bibstring{reprintof}\addspace\printorigdate}}
+ \printtext[title]{%
+ \printfield[titlecase]{title}%
+ \setunit{\subtitlepunct}%
+ \printfield[titlecase]{subtitle}}}
+ {\printtext[title]{%
+ \printfield[titlecase]{title}%
+ \setunit{\subtitlepunct}%
+ \printfield[titlecase]{subtitle}}
+ }%
+ \newunit}%
+\printfield{titleaddon}}
+
+\renewbibmacro*{maintitle}{%
+ \ifthenelse{\iffieldundef{maintitle}\AND\iffieldundef{mainsubtitle}}
+ {}
+ {%\iffieldundef{origlocation}{\printtext{ed. or. \printfield{year}}}{}
+ \printtext[maintitle]{%
+ \printfield[titlecase]{maintitle}%
+ \setunit{\subtitlepunct}%
+ \printfield[titlecase]{mainsubtitle}}%
+ \newunit}%
+ \printfield{maintitleaddon}}
+
+
+% label for entries without 'editor' and 'author'
+%%-------------------------------------------------------------
+\renewbibmacro*{labeltitle}{%%---------\renewbibmacro{editorstrg}{}??????
+ \iffieldundef{label}%
+ {\iffieldundef{shorttitle}
+ {\printfield{title}%
+ \clearfield{title}}
+ {\printfield[title]{shorttitle}}}
+ {\printtext{\printfield{label}}%
+ \postsep}}
+
+% macro 'author'
+%%----------------------------------------------------
+\renewbibmacro*{author}{%
+ \ifthenelse{\ifuseauthor\AND\NOT\ifnameundef{author}}
+ {\ifthenelse{\iffieldequals{fullhash}{\bbx@lasthash}\AND
+ \NOT\iffirstonpage}
+ {}%
+ {\savefield{fullhash}{\bbx@lasthash}%
+ \printnames{author}%
+ \postsep
+ \iffieldundef{authortype}
+ {}%
+ {\setunit{\addcomma\space}}}%
+ \iffieldundef{authortype}
+ {}%
+ {\usebibmacro{authorstrg}%
+ \setunit{\addspace}}}%
+ {\global\undef\bbx@lasthash
+ \usebibmacro{labeltitle}}%
+ \usebibmacro{date+extrayear}}
+
+% macro 'editor'
+%%----------------------------------------------------
+
+\renewbibmacro*{bbx:editor}[1]{%
+ \ifthenelse{\ifuseeditor\AND\NOT\ifnameundef{editor}}
+ {\ifthenelse{\iffieldequals{fullhash}{\bbx@lasthash}\AND
+ \NOT\iffirstonpage}
+ {}%
+ {\printnames{editor}%
+ \postsep\savefield{fullhash}{\bbx@lasthash}}%
+ \clearname{editor}}%
+ {\global\undef\bbx@lasthash
+ \usebibmacro{labeltitle}%
+ }%
+ \usebibmacro{date+extrayear}%
+ \setunit*{\unspace}
+ \iffieldundef{label}
+ {\usebibmacro{#1}}{}%
+ }
+
+
+%%---------------------------------------------------------------------------------------------
+% Crossref
+%%---------------------------------------------------------------------------------------------
+
+\renewbibmacro*{crossdate+extrayear}{%
+ \iffieldundef{year}%
+ {}%
+ {\unspace\printtext[parens]{\printdateextra}}}
+
+\DeclareCiteCommand{\bbx@inbookcrossref}
+ {}%
+ {\ifsingletitle%
+ {\printtext[bibhyperref]{\ifthenelse{\value{listtotal}=2}
+ {\printnames[][-\value{maxnamesincross}]{labelname}}
+ {\printnames[][-\value{minnamesincross}]{labelname}}}}%
+ {\ifthenelse{\value{listtotal}=2}
+ {\printnames[][-\value{maxnamesincross}]{labelname}}
+ {\printnames[][-\value{minnamesincross}]{labelname}}
+ \setunit{\addspace}
+ \printtext[bibhyperref]{\usebibmacro{crossdate+extrayear}}}}%
+ {\unspace}%
+ {\unspace}
+
+\DeclareCiteCommand{\bbx@crossref}
+ {}%
+ {\ifsingletitle%
+ {\printtext[bibhyperref]{\ifthenelse{\value{listtotal}=2}
+ {\printnames[][-\value{maxnamesincross}]{labelname}}
+ {\printnames[][-\value{minnamesincross}]{labelname}}}}%
+ {\ifthenelse{\value{listtotal}=2}
+ {\printnames[][-\value{maxnamesincross}]{labelname}}
+ {\printnames[][-\value{minnamesincross}]{labelname}}
+ \setunit{\addspace}
+ \printtext[bibhyperref]{\usebibmacro{crossdate+extrayear}}}}%
+ {\unspace}%
+ {\unspace}
+
+%%---------------------------------------------------------------------------------------------
+% BIBLIOGRAPHY DRIVERS
+%%---------------------------------------------------------------------------------------------
+
+\DeclareBibliographyDriver{collection}{%
+ \usebibmacro{bibindex}%
+ \usebibmacro{begentry}%
+ \usebibmacro{editor+others}%
+ \ifuseeditor{\setunit{\addspace}}%
+ {\unspace}\newblock
+ \usebibmacro{maintitle+title}%
+ \newunit
+ \printlist{language}%
+ \newunit\newblock
+ \usebibmacro{byeditor+others}%
+ \newunit\newblock
+ \printfield{edition}%
+ \newunit%
+ \iffieldundef{maintitle}
+ {\printfield{volume}%
+ \printfield{part}}
+ {}%
+ \newunit
+ \printfield{volumes}%
+ \newunit\newblock
+ \usebibmacro{series+number}%
+ \newunit\newblock
+ \printfield{note}%
+ \newunit\newblock
+ \usebibmacro{publisher+location+date}%
+ \newunit\newblock
+ \usebibmacro{chapter+pages}%
+ \newunit
+ \printfield{pagetotal}%
+ \newunit\newblock
+ \printfield{isbn}%
+ \newunit\newblock
+ \printfield{doi}%
+ \newunit\newblock
+ \usebibmacro{eprint}%
+ \newunit\newblock
+ \usebibmacro{url+urldate}%
+ \newunit\newblock
+ \printfield{addendum}%
+ \usebibmacro{origfields}%
+ \newunit\newblock
+ \usebibmacro{annotation}%
+ \newunit\newblock
+ \usebibmacro{pageref}%
+ \newunit\newblock
+ \usebibmacro{finentry}}
+
+
+
+\DeclareBibliographyDriver{set}{%
+ \entryset{}{\addperiod\postsep}%
+\nopunct\vskip-2\baselineskip
+\finentry}
+
+
+\endinput \ No newline at end of file