A couple of things .........

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

Moderators: hgm, Andres Valverde

A couple of things .........

Postby Jim Ablett » 27 Aug 2008, 10:54

Hi Harm,

#1. I get quite frustrated sometimes when I mistype in the 'Winboard Startup' additional options box and the whole thing exits and I have to startup again. Could an incorrect option just not accept the line, clear it and abort starting winboard, but keep the 'Winboard Startup' window there instead of shutting it down ?

#2. On the menus, why have 'Machine white" Machine black' ? Seems a bit outdated. Surely better to have 'Engine white' Engine black'.

Jim Ablett
Posts: 721
Joined: 27 Sep 2004, 10:39
Location: Essex, England

Re: A couple of things .........

Postby H.G.Muller » 27 Aug 2008, 14:46

I know exactly what you mean... :wink:

Unfortunately this is not easy to do at all. In the current control flow WinBoard might discover only very late in the day that there is a typo in the start-up menu. E.g. if it is in the second engine, which is not even touched unless you click "Two Machines". And forcing the user to type something correct for the second engine if he is not going to use it seems a step backwards. Letting WinBoard check if the enetered directory and executable exist is furthermore no guarantee evrything will work. You could have a typo in an engine argument, wich would make it crash after startup.

In fact I want to get rid of that entire starup dialog. Xboard does not have it. It would probably an equal amount of work to add it there, as it is to find an alternative in WinBoard.

How about this:

In the "File" menu we add an item "Engines...". That item would be greyed out in any other state than directly after "New Game" (internally, when gameMode == BeginningOfGame). At that point only the first engine is engaged, and in a known state.

In the "File -> Engines..." dialog we would then have the two engine fields that are now in the startup dialog. But there would be a "Browse" button next to them. There would be two separate type-in fields for the directories. They would be initialized to something like '$' or '~', meaning: "use the directory the engine executable was in". This would almost always make it unneeded to type something there, but you could if you wanted.

The type-in fields for the engine names would remember what you typed there last time (so you could edit out a typo), as long as you have not left WinBoard. (Initially it would be like the startup dialog, overruled by any -fcp or -scp options on the command line.) Using the menu and OK-ing it, would lead to shutdown of the engine process, and startup of a new one. So you could switch engines while WinBoard is running.

Now the only other thing that should be altered is that in case of failure to start up the engine, there will not be a fatal error, but an error message "Engine 1 (...) cannot be started" and a restart of WinBoard. Before the restart any offending engine names would be cleared (but not the memory of their type-in fields), so that WinBoard would in effect revert to game-viewer mode. But by using the "File -> Engines..." menu, you could switch back to engine mode. Correcting your typo, if that was the problem.

Of course changing the default of the -fd and -sd options from "" to "$", and adding a little code that replaces "$" by everything upto the last '/' or '\' in the corresponding engine name when it uses it, would already by itself relief 50% of the pain with a relative minor effort. It means you almost never would have to use the -fd and -sd commands again, pre-empting any typos there.

About the second thing: that would of course be a trivial change, but people are mostly very conservative, and might not like it. Perhaps we should put it up for voting?
User avatar
Posts: 3207
Joined: 16 Nov 2005, 12:02
Location: Diemen, NL

Re: A couple of things .........

Postby Olivier Deville » 27 Aug 2008, 16:14

This startup box is a big pain indeed, and I am sure it kept many people away from Winboard. Yes Harm, get rid of it :)

User avatar
Olivier Deville
Posts: 1175
Joined: 26 Sep 2004, 19:54
Location: Aurec, France

Return to WinBoard development and bugfixing

Who is online

Users browsing this forum: No registered users and 3 guests