Xboard match result outout

Discussions about the WinBoard protocol. Here you can also report bugs and request new features.

Moderators: hgm, Andres Valverde

Xboard match result outout

Postby F. Bluemers » 11 May 2012, 19:49

xboard emits the match result to stderr (like "xboard: match x vs. y final score: 1-0-0')
Is it possible to add this "feature"* to winboard,
It's very handy with clop.No need to parse a pgn for a result


Best
Fonzy

*It throws out a bit more with -debug.
Must have been used as a debugging aid.
F. Bluemers
 
Posts: 175
Joined: 04 Sep 2008, 16:56
Location: Netherlands

Re: Xboard match result outout

Postby H.G.Muller » 12 May 2012, 22:25

The problem is that in WinBoard stderr (or stdout, etc.) is not open.

In XBoard stdin / stdout / stderr remain open, and associated with the terminal window from which you launched XBoard. This terminal is then also used as ICS interaction window. I think XBoard prints the result in the terminal because DisplayFatalError is used to display the result in a popup window. (Older versions used to always exit after finishing a match.) But DisplayFatalError also prints to the standard output, because some fatal errors can occur before the X-Windows stuff is initialized (e.g. during parsing of the command-line options), and at this time popups do not work yet. So then the terminal is the only place where the user can see the error message. (In WinBoard popups work from the very start, probably because it is compiled as a GUI application.)
User avatar
H.G.Muller
 
Posts: 3453
Joined: 16 Nov 2005, 12:02
Location: Diemen, NL

Re: Xboard match result outout

Postby F. Bluemers » 12 May 2012, 22:45

H.G.Muller wrote:The problem is that in WinBoard stderr (or stdout, etc.) is not open.

In XBoard stdin / stdout / stderr remain open, and associated with the terminal window from which you launched XBoard. This terminal is then also used as ICS interaction window. I think XBoard prints the result in the terminal because DisplayFatalError is used to display the result in a popup window. (Older versions used to always exit after finishing a match.) But DisplayFatalError also prints to the standard output, because some fatal errors can occur before the X-Windows stuff is initialized (e.g. during parsing of the command-line options), and at this time popups do not work yet. So then the terminal is the only place where the user can see the error message. (In WinBoard popups work from the very start, probably because it is compiled as a GUI application.)

Thanks for clarifying.
Maybe its an idea to add an option to xboard and winboard to dump the matchresult in a file(name=commandline option).
No need then to rely on DisplayFatalError sideeffects.
F. Bluemers
 
Posts: 175
Joined: 04 Sep 2008, 16:56
Location: Netherlands


Return to WinBoard development and bugfixing

Who is online

Users browsing this forum: No registered users and 22 guests