使用 biblatex 和 titlesec 的參考書目中的標題問題

使用 biblatex 和 titlesec 的參考書目中的標題問題

我正在用乳膠寫論文,我在參考書目部分遇到了標題問題。我使用 titlesec 套件作為標題,使用 biblatex 套件作為參考書目和文字後面出現的出版物清單。

這是我的問題的 MWE,出版物列表部分中的標題很好,但在參考書目和頁腳中添加了“參考文獻”,我找不到如何正確獲取它。

\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}

這是結果輸出,我希望刪除紅色圓圈的“參考”:

標題錯誤

答案1

您更改了標題的設置bibliography,但隨後使用了heading=bibnumbered,因此您也必須更改它。大概是為了

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

順便說一句,您不必使用 empty \markboth{}{},完全將其省略就足夠了。

相關內容