Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

When working with large documents, or even across multiple (smaller) documents, I often find that I forget which typographical consistencies I should stick to.

With TeX being inherently consistent in the way it does things, most things are kept organized without the user even knowing about it. Additionally, using a customized documentclass (like memoir, for example) or packages (like xspace and titlesec, to name two) improves on this consistency by user's choice. Sometimes, however, you are left to your own devices and have to do things manually. Of course, the latter could also stem from not knowing that a package exists to do the job for you, or because you'd rather have more control over the placement/use of a certain things without having it automated or globally set.

To this extent, I though this would be a good place to ask the question: "Which tools/techniques do you use to maintain consistency within your document?"

Sure, the question sounds broad. Many answers are scattered across this site and elsewhere (like the Chicago Manual of Style or Bringhurst's Elements of Typographic Style). I was hoping to contain this diverse knowledge base in one location on TeX.SX (similar to what was done for Showcase of beautiful typography done in TeX & friends and LaTeX IDEs).

Here are some examples of useful (manual) tips/tricks:

  • The TeX Book mentions (p 25) the use of ties (~) in the context of Thor's "A SHORT STORY" when typesetting Mr.~Drofnats:

    A good typist will use ties within names...

  • \emph or \textit provides a good example of when/why to use either \emph or \textit.

  • The contents of DO’s and DON’Ts when typesetting a document has some very relevant manual application of consistencies, including:

    • Put a tilde before references or citations, e.g., Jie~\cite{habit06}.
    • Differentiate between text comma and math comma, e.g., type for $x=a$, $b$, or~$c$ instead of for $x=a,b$, or $c$.
    • Write ellipsis using \ldots instead of three dots.
  • The l2tabu documentation also provides an interesting list of "do's and dont's".

Any more?

share|improve this question
15  
Define commands for common structures; even if keywords will be typeset with \textsf, better define \newcommand\keyword{\textsf}. Similarly, define environments for common logical units that might deserve particular typographical treatment. –  egreg Sep 28 '11 at 22:16
4  
@egreg: I would suggest turning this into an answer. –  Werner Sep 28 '11 at 22:41
    
I'm assuming that the note about citations only applies if you are not using footnote citations, which you want to come right after the word? Or am I missing something? –  Canageek Sep 28 '11 at 22:45
    
@Canageek: I would think so, otherwise it would probably have used \footcite. –  Werner Sep 29 '11 at 5:02
    
A somewhat related question: Best practices references –  Werner Oct 7 '11 at 23:30
show 1 more comment

3 Answers

up vote 76 down vote accepted

Define commands for common structures; for instance, even if keywords will be typeset with \textsf, it's better to define

\newcommand\keyword{\textsf}

and use \keyword{mykey}. This not only adds visual clues when writing and reading the TeX document, but makes possible to change the typographical aspect at once everywhere.

Similarly, define environments for common logical units that might deserve particular typographical treatment.

Put structured comments around things like \enlargethispage or \pagebreak used during the final revision (which often turns out not to be really definitive). Make liberal use of comments in general.

share|improve this answer
3  
+1 for suggesting making "liberal use of comments in general". :-) –  Mico Oct 4 '11 at 10:59
3  
Thanks @egreg for "consistently" delivering valuable answers! –  Werner Dec 23 '11 at 6:10
    
Why would you use \newcommand\keyword{\textsf} instead of \let\keyword=\textsf? The \let variant leads to the same result (?) and doesn't need to be expanded on every occurence. –  Henri Menke Mar 23 at 16:36
    
@HenriMenke There are two reasons: first, \newcommand is documented in the manual, \let isn't; second, if you change meaning to \textsf also \keyword will follow it. –  egreg Mar 23 at 16:37
add comment

There are some situations in spacing, where the author has to make TeX/LaTeX aware of an exception. Make a difference between 'full stop' and 'full stop after an abbreviation' as in this example:

I like BASIC\@. What about you?

The \@ enforces end-of-sentence period even if the precedent character was a capital letter, it is not part of an acronym. Also, I usually set a fixed space between the number and the unit, when a quantity is given, e.g.:

switching frequency of 1\ MHz

\ inserts a space that cannot be stretched.

share|improve this answer
26  
I prefer using siuntix for typesetting numbers, eg. \SI{1}{\mega\hertz}. That makes it easier to change the style global and consistent. –  Tobi Sep 30 '11 at 12:51
1  
@Tobi: wasn't aware of that package... good idea! :) –  Count Zero Sep 30 '11 at 12:55
9  
@CountZero: Note that a space inserted with \ can be stretched and shrunk. –  mhp Sep 30 '11 at 18:38
    
@mhp: That's really a surprise for me... I'm quoting from The Not So Short Introduction to LATEX2e: 'A backslash in front of a space generates a space that will not be enlarged' –  Count Zero Oct 1 '11 at 9:05
3  
@mhp: Thanks, you're right about that one --- still, I don't really understand this. I'll rather post it as a question, so this page will not be cluttered with comments. –  Count Zero Oct 1 '11 at 21:45
show 3 more comments

For ellipses, do not only use \ldots, but also load the ellipsis package. Package description:

This is a simple package that fixes a problem in the way LaTeX handles ellipses: it always puts a tiny bit more space after \dots in text mode than before it, which results in the ellipsis being off-center when used between two words.

\documentclass{article}

% \usepackage{ellipsis}% Remove comment sign and compare

\begin{document}

\Huge

Some text \ldots\ and some more.

\end{document}

Note that ellipsis must be loaded after hyperref. (The ellipsis documentation doesn't mention this, but the hyperref README does.)

share|improve this answer
2  
Also if you use the ellipsis package and want square brackets around the dots you should load the package with the mla option as in \usepackage[mla]{ellipsis}. –  N.N. Sep 29 '11 at 7:15
3  
I prefer another way: use the Unicode ellipsis character '…' (but not in math mode). This ellipsis is just as the font designer wanted, not artificially generated, and this makes text look a bit more consistent. One also can set up a proper sfcode for this character, if using \nonfrenchspacing. –  Andrey Vihrov Sep 29 '11 at 7:32
    
Why do you need to force a space with \ after \ldots? Can you elaborate on that? –  adn Dec 8 '11 at 4:43
    
I know this is a bit old, but: doesn't the ellipsis package provide (or redefine) the \dots command? Why are you then talking about \ldots? Are they somehow related? –  mSSM May 17 '12 at 16:39
    
@mSSM From the LaTeX kernel: \let\ldots\dots. Perhaps I'll include a hint about this in my answer. –  lockstep May 17 '12 at 16:44
show 1 more comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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