
目次を作成しましたが、太字toc
を解除するにはどうすればよいですか。章のタイトルとページ番号の間も消えてしまいますか? どうすればいいですか。私の MWE は次のとおりです。chapter number
dotsep
dotsep
\documentclass{book}
\usepackage{mathptmx}
\makeatletter
\renewcommand\@dotsep{2}
\newcommand*\l@fmchapter[2]{%
\ifnum \c@tocdepth >\m@ne
\addpenalty{-\@highpenalty}%
\vskip0em% \@plus\p@
\setlength\@tempdima{2pc}%
\begingroup
\parindent \z@ \rightskip \@pnumwidth
\parfillskip -\@pnumwidth
\leavevmode \fontsize{10}{13}\selectfont
\advance\leftskip\@tempdima
\hskip -33pt
#1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\fontsize{10}{13}\selectfont\hss #2}\par
\penalty\@highpenalty
\endgroup
\fi\vskip1pt}
\renewcommand*\l@chapter[2]{%
\ifnum \c@tocdepth >\m@ne
\addpenalty{-\@highpenalty}%
\vskip 5pt \@plus\p@
\setlength\@tempdima{1.5em}%
\begingroup
\parindent \z@ \rightskip \@pnumwidth
\parfillskip -\@pnumwidth
\leavevmode \bfseries
\advance\leftskip\@tempdima
\hskip -\leftskip
#1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\hss \normalfont #2}\par
\penalty\@highpenalty
\endgroup
\fi}
\newcommand*\l@bmchapter[2]{%
\ifnum \c@tocdepth >\m@ne
\addpenalty{-\@highpenalty}%
\vskip11pt% \@plus\p@
\setlength\@tempdima{2pc}%
\begingroup
\parindent \z@ \rightskip \@pnumwidth
\parfillskip -\@pnumwidth
\leavevmode \fontsize{10}{13}
\advance\leftskip\@tempdima
\hskip -35.6pt
#1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\fontsize{10}{13}\selectfont\hss #2}\par
\penalty\@highpenalty
\endgroup
\fi\vskip-11pt}
\makeatother
\begin{document}
\chapter*{Contents}
\contentsline {fmchapter}{\numberline {}About the Author}{ix}
\contentsline {fmchapter}{\numberline {}Acknowledgements}{xi}
\contentsline {chapter}{\numberline {1}Introduction}{1}
\contentsline {chapter}{\numberline {2}Sequential Assignment}{11}
\contentsline {chapter}{\numberline {3}Revenue Maximization}{41}
\contentsline {bmchapter}{\numberline {}Bibliography}{181}
\contentsline {bmchapter}{\numberline {}Index}{191}
\end{document}
答え1
normalfont
以内にお電話くださいnumberline
。
tocstyle
ただし、または を使用した手動操作の少ないアプローチtocloft
が推奨されます。
\documentclass{book}
\usepackage{mathptmx}
\makeatletter
\renewcommand\@dotsep{2}
\newcommand*\l@fmchapter[2]{%
\ifnum \c@tocdepth >\m@ne
\addpenalty{-\@highpenalty}%
\vskip0em% \@plus\p@
\setlength\@tempdima{2pc}%
\begingroup
\parindent \z@ \rightskip \@pnumwidth
\parfillskip -\@pnumwidth
\leavevmode \fontsize{10}{13}\selectfont
\advance\leftskip\@tempdima
\hskip -33pt
#1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\fontsize{10}{13}\selectfont\hss #2}\par
\penalty\@highpenalty
\endgroup
\fi\vskip1pt}
\renewcommand*\l@chapter[2]{%
\ifnum \c@tocdepth >\m@ne
\addpenalty{-\@highpenalty}%
\vskip 5pt \@plus\p@
\setlength\@tempdima{1.5em}%
\begingroup
\parindent \z@ \rightskip \@pnumwidth
\parfillskip -\@pnumwidth
\leavevmode \bfseries
\advance\leftskip\@tempdima
\hskip -\leftskip
#1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\hss \normalfont #2}\par
\penalty\@highpenalty
\endgroup
\fi}
\newcommand*\l@bmchapter[2]{%
\ifnum \c@tocdepth >\m@ne
\addpenalty{-\@highpenalty}%
\vskip11pt% \@plus\p@
\setlength\@tempdima{2pc}%
\begingroup
\parindent \z@ \rightskip \@pnumwidth
\parfillskip -\@pnumwidth
\leavevmode \fontsize{10}{13}
\advance\leftskip\@tempdima
\hskip -35.6pt
#1\nobreak\hfil \nobreak\hb@xt@\@pnumwidth{\fontsize{10}{13}\selectfont\hss #2}\par
\penalty\@highpenalty
\endgroup
\fi\vskip-11pt}
\makeatother
\begin{document}
\chapter*{Contents}
\contentsline {fmchapter}{\numberline {}About the Author}{ix}
\contentsline {fmchapter}{\numberline {}Acknowledgements}{xi}
\contentsline {chapter}{\numberline {\normalfont 1}Introduction}{1}
\contentsline {chapter}{\numberline {\normalfont 2}Sequential Assignment}{11}
\contentsline {chapter}{\numberline {\normalfont 3}Revenue Maximization}{41}
\contentsline {bmchapter}{\numberline {}Bibliography}{181}
\contentsline {bmchapter}{\numberline {}Index}{191}
\end{document}