Skip to content

Commit ffe9832

Browse files
committed
fix: caption, itemize, and TOC font style
1 parent a67de1f commit ffe9832

File tree

1 file changed

+21
-6
lines changed

1 file changed

+21
-6
lines changed

style/styledef.tex

Lines changed: 21 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,8 @@
1616
\usepackage{color}
1717
\usepackage{etoolbox}
1818
\usepackage{caption} %修改图片表格名称字体字号的宏包
19+
\DeclareCaptionLabelSeparator{twospace}{\ ~}
20+
\captionsetup{labelsep=twospace}
1921
\usepackage{float} %自己设置图片插入位置
2022
\usepackage{fancyhdr} %设置页眉页脚的宏包
2123
\setlength{\headheight}{43pt}
@@ -24,7 +26,7 @@
2426
\usepackage{xcolor}
2527
\usepackage[colorlinks,linkcolor=black, citecolor=black, unicode={true}]{hyperref}
2628
\graphicspath{{figures/}} %%图片路径
27-
\usepackage[a4paper,top=4cm,bottom=3.8cm,left=3.3cm,right=1.8cm]{geometry} %设置页边距
29+
\usepackage[a4paper,top=4cm,bottom=3cm,left=3.3cm,right=1.8cm]{geometry} %设置页边距
2830

2931
\usepackage{fancybox} %画边界线
3032
\fancyput*(-0.8cm,-4.3cm){$|$}%
@@ -61,6 +63,17 @@
6163
\fancyput*(-0.8cm,-22.9cm){$|$}%
6264
\fancyput*(-0.8cm,-23.5cm){$|$}%
6365

66+
\floatstyle{plaintop}
67+
\restylefloat{table}
68+
69+
\usepackage{listing}
70+
\floatstyle{plain}
71+
\restylefloat{listing}
72+
73+
\usepackage{enumitem}
74+
\setlist[itemize]{labelindent=2em,leftmargin=*,itemsep=0pt,parsep=0pt}
75+
\setlist[enumerate]{labelindent=2em,leftmargin=*,itemsep=0pt,parsep=0pt}
76+
6477
%设置目录格式(引文部分)
6578
\usepackage[titles,subfigure]{tocloft}
6679
\newcounter{algoline}
@@ -75,10 +88,10 @@
7588

7689
\renewcommand{\cftdot}{$\cdot$}
7790
\renewcommand{\cftdotsep}{1}
78-
\setlength{\cftbeforesecskip}{15pt}
91+
\setlength{\cftbeforesecskip}{5pt}
7992
\setlength{\cftbeforesubsecskip}{3pt}
8093
\setlength{\cftbeforesubsubsecskip}{0pt}
81-
\renewcommand{\contentsname}{\zihao{4}\heiti 目录}
94+
\renewcommand{\contentsname}{\zihao{4}\heiti 目~~录}
8295
\renewcommand{\cftsecfont}{\heiti\zihao{5}}
8396
\renewcommand{\cftsubsecfont}{\heiti\zihao{5}}
8497
\renewcommand{\cftsubsubsecfont}{\heiti\zihao{5}}
@@ -93,9 +106,7 @@
93106

94107
\numberwithin{figure}{section}
95108
\numberwithin{table}{section}
96-
97-
\floatstyle{plaintop}
98-
\restylefloat{table}
109+
\setlength{\baselineskip}{18pt}
99110

100111
\newcommand{\xiaoer}{\fontsize{18pt}{18pt}\selectfont}
101112

@@ -201,3 +212,7 @@
201212
{\@latex@warning{Empty `thebibliography' environment}}%
202213
\endlist}
203214
\makeatother
215+
216+
\makeatletter
217+
\AtBeginDocument{\let\c@listing\c@figure}
218+
\makeatother

0 commit comments

Comments
 (0)