Debian Codegraph @

texmf-dist/doc/latex/syllogism/syllogism.tex

raw
1 % Manual for the syllogism package
2 % (c) Nicolas Vaughan 2008 ([email protected])
3 % 25/10/2008
4
5 \documentclass[letterpaper,
6 10pt,
7 ]{article}
8
9 \usepackage[T1]{fontenc}
10 \usepackage[english]{babel}
11
12 \usepackage[
13 colorlinks%
14 ,plainpages=false% This forces a unique identification of pages.
15 ,hypertexnames=true% This is necessary to have exact link on Index page.
16 ,naturalnames
17 ,hyperindex
18 ]{hyperref}
19
20 %--------------------------------------------------------------------------------
21 \usepackage[sc,osf]{mathpazo} % Palatino font
22 \usepackage[tracking=true,%
23 final,%
24 babel=true,%
25 verbose=true,
26 tracking=smallcaps]{microtype}
27 %----------------------------------------------------------------------------------
28
29 \usepackage{makeidx}
30 \usepackage{url}
31 \usepackage{xspace}
32 \usepackage{xcolor}
33 \usepackage{syllogism}
34
35 % . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
36
37 \newcommand{\syllversion}{release 1.2}
38 \newcommand{\syllp}{\texttt{\color{sred}syllogism}\xspace}
39 \colorlet{sblue}{blue!60!black}
40 \colorlet{sred}{red!60!black}
41 \colorlet{comcol}{green!45!black}
42 \newcommand{\comm}[1]{\texttt{\color{comcol}\textbackslash{}#1}\xspace} % commands
43 \newcommand{\commnb}[1]{\texttt{\color{comcol}#1}\xspace} % command without backslash
44 \newcommand\maincind[1]{\index{main commands!#1@\texttt{$\protect\backslash$#1}|}}
45 % main commands index
46 \newcommand\addcind[1]{\index{additional commands!#1@\texttt{$\protect\backslash$#1}|}}
47 % additional commands index
48 \newcommand\optind[1]{\index{package options!#1@\texttt{$\protect\backslash$#1}|}}
49 % package options index
50 % . . . . .. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .
51
52 \title{\vspace*{-1cm}%
53 \textsc{The} \syllp \textsc{package} \\%
54 {\large\syllversion}%
55 }
56 \author{(c) 2007--2008 \textsc{Nicolas Vaughan}\\ \\
57 Report bugs and submit questions to:\\
58 \texttt{[email protected]}
59 }
60 \date{Oct. 29, 2008}
61
62 \makeindex
63 \begin{document}% =============================================================
64 \setlength{\parindent}{0em}
65 \maketitle
66 \tableofcontents
67
68 \section{Introduction}
69 The \syllp package provides a simple way for neatly typesetting syllogisms and syllogistic-like arguments, composed of two premisses and a conclusion. It is fully configurable, allowing the user to tweak the various distances, line widths, and other options.
70
71 \section{Changelog}
72 \begin{description}
73 \item[v.\,1.2 (25/10/2008)] Changed the typesetting engine of \comm{syllog}.
74 \item[] Fixed a problem with \comm{syllogTAC}. (Thanks to Carlos Cortissoz for noticing this.)
75 \item[v.\,1.1 (02/06/2008)] Added a syllogism counter (\comm{c:syl}) and two new commands, \comm{syllogC} and \comm{syllogTAC}.
76 \end{description}
77
78 \section{How to use it~\label{S:howto}}
79 You must set
80 \comm{usepackage[\emph{options}]\{syllogism\}} before the
81 \comm{begin\{document\}} command. The available options
82 are described in section~\S \ref{S:options}.
83
84 To install \syllp, just place it anywhere \LaTeX can find it (e.g., \url{/texmf-local/tex/latex/syllogism}).
85
86 \subsection{\comm{syllog}~\label{SS:syllog}~\maincind{syllog}~\index{main commands}}
87 The main command provided by the package is \comm{syllog}, whose syntax is:
88
89 \bigskip
90
91 \comm{syllog[\emph{pre-text}]\{\emph{first premiss}\}\{\emph{second premiss}\}\{\emph{conclusion}\},
92 }
93
94 \bigskip
95
96 in which the optional parameter \emph{pre-text} is the text typeset to the left of the syllogism; \emph{first premiss}, \emph{second premiss} and \emph{conclusion} correspond respectively to the the text of the first and second premisses and the conclusion.
97
98 For example, the following command
99
100 \begin{quote}
101 \comm{syllog\{Every man except Socrates is musician\}}\%\\
102 \quad\commnb{\{Socrates is a man\}}\%\\
103 \quad\commnb{\{Socrates is not a musician\}},
104 \end{quote}
105
106 will produce this output:
107
108 \syllog{Every man except Socrates is musician}{Socrates is a man}{Socrates is not a musician}
109
110 If you choose to use the optional parameter, as in:
111
112 \begin{quote}
113 \comm{syllog[(S1)]\{Every man except Socrates is musician\}}\%\\
114 \quad\commnb{\{Socrates is a man\}}\%\\
115 \quad\commnb{\{Socrates is not a musician\}},
116 \end{quote}
117
118 you should get the following result:
119
120 \syllog[(S1)]{Every man except Socrates is musician}{Socrates is a man}{Socrates is not a musician}
121
122 \subsection{\comm{syllogC}~\label{SS:syllogC}~\maincind{syllogC}}
123 The package also provides the command \comm{syllogC} which includes an automatic numeration~\index{automatic numeration} feature. The syntax for this command is similar to the previous one, but does not take the optional parameter.%
124 \footnote{The~\label{N:slabel}~\index{automatic numeration!redefining the label} label for \comm{syllogC} is defined internally through the following instruction: \texttt{\textbackslash{}newcommand\{\textbackslash{}syl\}\{(S\textbackslash{}arabic\{c:syl\})\textbackslash{}xspace\}}. It may be thus redefined as usual in \LaTeX. For example, to remove the `S' in the label, use the following: \texttt{\textbackslash{}renewcommand\{\textbackslash{}syl\}\{(\textbackslash{}arabic\{c:syl\})\textbackslash{}xspace\}}.
125 } %
126
127 \bigskip
128
129 \comm{syllogC\{\emph{first premiss}\}\{\emph{second premiss}\}\{\emph{conclusion}\},
130 }
131
132 \bigskip
133
134 For example, the following code
135
136 \begin{quote}
137 \comm{syllogC\{Every man except Socrates is musician\}}\%\\
138 \quad\commnb{\{Socrates is a man\}}\%\\
139 \quad\commnb{\{Socrates is not a musician\}},
140 \end{quote}
141
142 will produce this output (provided that it has not been called elsewhere before):
143
144 \syllogC{Every man except Socrates is musician}{Socrates is a man}{Socrates is not a musician}
145
146 The counter associated with \comm{syllogC} is \comm{c:syl}, which may be reset or stepped with in the usual ways.
147
148 \subsection{\comm{syllogTA}~\label{SS:syllogTA}~\maincind{syllogTA}}
149 The command \comm{syllogTA} works almost exactly as \comm{syllog}, the only difference being that it adds some text to the second premiss and the conclusion. Its syntax is:
150
151 \bigskip
152
153 \comm{syllogTA[\emph{pre-text}]\{\emph{first premiss}\}\{\emph{second premiss}\}\{\emph{conclusion}\},
154 }
155
156 \bigskip
157
158 As for today, \syllp supports three languages for this task: English, Spanish and Latin. The default language is English. (The language may be changed through a package option, see \S \ref{S:options} below). The added text for each language is shown in Table \ref{T:languages}, below.
159
160 \begin{table}[h]
161 \begin{center}
162 \begin{tabular}{lcc}
163 & \textsc{second premiss} & \textsc{conclusion} \\
164 \textsc{english} & \emph{but} & \emph{Therefore} \\
165 \textsc{spanish} & \emph{pero} & \emph{Por lo tanto,} \\
166 \textsc{latin1} & \emph{sed} & \emph{Ergo} \\
167 \textsc{latin1} & \emph{sed} & \emph{Igitur} \\
168 \end{tabular}
169 \caption{Language variants}\label{T:languages}%
170 \end{center}
171 \end{table}
172
173 For example, the following code:
174
175 \begin{quote}
176 \comm{syllogTA\{Every man except Socrates is musician\}}\%\\
177 \quad\comm{\{Socrates is a man\}}\%\\
178 \quad\comm{\{Socrates is not a musician\}},
179 \end{quote}
180
181 will be typeset thus:
182
183 \syllogTA{Every man except Socrates is musician}{Socrates is a man}{Socrates is not a musician}
184
185 Please note that the text may be defined through several commands provided also by \syllp (see below \S \ref{SS:Tcomm}).
186
187 \subsection{\comm{syllogTAC}~\label{SS:syllogTAC}~\maincind{syllogTAC}}
188 The command \comm{syllogTAC}, which adds an automatic counter to \comm{syllogTA}~\maincind{syllogTA}.%
189 \footnote{See note \ref{N:slabel}, above.
190 } %
191 Its syntax is:
192
193 \bigskip
194
195 \comm{syllogTAC\{\emph{first premiss}\}\{\emph{second premiss}\}\{\emph{conclusion}\},
196 }
197
198
199 \section{Package options~\label{S:options}}
200 The package options~\index{package options} for \syllp are four, corresponding the language of the added text (used only with the commands \comm{syllogTA} and \comm{syllogTAC}):
201
202 \begin{description}
203 \item{\texttt{english}}~\optind{english}
204 \item{\texttt{spanish}}~\optind{spanish}
205 \item{\texttt{latin1}}~\optind{latin1}
206 \item{\texttt{latin2}}~\optind{latin2}
207 \end{description}
208
209 The option \texttt{english} is the default one. As stated previously, the text content selected by these options may be changed by one or more of several commands provided in the package (see below \S \ref{SS:Tcomm}).
210
211 \section{Additional commands~\label{S:addcomm}~\index{additional commands}}
212 \subsection{Length-related commands~\label{SS:Lcomm}}
213 \begin{description}
214 \item[\comm{setpresyl}] Command~\addcind{setpresyl} for changing the horizontal space to the right of the syllogism (def=2em).
215 \item[\comm{setsyllabel}] Command~\addcind{setsyllabel} for changing the horizonal space between the label and the syllogism (def=1em).
216 \item[\comm{setsylrh}] Command~\addcind{setsylrh} for changing the `width' of the rule (def=.3pt).
217 \item[\comm{setsylsepa}] Command~\addcind{setsylsepa} for changing the vertical space before the syllogism (def=\texttt{\textbackslash{}baselineskip}).
218 \item[\comm{setsylsepb}] Command~\addcind{setsylsepb} for changing the vertical space after the syllogism (def=\texttt{\textbackslash{}baselineskip}).
219 \item[\comm{setsylsep}] Command~\addcind{setsylsep} for changing the vertical space \emph{both} before \emph{and} after the syllogism to the same value.
220 \end{description}
221
222 \subsection{Text-related commands~\label{SS:Tcomm}}
223 These commands change the default text used with \comm{syllogTA} and \comm{syllogTAC}. The defaults are set by the package options (see above \S \ref{S:options}).
224
225 \begin{description}
226 \item[\comm{setsylsed}] Command~\addcind{setsylsed} for changing the text that begins the second premiss.
227 \item[\comm{setsylergo}] Command~\addcind{setsylergo} for changing the text that begins the conclusion.
228 \item[\comm{setsylpuncpa}] Command~\addcind{setsylpuncpa} for changing the punctuation after the first premiss (def=;).
229 \item[\comm{setsylpuncpb}] Command~\addcind{setsylpuncpb} for changing the punctuation after the second premiss (def=.).
230 \item[\comm{setsylpuncc}] Command~\addcind{setsylpuncc} for changing the punctuation after the conclusion (def=.).
231 \item[\comm{setsylergosign}] Command~\addcind{setsylergosign} for changing the sign that goes after the conclusion text (def=$\therefore$).
232 \end{description}
233
234 \section{Future features~\label{S:ffeatures}}
235 Future features depend on user feedback and requests. However, support for more languages and automatic language selection (through \texttt{babel}) is envisaged.
236 \clearpage
237 \printindex
238 \end{document}% =============================================================