24

LaTeX has a unique style compared to other document formatting applications and style guides. What is the name of this and why was it chosen for LaTeX?

Why was the particular Computer Modern font chosen? Why does it use such large margins? Why was the header on the same line as the paragraph? More broadly, what we would call this style? (e.g., in contrast to MLA style, etc.) I'm asking specifically about the default style for article.

Basically what @clemens said,

But of course there is a default style which is common in the standard classes. (Layout, font, font size, margin sizes, ...

  • 4
    Welcome to TeX.SX! I don't think there is one unique style. We've got document classes fitted for special purposes – user31729 Oct 12 '15 at 19:03
  • 2
    Prof. Knuth wrote TeX and created the style for it, including used font. Then L. Lampert creates LaTeX, based on TeX, which allowed an easier usage. With using macros you can create own styles, today named document class. Theese document class defines the general layout, the style if you want. – Kurt Oct 12 '15 at 19:08
  • 4
    It would be helpful, in terms of raising the odds of getting focused answers to your query, if you clarified what exactly you mean by "style". – Mico Oct 12 '15 at 19:35
  • 2
    Andrew sort of answered the font part -- it is the default font in TeX which LaTeX is built on. For the margins: Why are default LaTeX margins so big? I don't really understand what you mean by "header on the same line as the paragraph", unless you're talking about the lowest sectioning levels (\paragraph{} and \subparagraph{}). – Torbjørn T. Oct 12 '15 at 20:37
  • 1
    The margins are not excessive if you send those pages to the printer (the person who prints) directly. – percusse Oct 12 '15 at 21:32
41

If you make a LaTeX document without using many packages and without altering other defaults, then the style of the document is largely determined by two factors: the default font designed by Donald Knuth, and the default layout of the standard document classes designed by Leslie Lamport.

The Font

The default font is Computer Modern, designed by Donald Knuth. It is a computer version of the "modern" style typeface that was used in the first editions of his book The Art of Computer Programming. Knuth created TeX with the primary goal of using the computer to typeset this book.

Page Layout, Margins, Headings, etc.

The basic LaTeX document classes were designed by Leslie Lamport, based on then-common conventions for scientific publishing. For example, the large default margins in the article class are intended for use by academic journals, which have a narrow type block, and would trim down the page to fit their format.

These core classes have most of the style elements hard-coded into them, meaning that the style decisions cannot easily be modified by the user. This was because of the memory restrictions of computers at the time. Now we can use packages to alter these values, or we can use alternate classes that make it easier to customize.

Paragraph Shape, Character Spacing, Kerning, etc.

A third factor that shapes the overall look of any LaTeX document is the unsurpassed algorithm for building lines, paragraphs, and pages, used in the core TeX typesetting program written by Donald Knuth. This central feature of the TeX program controls the distribution of words on the page, which creates what designers call the "grayness" of the page. Some people claim to be able to recognize TeX-produced documents based on this alone.

Going Beyond the Defaults

If you use a different font package (try ebgaramond or newpxtext or gillius for example) the look will change dramatically. If you use a non-standard document class (beamer, memoir, the KOMA-script classes) or customize the standard ones by using packages like geometry, or write your own class, you can have any page layout and style you want.

You can also use an alternate format, ConTeXt, which provides its own interface for customizing the layout.

Or you can use Knuth's original Plain TeX format, though this requires you to write almost all the formatting code yourself, down to exactly how much stretchable space to insert after a section heading or in front of a bullet point.

Donald Knuth typeset the later editions of The Art of Computer Programming using his own macro package for Plain TeX, and if you look at that book you'll see his stylistic preferences are rather different from those of the default LaTeX classes, such as using sans-serif font for headings and slanted type for book titles.

  • "The large default margins in the article class are intended for use by academic journals, which have a narrow type block, and would trim down the page to fit their format." — I don't know if that's true, otherwise there wouldn't be separate designs for letter size and A4 paper. My (anecdotal) understanding is that when typesetting single column single spaced text, you Just Don't extend the lines too far. Optimal line length for readability and all that. It's not LaTeX's fault that letter and A4 are poor page sizes for good typesetting. – Will Robertson Oct 14 '15 at 8:46
  • @WillRobertson I thought it was a combination of the two: journals use a narrow type block for readability reasons (and just because they have always done so), and the LaTeX article format gives a narrow type block, which has aesthetic and functional values of its own, while allowing room for the pages to be trimmed down for journal publishing. The linked question on LaTeX's wide margins includes a healthy debate about this, though the consensus seemed to be that the publishing page size (smaller than letter or A4) was the most important factor. – musarithmia Oct 14 '15 at 13:16
  • @barbarabeeton Can you confirm about the relationship between the standard classes and publishers' requirements? – musarithmia Oct 14 '15 at 21:34
17

In LaTeX there is no unique style -- we've got collection of macros based on the LaTeX core (which itself uses the primitives of TeX, originally developed by D.E. Knuth in the late 70s/early 80s -- Mr. Knuth also provided the cm fonts)

About 1985 Leslie Lamport developed LaTeX as macro package based on the not very easy usage of Knuth's TeX language (My personal view). He aimed to simplify often used document settings (margins, chapters etc, title pages etc.) in bunch of (many ;-)) LaTeX commands. He was definitely guided (as well as others (still) contributing to LaTeX) by good typography design which commanded some settings.

Nowadays we use \documentclass as the 'style' for a particular purposes and macro packages which add some functionality or change the style too.

There are some settings in latex.ltx (the core of LaTeX) and the base classes do have .clo files (class option files) where the bootstrap settings are stored.

Since some of the standard classes (see below) use the article.cls as bootstrap (via \LoadClass{article}) the settings in article.cls propagate to other classes as well.

However -- we can basically change anything (with some exceptions).

Very often used document classes are

  • article
  • book
  • report

  • letter

Those are called standard document classes because they are provided with any LaTeX distribution in the base directory.

Other people provided further classes such as

  • memoir
  • The KOMA equivalent of the article, book and report
  • beamer for making screen presentations (but handouts too)

Publishers, magazines etc. often have a class of their own which fits their needs.

Edit The question changed a little bit after I answered it -- so either I have to change my answer too or I keep it. I'll keep it.

Edit 2: I've decided to undelete it.

  • 1
    But of course there is a default style which is common in the standard classes. (Layout, font, font size, margin sizes, …) The question is what the OP means by »style«. Then one can maybe answer why the default values are how they are. – clemens Oct 12 '15 at 19:22
  • 1
    @clemens: Yes and no: The settings of latex.ltx and the .clo files propagate through article.cls and thereby to the other classes as well. I would call them bootstrap settings, but not default style – user31729 Oct 12 '15 at 19:26
  • 1
    letter was in the wrong position, true, but do you have ever used slides? ;-) – user31729 Oct 12 '15 at 19:32
  • 2
    @ChristianHupfer you can immediately recognize any document created with LaTeX's whatever you call them (I find default style quite suitable). However, I find the question so very unclear that it's not worth arguing about names – clemens Oct 12 '15 at 19:35
  • 1
    @clemens: I did not intend to argue... different viewing angles ;-) – user31729 Oct 12 '15 at 19:39

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.