TransWikia.com

Customize bibtabular bibliography

TeX - LaTeX Asked by Cypher on May 30, 2021

i found this article and gave me a huge boost in building my own custom bibliography. It looks pretty good so far, but it is not perfect for me. I need to make some changes. I read this answer and used the first code example for my bibliography. My bibliography should look like this:

And it looks like that.

Changes i need to make:

  1. Change the order of the different bibtex items

  2. Change format (no use of "", generate my own abbreviations, no use of italic style)

  3. Remove the dot at the end of each entry

    documentclass[a4paper,12pt]{report}
    usepackage[ngerman]{babel}
    usepackage[utf8]{inputenc}
    
    usepackage[backend=biber,,citestyle=authoryear,hyperref=true,autocite=inline,sortlocale=de_DE,maxnames=99]{biblatex}
    addbibresource{jobname.bib}
    DeclareDelimFormat[bib,biblist]{nametitledelim}{addcolonspace}
    renewcommand{newunitpunct}{addcommaspace}
    DeclareDelimFormat{multinamedelim}{addsemicolonspace}
    DeclareDelimAlias{finalnamedelim}{multinamedelim}
    
    DeclareNameAlias{sortname}{family-given}
    
    DeclareFieldFormat*{shorttitle}{mkbibparens{#1}}
    DeclareFieldFormat{url}{url{#1}}
    
    renewbibmacro*{date}{%
      iffieldundef{year}
        {printtext{bibstring{nodate}}}
        {printdate}}
    
    makeatletter
    
    usepackage{biblatex-ext-tabular}
    
    % sortname labels (a robust style should add provision for missing  labelnames)
    newbibmacro*{sortname}{%
      ifnameundef{labelname}
        {printtext{No name given.}
         PackageWarning{biblatex}{No labelname for entry thefield{entrykey},MessageBreak
           we need to think of something else}}
        {printnames[sortname]{labelname}%
         iffieldequalstr{labelnamesource}{editor}
           {setunit{printdelim{editortypedelim}}%
            usebibmacro{editor+othersstrg}}
           {iffieldequalstr{labelnamesource}{translator}
              {setunit{printdelim{translatortypedelim}}%
               usebibmacro{translator+othersstrg}}
              {}}}}
    
    usepackage{array}
    newcolumntype{L}[1]{>{raggedrightletnewlinearraybackslashhspace{0pt}}p{#1}}
    newcolumntype{C}[1]{>{centeringletnewlinearraybackslashhspace{0pt}}p{#1}}
    newcolumntype{R}[1]{>{raggedleftletnewlinearraybackslashhspace{0pt}}p{#1}}
    
    usepackage{longtable}
    % demo new tabular bibliography format
    % I strongly prefer left-aligned with fixed width (L)
    % over justified (p) here
    % longtable for tables that break over pages
    defbibtabular{bibtabular}
      {defarraystretch{2}%
       begin{longtable}{@{}L{dimexpr0.3textwidth-tabcolseprelax}L{dimexpr0.7textwidth-tabcolseprelax}@{}}}
      {end{longtable}}
      {anchorlang{usebibmacro{sortname}} &
       driver{usebibmacro{tabular:omitsortname}} }
    
    renewbibmacro*{begentry}{%
      printfield{shorttitle}%
      printunit*{addspace}}
    % End Custom Bibliography
    
    usepackage{filecontents}
    
    begin{filecontents}{jobname.bib}
    @online{testonline,
        title = {Titel},
        subtitle = {Untertitel},
        shorttitle = {Stichwort},
        author = {{N}achname, {V}orname},
        url = {protokoll://serveradresse/dokumentenpfad/dokument},
        year = {Jahr},
        urldate = {01.01.2021}
        note = "(Kommentar)"
    }
    
    @ARTICLE{testarticle,
        title = {Titel},
        subtitle = {Untertitel},
        shorttitle = {Stichwort},
        author = {{N}achname, {V}orname},
        journal = {Name der Zeitschrift},
        year = {Jahr},
        volume = {Band},
        pages = {erste Seite - letzte Seite},
        number = {Nummer},
        month = {March},
        publisher = {Verlag}
    }
    
    @BOOK{testbook,
        title = {Titel}, 
        subtitle = {Untertitel},
        shorttitle = {Stichwort},
        author = {{N}achname, {V}orname},
        year = {Erscheinungsjahr},
        location = {Erscheinungsort},
        volume = {Band}, 
        edition = {Auflage},
        year = {Jahr},
    }
    end{filecontents}
    
    begin{document}
    
    autocite{testonline} 
    textcite{testonline} 
    autocite{testarticle} 
    textcite{testarticle} 
    autocite{testbook} 
    textcite{testbook} 
    
    printbibtabular
    end{document}
    

Could you please give me some recommandations?

Thank you in advance

Cypher

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP