LaTex入门:[2]源文件结构
1、\documentclass{...}这里是头文件,必须以这种命令开头指定文本类型,属性等
![LaTex入门:[2]源文件结构](https://exp-picture.cdn.bcebos.com/30601b6104a355e91cbce563d22ae3efe17868aa.jpg)
2、这个命令指定了你所写的文档的类别。在此之后,你可以加入控制文档式
样的命令,或者使用如下的命令来调入一些宏集
![LaTex入门:[2]源文件结构](https://exp-picture.cdn.bcebos.com/def72c6c576699cfab4122d7a885e036e3915eaa.jpg)
3、\usepackage{...}
当完成所有的设置后,你可利用如下的命令来开始你的文档:
\begin{document}
\end{document}
![LaTex入门:[2]源文件结构](https://exp-picture.cdn.bcebos.com/baab20863048614361c645858febf6a75e0f53aa.jpg)
4、一下是一个简单的例子:
\documentclass[a4paper,11pt]{article}
% define the title
\author{H.~Partl}
\title{Minimalism}
\begin{document}
% generates the title
\maketitle
% insert the table of contents
\tableofcontents
\section{Start}
Well, and here begins my lovely article.
\section{End}
\ldots{} and here it ends.
\end{document}
![LaTex入门:[2]源文件结构](https://exp-picture.cdn.bcebos.com/1d735518512c8cf119b52b87c384cde34a2c46aa.jpg)
5、小伙伴先不理解没关系,慢慢就好了,先把代码复制进去,跟着小编做就可以了,编译出来对比一下就懂了
![LaTex入门:[2]源文件结构](https://exp-picture.cdn.bcebos.com/57af657f860e7c752fe6f141650d3aceabd7bfaa.jpg)
6、效果如下图,编译完,dvi pdf就可以点了,编译之前是不能点这个的
![LaTex入门:[2]源文件结构](https://exp-picture.cdn.bcebos.com/732a12e265e7340fb76a199735b9763e20c2b4aa.jpg)
![LaTex入门:[2]源文件结构](https://exp-picture.cdn.bcebos.com/ba97ffd06de89a615a374c2745e8b004551badaa.jpg)
7、注意,\documentclass[a4paper,11pt]{article}的解释
![LaTex入门:[2]源文件结构](https://exp-picture.cdn.bcebos.com/d04eec260d9a310ef28be49e31b842406bfea2aa.jpg)
8、% define the title 其中 % 是注释,其他如下图
![LaTex入门:[2]源文件结构](https://exp-picture.cdn.bcebos.com/94af5fc1b727ac53f69a9c982ecadce8914899aa.jpg)
声明:本网站引用、摘录或转载内容仅供网站访问者交流或参考,不代表本站立场,如存在版权或非法内容,请联系站长删除,联系邮箱:site.kefu@qq.com。
阅读量:118
阅读量:34
阅读量:42
阅读量:29
阅读量:120