2 <!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
3 <!-- Created on July, 7 2004 by texi2html 1.64 -->
5 Written by: Lionel Cons <Lionel.Cons@cern.ch> (original author)
6 Karl Berry <karl@freefriends.org>
7 Olaf Bachmann <obachman@mathematik.uni-kl.de>
9 Maintained by: Olaf Bachmann <obachman@mathematik.uni-kl.de>
10 Send bugs and suggestions to <texi2html@mathematik.uni-kl.de>
14 <TITLE>GNU Shogi manual: xshogi</TITLE>
16 <META NAME="description" CONTENT="GNU Shogi manual: xshogi">
17 <META NAME="keywords" CONTENT="GNU Shogi manual: xshogi">
18 <META NAME="resource-type" CONTENT="document">
19 <META NAME="distribution" CONTENT="global">
20 <META NAME="Generator" CONTENT="texi2html 1.64">
24 <BODY LANG="" BGCOLOR="#FFFFFF" TEXT="#000000" LINK="#0000FF" VLINK="#800080" ALINK="#FF0000">
27 <TABLE CELLPADDING=1 CELLSPACING=1 BORDER=0>
28 <TR><TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_19.html#SEC19"> < </A>]</TD>
29 <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_21.html#SEC21"> > </A>]</TD>
30 <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_19.html#SEC19"> << </A>]</TD>
31 <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi.html#SEC_Top"> Up </A>]</TD>
32 <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_21.html#SEC21"> >> </A>]</TD>
33 <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi.html#SEC_Top">Top</A>]</TD>
34 <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_toc.html#SEC_Contents">Contents</A>]</TD>
35 <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_24.html#SEC24">Index</A>]</TD>
36 <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_abt.html#SEC_About"> ? </A>]</TD>
43 This section describes how to run the "xshogi" program.
55 xshogi provides an X11/Xt/Athena Widgets user interface for gnushogi.
56 With xshogi you can play gnushogi, set up arbitrary positions, force
57 variations, or watch xshogi manage a game between two shogi programs.
58 Furthermore, it can be used as an interface between two players on
62 xshogi can also be used as a shogi board to play out games. It will
63 read through a game file or allow a player to play through a variation
64 manually (force mode). This is useful for keeping track of email postal
65 games or browsing games off the net.
68 After starting xshogi, you can make moves by pressing mouse button 1
69 while the cursor is over a square with your piece on it and dragging the
70 mouse to another square. If the move is illegal, gnushogi will not
71 allow it. xshogi will then retract the move.
77 The following command line options also correspond to X resources that
78 you can set in your .Xdefaults file.
83 <DT><SAMP>`[standard Xt options]'</SAMP>
84 <DD>xshogi accepts standard Xt options like -display, -geometry, and
88 <DT><SAMP>`-tc or -timeControl minutes[:seconds]'</SAMP>
89 <DD>Amount of time for a set of moves determined by movesPerSession. If
90 this number of moves is played within the time control period, xshogi
91 resets the time clocks. Default: 5 minutes.
94 <DT><SAMP>`-mps or -movesPerSession moves'</SAMP>
95 <DD>Number of moves in a time control period. Default: 40 moves.
98 <DT><SAMP>`-st or -searchTime minutes[:seconds]'</SAMP>
99 <DD>Tell gnushogi to spend at most the given amount of time searching for
100 each of its moves. Without this option, gnushogi chooses its search
101 time based on the number of moves and amount of time remaining until the
102 next time control. Setting this option also sets -clockMode to False.
105 <DT><SAMP>`-sd or -searchDepth number'</SAMP>
106 <DD>Tell gnushogi to look ahead at most the given number of moves when
107 searching for a move to make. Without this option, gnushogi chooses
108 its search depth based on the number of moves and amount of time
109 remaining until the next time control. Setting this option also sets
113 <DT><SAMP>`-clock or -clockMode (True | False)'</SAMP>
114 <DD>Determines whether or not to use the clock. If clockMode is False, the
115 clock does not run, but the side that is to play next is still
119 <DT><SAMP>`-td or -timeDelay seconds'</SAMP>
120 <DD>Time delay between moves during "Load Game". This doesn't have to be
121 a round number. Try -td 0.4. Default: 1 second.
124 <DT><SAMP>`-nsp or -noShogiProgram (True | False)'</SAMP>
125 <DD>If this option is True, xshogi acts as a passive shogi board; it does
126 not try to start a shogi program, not even to check whether moves made
127 in Force mode are legal. It also sets -clockMode to False. Default:
131 <DT><SAMP>`-fsp or -firstShogiProgram program'</SAMP>
132 <DD>Name of first shogi program. In matches between two machines, this
133 program plays white. Default: "gnushogi".
136 <DT><SAMP>`-ssp or -secondShogiProgram program'</SAMP>
137 <DD>Name of second shogi program, if needed. In matches between two
138 machines, this program plays black; otherwise it is not started.
142 <DT><SAMP>`-fh or -firstHost host'</SAMP>
143 <DD>Name of host the first shogi program plays on. Default: "localhost".
146 <DT><SAMP>`-sh or -secondHost host'</SAMP>
147 <DD>Name of host the second shogi program plays on. Default: "localhost".
150 <DT><SAMP>`-rsh or -remoteShell shell_name'</SAMP>
151 <DD>Some systems do not use rsh as the remote shell. This option allows a
152 user to name the remote shell command. This should be done in the
156 <DT><SAMP>`-mm or -matchMode (False | Init | Position | Opening)'</SAMP>
157 <DD>Automatically run a game between firstShogiProgram and
158 secondShogiProgram. If matchMode is set to Init, xshogi will start the
159 game with the initial shogi position. If matchMode is set to Position,
160 xshogi will start the game with the position specified by the
161 loadPositionFile resource. If matchMode is set to Opening, xshogi will
162 play out the opening moves specified by the -loadGameFile resource. If
163 the -saveGameFile resource is set, a move record for the match will be
164 saved in the specified file. Default: "False".
167 <DT><SAMP>`-lgf or -loadGameFile file'</SAMP>
168 <DD>Name of file to read a game record from. Game files are found in the
169 directory named by the SHOGIDIR environment variable. If this variable
170 is not set, the current directory is used unless the file name starts
174 <DT><SAMP>`-lpf or -loadPositionFile file'</SAMP>
175 <DD>Name of file to read a game position from. Position files are found in
176 the directory named by the SHOGIDIR environment variable. If this
177 variable is not set, the current directory is used unless the file name
181 <DT><SAMP>`-sgf or -saveGameFile file'</SAMP>
182 <DD>Name of file to save a game record to. Game files are saved in the
183 directory named by the SHOGIDIR environment variable. If this variable
184 is not set, the current directory is used unless the file name starts
188 <DT><SAMP>`-spf or -savePositionFile file'</SAMP>
189 <DD>Name of file to save a game position to. Position files are saved in
190 the directory named by the SHOGIDIR environment variable. If this
191 variable is not set, the current directory is used unless the file name
195 <DT><SAMP>`-coords or -showCoords (True | False)'</SAMP>
196 <DD>If this option is True, xshogi displays algebraic coordinates along the
197 board's left and bottom edges. The default is False. The coordFont
198 resource specifies what font to use.
201 <DT><SAMP>`-mono or -monoMode (True | False)'</SAMP>
202 <DD>Determines whether xshogi displays its pieces and squares with two
203 colors or four. You shouldn't have to specify monochrome. xshogi will
204 determine if this is necessary.
207 <DT><SAMP>`-pc or -pieceColor color'</SAMP>
208 <DD>Color specification for pieces suitable for XParseColor().
212 <DT><SAMP>`-sc or -squareColor color'</SAMP>
213 <DD>Same for squares. Default: #EBDFB0.
216 <DT><SAMP>`-wps or -westernPieceSet (True | False)'</SAMP>
217 <DD>Choose the Western style piece set.
220 <DT><SAMP>`-npb or -normalPawnBitmap file'</SAMP>
221 <DD><DT><SAMP>`-nnb or -normalKnightBitmap file'</SAMP>
222 <DD><DT><SAMP>`-nbb or -normalBishopBitmap file'</SAMP>
223 <DD><DT><SAMP>`-nrb or -normalRookBitmap file'</SAMP>
224 <DD><DT><SAMP>`-nkb or -normalKingBitmap file'</SAMP>
225 <DD>Names of the bitmap files for the bitmap piece icons.
228 <DT><SAMP>`-rpb or -reversePawnBitmap file'</SAMP>
229 <DD><DT><SAMP>`-rnb or -reverseKnightBitmap file'</SAMP>
230 <DD><DT><SAMP>`-rbb or -reverseBishopBitmap file'</SAMP>
231 <DD><DT><SAMP>`-rrb or -reverseRookBitmap file'</SAMP>
232 <DD><DT><SAMP>`-rkb or -reverseKingBitmap file'</SAMP>
233 <DD>Names of the bitmap files for the outline piece icons.
236 <DT><SAMP>`-debug or -debugMode (True | False)'</SAMP>
237 <DD>Turns on debugging printout.
248 <DT><SAMP>`initString'</SAMP>
249 <DD>The actual string that is sent to initialize the shogi program can be
250 set from .Xdefaults. It can't be set from the command line because of
251 syntax problems. The default value is "new\nbeep\nrandom\neasy\n".
252 The "new" and "beep" commands are required. You can remove the
253 "random" command if you like; including it causes gnushogi to
254 randomize its move selection slightly so that it doesn't play the same
255 moves in every game. Even without "random", gnushogi randomizes its
256 choice of moves from its opening book. You can also remove "easy" if
257 you like; including it toggles easy mode off, causing gnushogi to think
258 on your time. That is, if "easy" is included in the initString, GNU
259 Shogi thinks on your time; if not, it does not. (Yes, this does seem
260 backwards, doesn't it.) You can also try adding other commands to the
261 initString; see the gnushogi documentation (see section <A HREF="gnushogi_19.html#SEC19">3. gnushogi</A>) for
265 <DT><SAMP>`blackString and whiteString'</SAMP>
266 <DD>These resources control what is sent when the Machine Black and Machine
267 White buttons are selected. This is mostly for compatibility with
268 obsolete versions of gnushogi.
271 Alternate bitmaps for piece icons can be specified either by choosing
272 one of the built-in sets or with the file name resources described
273 above. There are three built-in sets of piece bitmaps available, large
274 (the default), medium, or small. It is easiest to select the set you
275 prefer in the .Xdefaults file:
278 XShogi*boardSize: Medium
281 The font used for button labels and comments can be changed in the
282 .Xdefaults file. You may want to choose a smaller font if you are using
286 XShogi*font: helvetica_oblique12
289 The font used for coordinates (when the showCoords option is True) can
293 XShogi*coordFont: helvetica_10
296 If you are using a grayscale monitor, try setting the colors to:
299 XShogi*pieceColor: gray100 <BR>
300 XShogi*squareColor: gray60 <BR>
306 COMMAND BUTTONS AND KEYS
311 <DT><SAMP>`Quit'</SAMP>
312 <DD>Quits xshogi. Q or q is a keyboard equivalent.
315 <DT><SAMP>`Reset'</SAMP>
316 <DD>Resets xshogi to the beginning of a shogi game. It also deselects any
317 game or position files.
320 <DT><SAMP>`Flip View'</SAMP>
321 <DD>inverts the view of the shogi board.
324 <DT><SAMP>`Hint'</SAMP>
325 <DD>displays a move hint from gnushogi.
328 <DT><SAMP>`Load Game'</SAMP>
329 <DD>plays a game from a record file. If no file is specified a popup dialog
330 asks for a filename. Game files are found in the directory named by the
331 SHOGIDIR environment variable. If this variable is not declared then
332 the current directory is used unless the file name starts with a /. G
333 or g is a keyboard equivalent. The game file parser will accept almost
334 any file that contains moves in algebraic notation. If the first line
335 begins with `#', it is assumed to be a title and is displayed. Text
336 enclosed in parentheses or square brackets is assumed to be commentary
337 and is displayed in a pop-up window. Any other text in the file is
341 <DT><SAMP>`Load Position'</SAMP>
342 <DD>sets up a position from a position file. If no file is specified a
343 popup dialog asks for a filename. Position files are found in the
344 directory named by the SHOGIDIR environment variable. If this variable
345 is not declared then the current directory is used unless the file name
346 starts with a /. Position files must be in the format that the Save
347 Position command writes.
350 <DT><SAMP>`Save Game'</SAMP>
351 <DD>saves a game to a record file. If no file is specified a popup dialog
352 asks for a filename. If the filename exists, the user is asked whether
353 the current game record is be appended to this file or if the file
354 should be replaced. Game files are saved in the directory named by the
355 SHOGIDIR environment variable. If this variable is not declared then
356 the current directory is used unless the file name starts with a /.
357 Game files are human-readable, and can also be read back by the Load
358 Game command. Furthermore, they are accepted as gnushogi text bookfiles.
361 <DT><SAMP>`Save Position'</SAMP>
362 <DD>saves a position to a position file. If no file is specified a popup
363 dialog asks for a filename. Position files are saved in the directory
364 named by the SHOGIDIR environment variable. If this variable is not
365 declared then the current directory is used unless the file name starts
366 with a /. Position files are human-readable, and can also be read back
367 by the Load Position command.
370 <DT><SAMP>`Machine White'</SAMP>
371 <DD>forces gnushogi to play white.
374 <DT><SAMP>`Machine Black'</SAMP>
375 <DD>forces gnushogi to play black.
378 <DT><SAMP>`Force Moves'</SAMP>
379 <DD>forces a series of moves. That is, gnushogi stops playing and xshogi
380 allows you to make moves for both white and black.
383 <DT><SAMP>`Two Machines'</SAMP>
384 <DD>plays a game between two computer programs.
387 <DT><SAMP>`Forward'</SAMP>
388 <DD>moves forward through a series of remembered moves. F or f is a
392 <DT><SAMP>`Backward'</SAMP>
393 <DD>moves backward through a series of remembered moves. As a side effect,
394 puts xshogi into Force Moves mode. B or b is a keyboard equivalent.
397 <DT><SAMP>`Pause'</SAMP>
398 <DD>pauses the clocks or (in Load Game mode) pauses the game being loaded.
399 Press Pause again to continue. P or p is a keyboard equivalent.
402 <DT><SAMP>`Edit Position'</SAMP>
403 <DD>lets you set up an arbitrary board position. Use mouse button 1 to drag
404 pieces to new squares, or to delete a piece by dragging it off the board
405 or dragging an empty square on top of it. To drop a new piece on a
406 square, press mouse button 2 or 3 over the square. This brings up a
407 menu of black pieces (button 2) or white pieces (button 3). Additional
408 menu choices let you empty the square or clear the board. You can set
409 the side to play next by clicking on the Black or White indicator at the
413 <DT><SAMP>`Challenge'</SAMP>
414 <DD>allows you to make a two display game between two human players. Enter
415 the display you want to connect to. If you are allowed to connect, a
416 new board is displayed at the remote display. Challenge mode can only
417 be stopped by pressing "quit".
420 <DT><SAMP>`Select Level'</SAMP>
421 <DD>allows you to reset the clocks for both players. Enter the number of
422 moves and the number of minutes in which the moves should be done.
425 <DT><SAMP>`Move NOW'</SAMP>
426 <DD>force computer to stop thinking and to make the current best move.
429 <DT><SAMP>`Iconify I, i, C or c'</SAMP>
430 <DD>iconifies xshogi.
439 If you press the Pause button during GNU Shogi's turn,
440 xshogi will stop the clocks, but gnushogi will still make a
444 After a mate or draw when playing against gnushogi, if you
445 back up with the Backward button, the clocks are reset
446 (because gnushogi has exited and must be restarted).
449 The game parser recognizes only algebraic notation.
455 Original authors of XBoard: Chris Sears and Dan Sears.
458 Enhancements for XBoard (Version 2.0): Tim Mann.
461 Conversion to XShogi (Version 1.1): Matthias Mutz.
464 Current maintainer: Mike Vanier.
467 COPYRIGHT INFORMATION
470 XShogi borrows its piece bitmaps from CRANES Shogi.
473 Copyright 1991 by Digital Equipment Corporation, Maynard, Massachusetts.
474 Enhancements Copyright 1992 Free Software Foundation, Inc. Enhancements
475 Copyright 1993 Matthias Mutz. Further enhancements copyright 1999 by
476 Michael Vanier and the Free Software Foundation, Inc.
479 The following terms apply to Digital Equipment Corporation's copyright
486 Permission to use, copy, modify, and distribute this software and its
487 documentation for any purpose and without fee is hereby granted,
488 provided that the above copyright notice appear in all copies and that
489 both that copyright notice and this permission notice appear in
490 supporting documentation, and that the name of Digital not be used in
491 advertising or publicity pertaining to distribution of the software
492 without specific, written prior permission.
495 DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
496 ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
497 DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
498 ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
499 WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
500 ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
504 The following terms apply to the enhanced version of XShogi distributed
505 by the Free Software Foundation:
508 This file is part of XSHOGI.
511 XSHOGI is distributed in the hope that it will be useful, but WITHOUT
512 ANY WARRANTY. No author or distributor accepts responsibility to anyone
513 for the consequences of using it or for whether it serves any particular
514 purpose or works at all, unless he says so in writing. Refer to the
515 XSHOGI General Public License for full details.
518 Everyone is granted permission to copy, modify and redistribute XSHOGI,
519 but only under the conditions described in the XSHOGI General Public
520 License. A copy of this license is supposed to have been given to you
521 along with XSHOGI so you can know your rights and responsibilities. It
522 should be in a file named COPYING. Among other things, the copyright
523 notice and this notice must be preserved on all copies.
526 <A NAME="References and links"></A>
528 <TABLE CELLPADDING=1 CELLSPACING=1 BORDER=0>
529 <TR><TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_19.html#SEC19"> < </A>]</TD>
530 <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_21.html#SEC21"> > </A>]</TD>
531 <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_19.html#SEC19"> << </A>]</TD>
532 <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi.html#SEC_Top"> Up </A>]</TD>
533 <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_21.html#SEC21"> >> </A>]</TD>
534 <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT"> <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi.html#SEC_Top">Top</A>]</TD>
535 <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_toc.html#SEC_Contents">Contents</A>]</TD>
536 <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_24.html#SEC24">Index</A>]</TD>
537 <TD VALIGN="MIDDLE" ALIGN="LEFT">[<A HREF="gnushogi_abt.html#SEC_About"> ? </A>]</TD>
541 This document was generated
542 by <I>Michael C. Vanier</I> on <I>July, 7 2004</I>
543 using <A HREF="http://www.mathematik.uni-kl.de/~obachman/Texi2html
544 "><I>texi2html</I></A>