Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

修改目录样式 #7

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@
- 修改了原创性声明的格式,与官方保持一致。

- 其它大量的细节优化和 模板文件(`.cls`)注释添加

- 修改了目录样式,但是请注意没有为四级标题添加匹配(也不符合南邮规范)

## 运行环境

Expand Down
Binary file modified main.pdf
Binary file not shown.
22 changes: 15 additions & 7 deletions njupthesis.cls
Original file line number Diff line number Diff line change
Expand Up @@ -541,14 +541,22 @@
}

% 目录页设置
% TODO 修改目录
\newcommand{\thesistableofcontents}{
% \titlecontents{chapter}[4em]{\bfseries \zihao{5} \vspace{10pt}}{\contentslabel{4em}}{\hspace*{-4em}}{~\titlerule*[0.6pc]{$.$}~\contentspage}
% \titlecontents{section}[4em]{\bfseries \zihao{5} \vspace{10pt}}{\contentslabel{4em}}{\hspace*{-4em}}{~\titlerule*[0.6pc]{$.$}~\contentspage}
% \titlecontents{subsection}[4em]{\zihao{5}}{\contentslabel{2em}}{\hspace*{-2em}}{~\titlerule*[0.6pc]{$.$}~\contentspage}
\pdfbookmark{目录}{toc}
\tableofcontents
\thispagestyle{empty}
\setlength{\cftchapindent}{0pt} % 设置章标题的缩进
\setlength{\cftsecindent}{12pt} % 设置节标题的缩进为1个汉字字符
\setlength{\cftsubsecindent}{24pt} % 设置小节标题的缩进2个汉字字符


% 设置目录项目之间的距离为1.25倍行距
\setlength{\cftbeforechapskip}{3.5pt}
\setlength{\cftbeforesecskip}{3pt}
\setlength{\cftbeforesubsecskip}{3pt}
% 设置章节后两个半角空格(共4个汉字字符距离)
\setlength{\cftchapnumwidth}{56pt}

\pdfbookmark{目录}{toc}
\tableofcontents
\thispagestyle{empty}
}

% 章节名重构
Expand Down