Created
September 5, 2018 11:09
-
-
Save moewew/2e80191d73f380c19bf4060c35db11f8 to your computer and use it in GitHub Desktop.
https://tex.stackexchange.com/q/438933/35864 - code for biblatex 3.6
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
\documentclass[paper=a4,12pt,numbers=endperiod]{scrartcl} | |
\usepackage[backend=biber,style=authoryear]{biblatex} | |
\DefineBibliographyStrings{english}{references={Bibliography}} | |
\DeclareFieldFormat{editortype}{\mkbibparens{#1}} | |
\renewbibmacro*{byeditor+others}{% | |
\ifnameundef{editor} | |
{} | |
{\printnames[byeditor]{editor}% | |
\setunit{\addspace}% | |
\usebibmacro{byeditor+othersstrg}% | |
\clearname{editor}% | |
\newunit}% | |
\usebibmacro{byeditorx}% | |
\usebibmacro{bytranslator+others}} | |
\renewbibmacro*{byeditor+othersstrg}{\usebibmacro{editor+othersstrg}} | |
\renewbibmacro*{bytranslator+othersstrg}{\usebibmacro{translator+othersstrg}} | |
\renewbibmacro*{bytypestrg}[2]{% | |
\iffieldundef{#1type} | |
{\bibstring{#2}} | |
{\ifbibxstring{\thefield{#1type}} | |
{\bibstring{\thefield{#1type}}} | |
{\printtext{\thefield{#1type}}}}} | |
\renewcommand*{\multinamedelim}{/} | |
\renewcommand*{\finalnamedelim}{\multinamedelim} | |
\renewcommand*{\labelnamepunct}{\addcolon\space} | |
\renewcommand*{\postnotedelim}{\addcolon\space} | |
\DeclareFieldFormat{postnote}{#1} | |
\DeclareFieldFormat{multipostnote}{#1} | |
\DeclareFieldFormat{superedition}{\textsuperscript{#1}} | |
\providecommand*{\iflabeldateisdate}{% | |
\ifboolexpr{% | |
not test {\iffieldundef{labeldatesource}} | |
and | |
(test {\iffieldequalstr{labeldatesource}{}} | |
or test {\iffieldequalstr{labeldatesource}{year}})}} | |
\renewbibmacro*{date+extrayear}{% | |
\iffieldundef{labelyear} | |
{} | |
{\usebibmacro{origdate}% | |
\setunit*{\addspace}% | |
\printtext[parens]{% | |
\iflabeldateisdate | |
{\iffieldnum{edition} | |
{\printfield[superedition]{edition}% | |
\global\clearfield{edition}} | |
{}% | |
\printdateextra} | |
{\printlabeldateextra}}}} | |
\newbibmacro*{origdate}{% | |
\iffieldundef{origyear} | |
{} | |
{\printtext[brackets]{\printorigdate}}} | |
\renewcommand*{\bibpagespunct}{\addcolon\space} | |
\DeclareFieldFormat{pages}{#1} | |
\DeclareNameAlias{sortname}{family-given} | |
\DeclareFieldFormat[article,periodical]{number}{\mkbibparens{#1}} | |
\renewbibmacro*{volume+number+eid}{% | |
\printfield{volume}% | |
%\setunit*{\adddot}%<- comment this | |
\printfield{number}% | |
\setunit{\addcomma\space}% | |
\printfield{eid}} | |
\usepackage{filecontents} | |
\begin{filecontents}{\jobname.bib} | |
@collection{knobel2007a, | |
title = {A New Literacies Sampler}, | |
editor = {Knobel, Michele and Lankshear, Colin}, | |
keywords = {sek}, | |
location = {New York}, | |
publisher = {Peter Lang}, | |
year = {2007}, | |
series = {New Literacies and Digital Epistemologies}, | |
number = {29}, | |
} | |
@article{berg2012a, | |
title = {Identifying Graphematic Units. Vowel and Consonant Letters}, | |
author = {Berg, Kristian}, | |
journal = {Written Language \& Literacy}, | |
keywords = {sek}, | |
number = {1}, | |
pages = {26--45}, | |
volume = {15}, | |
year = {2012} | |
} | |
\end{filecontents} | |
\addbibresource{\jobname.bib} | |
\begin{document} | |
Example sentence \textcite[cf.][3--6]{knobel2007a}. | |
Another example sentence \parencite[][39]{berg2012a}. | |
\printbibliography | |
\end{document} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment