장 스타일과 제목 모두 사용자 정의

장 스타일과 제목 모두 사용자 정의

저는 회고록을 사용하고 있어요. 다음과 같은 기본 설정을 사용합니다.

\makechapterstyle{chappell2}{%
\setlength{\beforechapskip}{-15pt}
\renewcommand*{\chapnamefont}{\large}

\renewcommand*{\printchapternum}{\chapnumfont \Large \thechapter }
\renewcommand*{\chaptitlefont}{\Large\bfseries}
\renewcommand*{\printchaptertitle}[1]{%
%\vskip\onelineskip 
\chaptitlefont ##1}}

\makechapterstyle{mystyle}{%
    \chapterstyle{default}
    \renewcommand{\printchaptername}{}
    \renewcommand{\chapternamenum}{}
    \renewcommand{\chapnumfont}{\normalfont\bfseries}
    \renewcommand{\printchapternum}{}%\chapnumfont \thechapter\space}
    \renewcommand{\afterchapternum}{}
    \renewcommand*{\printchapternum}{%
    \@hangfrom{\chapnumfont \thechapter\quad}}%
}
%\nouppercaseheads

\chapterstyle{chappell2}
\renewcommand\thechapter{Capitolo \arabic{chapter}}
\renewcommand\thesection{\arabic{section}}
\renewcommand\thesubsection{\thesection.\arabic{subsection}}
\renewcommand\thesubsubsection{\thesubsection\arabic{subsubsection}}

나는 이것을 얻습니다 :

여기에 이미지 설명을 입력하세요

여기에 이미지 설명을 입력하세요

"Capitolo 2"라는 제목에만 인쇄하고 싶습니다. 내가 어떻게 해? 죄송합니다. 저는 라텍스 전문가가 아닙니다.

답변1

\documentclass...에서 까지 시작해야 하는 컴파일 가능한 예제를 제공하지 않았습니다 \end{document}. 필요한 코드를 추가했을 때 귀하가 제공한 내용은 그래픽에 표시된 내용을 생성하지 못했습니다.

나는 최선을 다했고 이것이 당신에게 적합할 것이라고 생각합니다.

\documentclass{memoir}
\usepackage{lipsum}

\renewcommand{\chaptername}{Capitolo}  % change chapter name
\renewcommand{\chapterrefname}{Capitolo} % change chapter reference name  
\makechapterstyle{chappell2}{%
\setlength{\beforechapskip}{-15pt}
%\renewcommand*{\chapnamefont}{\large}
\renewcommand*{\chapnamefont}{\Large\bfseries} % to match the chapter number

\renewcommand*{\printchapternum}{\chapnumfont \Large \thechapter }
\renewcommand*{\chaptitlefont}{\Large\bfseries}
\renewcommand*{\printchaptertitle}[1]{%
%\vskip\onelineskip 
\chaptitlefont ##1}}

%\nouppercaseheads

\chapterstyle{chappell2}
%\renewcommand\thechapter{Capitolo \arabic{chapter}}
\renewcommand\thesection{\arabic{section}}
\renewcommand\thesubsection{\thesection.\arabic{subsection}}
\renewcommand\thesubsubsection{\thesubsection\arabic{subsubsection}}

\begin{document}

\frontmatter
\tableofcontents
\mainmatter
\chapter{INFORMAZIONI}
\lipsum[1]
\section{First section}
\lipsum
\chapter{ANOTHER}
\lipsum[2]
\end{document}

챕터 스타일 을 정의했지만 mystyle사용하지 않았습니다. 왜?

관련 정보