{formatting} is for general questions about formatting document elements. Use this tag in addition to other tags specifying what should be formatted. For questions about font attributes (e.g., {bold}, {italic}, {small-caps}, {sans-serif}, {typewriter}), use the appropriate tag instead.

learn more… | top users | synonyms

16
votes
3answers
19k views

How to format the chapter heading?

How can I change the chapter heading of the book class to typeset centered chapter names as shown in the image above?
34
votes
2answers
3k views

Why Different Commands for Seemingly Similar Tasks?

Take a look at the following list: \textit, \it, \emph, \itshape, \mathit \textbf, \bf, \bfseries, \mathbf ... One might say, for instance, that: \mathbf and \mathit are for math mode, while the ...
3
votes
1answer
494 views

makeindex page entries are all underlined

Set up an index for a book and everything works well, except the page numbers listed for the words in the Index are all underlined---EXCEPT when I add bold face, then they look fine. Any ideas what ...
25
votes
3answers
42k views

Change bullet style / formatting in Beamer

I like the Boadilla layout for Beamer presentations, but I find its enumerate bullet points illegible, as illustrated below (from the Beamer Theme Matrix). How can I change the formatting of the ...
4
votes
1answer
313 views

Adding a label on a margin (instead of line number) in latex algorithmic package

I would like to mark (e.g. with a *) a line in a pseudo-code typeset with the algorithmic package. I would like the label to appear on the left margin, instead of the line number. Is that possible? I ...
14
votes
4answers
1k views

Nice formatting for theorems

I'm writing an article with some theorems and I would like to use special formatting for the theorems - my idea is putting a grey line in the side of the theorem. Can you please show me how to do this ...
3
votes
1answer
772 views

Dynamic “expansion” of tikz calendar's cells?

Please, is that possible. Having started with this latex source, i would like to have calendar's cells "expandable" vertically -- please see the picture below. \documentclass{article} ...
6
votes
1answer
1k views

Inlining circuit symbols

in a prevois question i asked if there was a good way to display electronics symbols in TeX, i was pointed towards circuitikz (which is awsome), but is there a way to inline a symbol in text? eg. ...
5
votes
1answer
2k views

floatrow: Changing the formatting of table footnotes

The floatrow package, which is useful for customizing the layout of floats, also allows to add footnotes as well as additional explanations (besides the caption) to tables. (The main commands are ...
5
votes
4answers
7k views

Centering split equation

I am quite new to TeX. I want that each line in the following equation be centered, but I cannot find how to do it. \documentclass{article} \usepackage{amsmath} \begin{document} \begin{equation} ...
3
votes
1answer
1k views

Where should I setup the markup of header/footer? In \fancyxxx or in redefinition of \xxxmark?

\renewcommand{\chaptermark}[1]{\markboth{\chaptername\ \thechapter.\ #1}{}} \renewcommand{\sectionmark}[1]{\markright{\thesection\ #1}} \fancyhead[RO,LE]{\small\sf\color{black}\rightmark} ...
7
votes
2answers
10k views

Should Greek letters inserted in text (using math mode, mostly) always be italic?

The least painful way I know of inserting a Greek letter in a text is to use the math mode and the corresponding command. This will produce an alpha letter : $\alpha$ But this always produces an ...
7
votes
2answers
472 views

Looking for a specific BibTeX style

I am brand new to BibTeX, so I apologize if this question is painfully naive. Up until now, I have been manually creating my bibliography for each paper using the environment thebibliography. I'm ...
10
votes
1answer
689 views

How to mark book paragraphs as note, warning, tip etc.?

In my text I have some paragraphs that should be denoted as "note", "caution", "tip", "story". These paragraphs should be rendered with darker background and an icon on the left side. I was not able ...
62
votes
12answers
112k views

Make MS Word document look like it has been typeset in LaTeX

A few years back, I used to use LaTeX for writing reports and such, and I really liked the look of them. However, nowadays I am forced to use MS Word to write my reports, but that does not hinder me ...
21
votes
5answers
14k views

Changing style of Proof

I'm using the \begin{proof} of the amsthm package. And I want to change the style of the Proof word that is added in the beginning. By default it is italic, I want to make it bold. How can I do it?
2
votes
2answers
1k views

Stretch space characters horizontally

I'm using XeTeX to mimic another document, but I only have a similar font which I stretch using the extend and letterspace options. My main problem is though, that my font's spaces (U+0020) are only ...
37
votes
2answers
23k views

\bfseries is to \textbf as WHAT is to \textsf

Neither of \sfseries nor \sfshape seem to work. So what is the command I'm looking for to change the current group to sans serif? \bfseries, \scshape and \itshape work, but I can't find the sans serif ...
0
votes
2answers
586 views

Package for displaying source code [duplicate]

Possible Duplicate: How best to include programming source code in LaTeX documents? What is a good way to display program source like c++/lisp code in a latex document?
22
votes
6answers
3k views

Paragraph breaks with asterisks

In many books—mostly novels—often some paragraphs will have a blank line between them to indicate a sort of 'pause' in the narration. If one of these blank lines appears at the top or bottom of the ...
3
votes
2answers
2k views

Biblatex: Changing the font of citation-marks and the references?

In my main text I use a roman font with oldstyle figures In all tables I use the same roman font, but with modern figures. Since some of the columns may consist of mainly figures and it looks abit ...
13
votes
2answers
1k views

Conventions for formatting scientific units?

I would appreciate some guidance on how to format units that incorporate SI, molecules, and text. Right now I am formatting the letters in chemicals or names as 'text' and the SI units, sub/super ...
31
votes
2answers
4k views

What is the canonical way to redefine the \emph command

Question says it all. What is the best way to redefine the \emph command to be bold font and upright?
4
votes
3answers
743 views

Tex like formatting on blog posts

When I write reports for school I usually use an IEEE formatted LaTex document these days because I feel like it just looks so much better then anything I can seem to do in Word. I have a blog and ...
3
votes
1answer
715 views

How to achieve different formats for label and text in a subsection heading using titlesec

How to get a different formatting for the label and text of a subsection using titlesec? Reason: Italic numbers in the subsection heading hurts my eyes and should be avoided at all cost, Label of the ...
14
votes
2answers
2k views

Why couldn't (La)TeX's layout model be as simple as CSS's layout model?

I feel CSS's layout model is simpler than (La)TeX's layout model. At the time Knuth developed TeX, the idea leading to CSS model is a "difficult" things? Or the CSS layout model is not appropriate to ...
11
votes
3answers
4k views

How can I create a Chicago Manual of Style formatted document in LaTeX?

I have an assignment which requires me to use CMS formatting, double spaced, in 12pt font. I'd rather avoid using the much inferior "Word" or "Writer" programs -- in particular I like how LaTeX ...
26
votes
5answers
12k views

How to display numbers using comma as a thousands separator?

I want numbers like 5.5 million to be displayed using a comma as a thousands separator as "5,500,000". Is there a way to do this automatically, without having to manually put commas?
11
votes
3answers
2k views

bad formating of ff in math mode

I'm trying to write something like: $affinity(x)$, but in the PDF I see some small spacing between the two f's. I tried $af{}firm(x)$ or $aff{}irm(x)$, but nothing works.
2
votes
1answer
494 views

How do I combine formatted page numbers in an index

If I format page numbers in an index, they show up in addition to non-formatted numbers. This minimal example: \documentclass{article} \usepackage{makeidx} \makeindex \begin{document} page 1 ...
1
vote
1answer
346 views

Add paragraph styling only in certain sections

I am writing my Masters thesis in LaTeX. I'm using the university template which is quite complex so I haven't tweaked it much as I'm new to LaTeX. My problem is that the paragraph style here seems to ...
10
votes
1answer
1k views

Changing number format in ToC

I'm using the tocloft package to alter the looks of my table of contents, but there's one thing I can't find in the documentation: splitting the number by level, to insert other delimiters than ".". ...
2
votes
1answer
1k views

Custom .bst style and reformatting \cite entries

I have created a custom .bst file with makebst. I managed to reformat the thebibliography-environment entries look by editing the .bst file by hand. This wasn't a hard task. But, now I would like to ...
9
votes
2answers
17k views

Table of contents using article and report classes

When I make a table of contents with the article and report classes the results are different. I have two questions. Why does this happen? How can I make the report ToC look like the article one? ...
43
votes
3answers
11k views

When to use bold, italics, small caps, typewriter etc.?

I'm a little confused on the purposes of each kind of text in LaTeX. I know the function of some of them, but sometimes people use each for different reasons. For example: \texttt is for code (no ...
49
votes
4answers
24k views

Make first row of table all bold

I'm trying to do something that I thought would be relatively simple but seems to be quite hard. I have a table with a number of columns, and I'd like to make all of the titles appear in bold text. ...
84
votes
1answer
69k views

What's the correct use of \author when multiple authors?

Working on a project, the article we are writing is written by me and someone else. How should I fill the \author? What about \author{LASTNAME1, FIRSTNAME1 \& LASTNAME2, FIRSTNAME2}? It doesn't ...
15
votes
2answers
3k views

How do I fill a shape with text, like a circle?

How do I confine text within a shape such as a circle or triangle? I don't want text along the perimeter, I would like it to break appropriately at all the inner edges.
23
votes
2answers
5k views

How to type a Backus-Naur form in LaTeX

I need to type Backus-Naur form in LaTeX document. I found several packages on CTAN: ebnf seems to not work with TeXLive 2009 latex-bnf does not align the declaration, etc. There is a module for ...
88
votes
7answers
11k views

Prettiest way to typeset “C++” (cplusplus)?

Writing "C++" in plain text results in an ugly setting, as the '+' signs are too big and too spaced: I've seen around the web several marcos for typesetting the "C++" symbol, ranging from mild ...
131
votes
6answers
57k views

What's the quickest way to write “2nd” “3rd” etc in LaTeX?

If I want to use abbreviations for second, third and so on in my LaTeX documents, I am currently doing this: 2$^{nd}$ which seems unsatisfactory. Is there a macro I'm missing? I'm sure I could define ...
17
votes
2answers
4k views

Formatting a \paragraph to look like a \section

I'm writing a document that contains a rather deep tree of nested lists, and was wondering if how I would go about reformatting the \paragraph macro to format the text contained within it as a ...
7
votes
4answers
6k views

How to change the formatting/font of page numbers?

So, I'm using the article class, and I'd like to make the page number smaller, and set it in a different font. I don't need to create a new pagestyle, necessarily, and I'm hesitant to do so without ...
9
votes
2answers
2k views

Double strikeout

I'm using the ulem for strikethrough, but need two formats of strikethrough. I'm currently using \dout{text} which looks good, but the second\xout{text} makes the base text a little too unreadable. ...
3
votes
3answers
1k views

Eat space in a line break in \lstinline{}

I use the listings package. If a line break inside a multi-word \lstinline{} occurs, I get a nasty spaces at the beginning of the new line: page left page right | ...
13
votes
1answer
2k views

Typeset a dialogue?

I need to typeset a dialogue in LaTeX, it's for a translation assignment. The original dialogue does something like this: - I found it, I told him. My finger was in the book, where George Best's ...
12
votes
1answer
4k views

Caption is bold. Can I have part of it not bold?

What is the simplest way to have part of a bold caption (including some inline math) non-bold?
13
votes
6answers
3k views

Formatting arrows between rows of corresponding matrices

Some material I'm creating requires output that looks like this: (note the position of the arrows). I'm using the following code (with the AMS macros) to generate this, and I'm looking for ...
6
votes
2answers
2k views

Disable/toggle smallcaps in the title

I am using the amsart document class. I want to to change the text in the titles (such as in \author) to be written normally and not in small caps. How can I change this globally? That is, so that ...
8
votes
2answers
4k views

siunitx: aligning numbers by decimal points in tables doesn't work for bolded or italicized numbers

This is a follow-up question for Aligning numbers by decimal points in table columns. User lockstep provided this solution: \usepackage{siunitx} \begin{document} \begin{tabular}{S[table-format=3.2]} ...