2

I am in the process of writing my thesis with latex and I have a header issue in the bibliography section. I use titlesec package for the header and biblatex for both bibliography and a publication list appearing later in the text.

Here is a MWE of my problem, the headers in the publication list sections are fine but "REFERENCES" is added in the header and footer of the bibliography and I cannot find how to get this correctly.

\documentclass[
    openany,
    twoside,
    12pt]
    {report}

\begin{filecontents}{exempleref.bib}
@book{jane1980,
  author    = "Jane Doe",
  title     = "Matrix Computations",
  edition   = "4th Edition",
  publisher = "The Johns Hopkins University Press",
  address   = "Baltimore, Maryland",
  year      = "2013",
  }

  @Article{doe2017,
  Author    = "John Doe",
  Title     = "Latex Minimal Working Ewample (MWE) First Edition",
  Journal = "Great LateX Journal",
  Year      = "2017",
  Number = "3",
  Pages = "1-23",
  Volume = {1},
  }

    @Article{doe2016,
  Author    = "John Doe",
  Title     = "First Latex Minimal Working Ewample (MWE) First Edition",
  Journal = "Great LateX Journal",
  Year      = "2017",
  Number = "3",
  Pages = "1-23",
  Volume = {1},
  }

    @Article{doe2015,
  Author    = "John Doe",
  Title     = "Previous Latex Minimal Working Ewample (MWE) First Edition",
  Journal = "Great LateX Journal",
  Year      = "2017",
  Number = "3",
  Pages = "1-23",
  Volume = {1},
  }

    @Article{doe2014,
  Author    = "John Doe",
  Title     = "Another Latex Minimal Working Ewample (MWE) First Edition",
  Journal = "Great LateX Journal",
  Year      = "2017",
  Number = "3",
  Pages = "1-23",
  Volume = {1},
  }

    @Article{doe2013,
  Author    = "John Doe",
  Title     = "Prequel to Latex Minimal Working Ewample (MWE) First Edition",
  Journal = "Great LateX Journal",
  Year      = "2017",
  Number = "3",
  Pages = "1-23",
  Volume = {1},
  }

    @Article{doe2012,
  Author    = "John Doe",
  Title     = "Prequel to prequel to Latex Minimal Working Ewample (MWE) First Edition",
  Journal = "Great LateX Journal",
  Year      = "2017",
  Number = "3",
  Pages = "1-23",
  Volume = {1},
  }

    @Article{doe2011,
  Author    = "John Doe",
  Title     = "Before Latex Minimal Working Ewample (MWE) First Edition",
  Journal = "Great LateX Journal",
  Year      = "2017",
  Number = "3",
  Pages = "1-23",
  Volume = {1},
  }

    @Article{doe2010,
  Author    = "John Doe",
  Title     = "Introduction to Latex Minimal Working Ewample (MWE) First Edition",
  Journal = "Great LateX Journal",
  Year      = "2017",
  Number = "3",
  Pages = "1-23",
  Volume = {1},
  }

\end{filecontents}

\usepackage[
    paperwidth=16cm,
    paperheight=24cm]
    {geometry} 

\linespread{1.5}

\usepackage[
    natbib=true,
    style=nature, %bibliography style
    backend=bibtex8,
    defernumbers, %Will put new reference number for publication list
    sorting = none, %sort bibliography by in text citation number
    firstinits=true,    %turn first and middle names as intials
    doi=false,      %no doi 
    isbn=false, %no isbn field
    url=false]      % no url in bibliography
    {biblatex}

\addbibresource{exempleref.bib}

\DefineBibliographyStrings{english}{%change the name of the bibliography section to "References"
  bibliography = {References},
}

\defbibheading{bibliography}[\refname]{% %should fix the heading but is inneficient
  \section*{#1}
  \markboth{}{}
  }

\usepackage[
    pagestyles] %option allow to change page header 
    {titlesec}
\titleformat{\chapter}{\normalfont\huge}{\bf\thechapter.}{20pt}{\huge\bf} %change chapter N to N. chapter title
\newpagestyle{mystyle} %page style for whole document
{\sethead[\thepage][][\thechapter .~\chaptertitle]{\thesection~\sectiontitle}{}{\thepage}
}
\newpagestyle{bibstyle} %page style for bibliography
{\sethead[\thepage][][\thechapter .~\chaptertitle]{}{}{\thepage}
}
\pagestyle{mystyle}

\usepackage{lipsum}

\begin{document}

\chapter {First Chapter}

\lipsum[1-1]
\cite{jane1980}
\lipsum[2-2]
\cite{doe2010,doe2011,doe2012,doe2013,doe2014,doe2015,doe2016,doe2017}


\pagestyle{bibstyle}  %use the header style for the bibliography
\printbibheading[title = {References}, heading = bibnumbered] %print bibliography title
\printbibliography[heading=none] %print the bibligraphy

\pagestyle{mystyle} %recover document heading style
\begin{refsection} %new section for separated publication list
\printbibheading[title = {Publications list}, heading = bibnumbered]
\nocite{*}
\section {Articles}
        \printbibliography[type=article, prefixnumbers={A.}, heading=none]
\section {Book}
        \printbibliography[type=book, prefixnumbers={B.}, heading=none]
\end{refsection}

\end{document}

This is the resulted output where I would like the red circled "REFERENCES" to be removed:

Wrong header

  • 2
    Welcome to TeX SX! I think I had a very similar problem last year. I solved it thanks to @egreg's answer to this post. For the report class, try adding this to your preamble after biblatex is loaded: \defbibheading{bibliography}[\refname]{\chapter*{#1}}. – Bernard Jul 6 '17 at 9:50
2

You change the setting for the heading bibliography, but then you use heading=bibnumbered, so you will have to change that as well. Probably to

\defbibheading{bibnumbered}[\refname]{\chapter{#1}}

BTW You should not have to use empty \markboth{}{}, it should be enough to leave it out altogether.

  • Well, thanks a lot! This worked like a charm! (I also removed \markboth{}{}) – Florian Bodranghien Jul 7 '17 at 10:53

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.