1

I would like to make some amendments to my entries.

I would like to create a special rule for newspapers as special journal entries (I thought it might be helpful if I label the entry as "newspaper". Only if it's a newspaper article and there is no author, I would want the "journal" title to replace the author position (at the front) BUT instead of small caps, it should be italic.

Image of current output Image of what it should more or less look like :)

Here is my MWE:

\documentclass{scrreprt}
\usepackage[main=ngerman, english]{babel}
\usepackage[babel, german=quotes]{csquotes}
\usepackage[ngerman]{isodate}
\usepackage[ngerman]{datetime}
%----------------------------------------------------------------------------
%   BIB
%----------------------------------------------------------------------------
 \usepackage[
    backend=biber,
    style=authoryear,
    sorting=nyvt, 
    maxnames=25,
    dashed=false, 
    isbn=false
  ]{biblatex}
 \addbibresource{library.bib}
\renewcommand{\mkbibnamefamily}[1]{\textsc{#1}}
\renewcommand{\labelnamepunct}{\addcolon\space}
\DeclareFieldFormat{postnote}{#1}
\DeclareFieldFormat{multipostnote}{#1}
\renewcommand\postnotedelim{\addcolon\addspace}
\DeclareFieldFormat
  [article,inbook,incollection,inproceedings,patent,unpublished]
  {title}{#1\isdot}
\DeclareFieldFormat
  [thesis]
  {title}{\mkbibemph{#1}\isdot}  % thesis title italic


% no period after addon titles
\usepackage{xpatch}
\DeclareFieldFormat{titleaddon}{\mkbibbrackets{#1}}
\DeclareDelimFormat{titleaddondelim}{\addspace}
\xpatchbibmacro{title}
  {\printfield{titleaddon}}
  {\setunit{\printdelim{titleaddondelim}}%
   \printfield{titleaddon}}
  {}
  {}
\DeclareFieldFormat{booktitleaddon}{\mkbibbrackets{#1}}
\DeclareDelimFormat{booktitleaddondelim}{\addspace}    
\xpatchbibmacro{booktitle}
  {\printfield{booktitleaddon}}
  {\setunit{\printdelim{titleaddondelim}}%
   \printfield{booktitleaddon}}
  {}
  {}
\DeclareFieldFormat{maintitleaddon}{\mkbibbrackets{#1}}
\DeclareDelimFormat{maintitleaddondelim}{\addspace}  
\xpatchbibmacro{maintitle}
  {\printfield{maintitleaddon}}
  {\setunit{\printdelim{titleaddondelim}}%
   \printfield{maintitleaddon}}
  {}
  {}

\begin{document}
\nocite{*}
\printbibliography[heading=bibintoc,title={Literaturverzeichnis}]
\end{document}

Plus the test entries:

@article{yomiuri.1981,
 journal = {Yomiuri Shimbun},
 type = {newspaper},
 year = {22.01.1981},
 pages = {20},
 location = {Kanagawa},
 note = {Morgenausgabe},
 title = {Atarashī taishū bunka sanmi ittai no dendō. Kawasaki ni manga shashin eizō bunka sentā},
 titleaddon = {Neuer Palast der Dreifaltigkeit der Populärkultur. Das Zentrum für Manga, Fotografie und visuelle Kultur in Kawasaki}
} 

@article{testauthor.1981,
 journal = {Yomiuri Shimbun},
 author = {Test, Author},
 type = {newspaper},
 year = {22.01.1981},
 pages = {20},
 location = {Kanagawa},
 note = {Morgenausgabe},
 title = {Atarashī taishū bunka sanmi ittai no dendō. Kawasaki ni manga shashin eizō bunka sentā},
 titleaddon = {Neuer Palast der Dreifaltigkeit der Populärkultur. Das Zentrum für Manga, Fotografie und visuelle Kultur in Kawasaki}
} 

Sorry for the inconveniences. Unfortunately I do not know how to solve this on my own

9
  • @moewe makes sense, thank you! :)
    – user168390
    Mar 20, 2019 at 8:20
  • Off-topic: year = {22.01.1981}, is wrong. year should only contain the year. Use date = {1981-01-22}, instead.
    – moewe
    Mar 20, 2019 at 8:28
  • I've noticed that too, but this way I would also have to change the formatting for date, as it does not give me a colon after (dd-mm-yyyy) :/ i.imgur.com/zS0hTCT.png
    – user168390
    Mar 20, 2019 at 8:30
  • 1
    Mhh, I get "Test, Author (22. Jan. 1981): Atarashi ..." with colon. The entry without author is different and does not have a colon even if you say year = {22.01.1981}..
    – moewe
    Mar 20, 2019 at 8:33
  • 1
    Let us continue this discussion in chat.
    – user168390
    Mar 20, 2019 at 8:58

1 Answer 1

2

This is quite a tricky requirement since one would want the journal to essentially take over all the jobs of the author in this situation. The idea is to have Biber copy the journal field into the author field with a source map.

There are also a few details different between a newspaper article with author and one without, so we need a way to indicate those special entries. This is automatically done with the entry option journalauthor.

Then we need to copy the original definitions and add tests for the 'journalauthor case'.

As discussed in the chat I based the suggestion on biblatex-ext. I also modified the field names a bit. I used entrysubtype = {newspaper}, instead of type. The field for "Morgenausgabe" is issue instead of note now.

\documentclass{article}
\usepackage[T1]{fontenc}
\usepackage[main=ngerman, english]{babel}
\usepackage[babel, german=quotes]{csquotes}
\usepackage[ngerman]{isodate}
\usepackage[ngerman]{datetime}

\usepackage[
  backend=biber,
  style=ext-authoryear,
  sorting=nyvt,
  maxnames=25,
  dashed=false,
  isbn=false,
  innamebeforetitle=true,
  usetranslator=true,
  alldates=terse,
  labeldate=year,
]{biblatex}

\usepackage{hyperref}

\DefineBibliographyStrings{german}{%
  andothers = {et al\adddot},
  editor    = {Hg\adddot},
  editors   = {Hg\adddot},
  urlseen = {letzter Abruf},
}

\DeclareSourcemap{
  \maps[datatype=bibtex]{
    \map[overwrite=false]{
      \pertype{article}
      \step[fieldsource=entrysubtype, match=\regexp{\Anewspaper\Z}, final]
      \step[fieldsource=journal, final]
      \step[fieldset=author, origfieldval, final]
      \step[fieldsource=author, match=\regexp{\A(.*)\Z}, replace=\regexp{\{$1\}}]
      \step[fieldset=author+an, fieldvalue={1=journalauthor}]
      \step[fieldset=options, fieldvalue={journalauthor}]
    }
  }
}

\newtoggle{bbx@journalauthor}
\DeclareEntryOption[boolean]{journalauthor}[true]{%
\settoggle{bbx@journalauthor}{#1}}

\renewcommand{\mkbibnamefamily}[1]{%
  \ifitemannotation{journalauthor}
    {\mkbibemph{#1}}
    {\textsc{#1}}}

\DeclareDelimFormat[bib]{nametitledelim}{\addcolon\space}

\DeclareDelimFormat{editortypedelim}{\addspace}
\DeclareFieldFormat{editortype}{\mkbibparens{#1}}
\DeclareDelimAlias{translatortypedelim}{editortypedelim}
\DeclareFieldAlias{translatortype}{editortype}

\DeclareFieldFormat
  [article,inbook,incollection,inproceedings,patent,unpublished,online]
  {title}{#1\isdot}
\DeclareFieldFormat
  [thesis]
  {title}{\mkbibemph{#1}\isdot} % thesis title italic


% no period after addon titles
\renewcommand*{\titleaddonpunct}{\addspace}
\DeclareFieldFormat{titleaddon}{\mkbibbrackets{#1}}
\DeclareFieldAlias{booktitleaddon}{titleaddon}
\DeclareFieldAlias{maintitleaddon}{titleaddon}


\newbibmacro{online:editor+maintitle}{%
  \printnames{editor}%
  \setunit*{\addcolon\space}%
  \usebibmacro{maintitle}}

\usepackage{xpatch}
\xpatchbibdriver{online}
  {\usebibmacro{byeditor+others}}
  {\usebibmacro{online:editor+maintitle}}
  {}{}
\xpatchbibmacro{editorstrg}{\bibstring}{\bibcpstring}{}{}
\xpatchbibmacro{editorstrg}{\bibstring}{\bibcpstring}{}{}

\renewbibmacro*{in:}{%
  \iftoggle{bbx@journalauthor}
    {}
    {\printtext{%
     \bibstring{in}\intitlepunct}}}

\DeclareNameAlias{ineditor}{sortname}

\renewcommand*{\volnumdelim}{\addcomma\space}

\DeclareListWrapperFormat[article]{parenlocation}{\mkbibparens{#1}}
\DeclareListAlias{parenlocation}{location}
\renewbibmacro*{journal}{%
  \ifboolexpr{
    (test {\iffieldundef{journaltitle}}
     and
     test {\iffieldundef{journalsubtitle}})
    or
    togl {bbx@journalauthor}
  }
    {\ifboolexpr{
       togl {bbx@journalauthor}
       and
       test {\iffieldequalstr{entrysubtype}{newspaper}}
     }
       {\printlist{location}}
       {}}
    {\printtext[journaltitle]{%
       \printfield[titlecase]{journaltitle}%
       \setunit{\subtitlepunct}%
       \printfield[titlecase]{journalsubtitle}}%
     \iffieldequalstr{entrysubtype}{newspaper}
       {\setunit{\addspace}%
        \printlist[parenlocation]{location}}
       {}}}

\renewbibmacro*{issue+date}{%
  \usebibmacro{bbx:ifmergeddate}
    {}
    {\printtext[issuedate]{%
       \printdate}}%
  \setunit{\addcomma\space}%
  \printfield{issue}%
  \setunit{\addcomma\space}}

\renewbibmacro*{journal+issuetitle}{%
  \usebibmacro{journal}%
  \setunit*{\jourvoldelim}%
  \iffieldundef{series}
    {}
    {\setunit*{\jourserdelim}%
     \printfield{series}%
     \setunit{\servoldelim}}%
  \usebibmacro{volume+number+eid}%
  \setunit{\volnumdatedelim}%
  \iftoggle{bbx@journalauthor}
    {}
    {}
  \usebibmacro{issue+date}%
  \setunit{\addcolon\space}%
  \usebibmacro{issue}%
  \newunit}


\urlstyle{same}% boo
\DeclareFieldFormat{url}{\url{#1}}
\DeclareFieldFormat{urldate}{\mkbibparens{\bibstring{urlseen}\addcolon\space#1}}

\makeatletter
\renewbibmacro*{cite:labeldate+extradate}{%
  \iffieldundef{labelyear}
    {}
    {\printtext[extblx@inner\blx@delimcontext delims]{%
       \printtext[bibhyperref]{%
         \iftoggle{bbx@journalauthor}
           {\printfield{issue}%
            \setunit{\addcomma\space}%
            \printtext[\blx@delimcontext labeldate]{%
              \printdateextra}}
           {\printtext[\blx@delimcontext labeldate]{%
              \printlabeldateextra}}}}}}
\makeatother

\renewcommand\postnotedelim{\addcolon\addspace}
\DeclareFieldFormat{postnote}{\mknormrange{#1}}
\DeclareFieldFormat{multipostnote}{\mknormrange{#1}}



%-------------
\usepackage{filecontents}
\begin{filecontents*}{\jobname.bib}
@article{yomiuri.1981,
  journal      = {Yomiuri Shimbun},
  entrysubtype = {newspaper},
  date         = {1981-01-22},
  pages        = {20},
  location     = {Kanagawa},
  issue        = {Morgenausgabe},
  title        = {Atarashī taishū bunka sanmi ittai no dendō.
                  Kawasaki ni manga shashin eizō bunka sentā},
  titleaddon   = {Neuer Palast der Dreifaltigkeit der Populärkultur.
                  Das Zentrum für Manga, Fotografie und visuelle Kultur in Kawasaki}
}
@article{testauthor.1981,
  journal      = {Yomiuri Shimbun},
  author       = {Test, Author},
  entrysubtype = {newspaper},
  date         = {1981-01-22},
  pages        = {20},
  location     = {Kanagawa},
  issue        = {Morgenausgabe},
  title        = {Atarashī taishū bunka sanmi ittai no dendō.
                  Kawasaki ni manga shashin eizō bunka sentā},
  titleaddon   = {Neuer Palast der Dreifaltigkeit der Populärkultur.
                  Das Zentrum für Manga, Fotografie und visuelle Kultur in Kawasaki}
}
@incollection{Chua.2017,
  author    = {Chua, Beng Huat},
  year      = {2017},
  title     = {Regional soft power/creative industries competition},
  publisher = {Routledge},
  maintitle = {Routledge Handbook of East Asian Popular Culture},
  location  = {London},
  pages     = {242--253},
  editor    = {Iwabuchi, K\={o}ichi and Berry, Chris and Tsai, Eva}
}
@book{fukuzawa,
  author     = {Fukuzawa, Yukichi},
  title      = {Fukuzawa Yukichi -- Eine autobiographische Lebensschilderung},
  year       = {1971},
  editor     = {Gerhard  Linzbichler},
  translator = {Gerhard  Linzbichler},
  location   = {Tôkyô},
  publisher  = {Keiô  Gijuku  Daigaku},
}
@book{philippi,
  translator = {Philippi, Donald L.},
  year       = {1968},
  title      = {Kojiki},
  location   = {Tôkyô},
  publisher  = {University of Tokyo Press},
}

@article{Cho.2011,
author = {Cho, Younghan},
year = {2011},
title = {Desperately Seeking East Asia Amidst the Popularity of South Korean Pop Culture in Asia},
pages = {383--404},
volume = {25},
issn = {0950-2386},
journal = {Cultural Studies},
number = {3}
}
@suppcollection{Geertz.2001,
author = {Geertz, Clifford},
year = {2001},
title = {Introduction},
publisher = {Princeton University Press},
maintitle = {Schools of Thought},
mainsubtitle = {Twenty-Five Years of Interpretive Social Science},
pagetotal = {1--12},
location = {Princeton, New Jersey},
editor = {Scott, Joan W. and Keates, Deborah}
}

@book{Furuta.2002,
author = {Furuta, Hisateru and Robson, Dean},
year = {2002},
title = {Broadcasting in Japan},
publisher = {NHK Broadcasting Culture Research Institute},
isbn = {4990138708},
subtitle = {The Twentieth Century Journey from Radio to Multimedia},
location = {Tokyo},
organization = {Nihon h\={o}s\={o} ky\={o}kai h\={o}s\={o} bunka ch\={o}sa kenky\={u}jo},
}

@book{Ito.1978,
author = {It\={o}, Masami},
year = {1978},
title = {Broadcasting in Japan},
volume = {7},
publisher = {{Routledge and Kegan Paul: International Institute of Communications}},
isbn = {071000043X},
location = {London},
maintitle = {Case studies on broadcasting systems}
}

@book{keizaizasshi.1901,
date = {1897/1901},
maintitle = {Kokushi taikei},
maintitleaddon = {Kompendium nationaler Geschichte},
title = {Nihon kiryaku},
volume = {5},
author = {{Keizai Zasshi-sha-hen}},
publisher = {Keizai Zasshi-sha},
doi = {10.11501/991095},
addendum = {(letzter Abruf: 10.03.2019)}
}

@book{Kontentsu.2008,
author = {{Kontentsu bijinesu ch\={o}sa kenky\={u}-kai}},
year = {2008},
title = {Saishin kontentsu bijinesu no subete ga wakaru hon},
publisher = {{Nihon n\={o}ritsu ky\={o}kai manejimento sentā [JMA Management Center]}},
location = {T\={o}ky\={o}},
titleaddon = {Buch, mit dem Sie alles {\"u}ber das neue Contents Business verstehen}
}

@article{Takeda.2010,
author = {Takeda, Kazuya},
year = {2010},
title = {Heij\={o}-ky\={o} ato hakkutsu ch\={o}sa no ima},
titleaddon = {Ausgrabungsübersicht der Heijyo-ky\={o}-Ruinen},
pages = {8-12},
series = {Heijō\={o}-ky\={o} sento 1300-nen},
volume = {599},
journal = {Gekkan k\={o}ko-gaku j\={a}naru},
publisher = {Nara Women's University Academic Information Center}
}

@article{Yang.2012,
title = {From Korean Wave to Korean Living},
author = {Yang, Fang-Chih},
year = {2012},
month = {9},
volume = {43},
pages = {419--445},
journal = {Korea Observer},
issn = {0023-3919},
publisher = {Institute of Korean Studies},
number = {3}
}
@online{ShogakukanInc.2015b,
 year = {2015},
 title = {Shakai shugi keizai},
 url = {http://erf.sbb.spk-berlin.de/han/japanknowledge/https/japanknowledge.com/lib/display/?lid=1001000111175},
 urldate = {2019-02-10},
 author = {{Shogakukan Inc.}},
 maintitle = {Dejitaru daijisen},
 maintitleaddon = {Digitales einsprachiges japanisches Wörterbuch},
 keywords = {encyclopedia}
 } 

@online{Buritanika.2014,
 year = {2014},
 title = {Tahinshu sh\={o}ry\={o} seisan},
 url = {https://kotobank.jp/word/%E5%A4%9A%E5%93%81%E7%A8%AE%E5%B0%91%E9%87%8F%E7%94%9F%E7%94%A3-94128},
 urldate = {2019-02-10},
 author = {{Britannica Japan Co.}},
 maintitle = {Buritanika kokusai daihyakkajiten},
 maintitleaddon = {Britannica internationale Enzyklopädie},
 keywords = {encyclopedia}
 }

@online{JiyukokuminshaCo.2015,
 year = {2015},
 title = {Soren ky\={o}sant\={o}},
 url = {http://erf.sbb.spk-berlin.de/han/japanknowledge/https/japanknowledge.com/lib/display/?lid=500202018012390},
 urldate = {2019-02-10},
 author = {{Jiyukokuminsha Co., Ltd}},
 maintitle = {Gendai y\={o}go no kiso chishiki},
 maintitleaddon = {Basiswissen moderner Terminologien},
 keywords = {encyclopedia}
 }
\end{filecontents*}

\addbibresource{\jobname.bib}

\begin{document}
\autocite{yomiuri.1981} and \autocite{testauthor.1981} and \autocite{Chua.2017,fukuzawa}

\nocite{*}
\printbibliography[heading=bibintoc,title={Literaturverzeichnis}]
\end{document}

Screenshot of the last page of the bibliography output.

1
  • thank you so much! I couldn't be more thankful! Much appreciated. It works brilliantly! Thank you for investing time and effort!
    – user168390
    Mar 21, 2019 at 17:49

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .