![tufte-book 中全宽环境下的标题问题](https://linux22.com/image/414736/tufte-book%20%E4%B8%AD%E5%85%A8%E5%AE%BD%E7%8E%AF%E5%A2%83%E4%B8%8B%E7%9A%84%E6%A0%87%E9%A2%98%E9%97%AE%E9%A2%98.png)
我在 tufte-book documentclass 下工作,我想将我的后记(参考书目、词汇表、索引和目录)放在全宽环境中。为此,我使用以下代码(参考书目示例):
\documentclass[symmetric,justified,marginals=raggedouter]{tufte-book}
\begin{document}
\backmatter
\newgeometry{left=1in,right=1in}
\bibliographystyle{plain-fr}
\bibliography{sample-handout}
\clearpage
\restoregeometry
\end{document}
我尝试了问题的答案中提出的以下代码多页参考书目:
\documentclass[symmetric,justified,marginals=raggedouter]{tufte-book}
\usepackage[most]{tcolorbox}
\begin{document}
\begin{tcolorbox}[enhanced, breakable, colback=white, colframe=white, check odd page, toggle left and right, grow to right by=\marginparwidth+\marginparsep, toggle enlargement=evenpage]
\bibliography{sample-handout}
\bibliographystyle{plain-fr}
\end{tcolorbox}
\end{document}
但效果不太好,因为标题仍然是上一章的标题,而不是参考书目的标题!
谁能帮我 ?
答案1
我找到了一个解决方案,到目前为止,它只适用于参考书目章节(tcolorbox 的使用似乎不适用于索引、词汇表和目录,因为我认为需要在序言中进行修改才能允许它,但我不知道如何解决这个问题……)。这是获得以下结果的代码:
\documentclass[nobib,twoside,symmetric,justified,marginals=raggedouter]{tufte-book}
\usepackage{csquotes}
\usepackage[backend=biber,style=authoryear-icomp]{biblatex}
\makeatletter
\newbibmacro*{adtcite}{%
\iffieldundef{shorthand}
{\ifthenelse{\ifciteibid\AND\NOT\iffirstonpage}
{\usebibmacro{cite:ibid}}
{\iffieldequals{namehash}{\cbx@lasthash}
{\setunit{\compcitedelim}}
{\printnames{labelname}%
\setunit*{\printdelim{nameyeardelim}}%
\printlabeldateextra
\setunit*{\printdelim{nametitledelim}}%
\savefield{namehash}{\cbx@lasthash}}%
\usebibmacro{cite:title}}}%
{\usebibmacro{cite:shorthand}%
\usebibmacro{cite:reinit}}%
\setunit{\multicitedelim}}
\makeatother
\newbibmacro*{cite:title}{%
\printtext[bibhyperref]{\printfield[citetitle]{labeltitle}}}
\DeclareCiteCommand{\fadtcite}[\mkbibfootnote]
{\usebibmacro{cite:init}%
\usebibmacro{prenote}}
{\usebibmacro{citeindex}%
\usebibmacro{adtcite}}
{}
{\usebibmacro{cite:postnote}}
\DeclareMultiCiteCommand{\fadtcites}[\mkbibfootnote]{\fadtcite}
{\setunit{\multicitedelim}}
\DeclareAutoCiteCommand{fadt}{\fadtcite}{\fadtcites}
\ExecuteBibliographyOptions{autocite=fadt}
\usepackage[most]{tcolorbox}
\defbibenvironment{bibliography}
{\list{}{\parsep\bibparsep}}
{\endlist}
{\item}
\AtEveryBibitem{\hskip-\bibhang}
\addbibresource{sample-handout.bib}
\defbibheading{bibintoc}[\bibname]{%
\chapter*{#1}\markboth{#1}{}%
}
\PassOptionsToPackage{hyphens}{url}
\usepackage{glossaries}
\makeglossaries
\defglsentryfmt[main]{\glsgenentryfmt\ifglsused{\glslabel}{}{*}}
\usepackage{imakeidx}
\usepackage{adjmulticol,tikz}
\makeindex[name=piece,title={Index des \oe uvres},columns=2]
\makeindex[title=Index,columns=2]
\newcommand{\full}[1]{\begin{adjmulticols}{1}{0cm}{\dimexpr-\marginparwidth-
\marginparsep\relax}
#1
\end{adjmulticols}}
\begin{document}
\backmatter
\printbibheading[heading=bibintoc]
\begin{tcolorbox}[enhanced, breakable, colback=white, colframe=white, check odd page, toggle left and right, grow to right by=\marginparwidth+\marginparsep, toggle enlargement=evenpage]
\printbibliography[nottype=misc, heading=subbibintoc, title=Sources bibliographiques]
\printbibliography[type=misc, heading=subbibintoc, title= Sources internet]
\end{tcolorbox}
\printglossaries
\clearpage
\printindex
\clearpage
\printindex[piece]
\clearpage
\tableofcontents
\clearpage
\end{document}