Debian Codegraph @

texmf-dist/doc/latex/psgo/psgomanual.tex

raw
1 %% psgomanual.tex
2 %% Copyright 2003,2001 V. Bos
3 %
4 % This program may be distributed and/or modified under the
5 % conditions of the LaTeX Project Public License, either version 1.2
6 % of this license or (at your option) any later version.
7 % The latest version of this license is in
8 % http://www.latex-project.org/lppl.txt
9 % and version 1.2 or later is part of all distributions of LaTeX
10 % version 1999/12/01 or later.
11 %
12 % This program consists of the files:
13 %
14 % psgo.sty
15 % psgomanual.tex
16 % psgomanual.ps
17 %
18 % RCS-ID: $Id: psgomanual.tex,v 1.6 2004/02/24 10:17:23 vbos Exp $
19 %
20 \documentclass[a4paper]{article}
21
22 \usepackage{psgo,array,url}
23 \newcommand{\pstricks}{\textsf{PSTricks}}
24
25 \newcommand{\commandname}[1]{{\ttfamily\symbol{'134}#1}}
26 % The following code is taken from the doc package. It defines a global
27 % macro \bslash that produces a bslash (if present in the current font).
28 \makeatletter
29 {\catcode`\|=\z@ \catcode`\\=12 |gdef|bslash{\}}
30 \makeatother
31 \newcommand{\cmd}[1]{\texttt{\bslash #1}}
32
33 \title{\psgo\\{\normalfont\normalsize Typesetting Go Diagrams with \pstricks}}
34 \author{Victor Bos\\email: [email protected]}
35 \date{September 04, 2008}
36
37
38 \setgounit{0.4cm}
39
40 \begin{document}
41 \maketitle
42
43
44 \section{Introduction}
45
46 The \psgo{} package provides functionality to typeset Go diagrams in
47 \LaTeXe. It is built on top of the \pstricks{} package, which is
48 nowadays available in many \LaTeX{} distributions. Although \psgo{}
49 does not understand the \emph{Smart Game Format} (SGF), it has support
50 for all graphical markup properties of SGF FF[4], see
51 \verb|http://www.red-bean.com/sgf/|.
52
53 \section{Download and installation}
54
55 The \psgo{} package can be found at CTAN (mirrors) in the directory
56 \url{graphics/pstricks/contrib/psgo/}. It is also available from
57
58 \medskip
59 \url{http://www.abo.fi/~vbos/psgo-frame.html}
60
61 \medskip\noindent To install the package, download the files
62 \texttt{psgo.sty} and \texttt{psgomanual.tex} and put them in a
63 directory where \LaTeX{} can find them. After that, test the
64 installation by running \LaTeX{} on \texttt{psgomanual.tex}.
65
66 Note that \textsf{psgo} uses \textsf{pstricks} to draw
67 graphics. Therefore, the same things that apply to viewing and
68 printing documents with \textsf{pstricks} graphics also apply to
69 documents with \textsf{psgo} graphics. In particular, it is usually
70 better to use a PostScript viewer (e.g., \texttt{gv} or
71 \texttt{gsview}) instead of a DVI viewer (like \texttt{xdvi} or
72 \texttt{yap}).
73
74 \section{Go boards}
75
76 The interface of \psgo{} is based on how Go diagrams are usually
77 displayed in books. That is, the rows of a $19\times19$ board are
78 indexed by $1,2,\ldots,19$ and the columns are indexed by $A, B,
79 \ldots, T$ (skipping $I$). Further, the lower left corner has index
80 $(A, 1)$ and the upper right corner has index
81 $(T,19)$. Figure~\ref{fig:empty:boards} shows a $19\times 19$ board
82 and a $9\times9$ board. Note that the sizes of the boards are reduced
83 in order to fit in one figure. To re-size a Go board, the command
84 \verb|\setgounit| can be used. This command takes the desired
85 horizontal unit distance as an argument. The default horizontal unit
86 distance is~$0.6$cm. The vertical unit distance is computed by the
87 \psgo{} package. For the diagrams in this document, except for the
88 diagrams of Figure~\ref{fig:empty:boards}, we have set the horizontal
89 unit distance to~$0.4$cm (\verb|\setgounit{0.4cm}|).
90
91 \begin{figure}
92 \setgounit{0.3cm}
93 \begin{center}
94 \begin{tabular}{cc}
95 \begin{psgoboard}
96 \end{psgoboard} &
97 \begin{psgoboard}[9]
98 \end{psgoboard}
99 \end{tabular}
100 \caption{Different size Go boards}
101 \label{fig:empty:boards}
102 \end{center}
103 \end{figure}
104
105 Go boards are defined in the \verb|psboard| environment of \psgo. This
106 environment takes~1 optional parameter which indicates the size of the
107 board (default size is~19). For instance, the boards of
108 Figure~\ref{fig:empty:boards} were defined by:
109
110 \begin{verbatim}
111 \begin{psgoboard}
112 \end{psgoboard}
113 \begin{psgoboard}[9]
114 \end{psgoboard}
115 \end{verbatim}
116
117 If the indices are not desired, the starred version \verb|psgoboard*|
118 of the environment should be used. Figure \ref{fig:no:indices} shows
119 the boards of Figure~\ref{fig:empty:boards} without indices. The code
120 for these boards is given below.
121 \begin{verbatim}
122 \begin{psgoboard*}
123 \end{psgoboard*}
124 \begin{psgoboard*}[9]
125 \end{psgoboard*}
126 \end{verbatim}
127
128 \begin{figure}
129 \setgounit{0.3cm}
130 \begin{center}
131 \begin{tabular}{cc}
132 \begin{psgoboard*}
133 \end{psgoboard*} &
134 \begin{psgoboard*}[9]
135 \end{psgoboard*}
136 \end{tabular}
137 \caption{Go boards of Figure~\ref{fig:empty:boards} without indices}
138 \label{fig:no:indices}
139 \end{center}
140 \end{figure}
141
142
143 \section{Stones and moves}
144
145 There are two commands to put stones on the board and one command to
146 make pass moves. The first one is \verb|\stone| which takes three
147 parameters: the color, the column, and the row of the stone. For
148 example, \verb|\stone{black}{c}{4}| puts a black stone at
149 position~$(C,4)$ (note that in the \LaTeX{} code, the columns are
150 indicated by lower case characters). The \verb|\stone| command can be
151 used to setup a particular configuration. For instance, the
152 configuration of Figure~\ref{fig:ko:configuration} is defined as
153 follows.
154
155 \begin{verbatim}
156 \begin{psgoboard}[9]
157 \stone{white}{c}{3}
158 \stone{white}{e}{3}
159 \stone{white}{d}{2}
160 \stone{white}{d}{4}
161 \stone{black}{f}{3}
162 \stone{black}{e}{2}
163 \stone{black}{e}{4}
164 \end{psgoboard}
165 \end{verbatim}
166
167 \begin{figure}
168 \begin{center}
169 \begin{psgoboard}[9]
170 \stone{white}{c}{3}
171 \stone{white}{e}{3}
172 \stone{white}{d}{2}
173 \stone{white}{d}{4}
174 \stone{black}{f}{3}
175 \stone{black}{e}{2}
176 \stone{black}{e}{4}
177 \end{psgoboard}
178 \caption{Setting up a configuration}
179 \label{fig:ko:configuration}
180 \end{center}
181 \end{figure}
182
183
184 The second command is \verb|move| which takes two parameters: the
185 column and the row of the next move. Moves are usually numbered. The
186 counter that keeps track of the move number is
187 called~\verb|gomove|. This is a normal \LaTeX{} counter and can be
188 changed using ordinary \LaTeX-counter commands. The color of the
189 stones placed by the \verb|\move| command alternates between
190 successive moves. For example, \verb|\move{b}{3}| puts a stone on
191 position~$(B, 3)$. If this was a black move, the stone is black,
192 otherwise it is white.
193
194 In addition, there is a command for pass moves: \verb|\pass|. It is
195 like \verb|\move| in that it increases the move number and changes the
196 color for the next move, but it does not draw a stone on the board.
197
198 It is time for an example. The following code generates a $9\times 9$
199 board with six moves. Note that the third move (move number~2) is a pass by
200 black. The result is depicted in Figure~\ref{fig:9x9:example}(a).
201
202 \begin{verbatim}
203 \begin{psgoboard}[9]
204 \move{c}{3}
205 \move{g}{7}
206 \pass
207 \move{f}{1}
208 \move{a}{9}
209 \end{psgoboard}
210 \end{verbatim}
211
212
213 As can be seen, the move numbers are displayed on the stones. The
214 \verb|gomove| counter is never reset by the \psgo{} package. So, the
215 move numbers just continue in subsequent diagrams. Of course, it is
216 possible to reset the value of~\verb|gomove| manually. In that case,
217 one should know that the \verb|\move| command increases the
218 \verb|gomove| counter \emph{before} it draws the stone. So, if a
219 diagram should start with move~0, one should issue the command
220 \verb|\setcounter{gomove}{-1}| just before the diagram.
221
222 If a diagram continues another diagram, the numbers on the stones
223 played so far are usually not desirable. Therefore, \psgo{} has
224 defined a starred version the move command: \verb|\move*|. This
225 command does not decorate stones with move numbers and it does not
226 increase the \verb|gomove| counter. For instance, if the game of
227 Figure~\ref{fig:9x9:example}(a) is continued, all we have to do is
228 copy\&paste the game played so far, replace the existing \verb|\move|
229 commands by \verb|\move*|, and add some new \verb|\move| (unstarred!)
230 commands to it. For convenience, there is also a \verb|\pass*| command; its
231 effect is to change the color for the next move. The code is given
232 below and the result displayed in Figure~\ref{fig:9x9:example}(b).
233 \begin{verbatim}
234 \begin{psgoboard}[9]
235 \move*{c}{3}
236 \move*{g}{7}
237 \pass*
238 \move*{f}{1}
239 \move*{a}{9}
240 \move{f}{6} % new \move commands
241 \move{e}{6}
242 \pass
243 \move{c}{5}
244 \end{psgoboard}
245 \end{verbatim}
246
247 \begin{figure}
248 \begin{center}
249 \begin{tabular}{cc}
250 \begin{psgoboard}[9]
251 \move{c}{3}
252 \move{g}{7}
253 \pass
254 \move{f}{1}
255 \move{a}{9}
256 \end{psgoboard}
257 &
258 \begin{psgoboard}[9]
259 \move*{c}{3}
260 \move*{g}{7}
261 \pass*%
262 \move*{f}{1}
263 \move*{a}{9}
264 \move{f}{6}
265 \move{e}{6}
266 \pass
267 \move{c}{5}%
268 \end{psgoboard}\\
269 (a) First 5 moves (2: black pass).
270 &
271 (b) Successive moves (7: white pass).
272 \end{tabular}
273 \caption{Moves on a board}
274 \label{fig:9x9:example}
275 \end{center}
276 \end{figure}
277
278
279 \section{Markers}
280
281 Empty positions on the board can be marked with the command
282 \verb|\markpos|. This command takes three parameters, being, the
283 marker, the column, and the row. Available markers and the commands to
284 generate them are listed in Table~\ref{tbl:markers}. Each marker is
285 illustrated at position~$(B,2)$ on a~$3\times3$ board. Note that the
286 label marker command, \verb|\marklb|, takes one argument, being the
287 label. It is possible, though not advisable, to add more than one
288 marker to an empty position.
289
290 \begin{table}
291 \begin{center}
292 \begin{tabular}{|c|l|l|l|}
293 \hline
294 Diagram & \psgo{} Command & Description & Example\\
295 \hline\hline
296 \raisebox{-0.5\height}{\begin{psgoboard*}[3]\markpos{\markma}{b}{2}\end{psgoboard*}} &
297 \commandname{markma}& Cross &
298 {\ttfamily\commandname{markpos}\{\commandname{markma}\}\{b\}\{2\}}\\\hline
299 %
300 \raisebox{-0.5\height}{\begin{psgoboard*}[3]\markpos{\marktr}{b}{2}\end{psgoboard*}} &
301 \commandname{marktr}& Triangle &
302 {\ttfamily\commandname{markpos}\{\commandname{marktr}\}\{b\}\{2\}}\\\hline
303 %
304 \raisebox{-0.5\height}{\begin{psgoboard*}[3]\markpos{\markcr}{b}{2}\end{psgoboard*}} &
305 \commandname{markcr}& Circle &
306 {\ttfamily\commandname{markpos}\{\commandname{markcr}\}\{b\}\{2\}}\\\hline
307 %
308 \raisebox{-0.5\height}{\begin{psgoboard*}[3]\markpos{\marksq}{b}{2}\end{psgoboard*}} &
309 \commandname{marksq}& Open square &
310 {\ttfamily\commandname{markpos}\{\commandname{marksq}\}\{b\}\{2\}}\\\hline
311 %
312 \raisebox{-0.5\height}{\begin{psgoboard*}[3]\markpos{\marklb{A}}{b}{2}\end{psgoboard*}} &
313 \commandname{marklb\{\#1}\}& Label &
314 {\ttfamily\commandname{markpos}\{\commandname{marklb}\{A\}\}\{b\}\{2\}}\\\hline
315 %
316 \raisebox{-0.5\height}{\begin{psgoboard*}[3]\markpos{\marksl}{b}{2}\end{psgoboard*}} &
317 \commandname{marksl}& Filled square &
318 {\ttfamily\commandname{markpos}\{\commandname{marksl}\}\{b\}\{2\}}\\\hline
319 %
320 \raisebox{-0.5\height}{\begin{psgoboard*}[3]\markpos{\markdd}{b}{2}\end{psgoboard*}} &
321 \commandname{markdd}& Hatched lines &
322 {\ttfamily\commandname{markpos}\{\commandname{markdd}\}\{b\}\{2\}}\\\hline
323 \end{tabular}
324 \caption{Markers on empty positions}
325 \label{tbl:markers}
326 \end{center}
327 \end{table}
328
329 Stones can be marked too. To this end, the commands \verb|\stone| and
330 \verb|\move| take an optional parameter representing the marker of the
331 stone. For example, \verb|\stone[\markma]{black}{b}{4}| puts a black
332 stone marked with a cross at
333 position~$(B,4)$. Table~\ref{tbl:stone:markers} shows how stones can
334 be marked. It is possible, though not advisable, to add more than one
335 marker to a stone or to add markers to numbered stones.
336
337 \begin{table}
338 \begin{center}
339 \begin{tabular}{|c|l|l|p{0.5\linewidth}|}
340 \hline
341 Diagram & \psgo{} Command & Description & Example\\
342 \hline\hline
343 \raisebox{-0.5\height}{\begin{psgoboard*}[4]\stone[\markma]{black}{b}{2}\stone[\markma]{white}{c}{3}\end{psgoboard*}} &
344 \commandname{markma}& Cross &
345 {\ttfamily\commandname{stone}[\commandname{markma}]\{black\}\{b\}\{2\}
346 \commandname{stone}[\commandname{markma}]\{white\}\{c\}\{3\}}\\\hline
347 %
348 \raisebox{-0.5\height}{\begin{psgoboard*}[4]\stone[\marktr]{black}{b}{2}\stone[\marktr]{white}{c}{3}\end{psgoboard*}} &
349 \commandname{marktr}& Triangle &
350 {\ttfamily\commandname{stone}[\commandname{marktr}]\{black\}\{b\}\{2\}
351 \commandname{stone}[\commandname{marktr}]\{white\}\{c\}\{3\}}\\\hline
352 %
353 \raisebox{-0.5\height}{\begin{psgoboard*}[4]\stone[\markcr]{black}{b}{2}\stone[\markcr]{white}{c}{3}\end{psgoboard*}} &
354 \commandname{markcr}& Circle &
355 {\ttfamily\commandname{stone}[\commandname{markcr}]\{black\}\{b\}\{2\}
356 \commandname{stone}[\commandname{markcr}]\{white\}\{c\}\{3\}}\\\hline
357 %
358 \raisebox{-0.5\height}{\begin{psgoboard*}[4]\stone[\marksq]{black}{b}{2}\stone[\marksq]{white}{c}{3}\end{psgoboard*}} &
359 \commandname{marksq}& Open square &
360 {\ttfamily\commandname{stone}[\commandname{marksq}]\{black\}\{b\}\{2\}
361 \commandname{stone}[\commandname{marksq}]\{white\}\{c\}\{3\}}\\\hline
362 %
363 \raisebox{-0.5\height}{\begin{psgoboard*}[4]\stone[\marklb{A}]{black}{b}{2}\stone[\marklb{B}]{white}{c}{3}\end{psgoboard*}} &
364 \commandname{marklb\{\#1}\}& Label &
365 {\ttfamily\commandname{stone}[\commandname{marklb}\{A\}]\{black\}\{b\}\{2\}
366 \commandname{stone}[\commandname{marklb}\{B\}]\{white\}\{c\}\{3\}}\\\hline
367 %
368 \raisebox{-0.5\height}{\begin{psgoboard*}[4]\stone[\marksl]{black}{b}{2}\stone[\marksl]{white}{c}{3}\end{psgoboard*}} &
369 \commandname{marksl}& Filled square &
370 {\ttfamily\commandname{stone}[\commandname{marksl}]\{black\}\{b\}\{2\}
371 \commandname{stone}[\commandname{marksl}]\{white\}\{c\}\{3\}}\\\hline
372 %
373 \raisebox{-0.5\height}{\begin{psgoboard*}[4]\stone[\markdd]{black}{b}{2}\stone[\markdd]{white}{c}{3}\end{psgoboard*}} &
374 \commandname{markdd}& Hatched lines &
375 {\ttfamily\commandname{stone}[\commandname{markdd}]\{black\}\{b\}\{2\}
376 \commandname{stone}[\commandname{markdd}]\{white\}\{c\}\{3\}}\\\hline
377 \end{tabular}
378 \caption{Markers on stones}
379 \label{tbl:stone:markers}
380 \end{center}
381 \end{table}
382
383 \section{Lines and arrows}
384
385 In addition to markers, it is possible to add lines and arrows to the
386 diagrams. The command \verb|\goline| draws a line and the command
387 \verb|\goarrow| draws an arrow. Both commands take four parameters
388 indicating the column and the row of the start position and the column
389 and the row of the end position. That is, \verb|\goline{a}{1}{c}{5}|
390 draws a line from position~$(A,1)$ to position~$(C,5)$ and
391 \verb|\goarrow{e}{3}{b}{2}| draws an arrow from position~$(E,3)$ to
392 position~$(B,2)$, as illustrated in Figure~\ref{fig:more:features}(a).
393
394
395 \section{Partial Boards}
396 \label{sec:partial-boards}
397
398 It is sometimes desirable to display \emph{partial} go boards. For
399 instance, when describing joseki's, displaying a whole board might be
400 a waste of space. To this end, there is a variant of the
401 \texttt{psgoboard} environment called \texttt{psgopartialboard}. In
402 addition to the board size, this environment takes two points on the
403 board as parameters. These points define the lower-left and the
404 upper-right of a frame on the board. Only the inside
405 the frame will be displayed. The coordinates of the points should be
406 given as one parameter with syntax
407 %
408 \begin{center}
409 \texttt{($llx$,$lly$)($urx$,$ury$)}
410 \end{center}
411 %
412 Here, $llx$ is the $x$-coordinate of the lower-left point, $lly$ is
413 the $y$-coordinate of the lower-left point, $llx$ is the
414 $x$-coordinate of the upper-right point, and $ury$ is the
415 $y$-coordinate of the upper-right
416 point. Figure~\ref{fig:part:goboards} shows examples of partial go
417 boards of different sizes.
418
419 \begin{figure}
420 \setgounit{0.3cm}
421 \begin{center}
422 \begin{tabular}[b]{cc}
423 \begin{psgopartialboard*}{(1,1)(6,8)}
424 \stone{white}{a}{3}
425 \stone{black}{f}{4}
426 \stone{white}{d}{7}
427 \stone{black}{b}{1}
428 \end{psgopartialboard*} &
429 \begin{psgopartialboard}[9]{(4,2)(9,9)}
430 \stone{white}{d}{2}
431 \stone{black}{f}{5}
432 \stone{white}{j}{8}
433 \end{psgopartialboard}\\[2ex]
434 \parbox{5.5cm}{\raggedright\small
435 \texttt{\cmd{begin}\{psgopartialboard*\}\%\\
436 \qquad\{(1,1)(6,8)\}\\
437 \cmd{stone}\{white\}\{a\}\{3\}\\
438 \cmd{stone}\{black\}\{f\}\{4\}\\
439 \cmd{stone}\{white\}\{d\}\{7\}\\
440 \cmd{end}\{psgopartialboard*\}
441 }}
442 &
443 \parbox{5.5cm}{\raggedright\small
444 \texttt{\cmd{begin}\{psgopartialboard\}[9]\%\\
445 \qquad\{(4,2)(9,9)\}\\
446 \cmd{stone}\{white\}\{d\}\{2\}\\
447 \cmd{stone}\{black\}\{f\}\{5\}\\
448 \cmd{stone}\{white\}\{j\}\{8\}\\
449 \cmd{end}\{psgopartialboard\}
450 }}\\
451 \end{tabular}
452 \caption{Partial go boards}
453 \label{fig:part:goboards}
454 \end{center}
455 \end{figure}
456
457 Note that if a partial board includes an edge of the board, the
458 indices for that edge are printed. On the other hand, if an edge is
459 not included, no indices are printed. The current implementation of
460 partial boards uses the clipping feature of \textsf{pstricks} to cut
461 out part of the board specified by the lower-left and upper-right
462 points. That is, the partial board is drawn as a normal board, but by
463 using clipping, only part of the board is visible. In particular,
464 coordinates of moves and stones should be given as for a normal
465 board. An example of a partial go board with stones is given in
466 Figure~\ref{fig:partial:ko:configuration}.
467
468 \begin{figure}
469
470 \begin{center}
471 \begin{tabular}{cb{5cm}}
472 \begin{psgopartialboard}[9]{(4,1)(9,6)}
473 \stone{white}{c}{3}
474 \stone{white}{e}{3}
475 \stone{white}{d}{2}
476 \stone{white}{d}{4}
477 \stone{black}{f}{3}
478 \stone{black}{e}{2}
479 \stone{black}{e}{4}
480 \end{psgopartialboard}
481 &
482 \small\ttfamily
483 \cmd{begin}\{psgopartialboard\}[9]\{(4,1)(9,6)\}
484 \cmd\{stone\}\{white\}\{c\}\{3\}
485 \cmd{stone}\{white\}\{e\}\{3\}
486 \cmd{stone}\{white\}\{d\}\{2\}
487 \cmd{stone}\{white\}\{d\}\{4\}
488 \cmd{stone}\{black\}\{f\}\{3\}
489 \cmd{stone}\{black\}\{e\}\{2\}
490 \cmd{stone}\{black\}\{e\}\{4\}
491 \cmd{end}\{psgopartialboard\}
492 \end{tabular}
493
494 \caption{Part of the configuration of Figure~\ref{fig:ko:configuration}}
495 \label{fig:partial:ko:configuration}
496 \end{center}
497
498 \end{figure}
499
500
501
502
503
504 \section{Stones in text}
505
506 In comments on a Go diagram, one often sees graphical representations
507 of the stones on the board. Therefore, \psgo{} has facilities to
508 include stones in running text. For instance, we can refer to stone
509 \stone[4]{black} of Figure~\ref{fig:9x9:example}(a) with the
510 command~\verb|\stone[4]{black}|. As can be seen, in running text
511 (i.e., outside the \verb|psgoboard| environment), \verb|\stone| takes
512 two parameters. The first one is optional and denotes a number or a
513 marker to be placed on the stone. The second parameter denotes the
514 color of the stone. As another example, here is a list of various stones:
515 \stone[\markma]{black}, \stone[\markma]{white},
516 \stone[\marktr]{black}, \stone[\marktr]{white},
517 \stone[\markcr]{black}, \stone[\markcr]{white},
518 \stone[\marksq]{black}, \stone[\marksq]{white},
519 \stone[\marklb{A}]{black}, \stone[\marklb{A}]{white},
520 \stone[\marksl]{black}, \stone[\marksl]{white},
521 \stone[\markdd]{black}, \stone[\markdd]{white}.
522 This list was generated by the following code:
523 \begin{verbatim}
524 \stone[\markma]{black}, \stone[\markma]{white},
525 \stone[\marktr]{black}, \stone[\marktr]{white},
526 \stone[\markcr]{black}, \stone[\markcr]{white},
527 \stone[\marksq]{black}, \stone[\marksq]{white},
528 \stone[\marklb{A}]{black}, \stone[\marklb{A}]{white},
529 \stone[\marksl]{black}, \stone[\marksl]{white},
530 \stone[\markdd]{black}, \stone[\markdd]{white}.
531 \end{verbatim}
532
533
534 It is possible to attach ordinary \LaTeX{} labels to \emph{moves}
535 on a board. For instance, the digram of Figure~\ref{fig:more:features}(b) was
536 generated by the following code:
537
538 \begin{verbatim}
539 \begin{psgoboard}[5]
540 \move{b}{2}
541 \move{d}{3}\label{go:move}
542 \move{d}{1}
543 \end{psgoboard}
544 \end{verbatim}
545 As can be seen, a label \verb|{funny:go:move}| is defined after the
546 second move. To refer in the text to this move, the ordinary \LaTeX{}
547 \verb|\ref| command can be used. In this case, we type
548 \verb|\stone[\ref{go:move}]{white}|, which results in the
549 stone~\stone[\ref{go:move}]{white}, as expected. Of course, the
550 color should still be defined manually.
551
552 \begin{figure}
553 \begin{center}
554
555 \begin{tabular}{cc}
556 \begin{psgoboard}[5]
557 \goline{a}{1}{c}{5}
558 \goarrow{e}{3}{b}{2}
559 \end{psgoboard}
560 &
561 \setcounter{gomove}{-1}
562 \begin{psgoboard}[5]
563 \move{b}{2}
564 \move{d}{3}\label{go:move}
565 \move{d}{1}
566 \end{psgoboard}\\
567 (a) Lines and arrows &
568 (b) Labeling stones
569 \end{tabular}
570
571 \caption{More \psgo{} features: lines, arrows, and labels}
572 \label{fig:more:features}
573 \end{center}
574 \end{figure}
575
576 \section{Remarks, limitations, and known bugs}
577
578 \begin{enumerate}
579
580 \item The \verb|\pass| moves cannot be labels with \verb|\label|.
581
582 \item Version 0.15 fixes the stones-on-the-edge problem introduced in
583 versions 13 and~14.
584
585 \item The \verb|\pass| command was requested by Markus Enzenberger
586 (16.09.2003). It was implemented at 01.10.2003. For convenience,
587 there is also a \verb|\pass*| command. Like \verb|\move*|,
588 \verb|\pass*| is useful for copy\&pasting moves and passes from
589 previous boards. See Figure~\ref{fig:9x9:example} for an example.
590
591 \item Lukas van de Wiel requested a possibility to generare partial
592 go-boards (27.09.2003). This was implemented in the
593 \texttt{psgopartialboard(*)} environments (see
594 Section~\ref{sec:partial-boards}) using the clipping features of
595 \textsf{pstricks}.
596
597 \item Xiaozhen Niu discovered a bug in partial go-boards (20.2.2004):
598 stones on the edge were not displayed completely if there are no
599 indices at that edge. This was fixed by setting the \verb+xoffset+ and
600 \verb+yoffset+ to .5\verb+\goxunit+ and .5\verb+goyunit+,
601 respectively.
602
603
604 \end{enumerate}
605
606 \end{document}