Most Popular
1500 questions
89
votes
1 answer
Automated management of package options and loading order
This question led to a new package:
pkgloader(CTAN, Github)
LaTeX package conflicts are a common source of frustration: (1) (2) (3) (4) (5) (6). To quote Freek Dijkstra:
Package conflicts in LaTeX are a hell.
I've been looking around, but I…
mhelvens
- 6,126
89
votes
4 answers
include svg images with the svg package
I'm trying to use the svg package for inserting svg images in my latex file, as suggested in other questions. But now I ran into a problem:
For example I have a image figure1.svg, if I write
\includesvg{figure1}
it will give an error says
ERROR:…
LWZ
- 2,972
89
votes
2 answers
Reference to a listing returns wrong number
I'm using the following code to create a listing with sourcecode:
\begin{lstlisting}[caption={caption_text}\label{lst:a_label},language=Java]
// Code...
\end{lstlisting}
Unfortunately, a \ref{lst:a_label} somewhere in my text does not return the…
alapeno
- 993
89
votes
1 answer
On the basics of writing to & reading from auxiliary files (.aux, .toc, etc.)
Some actions (such as generating the Table of Contents) require two passes of the TeX compiler: during the first pass, some data get written to an auxiliary file, only to be retrieved during the second pass. Here are a few TeX.SE questions that…
jub0bs
- 58,916
89
votes
13 answers
What are the advantages of using version control (git, etc.) in LaTeX documents
Why would I need to use version control with my LaTeX documents? I know people who do it, and I've seen questions about it on here and on SO, but I haven't understood what value there is to doing it...
[Maybe this should be CW?]
Seamus
- 73,242
88
votes
5 answers
How to reduce space between image and its caption?
I m importing one image in latex document. But caption has bigger font than my normal text on page.
\documentclass{article}
\usepackage{graphicx}
\begin{document}
Some text...
\begin{figure}[htb]
\begin{center}
…
manish
- 9,111
88
votes
3 answers
How to merge cells vertically
Is it possible to create a table like this one?
The usual structure of tables I use looks like this:
\begin{table}[H]
\begin{adjustbox}{width=\textwidth,center}
% \begin{adjustbox}{center}
\begin{tabular}{lll}
\hline
…
eualin
- 1,335
88
votes
3 answers
Hatch a rectangle in TikZ
I know how to make a rectangle and fill it.
But what shoud be done to hatch this rectangle with thin 45 degree inclined line with 2mm gap.
\documentclass{article}
\usepackage{tikz}
\begin{document}
\begin{tikzpicture}
%\draw (0,0) rectangle…
sandu
- 7,950
88
votes
2 answers
Recalling a theorem
Suppose I have some theorem in the paper
Section 1
Theorem 1.1. Let ...
And then later in the paper I want to recall the theorem by reprinting it
Section 4
We recall Theorem 1.1:
Theorem 1.1. Let ...
What's the proper way to do this?
Y Zhao
- 983
88
votes
5 answers
How to break a line in a table
Possible Duplicate:
How to add a forced line break inside a table cell
In a table I would like to have a line break in the text inside a cell. Is there an easy way to do so, or do I have to create a new line without borders? The same holds true…
damusnet
- 1,317
- 2
- 12
- 11
88
votes
7 answers
How do I left-align entries in a matrix with \begin{matrix}?
I'd like to left align the -1 entry in the following matrix so that the 1s line up. Is there a way to get matrices to ignore signs in that way?
\begin{matrix}
1 & 1 \\
1 & -1 \\
\end{matrix}
Using \flushright{-1} doesn't seem to work.
Will
- 3,681
- 4
- 23
- 24
88
votes
3 answers
Which package can be used to draw automata?
I'm looking for a LaTeX package which helps drawing automata problems. I googled and found A package for drawing automata and graphs (Version 0.4). But I'm not sure is this package a standard one, or there are some better alternatives. Any…
roxrook
- 9,907
88
votes
3 answers
How to insert 4 digit year that shows up in \today?
Using the LaTeX command \today, I can insert the current date. Is there any way to insert the current year with a simple command? All I want is the simple 4 digit year that shows up in \today.
Amandasaurus
- 2,501
- 3
- 14
- 9
88
votes
4 answers
How to format an inline source code
I have a document where I quiet often refer to source code element, such as class names, I wanted to format these strings differently, but at the beginning I didn't want to fiddle with various options I had, rather I defined my custom command as…
Steves
- 1,013
88
votes
4 answers
How to insert pipe symbol in (La)TeX?
How to insert pipe symbol | in TeX (LaTeX)?
I have tried this sample with pdflatex tmp.tex
\documentclass{extarticle}
\begin{document}
\textpipe
\end{document}
And it give undefined control sequence error
This is pdfTeX, Version 3.1415926-1.40.10…
avsej
- 1,205