Most Popular

1500 questions
101
votes
5 answers

Custom first page with fancyhdr

I'm using the package fancyhdr to format my footers and headers, with my name in the header and a n of m pages format for the footer. Like so: \pagestyle{fancy} \fancyhf{} % clear all header and footer…
cara
101
votes
6 answers

Is there any reason to compile to DVI rather than PDF these days?

I appreciate that in the past, latex was faster than pdflatex, but computer speeds being what they are nowadays, I can't see any difference in how quickly documents compile... So, given that the end product I want is the PDF, are there good reasons…
Seamus
  • 73,242
101
votes
4 answers

How to add newline within node using TikZ?

I want to break the input of a path in order to draw pushdown automaton, so I tried to use the break line symbol \\ and even $$ $$, but it still doesn't break the lines. For example, the input should be 0, 1, 2 3, 4, 5 Any idea? Thank you. Code…
roxrook
  • 9,907
101
votes
3 answers

Start new chapter on same page

I am using report document class. When I create a new chapter, it starts it on a new blank page in which only the chapter name appears. I want to be able to start new chapters on the same page as the old chapter ends. Is there any way to do it?
prakashkut
  • 1,265
101
votes
7 answers

How to create small PDF files for the Internet

I feel that PDF documents when intended to be uploaded on the Internet should be of minimal final size in bytes. Many strategies exist to create such small documents: Pay attention to the size of the embedded raster images. Create diagrams with…
pluton
  • 16,421
101
votes
5 answers

vector arrow with superscript

I want to have a vector with a superscript: \vec{o}^t But this gives very bad results: the t is overlapping with the vector arrow. How do I fix this (and why does this give bad results in the first place) ?
Ben
  • 1,013
101
votes
2 answers

lstlisting line wrapping

How is it possible to let lstlisting wrap lines? I've troubles with following block: \begin{lstlisting}[language=java] public class MeasureStationControllerV0Test { MeasureStationControllerV0 controller; MeasureStation ms = new…
MemLeak
  • 1,247
  • 3
  • 10
  • 8
101
votes
3 answers

How to write (La)TeX (with parentheses) [or any other TeX-related logo]

I'm looking after a macro to write the (La)TeX logo (with parentheses), i.e. something similar to \TeX, \LaTeX, but where the output includes ()'s.
PHL
  • 7,555
100
votes
1 answer

How to center a specific caption?

I'm having a problem with centering my figure captions. Particuarly, I know that we can use \usepackage[justification=centering]{caption} to center captions, however, I'm interested in just centering a specific caption. I've read the caption manual…
100
votes
4 answers

Tikz - How to Draw Boxes Around Set of Nodes

How to draw the boxes as shown in the attached image? I could only manage to draw the chart but could not highlight the desired node / nodes with a rectangle box. Preferably dotted. I could not draw dotted in MS paint.…
Aku
  • 11,026
100
votes
3 answers

Summary of Tikz commands

Many times, when I'm coding a tikz-picture, I don't remember the command syntax or the name of one option, and I have to look in pgf-manual is not very short. Does anybody has a summary of Tikz commands fit to one or two pages?
100
votes
4 answers

Detecting unused packages in LaTeX document

I have quite a bad habit of copy-and-pasting my packages from one LaTeX document to another. Is there any way we can detect unused packages (i.e. \usepackage commands) so that they can be removed from the LaTeX document?
Bluemilk
  • 1,225
  • 2
  • 12
  • 10
100
votes
1 answer

How to write crossed-out math in LaTeX?

Possible Duplicate: Draw a diagonal arrow across an expression in a formula to show that it vanishes As you might know from my other questions, I am still a newbie at LaTeX, so please don't expect me to know anything. How would I write…
Zerium
  • 12,559
100
votes
1 answer

Cute (child-friendly) document in LaTeX

My girlfriend is teacher at primary school, she's new using LaTeX and she needs to make a "cute document" for kids, but I don't know how change the following items to make them look nice for the kids: parts, sections, page number/number of…
DaniTeba
  • 1,145
100
votes
10 answers

How to annotate PDF files generated by pdflatex?

I want to annotate some PDF files (created with pdflatex), e.g. word x is missing here this part of a sentence should be moved to the front replace word x by y highlight this sentence insert a note etc. The current Acrobat Reader has some…
maxschlepzig
  • 12,082