-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathdemo-figures.tex
91 lines (75 loc) · 2.52 KB
/
demo-figures.tex
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
%
% demo-figures.tex 2009-10-30 Mark Senn http://engineering.purdue.edu/~mark
%
% Demonstrate how to do figures.
%
\chapter{Demonstrate Figures}
The
\verb+h+
specifier used in all the examples below
tells \LaTeX\ to put the figure
``here''
instead of trying
to find a good spot
at the top or bottom of a page.
Specifiers can be combined, for example,
``\verb+\begin{figure}[htbp!]+''.
The complete list of specifiers:
\begin{center}
\renewcommand{\baselinestretch}{1}\normalsize
\begin{tabular}{ll}
\bf Specifier& \bf Description\cr
\tt b& bottom of page\cr
\tt h& here on page\cr
\tt p& on separate page of figures\cr
\tt t& top of page\cr
\tt !& try hard to put figure as early as possible\cr
\end{tabular}
\end{center}
Label ``fi:not-centered'' is ``\ref{fi:not-centered}''.
Label ``sf:four-parts-c'' is ``\ref{sf:four-parts-c}''.
\Repeat{This is the first paragraph.}{5}
\begin{figure}[h]
\includegraphics{plot.eps}
\caption{%
By default figures are not centered.
This is a long caption to demonstrate that captions are single spaced.
}
\label{fi:not-centered}
\end{figure}
\Repeat{This is the second paragraph.}{10}
\begin{figure}[h]
\centering
\includegraphics{plot.eps}
\caption{Use {\tt \char'134centering\/} to center figures.}
\label{fi:centered}
\end{figure}
\Repeat{This is the third paragraph.}{15}
\begin{figure}[h]
\centering
\includegraphics{plot.eps}
\caption{This is another figuure.}
\label{fi:another}
\end{figure}
\Repeat{This is the fourth paragraph.}{10}
\begin{figure}[h]
\centering
\subfigure[First subcaption.]{\label{sf:two-parts-a} \includegraphics[width=0.3\textwidth]{plot.eps}}%
\hskip 0.5truein
\subfigure[Second subcaption.]{\label{sf:two-parts-b}\includegraphics[width=0.3\textwidth]{plot.eps}}
\caption{This figure has two parts.}
\label{fi:two-parts}
\end{figure}
\Repeat{This is the fifth paragraph.}{10}
\begin{figure}[h]
\centering
\subfigure[First subcaption.]{\label{sf:four-parts-a} \includegraphics[width=0.3\textwidth]{plot.eps}}%
\hskip 0.5truein
\subfigure[Second subcaption.]{\label{sf:four-parts-b}\includegraphics[width=0.3\textwidth]{plot.eps}}
\subfigure[Third subcaption.]{\label{sf:four-parts-c}\includegraphics[width=0.3\textwidth]{plot.eps}}%
\hskip 0.5truein
\subfigure[Fourth subcaption.]{\label{sf:four-parts-d}\includegraphics[width=0.3\textwidth]{plot.eps}}
\caption{This figure has four parts.}
\label{fi:four-parts}
\end{figure}
\Repeat{This is the sixth paragraph.}{10}