美文网首页
latex排版文档元素

latex排版文档元素

作者: 何同尘 | 来源:发表于2019-02-03 22:56 被阅读0次

    章节和目录

    \chapter{} 只在book和report文档类有定义
    \section{}
    \subsection{}
    \subsubsection{}
    \paragraph{}
    \subparagraph{}
    \part{}用于将整个文档分割为大的分块
    每个命令有两种变体
    \section[<short title>]{title}
    \section*{<title>} 标题不带编号
    titlesec宏包有更多的功能

    目录

    \tableofcontents
    \addcontentsline{}{}{}

    文档结构划分

    book 前言 正文 后记
    标题页
    \title{}
    \author{}
    \date{} 默认\today
    \maketitle
    ....

    交叉引用

    \label{<label-name>}
    \ref{} \pageref{}
    脚注
    \footnote{}

    特殊环境

    列表

    \begin{enumerate} \begin{itemize}
    \item
    \end{enumrate}
    关键字 begin{description} \item[关键字] \end{}

    对齐环境

    center,flushleft,flushright, 居中,左对齐,右对齐。
    使用命令 \centering \raggedright

    引用环境

    \begin{quote} 引用短文字,首行不缩进
    quotation
    verse 用于排版诗歌

    摘要环境

    abstract 在 article ,report 可用, 一般紧跟\maketitle

    代码环境

    verbatim* 带*将空格显示为图形
    \verb{<delim><code><delim>}
    宏包 verbatim{} \verbatiminput
    宏包 fancyvrb listings

    表格

    \begin{tabular}{lrcp{}|@{自定义}}
    \hline \cline{3-4}
    三线表 booktabs宏包 \toprule \midrule \bottomrule \cmidrule与\cline对应
    合并单元格 \multicolumn{n}{格式rclp}{内容}
    纵向合并 \multirow{}{宽度 *为自然宽度}{}
    拆分单元格 宏包makecell \makecell
    诸多知识,用的时候在查

    图片

    调用 graphicx宏包
    \ includegraphics[]{} 、graphicspath{{figure/}{logo/}}申明目录,使用不用写路径
    参数 width=<> height= <> scale=<> angle=<>

    盒子

    水平盒子 \mbox \makebox[10em][r]{}
    带框的水平盒子 \fbox \framebox[][]{}
    垂直盒子 \parbox[][对齐方式 t b c s分散]{宽度} begin{minipage}

    \rule 小黑盒子

    浮动体

    \begin{table or figure}[h t b p !]
    浮动体的标题 \caption{}
    \listoftables \listoffigures
    并排与自图表
    \begin{figure} \includegraphics[]{}
    使用minipage环境添加标题
    subfig宏包 \subfloat 命令

    相关文章

      网友评论

          本文标题:latex排版文档元素

          本文链接:https://www.haomeiwen.com/subject/phvusqtx.html