3

How to remove period after part number in TOC (KOMA used)? My solution was to set tocloft package, which is provide command \cftpartaftersnum but I do not want to use it for some compatibility reasons. enter image description here

\documentclass{scrbook}
\usepackage{polyglossia}
%\usepackage{tocloft}
%\setmainlanguage{ukrainian}
\usepackage{etoolbox}
\renewcommand*{\figureformat}{%
  \figurename~\thefigure%
%  \autodot% DELETED
}
\makeatletter
\makeatother
\begin{document}
\tableofcontents
\part{One}
\part{Two}
\end{document}
sergiokapone
  • 5,578
  • 1
  • 16
  • 39

2 Answers2

5

Update

To remove the dots at the end of the numbers only in TOC and lists you can use

\BeforeStartingTOC{\def\autodot{}}

If this should be done only for TOC (or for a special) list you can add the optional argument

\BeforeStartingTOC[toc]{\def\autodot{}}

enter image description here

Code:

\documentclass{scrbook}
\usepackage{polyglossia}

\BeforeStartingTOC{\def\autodot{}}

\usepackage{blindtext}% dummy text
\begin{document}
\tableofcontents

\part{One}
\part{Two}
\blinddocument
\end{document}

You could use the KOMA-Script class option numbers=noenddot to suppress the end dots for all sectioning levels (and figures etc.) in mainmatter and TOC:

\documentclass[numbers=noenddot]{scrbook}
\usepackage{polyglossia}

\usepackage{blindtext}% dummy text
\begin{document}
\tableofcontents

\part{One}
\part{Two}
\blinddocument
\end{document}

enter image description here

esdd
  • 85,675
  • I think the OP wants this behavior only in the ToC. – karlkoeller Jan 19 '15 at 12:28
  • From his comment to the question: "As you can see in my MWE period after part number are suppressed in mainmatter." So I think he removes the dot not only for the figures but also for the parts in the mainmatter. – esdd Jan 19 '15 at 13:06
3

To remove the dots for all sectioning levels, write the following lines in your preamble

\makeatletter
\renewcommand*{\numberline@numberformat}[1]{\ifstr{#1}{}{}{#1}}
\ma‌​keatother

MWE

\documentclass{scrbook}
\usepackage{polyglossia}
%\usepackage{tocloft}
%\setmainlanguage{ukrainian}
\usepackage{etoolbox}
\renewcommand*{\figureformat}{%
  \figurename~\thefigure%
%  \autodot% DELETED
}

\makeatletter
\renewcommand*{\numberline@numberformat}[1]{\ifstr{#1}{}{}{#1}}
\makeatother

\begin{document}
\tableofcontents
\part{One}
\chapter{First}
\part{Two}
\chapter{Second}
\end{document} 

Output

enter image description here

karlkoeller
  • 124,410