This tutorial will help you make your first document by writing one page article in LaTeX using Gummi Editor part of our ongoing Gummi+LaTeX series in The Ubuntu Buzz. We intend this to students (and any other people) who begin their academic writings using LaTeX --the standard typesetting of academic world-- for their first time. Finally, you will also be able to download sample text below to make your exercise easier. Now let's start it!
Subscribe to UbuntuBuzz Telegram Channel to get article updates.
Download sample documents
We provide you here a sample text file for your exercise accompanied with final documents in zip so you can practice and then compare the results. If you cannot download these, find the copy of sample text at the end of this post.
How To Write LaTeX Document
1. Run Gummi.
2. Copy and paste sample text here to Gummi.
3. Save it as my-first-document.tex.
4. Edit text following four explanations below.
5. Document -> Compile (F9) to see preview of the document. If successful, beautiful document will show. If failed, an error message will show instead.
1. Upper part of the document
In the beginning of every document, there should be at minimum some initial lines of code like the following:
\documentclass{ }
\title{ }
\author{ }
Meaning of this code is to determine what kind of document we are making, what is the title, and who is the author. Now please edit the sample text as the following:
Before:
After:
2. Middle part of the document
In the middle or main part of the document, we begin to fill up our document like the following:
\begin{document}
\maketitle
\date
\section{ }
\section{ }
\section{ }
Meaning we determine where the content of document should start, show the title, show when the date the document is created, and create sections (headings). Now please edit the sample text as the following:
Before:
After:
Click Compile (F9) to see the preview.
3. Lower part of the document
In the end of document, or in the last line, there should be at minimum a closing code to pair with the begin code we put above like the following:
\end{document}
Meaning the code to mark the end of content of the document. However, because there are sections of text need to be formatted, please also format them like example above then put the ending code like the following:
Before:
After:
Click Compile (F9) to see the preview.
4. Adding bullets and numbering
Because there are bullets and numbering in our sample text, we ask, how do we make it? In LaTeX, we create bullets and numbering by the following lines of code:
\begin{enumerated}
\item ...
\item ...
\item ...
\end{enumerated}
Meaning just like the content of the document, a block of bullets and numbering is also written as a pair of \begin and \end lines of code in LaTeX. So please edit the sample text as the following:
Before:
After:
Click Compile (F9) to see the preview.
5. Full document, compiling and exporting to PDF
Now, our simple document is complete. The lines of code should look like the following. If we press Compile (F9), the preview should look like it too. To produce PDF, go to File -> Export to PDF (Ctrl+E) -> Save.
Final Result
Your document should look more or less like this. Congratulations for making your first LaTeX document! However, please notice that there are no outline (clickable titles to the left) yet when we view it on PDF viewer and no link can be clicked either. We will discuss that later in this series.
In the file manager, now you should have two files, one .tex and one .pdf like the following.
Notes
1. Actually, the action of compiling document is translating from .tex into .pdf by using program called pdflatex. Gummi made this work automatically behind the scene.
2. Learn that LaTeX automatically made many things in the document to make us focused to the content instead of formatting:
- Page margins
- Page number
- Heading number
- Spacing
- Font choice
We hope you enjoy this exercise!
Sample Text
Ubuntu
Ade Malsasa Akbar
April 6, 2025
What is Ubuntu?
Ubuntu is a general-purpose computer operating system developed by Canonical corporation from the United Kingdom since 2004 with wide support for multiple computer architectures from the smallest to the largest of them. Ubuntu is one of the most popular operating system as well as GNU/Linux distributions from the Free Software and Open Source community.
What are the components of Ubuntu?
Ubuntu is consisted of technologies as the following:
GNU operating system and Linux kernel
X window System (also known as XOrg)
GNOME desktop environment and applications
Package management system consisted of APT/DPKG derived from Debian and Snap from Canonical
and many more...
How to get Ubuntu?
One can purchase a computer preinstalled with Ubuntu from brands they trust. One can also download Ubuntu at no cost (gratis) and then install it on computer they have. Select your preinstalled computer and laptop from brands like HP, Dell, Lenovo, System76, Entroware, Star Labs and many more. Download Ubuntu from its official website https://www.ubuntu.com.
****
References
LaTex, Gummi and Ubuntu (in Indonesian) by Author
In This Series
<- Go back to "How To Install Gummi LaTeX Editor".
-> Go forward to "Document Structure in LaTeX (Sections, Paragraph)"
****
This article is licensed under CC BY-SA 3.0.