【问题标题】:Spacing between label and sectiontitle标签和章节标题之间的间距
【发布时间】:2021-05-13 03:27:29
【问题描述】:

我想更改标签和章节标题之间的间距。现在我正在使用titlesecscrartcl,但有警告。我猜是因为titlesec KOMA-script 有一些问题。

所以我想通过使用 KOMA-Script 命令来创建相同的内容。你有什么想法吗?

\documentclass[pdftex,a4paper]{scrartcl}
\usepackage{titlesec}

\titleformat{\section}[hang]
{\normalfont\bfseries}{\thesection}{1cm}{}


\titleformat{\subsection}[hang]
{\normalfont\bfseries}{\thesubsection}{3cm}{}

\titleformat{\subsubsection}[hang]
{\normalfont\bfseries}{\thesubsubsection}{5cm}{}

\begin{document}

\section{Ein erster Abschnitt}
\subsection{Unterabschnitt}
\subsubsection{Unter-Unterabschnitt}

\end{document}

Warnings

Output document

【问题讨论】:

    标签: latex overleaf


    【解决方案1】:

    快速破解:

    \documentclass[
    %pdftex,
    a4paper]{scrartcl}
    
    \renewcommand*{\sectionformat}{\thesection\autodot\enskip\hspace{2cm}}
    \renewcommand*{\subsectionformat}{\thesubsection\autodot\enskip\hspace{2cm}} 
    \renewcommand*{\subsubsectionformat}{\thesubsubsection\autodot\enskip\hspace{2cm}}
    
    \begin{document}
    
    \section{Ein erster Abschnitt}
    \subsection{Unterabschnitt}
    \subsubsection{Unter-Unterabschnitt}
    
    \end{document}
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2022-11-10
      • 1970-01-01
      • 2014-05-09
      • 2018-10-14
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多