Hello hello, welcome again, in the last post we have talked about how to compile the document and set the language, today I am going to give you a brief introduction to the structure of the document, the special characters, and some instructions to create paragraphs
Types of documents
In the last posts, I told you:
There are many types of documents in the LaTeX world
Of course, we are not going to cover every single type of document
The type of document must be in the
\documentclass
option
- If you have forgotten that, you can check it here
The type of document is the structure that your document will have, this also determines what kind of commands you could use to give it the desired structure, and I explain this in the body of this document. You could be asking: What does he mean with the structure? thanks for ask that.
- In LaTeX documents, like a normal book you can create an index, a table of contents, there are some commands, like
\chapter
or\section
that when you put that LaTeX recognize them and then it classifies those in the table of contents
And I am going to tell you what you can use where
Book
I think these are self-explanatory, but if not, these document structures are used to create books and reports, you can use \part
, \chapter
, \section
, \subsection
, \subsubsection
- Remember that the name of the section must be in curly braces
\section{nameOfYourSection}
Article
You use this when you want to create an article or a document simpler than a book, you just can use \section
, \subsection
, \subsubsection
Remember
Book and Article are common types of documents, of course, there are other differences between these types of documents, not just the commands. I encourage you to explore them, you do not need more commands, in both, those commands are enough to notice the differences
A tip
If you do not want that your chapter or subsection or any type of label that I just wrote is numbered, you just need to add *
before the curly brace, for example, \section*{mySection}
The Paragraphs
You can create a new paragraph in many ways,
Paragraph and subparagraph
These are useful commands, these create a new paragraph with bold text,
-
\paragraph{textInBold}
is aligned according with your document -
\subparagraph{textInBold}
has an extra space, like if it were inside the text
Other commands
- We denote a paragraph ending with
\\
, we can put more than one to create more space The output is Sometimes we can not create a line skip with\\
, an alternative is\par
- We create a new indented paragraph with
\par
, to avoid it we must put\par\noindent
or we can set the size of the space with\par\parindent=Xmm
The output is
Did you notice? the first and the second paragraph are at the same level, that is because the first paragraph always is indented, however, the third paragraph has not indentation and you can compare
Thanks, this is all for today, do not forget and follow me in @latexteada
See you :)
Top comments (0)