GeneralWhat Are "Packages"?

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
gremlint
Posts: 16
Joined: Tue Oct 09, 2012 6:04 am

What Are "Packages"?

Post by gremlint »

I have spent my whole day trying to learn this software. It's ridiculous. I have read two tutorials, and neither explains some basic terminology that I need to understand.

WHAT IS A "PACKAGE"?????

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

Stefan Kottwitz
Site Admin
Posts: 10347
Joined: Mon Mar 10, 2008 9:44 pm

What Are "Packages"?

Post by Stefan Kottwitz »

The TeX FAQ answers this and a lot of other frequently asked questions:
At this occasion, a small comment from a moderator: please write in a nice way, don't write whole words or sentences in capital letters, please respect the work of LaTeX developers who built the system which you now use for free.

Stefan
LaTeX.org admin
User avatar
nlct
Posts: 276
Joined: Thu Nov 06, 2008 11:15 am

What Are "Packages"?

Post by nlct »

Does this section help?

Regards
Nicola Talbot
User avatar
cgnieder
Site Moderator
Posts: 2000
Joined: Sat Apr 16, 2011 7:27 pm

What Are "Packages"?

Post by cgnieder »

A class is a file that has to be loaded at the beginning of a document by saying

Code: Select all

\documentclass{<class name>}
The class provides a basic layout and a basic set of available commands for usage in the document. How the layout looks and which commands are provided strongly depends on the chosen class. What most of them have in common are sectioning commands like \section and \subsection and basic floats like figure.

Common classes are the standard classes article, book, report and letter. Also well-known are the KOMA-Script equivalents scrarticl, scrbook, scrreprt and scrlttr2. Unlike the standard classes the KOMA classes have a rich set of options and possibilities to customize layout and stuff. They are described in detail in scrguien.pdf.

Another well-known class is memoir which is somewhat of a “all-in-one” class and has a detailed manual: memman.pdf.

A package can be seen as an “add-on” that extends the basic functionality of the LaTeX kernel. A package can consist of a single file or of a bunch of files. Its usage may be as simple as loading it ar provide loads of commands and options for a user. This strongly varies and one can't be more specific as there are over 1500 packages on CTAN and a complete LaTeX installation. All of them are loaded in the same way: via \usepackage{<package name>} in the document preamble, i.e., between \documentclass and \begin{document}.

Code: Select all

\documentclass{<class name>}
% preamble:
\usepackage{<package name>}
...
% document:
\begin{document}
...
\end{document}
A list of commonly by many people used packages can be found here.

Regards
site moderator & package author
gremlint
Posts: 16
Joined: Tue Oct 09, 2012 6:04 am

What Are "Packages"?

Post by gremlint »

Thank you for the replies, everyone. The pages from TeX FAQ and Dickimaw left me still confused ("TeX primitives"? "A model offering an abstraction"?), but the explanation from Clemens was good, and I think I'm beginning to understand.

For what it's worth, I would have voted to retain "style", instead of "class".

A glossary of terms for LaTeX would be quite helpful. I looked but did not find one.
User avatar
cgnieder
Site Moderator
Posts: 2000
Joined: Sat Apr 16, 2011 7:27 pm

What Are "Packages"?

Post by cgnieder »

gremlint wrote:For what it's worth, I would have voted to retain "style", instead of "class".
In the old times, i.e., before 1994 when LaTeX2e was released, the equivalents (in LaTeX 2.09) were indeed called styles. In order to maintain backwards compatibility as far as possible a new name was needed. So class it is...
gremlint wrote:A glossary of terms for LaTeX would be quite helpful. I looked but did not find one.
This comes close.

Regards
site moderator & package author
Post Reply