xboard.git
10 years agoImplement LionChess
H.G. Muller [Mon, 30 Sep 2013 20:14:15 +0000]
Implement LionChess

Add legality testing for Lions, so it ca be played with legality testing on.
Cyan markers are now also used in autonomous highlighting, so that double-
moving is triggered: A new move type FirstLeg instructs the marker callback
to use cyan on Lion contact captures. Igui required a special test, to make
XBoard realize the fial square is empty. Implement Lion-capture rules.
Forbid Pawn promotion to Lion: The Lion is skipped during the promotion
sweep (and it was not in the promotion popp anyway). Chu should not suffer
from this, as the piece used as promoted Kylin is not a real Lion (although
it looks like one). King is not considered a protector in Mighty-Lion Chess
This rule was added to allow trading Lions in the late end-game,
to prevent the game from being too drawish.

10 years agoFix sweep promotions
H.G. Muller [Mon, 30 Sep 2013 20:01:00 +0000]
Fix sweep promotions

10 years agoFix hover event
H.G. Muller [Mon, 30 Sep 2013 10:14:46 +0000]
Fix hover event

HoverEvent was relying on highlight-dragging to detect if the mouse pointer
entered a new square, but on XBoard highlight dragging is sick. Now the
routine remembers the previous mouse position independent of the highlights.
To detect if we are in the starting square, it looks for change of the
from-square, in which case it fakes (first) entry of the current square
(where it saves marker state, so it can be restored after we leave the
square again, in case the engine saw fit to respond to the hover command).

10 years agoImplement Chu Shogi
H.G. Muller [Sun, 29 Sep 2013 22:00:43 +0000]
Implement Chu Shogi

Chu Shogi is added as a new variant, usig the extended piece set.
Implement Lion double-moves. Apart from a from- and a to-square, each move
now also has a kill square (all represented by X and Y coordinate). This
is set on receiving a pair of partial moves (and passed around as a global;
sorry about that). MakeMove uses the kill-square to remove an extra piece,
and append it as ";SQUARE" to the long-algebraic move. SendMoveToProgram()
converts this back to a double move of the Alien protocol (two comma-separated
long-algebraic moves, stepping via SQUARE).
  For user input, releasing or to-clicking on a cyan square sets the kill-
square, and sends a lift command to prompt the engine for the markers for
the second leg. The to-click of this second leg then determines the to-square.

10 years agoIncrease number of piece types to 44
H.G. Muller [Sun, 29 Sep 2013 21:21:32 +0000]
Increase number of piece types to 44

SVG pieces are added for implementing Chu Shogi; the promoted versions for
Chu are offset by 22 rather than the usual 11.

10 years agoAutomatically adapt board format to FEN
H.G. Muller [Sat, 7 Sep 2013 21:47:42 +0000]
Automatically adapt board format to FEN

In some situations (such as loading a game or poition) the board-size
overrules are directly set to the values that can be deduced from the FEN.
The routine ParseFEN() has an extra parameter autoSize to control that.

10 years agoClear memory of erased position on variant switch
H.G. Muller [Sun, 22 Dec 2013 10:48:26 +0000]
Clear memory of erased position on variant switch

The Edit Position clear-board cycle would go from initial position to
last-erased position (if this is different), but the latter could have been
from another variant. In wich case we also want to clear.
  also print a message to alert people to the fact that they can click the
clock again to restore the position.

10 years agoImprove Edit Position mode
H.G. Muller [Sat, 21 Dec 2013 23:08:35 +0000]
Improve Edit Position mode

Clear Board now cycles trough boards:
current -> empty -> some pieces -> all pieces -> current
were 'some pieces' sows every piece type once (ad no Pawns), while
'all pieces' is the stadard opening position. In the end you get the
position that was erased back (to recover from accidental erasure).

10 years agoconverted icons from xpm to png
Arun Persaud [Sat, 7 Dec 2013 19:48:10 +0000]
converted icons from xpm to png

This removes all xpm images from XBoard.

10 years agoremove xpm from XBoard
Arun Persaud [Sun, 29 Sep 2013 18:04:19 +0000]
remove xpm from XBoard

XBoard does not use xpm files anymore, apart as a fallback for desktop icons.
Therefore, all references to libxpm was removed.

Also zic2xpm was removed from XBoard, since it converted pieces is not that usefull anymore.

10 years agoUpdated Spanish translation
Arun Persaud [Sat, 7 Dec 2013 16:48:48 +0000]
Updated Spanish translation

10 years agoOnly save clock settings in PGN when an engine plays
H.G. Muller [Wed, 4 Dec 2013 19:26:59 +0000]
Only save clock settings in PGN when an engine plays

10 years agoanother round of translation string fixes
Arun Persaud [Mon, 2 Dec 2013 02:55:31 +0000]
another round of translation string fixes

Thanks to Benno Schulenberg for pointing these and the previous string changes out to us.

10 years agoupdated Spanish translation
Arun Persaud [Mon, 2 Dec 2013 01:38:36 +0000]
updated Spanish translation

10 years agoupdated Dutch translation
Arun Persaud [Mon, 2 Dec 2013 01:38:04 +0000]
updated Dutch translation

10 years agoSave clocks with unfinished PGN games
H.G. Muller [Tue, 26 Nov 2013 12:21:51 +0000]
Save clocks with unfinished PGN games

When saving a game with an unfinished result, the remaining time of both
players is appended to the result comment, as "(Clocks: WHITETIME, BLACKTIME)"
with the times in seconds. When a game with unfinished result is loaded,
and the result message contains such a text, the clock settings are restored
from it accordingly. This makes it easier to resume interrupted games.

10 years agoAutomaticaly install Java engines
H.G. Muller [Tue, 26 Nov 2013 09:51:25 +0000]
Automaticaly install Java engines

If the engine name entered in the Load Engine dialog refers to a .jar file,
the text "java -jar " will be prefixed to the engine command automatically.

10 years agoRename Match dialog to Tournament
H.G. Muller [Tue, 26 Nov 2013 09:21:08 +0000]
Rename Match dialog to Tournament

Rename this dialog to conform with XBoard, both in menu item and window title.
Also puts the remark on sync options in a single Label Option above the
options, rather than distributed over two lines behind the checkboxes.

10 years agoupdated German translation
Arun Persaud [Mon, 25 Nov 2013 03:08:00 +0000]
updated German translation

10 years agoupdated Dutch translation
Arun Persaud [Mon, 25 Nov 2013 02:25:10 +0000]
updated Dutch translation

10 years agomore translations fixes: use uppercase for variant names
Arun Persaud [Mon, 25 Nov 2013 02:21:56 +0000]
more translations fixes: use uppercase for variant names

10 years agofixed some more translation strings
Arun Persaud [Mon, 25 Nov 2013 02:06:11 +0000]
fixed some more translation strings

10 years agooutput configure options when looking at --version
Arun Persaud [Sat, 23 Nov 2013 18:17:39 +0000]
output configure options when looking at --version

10 years agoexpose the configure options to xboard
Arun Persaud [Sat, 23 Nov 2013 18:16:28 +0000]
expose the configure options to xboard

10 years agoconfigure.ac: don't set xaw if we choose gtk
Arun Persaud [Sat, 23 Nov 2013 17:49:46 +0000]
configure.ac: don't set xaw if we choose gtk

10 years agofixed some whitespace issues in configure.ac
Arun Persaud [Sat, 23 Nov 2013 17:49:04 +0000]
fixed some whitespace issues in configure.ac

10 years agoTranslation: fixed some inconsistencies reported by Benno Schulenberg
Arun Persaud [Sat, 23 Nov 2013 05:10:25 +0000]
Translation: fixed some inconsistencies reported by Benno Schulenberg

10 years agoAdded Dutch translation
Arun Persaud [Fri, 22 Nov 2013 03:52:57 +0000]
Added Dutch translation

10 years agoUpdated Ukrainian translations
Arun Persaud [Fri, 22 Nov 2013 03:49:46 +0000]
Updated Ukrainian translations

10 years agoUpdated German translation
Arun Persaud [Sat, 16 Nov 2013 22:34:53 +0000]
Updated German translation

10 years agoBUILD: fix withXaw conditional (tiny change)
hasufell [Wed, 18 Sep 2013 03:57:03 +0000]
BUILD: fix withXaw conditional (tiny change)

Listing both one after another leads to withXaw being false
if you pass "--with-Xaw3d --without-Xaw".

10 years agoBUILD: make Xaw frontend default (tiny change)
hasufell [Wed, 18 Sep 2013 03:56:07 +0000]
BUILD: make Xaw frontend default (tiny change)

10 years agoBUILD: fix configure switches (tiny change)
hasufell [Wed, 18 Sep 2013 03:54:15 +0000]
BUILD: fix configure switches (tiny change)

10 years agoBUILD: make paths modifiable (tiny change)
hasufell [Wed, 18 Sep 2013 03:39:17 +0000]
BUILD: make paths modifiable (tiny change)

    This can help with setups where games are installed in their
    own location, but system data files like desktopfiles
    should still go to /usr/share.

        https://savannah.gnu.org/bugs/index.php?39969

10 years agoMake XBoard xpm-free
H.G. Muller [Sat, 7 Sep 2013 16:48:34 +0000]
Make XBoard xpm-free

The icons in the Engine-Output window were the only pixmaps still in use.
They are now replaced by bitmaps, like the checkmark already was.

10 years agoImplement (inaccessible) dark squares
H.G. Muller [Sun, 1 Sep 2013 20:47:14 +0000]
Implement (inaccessible) dark squares

10 years agoFix variant choice for second engine
H.G. Muller [Sun, 1 Sep 2013 20:11:30 +0000]
Fix variant choice for second engine

10 years agoFix engine-defined names
H.G. Muller [Sun, 1 Sep 2013 18:35:43 +0000]
Fix engine-defined names

10 years agoAllow engine to define its own variant names
H.G. Muller [Sat, 31 Aug 2013 21:31:52 +0000]
Allow engine to define its own variant names

Non-standard variants will appear in the New Variant menu, and when
selected will lead to sending of the engine-defined name in the variant
comand to the engine. Which then should report with a setup commandto specify parent variant, board & holdings size, piece-to-char table and
iitial position.

10 years agoMerge branch 'v4.7.x'
Arun Persaud [Thu, 29 Aug 2013 05:04:01 +0000]
Merge branch 'v4.7.x'

Conflicts:
winboard/winboard.c

also fixed version number and po files after merge with v4.7.x branch

10 years agoupdated po files for new release (make distcheck)
Arun Persaud [Thu, 29 Aug 2013 04:50:30 +0000]
updated po files for new release (make distcheck)

10 years agonew version number for release 4.7.2
Arun Persaud [Thu, 29 Aug 2013 04:48:27 +0000]
new version number for release 4.7.2

10 years agoupdated Changelog, NEWS, etc.
Arun Persaud [Thu, 29 Aug 2013 04:45:51 +0000]
updated Changelog, NEWS, etc.

10 years agoFix -zippyVariants option
H.G. Muller [Tue, 27 Aug 2013 20:55:52 +0000]
Fix -zippyVariants option

Due to the change of cps->variants from (char []) to (char *), copying
zippyVariants to it on behalf of v1 engines would no longer work. This
is fixed by using ASSIGN() in stead of safeStrCpy().

10 years agoFix -zippyVariants option
H.G. Muller [Tue, 27 Aug 2013 20:55:52 +0000]
Fix -zippyVariants option

Due to the change of cps->variants from (char []) to (char *), copying
zippyVariants to it on behalf of v1 engines would no longer work. This
is fixed by using ASSIGN() in stead of safeStrCpy().

10 years agoFix XBoard hover command
H.G. Muller [Fri, 5 Jul 2013 16:30:06 +0000]
Fix XBoard hover command

10 years agoAllow engine to click squares on behalf of user
H.G. Muller [Wed, 3 Jul 2013 17:39:25 +0000]
Allow engine to click squares on behalf of user

A new engine->GUI command 'click SQUARE' is added, which will trigger the
same events in the GUI as when the user clicked the mentioned SQUARE
(up+down). With legality testing off, this allows an engine to implement
one-click moving, in response to a 'lift' command issued by the GUI when
the user clicks the from-square.

A comma suffixed to the square is used to indicate the specified click
should be performed as if the user hat the Ctrl key pressed during it.

10 years agoLet magenta marker activate sweep promotion
H.G. Muller [Wed, 3 Jul 2013 14:37:27 +0000]
Let magenta marker activate sweep promotion

This allows an engine to indicate non-standard promotion possibilities.

10 years agoImplement hover command
H.G. Muller [Wed, 3 Jul 2013 14:27:47 +0000]
Implement hover command

When the user hovers a dragged piece over a square marked as a legal
capture target (by R in the highlight command), the engine is notified
by a hover command indicating the square (at the moment the user enters it).
Only send hover when the engine has feature highlight=1.

10 years agoExpand number of marker colors to 8
H.G. Muller [Wed, 3 Jul 2013 13:59:41 +0000]
Expand number of marker colors to 8

The markers for -showTargetSquares are now no longer tied to the highlight
and premove highlight colors, but are hard-coded RGB, YCM and BW.

10 years agoUse highlight command to specify move legality
H.G. Muller [Wed, 3 Jul 2013 13:34:48 +0000]
Use highlight command to specify move legality

When a highlight command has been sent, LeftClick will only accept
to-square events when they occur on a square that highlight marked
as legal, i.e. indicated by a capital. The transparant 'color' T
is added to allow the engine to mark a to-square as legal without
putting any visible marker on it.

10 years agoImplement board-marker protocol
H.G. Muller [Wed, 3 Jul 2013 13:28:38 +0000]
Implement board-marker protocol

The commands 'lift SQ' and 'put SQ' are sent to the engine to indicate
the user selects or puts down pieces, so the engine can respond with
'highlight FEN' to put markers on the board. This implements an externally
driven -showTargetSquares feature. The engine has to enable this by
'feature highight=1' The highlight command is further ignored when
native showTargetSquares is on.
  A comma suffix on the square is used to indicate the user kept Ctrl
down during the to-square event reported by the put command.

10 years agoFix initial board sizing WB
H.G. Muller [Mon, 26 Aug 2013 16:25:55 +0000]
Fix initial board sizing WB

The initial board size was based on the assumption the board would be 8x8.
This could push auxiliary windows off screen if the board was smaller,
after which EnsureOnScreen would undock them and park them in the upper-
right corner before the board assumed its true size. InitPos() is now called
before the initial sizing to et the board format correctly, InitDrawingSizes()
had to be made resitant to calling before a board size was picked for this
(because InitPos() might call that too).
  ActivateTheme() now uses the new board size, not the previous one (as was
indicated by size -2), so that -boardSize specifications inside a theme
will take effect.
  Board size petite should not be forbidden for Shogi; all pieces exist there.

10 years agoFix grabbing of selected piece
H.G. Muller [Mon, 26 Aug 2013 12:40:57 +0000]
Fix grabbing of selected piece

A second static click on a selected piece should deselect it, but an attempt
to drag an already selected piece should not 'bounce off'. It was already
possible to move a selected piece to another square, but the dragging was
not animated. This is now fixed, by only skipping the code to start dragging
when the second click is part of the only-move double-click for only capture.
(Before it was skipped on any second click.)

10 years agoAllow entry of negative numbers in spin control (WB)
H.G. Muller [Mon, 26 Aug 2013 11:35:47 +0000]
Allow entry of negative numbers in spin control (WB)

Windows numeric controls do not accept negative numbers, so in case the
range of a spin option can go negative, the style ES_NUMBER should not be
set on the control.

10 years agoAllow drops / promotions/ deferrals to be edited into book
H.G. Muller [Mon, 26 Aug 2013 09:37:27 +0000]
Allow drops / promotions/ deferrals to be edited into book

For no real reason only NormalMove would be accepted when parsing the list
of book moves.

10 years agoFix GUI book after setup position
H.G. Muller [Mon, 26 Aug 2013 09:28:54 +0000]
Fix GUI book after setup position

The routine to send move to the engine would automatically append a 'go'
is a preious setboard had put the engine in force mode, but this should
not happen on a book hit, where the engine should even be put in force mode
if it was not yet there.

10 years agoFix book creation
H.G. Muller [Fri, 5 Jul 2013 16:32:46 +0000]
Fix book creation

Due to duplicate use of the same file pointer variable the game file would be
closed before any games were read from it.

10 years agoMake PGN parser immune to unprotected time stamps
H.G. Muller [Mon, 20 May 2013 09:14:01 +0000]
Make PGN parser immune to unprotected time stamps

The parser choked on time stamps of the form dd:dd or dd:dd:dd if one
of the fields happened to be 00, because it wouldmistake that for a
non-compliant king-side castling. By excluding this interpretation when
the 00 is immediately preceded or followed by ':' this is now prevented.

10 years agoAllow seting of -egtPath through menu WB
H.G. Muller [Mon, 26 Aug 2013 17:57:43 +0000]
Allow seting of -egtPath through menu WB

The Nalimov Path control in Common Engine Options can now also be used
to set the -egtPath; if it has the format of an egtPath string, it will
count for the latter. If both -defaultPathEGTB and -egtPath are defined
(which is really an inconsistent setting), the Nalimov path will be displayed.

10 years agoAdd checkboxes for autoDisplayTags/Comments in menu WB
H.G. Muller [Mon, 26 Aug 2013 17:52:11 +0000]
Add checkboxes for autoDisplayTags/Comments in menu WB

The auto-display options can now be controlled from the Genral Options
menu dialog through two new checkboxes.

10 years agoFix initial board sizing WB
H.G. Muller [Mon, 26 Aug 2013 16:25:55 +0000]
Fix initial board sizing WB

The initial board size was based on the assumption the board would be 8x8.
This could push auxiliary windows off screen if the board was smaller,
after which EnsureOnScreen would undock them and park them in the upper-
right corner before the board assumed its true size. InitPos() is now called
before the initial sizing to et the board format correctly, InitDrawingSizes()
had to be made resitant to calling before a board size was picked for this
(because InitPos() might call that too).
  ActivateTheme() now uses the new board size, not the previous one (as was
indicated by size -2), so that -boardSize specifications inside a theme
will take effect.
  Board size petite should not be forbidden for Shogi; all pieces exist there.

10 years agoFix grabbing of selected piece
H.G. Muller [Mon, 26 Aug 2013 12:40:57 +0000]
Fix grabbing of selected piece

A second static click on a selected piece should deselect it, but an attempt
to drag an already selected piece should not 'bounce off'. It was already
possible to move a selected piece to another square, but the dragging was
not animated. This is now fixed, by only skipping the code to start dragging
when the second click is part of the only-move double-click for only capture.
(Before it was skipped on any second click.)

10 years agoAllow entry of negative numbers in spin control (WB)
H.G. Muller [Mon, 26 Aug 2013 11:35:47 +0000]
Allow entry of negative numbers in spin control (WB)

Windows numeric controls do not accept negative numbers, so in case the
range of a spin option can go negative, the style ES_NUMBER should not be
set on the control.

10 years agoAdd Save button to Edit Tags dialog
H.G. Muller [Mon, 26 Aug 2013 10:03:30 +0000]
Add Save button to Edit Tags dialog

When editing an opening book it is very anoying if the Edit Book dialog closes
every time you add a move or change a weight, and closing the dialog was
(in WB) the only way to save the changes. A separate button now is added for
this. Pressing it will also cause a refresh of the list of book moves, so
the user can see if his change were accepted, and the consequences for the
playing percentages.

10 years agoAllow drops / promotions/ deferrals to be edited into book
H.G. Muller [Mon, 26 Aug 2013 09:37:27 +0000]
Allow drops / promotions/ deferrals to be edited into book

For no real reason only NormalMove would be accepted when parsing the list
of book moves.

10 years agoFix GUI book after setup position
H.G. Muller [Mon, 26 Aug 2013 09:28:54 +0000]
Fix GUI book after setup position

The routine to send move to the engine would automatically append a 'go'
is a preious setboard had put the engine in force mode, but this should
not happen on a book hit, where the engine should even be put in force mode
if it was not yet there.

10 years agoFix book creation
H.G. Muller [Fri, 5 Jul 2013 16:32:46 +0000]
Fix book creation

Due to duplicate use of the same file pointer variable the game file would be
closed before any games were read from it.

10 years agoAdd quit-after-game checkbox in ICS options dialog XB
H.G. Muller [Sun, 16 Jun 2013 12:49:55 +0000]
Add quit-after-game checkbox in ICS options dialog XB

This checkbox can be used to log out from a busy ICS where your engine
running in zippy mode is in much demand, without having to abort a game.
The state of the box is checked in GameEnd, and when checked will cause
an ExitEvent (only in ICS mode).

10 years agoBuild in limited EPD capability for engine fingerprintig
H.G. Muller [Sun, 16 Jun 2013 15:54:31 +0000]
Build in limited EPD capability for engine fingerprintig

The new option -finger FILENAME causes games to end after the first
move, where the initial position plus the move will then be written to
the specified file in EPD format. This can be used in match mode with
a set of start positions or opening lines to record the best moves of
an engine on a set of positions (as in CSVN fingerprinting).

10 years agoDo not always start Makruk & ASEAN as setup position
H.G. Muller [Sat, 1 Jun 2013 17:56:17 +0000]
Do not always start Makruk & ASEAN as setup position

All engines by now should know the start position by themselves, and
considering it a setup poition would interfere with the possibility for
an engine to load the GUI with the aid of a setup command when it wants
to play a Makruk variant (such as Cambodian or Ai-Wok) with legality
testing off.

10 years agoMake writing of move counts in PositionToFEN optional
H.G. Muller [Sat, 1 Jun 2013 17:53:34 +0000]
Make writing of move counts in PositionToFEN optional

This way it can be used to write the position part of an EPD, which should
not contain the move-count fields.

10 years agoMake PGN parser immune to unprotected time stamps
H.G. Muller [Mon, 20 May 2013 09:14:01 +0000]
Make PGN parser immune to unprotected time stamps

The parser choked on time stamps of the form dd:dd or dd:dd:dd if one
of the fields happened to be 00, because it wouldmistake that for a
non-compliant king-side castling. By excluding this interpretation when
the 00 is immediately preceded or followed by ':' this is now prevented.

10 years agoImplement variant ASEAN
H.G. Muller [Sun, 19 May 2013 21:03:09 +0000]
Implement variant ASEAN

This is basically a clone of Makruk, with as only difference the depth of the
promotion zone, the initial setup, and the pieceToCharTable.

11 years agoupdated po files for new release (make distcheck)
Arun Persaud [Sun, 5 May 2013 15:03:00 +0000]
updated po files for new release (make distcheck)

11 years agonew version number for release 4.7.1
Arun Persaud [Sun, 5 May 2013 14:57:22 +0000]
new version number for release 4.7.1

11 years agoupdated Changelog, NEWS, etc.
Arun Persaud [Sun, 5 May 2013 14:53:54 +0000]
updated Changelog, NEWS, etc.

11 years agoUpdate zippy.README
H.G. Muller [Thu, 2 May 2013 20:47:44 +0000]
Update zippy.README

It is explained how to generate multi-line commands for -zipyGameEnd.

11 years agoFix Xaw file browser
H.G. Muller [Mon, 1 Apr 2013 18:43:36 +0000]
Fix Xaw file browser

The 'next page' entry of the Xaw file browser contained a \177 character
to keep at sorted at the bottom. This caused trouble for gettext.
Now the sorting range is adapted so the 'next page' is never part of it.
  More seriously, the listbox fill code had a wrong cast when testing for
an empty listbox on the first element, so that it only tested the low byte
of the pointer, in stead of the entire pointer for NULLness. As a result
the contents of the listboxes could suddenly disappear when even when it
was non-empty, because the first filename was allocated at an unlucky address.

11 years agoMake Chat Box window obey -topLevel option
H.G. Muller [Fri, 22 Mar 2013 18:23:25 +0000]
Make Chat Box window obey -topLevel option

It was always popping up as a dialog of the main board, covering it.
One could argue it should always be to-level.

11 years agoFix scrolling of Chat Box
H.G. Muller [Tue, 19 Mar 2013 12:20:24 +0000]
Fix scrolling of Chat Box

Seems the problem is that scroll_to_iter does not work until after some time,
needed to calculate line heights. Use scroll_to_mark instead, after clumsily
adding a text_mark.

11 years agoFix GTK SetInsertPos
H.G. Muller [Sun, 17 Mar 2013 09:33:31 +0000]
Fix GTK SetInsertPos

SetInsertPos() was not yet ported to GTK, with as a result that the cursor
was positioned at the start of a line recalled in the ICS Input Box,
rather than at the end. The code also called SetInsertPos to force scrolling
to that point in the text (which in Xaw is an automatic side effect). So for
multi-line text edits this function calls ScrollToCursor(). For some reason
this does not work when replacing texts in the Chat Box memo, when switching
chat, although it does work in the same memo when a line is added to the
existing text.

11 years agoPrint score of final position in Analyze Game
H.G. Muller [Thu, 7 Mar 2013 20:38:43 +0000]
Print score of final position in Analyze Game

The score/depth of the final position of the analyed game is added
(as an explicit comment) behind the PV of the forelast position.
To make this work, a new 'addBraces' mode (3) had to be added to
AppendComment, which suppresses stripping of the score/depth from
the comment.

11 years agoFix horrible bug in reading scores from PGN
H.G. Muller [Tue, 12 Mar 2013 17:50:08 +0000]
Fix horrible bug in reading scores from PGN

Reading scores like -0.94 flipped the sign, because the integer part
-0 would read as 0, and thus was no reason for sign flipping.

11 years agoFix disappearence of pieces that were moved illegally
H.G. Muller [Sun, 10 Mar 2013 11:43:59 +0000]
Fix disappearence of pieces that were moved illegally

Dragging damages the from-square, but it is not marked as such, because
selective board redraws to update highlights and such would draw the piece
that is really still there, making it flash on the from-square before
the position after the move is drawn. This, however, backfires when the
move was illegal, as then there is no draw of a new position, and the
from-square stays empty. For now this is solved by making DisplayMoveError()
order a total redraw. (As this is rare, only done in case of an error,
and might even throw up a pop-up, the performance cost of this is acceptable.)

11 years agoFix quoting of book name in tourney file
H.G. Muller [Wed, 20 Mar 2013 16:50:33 +0000]
Fix quoting of book name in tourney file

The argument of -polyglotBook was written to the tourney file unquoted,
which effectively made it disappear if it was an empty or blank string.

11 years agoProvide compatibility with Alien Edition setup command
H.G. Muller [Thu, 7 Mar 2013 17:11:31 +0000]
Provide compatibility with Alien Edition setup command

The setup command of the Alien Edition has a board-size specifier
(possibly as prefix on a parent-variant name) between pieceToCharTable
and FEN. The regular version would choke on that, precluding engines
designed for the Alien protocol extension to have their setup processed
when running under regular XBoard. This patch makes it skip the extra info.

11 years agoFix saving of analyzed game
H.G. Muller [Thu, 7 Mar 2013 16:52:02 +0000]
Fix saving of analyzed game

Anotated games after batch-mode Analyze Game were not auto-saved,
because the GameEnds() call supposed to do that was called with a NULL
argument for resultDetails. Now it is called with the resultDetails as
pre-existing in the gameInfo, or an empty string if none exist. This bug
was masked by the fact that in standard game ends (mate, etc.) the
analyzing engine would declare game end and supply a message.
 Also makes a distinction between Analyze Game and regular Analyze mode
when resuming analysis after loading a game; only the former now would
trigger a batch analysis.

11 years agoFix spurious popup after batch-mode Analyze Game
H.G. Muller [Thu, 7 Mar 2013 16:48:45 +0000]
Fix spurious popup after batch-mode Analyze Game

A batch analysis of games was not properly terminated, because the game
mode was tested after it had already been changed. No oldGameMode is
tested in stead.

11 years agoLet XBoard -autoBox option also affect move type-in
H.G. Muller [Sat, 2 Mar 2013 21:21:29 +0000]
Let XBoard -autoBox option also affect move type-in

11 years agoFix GTK box popup
H.G. Muller [Sat, 2 Mar 2013 21:17:31 +0000]
Fix GTK box popup

Key values > 255 are used for PgUp, PgDown etc., so to pop up only on
printables needs a two-sided test.

11 years agoFix fatal error on unsupported board size
H.G. Muller [Fri, 1 Mar 2013 11:50:06 +0000]
Fix fatal error on unsupported board size

When a board size unsupported by the engine was requested through the
New Variant dialog, this was discovered while the dialog was still up,
causing the error message to pop up as a child of the New Variant dialog,
so that it would immediately be taken down as the latter closed.
As a result it could not be confirmed, so that XBoard would not exit, and
was left in a pathologic state (ignoring window-close). This is fixed
by performing Reset (which detects the error) after PopDown of New Variant.

11 years agoAccept setup command for non-standard board size
H.G. Muller [Fri, 1 Mar 2013 11:39:40 +0000]
Accept setup command for non-standard board size

The code to test if board-size is standard for the current variant
has been moved to a subroutine, to allow its calling when receiving
a "setup" command from the engine.

11 years agoFix buffer overflow in feature parsing
H.G. Muller [Fri, 1 Mar 2013 10:57:01 +0000]
Fix buffer overflow in feature parsing

String features (variants, egt, myname and option) relied on a buf[MSG_SIZ]
for processing their value. The Nebiyu engine had combobox options that
required more than that. All string features are now stored in allocated
memory rather than in static arrays, and StringFeature allocates a buffer
of sufficient size for them. Only limitation now is the low-level input
buffer in the InputSource threads, whih is a static buffer of 4096
(=INPUT_SOURCE_BUF_SIZE) characters.

11 years agoFix vertical sizing of GTK board
H.G. Muller [Wed, 27 Feb 2013 22:44:55 +0000]
Fix vertical sizing of GTK board

The clipping of the boad at the bottom was due to resizing of the clock
height when we first write it with a big font. This patch delays calculation
of the final size until after the clock height changes.

11 years agoUpdated German translation
Arun Persaud [Wed, 27 Feb 2013 05:13:32 +0000]
Updated German translation

11 years agoUpdated Ukrainian translations
Arun Persaud [Wed, 27 Feb 2013 04:27:24 +0000]
Updated Ukrainian translations

11 years agoFix of argument error
H.G. Muller [Tue, 26 Feb 2013 16:59:43 +0000]
Fix of argument error

Oops. Pevious patch for skipping unknown multi-line arguments
was still buggy.

11 years agoLet popping up of WinBoard chatbox for channel open it
H.G. Muller [Tue, 26 Feb 2013 16:44:10 +0000]
Let popping up of WinBoard chatbox for channel open it

WinBoard now issues a +ch command for a channel when you pop up a chatbox
for that channel. A work-around is added for the fact that the public
FICS seems to ignore the first such command.

11 years agoMake skipping of unknown option smarter
H.G. Muller [Tue, 26 Feb 2013 16:27:59 +0000]
Make skipping of unknown option smarter

To make XBoard better resistant to the presence of disbanded or future
options in its settings file, encountering those is no longer a fatal error.
But the error recovery only consisted of skipping the rest of the line.
This fails badly on string options with a multi-line value, which is
enclosed by {braces}. We now detect that case, to skip to } instead.