diff options
Diffstat (limited to 'Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4')
10 files changed, 268 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-1.tex b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-1.tex new file mode 100644 index 00000000000..8a19c9114ec --- /dev/null +++ b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-1.tex @@ -0,0 +1,39 @@ +\documentclass{article} +\begin{document} +A section of text may be displayed by indenting it by an equal amount +on both sides, with the `quote' or `quotation' environment, as +demonstrated here for the `quote' environment first. +\begin{quote} +Additonal vertical spacing is inserted above and below the displayed +text to seperate it vertically from normal text. + +The text to be displayed may be over any length; it can be part of a +sentence, a whole paragraph, or several paragraphs. + +Paragraphs are seperated as usual with an empty line, although no +empty lines are needed at the beginning and end of the displayed +text since additional vertical spacing is inserted here anyway. +\end{quote} +And here follows a demonstration of the `quotation' environment. +\begin{quotation} +In the `quotation' environment, paragraphs are marked by extra indentation +of the first line, wheras in the `quote' environment, they are indicated +more vertical spacing between them. + +The present text is produced within the `quotation' environment, while +the example above was done with the `quote' environment. + +The `quotation' environment is only really meaningfil, when the regular +text makes use of first-line indentation to show off new paragraphs. +\end{quotation} +The adjacent text behind the `quote' and/or `quotation' environment is +processed in standard form again, as shown here. An empty line behind +one of this environments starts the adjecent text as a new paragraph, +indicated by an indentend first line of the the following text. The +user may demonstrate this by the slight modification for this solution +example. +\end{document} + + + + diff --git a/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-10.tex b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-10.tex new file mode 100644 index 00000000000..5cca868bdac --- /dev/null +++ b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-10.tex @@ -0,0 +1,19 @@ +\documentclass{article} +\begin{document} + +% This text is taken from Chapter 6, Tables +% Guide to LaTeX, 4th edition. + +\begin{verbatim} +Table material is made to float with the environment: +\begin{quote} + \verb=\begin{table}= \emph{head\_text\quad table\quad foot\_text\quad} + \verb=\end{table} +\end{quote} +where \emph{table} stands for the entire table as defined in the +\texttt{tabular} environment, \emph{head\_text} for whatever text appears +above the table, and \emph{foot\_text} for that below. Width, spacing, +and positioning of the texts relative to the table are all matters for the +user to arrange. +\end{verbatim} +\end{document} diff --git a/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-2.tex b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-2.tex new file mode 100644 index 00000000000..82fd219788e --- /dev/null +++ b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-2.tex @@ -0,0 +1,42 @@ +\documentclass[12pt]{article} +\setlength{\textwidth}{100mm} +\begin{document} +\begin{center}\Large\textbf{The Jabberwocky}\end{center} +\begin{verse}\itshape +'Twas brillig, and the slithy toves\\ +Did gyre and gimble in the wabe:\\ +All mimsy were the borogoves,\\ +And the mome raths outgrabe. + +"Beware the Jabberwock, my son!\\ +The jaws that bite, the claws that catch!\\ +Beware the Jubjub bird, and shun\\ +The frumious Bandersnatch!" + +He took his vorpal sword in hand:\\ +Long time the manxome foe he sought-\\ +So rested he by the Tumtum tree,\\ +And stood awhile in thought. + +And, as in uffish thought he stood,\\ +The Jabberwock, with eyes of flame,\\ +Came whiffling through the tulgey wood,\\ +And burbled as it came! + +One, two! One, two! And through and through\\ +The vorpal blade went snicker-snack!\\ +He left it dead, and with its head\\ +He went galumphing back. + +"And hast thou slain the Jabberwock?\\ +Come to my arms, my beamish boy!\\ +O frabjous day! Callooh! Callay!"\\ +He chortled in his joy. + +'Twas brillig, and the slithy toves\\ +Did gyre and gimble in the wabe:\\ +All mimsy were the borogoves,\\ +And the mome raths outgrabe. +\end{verse} +\begin{flushright} Lewis Carroll\end{flushright} +\end{document} diff --git a/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-3.tex b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-3.tex new file mode 100644 index 00000000000..405f4ff97cf --- /dev/null +++ b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-3.tex @@ -0,0 +1,12 @@ +\documentclass{article} +\begin{document} +\begin{titlepage} \centering +\vspace*{5cm} +\textbf{\Huge Exercises}\\[1.5cm] +\Large Steven Writer\\ +Texas A \& M University\\ +Department of Computer Science\\[5mm] +College Station, Texas \today +\end{titlepage} +\end{document} + diff --git a/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-4.tex b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-4.tex new file mode 100644 index 00000000000..852050a335c --- /dev/null +++ b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-4.tex @@ -0,0 +1,57 @@ +\documentclass{article} +\begin{document} +A forfould nestin of the itemize an environment appears as follows: +\begin{itemize} + \item The label for the first level is a black dot, a \emph{bullet}. + \begin{itemize} + \item That of the second level is a long dash (en dash). + \begin{itemize} + \item That of the third level is an asterisk. + \begin{itemize} + \item And the label for the fourth level is an upshifted dot. + \item At the same time, the vertical spacing is decrease with + increasing depth. + \end{itemize} + \item Back to the third level. + \item Each level may contain several labels of the same degree, + \item as shown here for third level. + \end{itemize} + \item Back to the second level. + \end{itemize} + \item And here we are at the first level of the itemize list again. + \item The standard label markers for each level can be changed by + the user + \item as demonstrated with the solution example for exercise 4.6. +\end{itemize} +Similary for the enumerate environment, where the style of numberin changes +with the nesting level: +\begin{enumerate} + \item The numbering at the first level is with Arabic numerals followed + by a period. + \begin{enumerate} + \item At the second level, it is with lower case letters in paranthesis. + \begin{enumerate} + \item The third level is numbered with lower case Roman numerals + with a period. + \begin{enumerate} + \item At the fourth level, capital letters are used. + \item The label style can be changed as shown in the solution + example for exercise 4.7. + \end{enumerate} + \item Back to the third level. + \end{enumerate} + \item Back to the second level. + \item Also the enumerat environment may contain in every level + several labels of the same degree, + \item as shown here for the second level. + \end{enumerate} + \item Each level should contain at least two labels, + \item but formally less labels are allowed! +\end{enumerate} +\end{document} + + + + + + diff --git a/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-5.tex b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-5.tex new file mode 100644 index 00000000000..838f06ca659 --- /dev/null +++ b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-5.tex @@ -0,0 +1,16 @@ +\documentclass{article} +\begin{document} +\textbf{\large Canadian Participants} +\begin{description} +\item[Ady, Michael S.] Edmonton, Alberta +\item[Brunskill, Roxanne] Calgary, Alberta +\item[Chan, Stephen] Burnaby, British Columbia +\item[Dick, Roberta] Don Mills, Ontario +\item[Flynn, Frank] Vancouver, British Collumbia +\item[Galko, Peter] Ottawa, Ontario +\item[Jones, Ed] Halifax, Nona Scotia +\item[Herschorn, Michael] Montr\'eal, Qu\'ebec +\item[Mackinnon, James G.] Kingston, Ontario +\end{description} +\end{document} + diff --git a/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-6.tex b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-6.tex new file mode 100644 index 00000000000..ec8b4405cf0 --- /dev/null +++ b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-6.tex @@ -0,0 +1,21 @@ +\documentclass{article} +\renewcommand{\labelitemi}{---} +\renewcommand{\labelitemii}{--} +\renewcommand{\labelitemiii}{-} +\begin{document} +With the user changed label commands, the standard labels occure now +in the following form: +\begin{itemize} +\item The label for the first level is a long dash (em dash). +\begin{itemize} +\item That for the second level a medium dash (en dash). +\begin{itemize} +\item And that for the third level a short dash, a hyphen. +\item Changed label symbols should be uniform for the whole users documen. +\end{itemize} +\item Also not changed several times within the document. +\end{itemize} +\item As shown here. +\end{itemize} +\end{document} + diff --git a/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-7.tex b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-7.tex new file mode 100644 index 00000000000..f9d739fffdf --- /dev/null +++ b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-7.tex @@ -0,0 +1,27 @@ +\documentclass{article} +\renewcommand{\labelenumi}{(\Roman{enumi})} +\renewcommand{\labelenumii}{\Roman{enumi}--\arabic{enumii}} +\begin{document} +With the user modified label commands for the first two level of the +enumerate environment, the corresponding labels occure now as follows: +\begin{enumerate} +\item The labels for the first level are roman captal numerals enclosed by +parenthesis. +\begin{enumerate} +\item The labels for the second level are the roman numerals of the first + level followed by the number of the second level, seperated by + a medium dash. +\item Here is the next label of the second level. +\item Followed by the third label of the second level. +\end{enumerate} +\item And back now to the second label of the first level. +\begin{enumerate} +\item And again at the second level with the combined roman numeral and + the actual label number of this level. +\item And so one for continously labels of this label +\item as demonstrated here for the third label +\end{enumerate} +\item An back now the the next label of the first level +\item before we leave the enumerate environment. +\end{enumerate} +\end{document} diff --git a/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-8.tex b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-8.tex new file mode 100644 index 00000000000..eb5c771f23d --- /dev/null +++ b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-8.tex @@ -0,0 +1,19 @@ +\documentclass{article} +\newcounter{num} +\newenvironment{sample}{\begin{list}{\textbf{Sample \Alph{num}}\hfill}% + {\usecounter{num} \setlength{\labelwidth}{20mm} + \setlength{\leftmargin}{22mm} \setlength{\rightmargin}{5mm} + \setlength{\itemsep}{1ex plus0.5ex minus 0.4ex} + \setlength{\listparindent}{1em} + \setlength{\parsep}{0ex plus0.5ex} }} + {\end{list}} +\begin{document} +The user defined \texttt{sample}-environment of the upper preamble +demontrates the position of the corresponding label and their +left an right margins. +\begin{sample} +\item with no commercial value. +\item on receipt of the enclosed voucher an amount of 5.00 \$ will be + paid. +\end{sample} +\end{document} diff --git a/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-9.tex b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-9.tex new file mode 100644 index 00000000000..a90d9519bb8 --- /dev/null +++ b/Master/texmf-dist/doc/latex/guide-to-latex/exercises/chap4/exer4-9.tex @@ -0,0 +1,16 @@ +\documentclass{article} +\begin{document} +\begin{verbatim} +Table material is made to float with the envronment: +\begin{quote} + \verb=\begin{table}= \emph{head\_text\quad table\quad foot\_text\quad} + \verb=\end{table} +\end{quote} +where \emph{table} stands for the entire table as defined in the +\texttt{tabular} environment, \emph{head\_text} for whatever text appears +above the table, and \emph{foot\_text} for that below. Width, spacing, +and positioning of the texts relative to the table are all matters for the +user to arrange. +\end{verbatim} +\end{document} + |