latex 课程论文模板

latex 课程论文模板
latex 课程论文模板

在网上有很多LATEX模板,但大多是重量级的,主要用于写毕业论文,对于写课程论文不太方便。我搜集了网上的一些方法,自己写了一个配置文件,虽然很简单,但对于写一般的课程论文已经足够了。我的配置文件包含以下功能:

1、增加页眉

2、设定段与段之间的距离

3、增加 \makeak 命令用于产生摘要和关键字部分

=====包文件 package.tex =========

\usepackage{indentfirst}

\usepackage{CJK}

\usepackage[%

paper=a4paper,

vmargin={3.8cm, 3.8cm}

body={14.6true cm, 22true cm}

]{geometry}

\usepackage{fancyhdr}

\usepackage{color}

\usepackage{CJKpunct}

\usepackage{listings}

======配置文件 format.tex =========

\newcommand{\chuhao}{\fontsize{42pt}{\baselineskip}\selectfont}

\newcommand{\yihao}{\fontsize{28pt}{\baselineskip}\selectfont}

\newcommand{\erhao}{\fontsize{21pt}{\baselineskip}\selectfont}

\newcommand{\sanhao}{\fontsize{15.75pt}{\baselineskip}\selectfont}

\newcommand{\sihao}{\fontsize{14pt}{\baselineskip}\selectfont} \newcommand{\wuhao}{\fontsize{10pt}{\baselineskip}\selectfont}

\newcommand{\song}{\CJKfamily{song}}

\newcommand{\zhuan}{\CJKfamily{zhuan}}

\newcommand{\li}{\CJKfamily{li}}

\newcommand{\hei}{\CJKfamily{hei}}

\setlength{\parskip}{1.5ex plus 0.3ex minus 0.2ex}

\pagestyle{fancy}

\fancyhead{}

\chead{\wuhao\textnormal\leftmark}

\cfoot{--\thepage--}

% \renewcommand{\headrulewidth}{0.4pt}

% \renewcommand{\footrulewidth}{0.4pt}

\renewcommand{\sectionmark}[1]{%

\markboth{#1}{}

}

\makeatletter

\def\cabs#1{\def\@cabs{#1}}\def\@cabs{}

\def\ckey#1{\def\@ckey{#1}}\def\@ckey{}

\def\makeak{%

\noindent{摘要:}\@cabs\\[0.5em] \noindent{关键字:}\@ckey

}

\makeatother

========例子 test.tex ========

\documentclass[a4paper, 12pt]{article} \input{package.tex}

\input{format.tex}

\begin{document}

\begin{CJK*}{UTF8}{song}

\title{A test document}

\author{abc}

\maketitle

\cabs{这是摘要}

\ckey{这是关键字}

\makeak %生成摘要、关键字

相关主题
相关文档
最新文档