Überarbeitungsverlauf[Zurück]
Klicke auf Einblenden/Ausblenden von Überarbeitungen 2

28 Feb '19, 07:08

moewe's gravatar image

moewe
3.7k36

Wenn Du unzufrieden damit bist, `editora` zu verwenden, da es sich hier nicht um Herausgeber im weiteren Sinne handelt, sondern um Autoren, dann wirst Du nicht umhin kommen, selbst etwas Hand anzulegen. Es ist recht einfach, den Code für `editorx` zu kopieren und zu `authorx` umzumodeln. (Es sei erwähnt, dass ich es zwar verstehen kann, dass Du der Meinung bist, `editorx` sei nicht ganz passend, andererseits sind die Punkte 2 und 3 auf Seite 12 von [`btxdoc`](http://mirrors.ctan.org/biblio/bibtex/base/btxdoc.pdf) sehr zutreffend. Gerade hier stellt sich die Frage, wie häufig Du auf ähnliche Situationen triffst, und was Du gewinnst, wenn Du `editorx` nicht verwendest.) \documentclass[ngerman]{article} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage{babel} \usepackage{csquotes} \usepackage{filecontents} \begin{filecontents}{authorx.dbx} \DeclareDatamodelFields[type=list, datatype=name]{ authora, authorb, authorc} \DeclareDatamodelFields[type=field, datatype=key]{ authoratype, authorbtype, authorctype} \DeclareDatamodelEntryfields[article]{ authora, authoratype, authorb, authorbtype, authorc, authorctype} \end{filecontents} \usepackage[style=authoryear, backend=biber, datamodel=authorx]{biblatex} \DeclareNameAlias{byauthora}{byauthor} \DeclareNameAlias{byauthorb}{byauthor} \DeclareNameAlias{byauthorc}{byauthor} \newbibmacro*{byauthorx}{% \ifnameundef{authora} {} {\usebibmacro{bytypestrg}{authora}{author}% \setunit{\addspace}% \printnames[byauthora]{authora}% \newunit}% \ifnameundef{authorb} {} {\usebibmacro{bytypestrg}{authorb}{author}% \setunit{\addspace}% \printnames[byauthorb]{authorb}% \newunit}% \ifnameundef{authorc} {} {\usebibmacro{bytypestrg}{authorc}{author}% \setunit{\addspace}% \printnames[byauthorc]{authorc}% \newunit}} \renewbibmacro*{byauthor}{% \ifboolexpr{ test \ifuseauthor or test {\ifnameundef{author}} } {} {\usebibmacro{bytypestrg}{author}{author}% \setunit{\addspace}% \printnames[byauthor]{author}}% \usebibmacro{byauthorx}} \usepackage{filecontents} \begin{filecontents}{\jobname.bib} @book{elk, author = {Anne Elk}, title = {A Theory on Brontosauruses}, year = {1972}, authora = {Humphrey Appleby and James Hacker}, authoratype = {collaborator}, } \end{filecontents} \addbibresource{\jobname.bib} \addbibresource{biblatex-examples.bib} \begin{document} \cite{sigfridsson,elk} \printbibliography \end{document} Die Ausgabe ist die, die Du auch mit `editorx` bekommen würdest. [![Elk, Anne (1972). A Theory on Brontosauruses. Unter Mitarb. von Humphrey Appleby und James Hacker.][1]][1] Wenn die `authorx` aber noch zur Sortierung oder für andere Features (`uniquename`, `uniquelist`, `labelalpha`) herangezogen werden sollen, dann ist mehr Arbeit nötig. ---- Damit es nicht verloren geht, hier eine (vielleicht nicht ganz ausgereifte) Erweiterung, bei der die `authorx`en zusammen mit dem Autor vor dem Titel stehen. Der konkrete Code ist für `alphabetic` gedacht, funktioniert also mit allen Standardstilen, außer denen, deren Bibliographiestil auf `authortitle` und `authoryear` aufbaut. Eine ähnliche Methode wäre dort aber anwendbar. \documentclass[ngerman]{article} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage{babel} \usepackage{csquotes} \usepackage{filecontents} \begin{filecontents}{authorx.dbx} \DeclareDatamodelFields[type=list, datatype=name]{ authora, authorb, authorc} \DeclareDatamodelFields[type=field, datatype=key]{ authoratype, authorbtype, authorctype} \DeclareDatamodelEntryfields[article]{ authora, authoratype, authorb, authorbtype, authorc, authorctype} \end{filecontents} \usepackage[style=authoryear, backend=biber, datamodel=authorx]{biblatex} \DeclareNameAlias{authora}{author} \DeclareNameAlias{authorb}{author} \DeclareNameAlias{authorc}{author} \DeclareNameAlias{byauthora}{byauthor} \DeclareNameAlias{byauthorb}{byauthor} \DeclareNameAlias{byauthorc}{byauthor} \newbibmacro*{authorxstrg}[1]{% \iffieldundef{#1type} {} {\printtext[#1type]{% \ifbibxstring{\thefield{#1type}} {\ifboolexpr{ test {\ifnumgreater{\value{#1}}{1}} or test {\ifandothers{#1}} } {\bibstring{\thefield{#1type}s}} {\bibstring{\thefield{#1type}}}} {\thefield{#1type}}}}} \newbibmacro*{authorx}{% \ifboolexpr{ test {\ifnameundef{authora}} and test {\ifnameundef{authorb}} and test {\ifnameundef{authorc}} } {} {\bibstring{with}% \setunit{\addspace}% \printnames{authora}% \setunit{\printdelim{authortypedelim}}% \usebibmacro{authorxstrg}{authora}% \clearname{authora}% \printnames{authorb}% \setunit{\printdelim{authortypedelim}}% \usebibmacro{authorxstrg}{authorb}% \clearname{authorb}% \printnames{authorc}% \setunit{\printdelim{authortypedelim}}% \usebibmacro{authorxstrg}{authorc}% \clearname{authorc} \setunit{\printdelim{nameyeardelim}}}} \renewbibmacro*{author}{% \ifboolexpr{ test \ifuseauthor and not test {\ifnameundef{author}} } {\usebibmacro{bbx:dashcheck} {\bibnamedash} {\usebibmacro{bbx:savehash}% \printnames{author}% \iffieldundef{authortype} {\setunit{\printdelim{nameyeardelim}}} {\setunit{\printdelim{authortypedelim}}}}% \iffieldundef{authortype} {} {\usebibmacro{authorstrg}% \setunit{\printdelim{nameyeardelim}}}% \usebibmacro{authorx}}% {\global\undef\bbx@lasthash \usebibmacro{labeltitle}% \setunit*{\printdelim{nonameyeardelim}}}% \usebibmacro{date+extradate}} \newbibmacro*{byauthorx}{% \ifnameundef{authora} {} {\usebibmacro{bytypestrg}{authora}{author}% \setunit{\addspace}% \printnames[byauthora]{authora}% \newunit}% \ifnameundef{authorb} {} {\usebibmacro{bytypestrg}{authorb}{author}% \setunit{\addspace}% \printnames[byauthorb]{authorb}% \newunit}% \ifnameundef{authorc} {} {\usebibmacro{bytypestrg}{authorc}{author}% \setunit{\addspace}% \printnames[byauthorc]{authorc}% \newunit}} \renewbibmacro*{byauthor}{% \ifboolexpr{ test \ifuseauthor or test {\ifnameundef{author}} } {} {\usebibmacro{bytypestrg}{author}{author}% \setunit{\addspace}% \printnames[byauthor]{author}}% \usebibmacro{byauthorx}} \NewBibliographyString{with} \DefineBibliographyStrings{german}{ with = {mit}, } \usepackage{filecontents} \begin{filecontents}{\jobname.bib} @book{elk, author = {Anne Elk}, title = {A Theory on Brontosauruses}, year = {1972}, authora = {Humphrey Appleby and James Hacker}, authoratype = {collaborator}, } \end{filecontents} \addbibresource{\jobname.bib} \addbibresource{biblatex-examples.bib} \begin{document} \cite{sigfridsson,elk} \printbibliography \end{document} [1]: https://texwelt.de/wissen/upfiles/eztezteztehghhsghg.pnghttps://texwelt.de/wissen/upfiles/eztezteztehghhsghg.png
Klicke auf Einblenden/Ausblenden von Überarbeitungen 1

27 Feb '19, 07:37

moewe's gravatar image

moewe
3.7k36

Wenn Du unzufrieden damit bist, `editora` zu verwenden, da es sich hier nicht um Herausgeber im weiteren Sinne handelt, sondern um Autoren, dann wirst Du nicht umhin kommen, selbst etwas Hand anzulegen. Es ist recht einfach, den Code für `editorx` zu kopieren und zu `authorx` umzumodeln. (Es sei erwähnt, dass ich es zwar verstehen kann, dass Du der Meinung bist, `editorx` sei nicht ganz passend, andererseits sind die Punkte 2 und 3 auf Seite 12 von [`btxdoc`](http://mirrors.ctan.org/biblio/bibtex/base/btxdoc.pdf) sehr zutreffend. Gerade hier stellt sich die Frage, wie häufig Du auf ähnliche Situationen triffst, und was Du gewinnst, wenn Du `editorx` nicht verwendest.) \documentclass[ngerman]{article} \usepackage[T1]{fontenc} \usepackage[utf8]{inputenc} \usepackage{babel} \usepackage{csquotes} \usepackage{filecontents} \begin{filecontents}{authorx.dbx} \DeclareDatamodelFields[type=list, datatype=name]{ authora, authorb, authorc} \DeclareDatamodelFields[type=field, datatype=key]{ authoratype, authorbtype, authorctype} \DeclareDatamodelEntryfields[article]{ authora, authoratype, authorb, authorbtype, authorc, authorctype} \end{filecontents} \usepackage[style=authoryear, backend=biber, datamodel=authorx]{biblatex} \DeclareNameAlias{byauthora}{byauthor} \DeclareNameAlias{byauthorb}{byauthor} \DeclareNameAlias{byauthorc}{byauthor} \newbibmacro*{byauthorx}{% \ifnameundef{authora} {} {\usebibmacro{bytypestrg}{authora}{author}% \setunit{\addspace}% \printnames[byauthora]{authora}% \newunit}% \ifnameundef{authorb} {} {\usebibmacro{bytypestrg}{authorb}{author}% \setunit{\addspace}% \printnames[byauthorb]{authorb}% \newunit}% \ifnameundef{authorc} {} {\usebibmacro{bytypestrg}{authorc}{author}% \setunit{\addspace}% \printnames[byauthorc]{authorc}% \newunit}} \renewbibmacro*{byauthor}{% \ifboolexpr{ test \ifuseauthor or test {\ifnameundef{author}} } {} {\usebibmacro{bytypestrg}{author}{author}% \setunit{\addspace}% \printnames[byauthor]{author}}% \usebibmacro{byauthorx}} \usepackage{filecontents} \begin{filecontents}{\jobname.bib} @book{elk, author = {Anne Elk}, title = {A Theory on Brontosauruses}, year = {1972}, authora = {Humphrey Appleby and James Hacker}, authoratype = {collaborator}, } \end{filecontents} \addbibresource{\jobname.bib} \addbibresource{biblatex-examples.bib} \begin{document} \cite{sigfridsson,elk} \printbibliography \end{document} Die Ausgabe ist die, die Du auch mit `editorx` bekommen würdest. [![Elk, Anne (1972). A Theory on Brontosauruses. Unter Mitarb. von Humphrey Appleby und James Hacker.][1]][1] Wenn die `authorx` aber noch zur Sortierung oder für andere Features (`uniquename`, `uniquelist`, `labelalpha`) herangezogen werden sollen, dann ist mehr Arbeit nötig. [1]: https://texwelt.de/wissen/upfiles/eztezteztehghhsghg.png