xboard-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [XBoard-devel] GTK version, promotion popup


From: Tim Mann
Subject: Re: [XBoard-devel] GTK version, promotion popup
Date: Fri, 4 Sep 2009 19:24:03 -0700

I agree the promotion popup needs work -- it will be nice to not have
it come up if the move would be illegal no matter what piece you're
promoting to, and it definitely needs to adapt itself to show all
the pieces that are possible to promote to in whatever variant you're
playing.

In cases where you can promote only to a held piece, showing only those
would be nice.  Or show all types but grey out the ones you aren't
holding...??

I think it should still be a popup window, though, not temporarily
overwrite something on the main board.  Popup windows are familiar to
users and (should be) easier to code than something that essentially
emulates a non-movable popup window by overwriting part of the board
and then restoring it later.

Making the window show the possible pieces graphically (either in
addition to or instead of names) sounds nice.

For accessibility, there still needs to be a way to select the piece
with the keyboard -- at least being able to move a highlight around
with the arrow keys and hitting enter to select the highlighted piece.
I don't know what to suggest about the internationalization of the
piece name and its accelerator key.

As usual, just my 2 cents.

        --Tim

On Fri, 04 Sep 2009 10:20:10 +0200, "h.g. muller" <address@hidden> wrote:
> At 23:49 3-9-2009 -0700, Arun Persaud wrote:
> >The GTK version also still crashes, for example when promoting a pawn, 
> >since the promotion-window is not been ported to GTK and the old X-code 
> >will now create a crash...
> 
> Getting rid of the promotion popup altogether is on my to-do list,
> so perhaps you should not bother porting the old dialog. One of
> the very annoying things about the XBoard promotion popup is
> that it is shown even for moves that are already known to be illegal.
> Try for instance to play e2d8 from the opening setup. When legality
> testing is on, it first shows te promotion popup to make you select
> a piece, and no matter what you choose, the move is then rejected
> as illegal later. In WinBoard I fixed this, but not yet in XBoard.
> Especially in Shogi, where moving any piece type in or out of a rather
> deep promotion zone could cause a promotion, this behavior was very
> annoying. (For normal Chess you are of course not very likely to draw
> Pawns to the last rank by accident.)
> 
> But what is even more annoying is that the promotion popup is not
> variant-proof. Not all of the 22 piece types can appear in the promotion
> menu, although it is patched a little to work in the most common variants
> (e.g. in giveaway you can promote to King, and in Gothic to Archbishop
> and Chancelor, while in Shogi you can select Yes/No.)
> 
> Another problem is that currently internationalization is broken in the
> promotion popup: It uses the first letter of the name on the button as
> a piece indicator (except for Knight), so if yo change the button labels,
> you would get invalid choices unless you would also adapt the
> pieceToChar table to the language. (Which is in general undesirable,
> as it would preclude you from reading international PGN.)
> 
> In Superchess (-variant super) and Great Shatranj you can only promote
> to a captured piece, and for this purpose I let these games display holdings
> (although they are not drop games) to show what is captured. in WinBoard
> I already implemented promotion in these games without a popup,
> by having the user click the piece in the holding he wants to promote to,
> in order to finish the move. (Until then the piece is shown as Pawn on
> the promotion square. It would of course be still nicer if the Pawn kept
> flashing there until you make the choice; I think that XBoard can flash
> pieces.)
> 
> I would like to switch to that method also for games where the promotion
> choice is fixed (i.e. not dependent on what is captured, so no holdings
> are shown). To this end I would want to show a "pseudo-popup", i.e. just
> change the background color of a rectangular area in the board to black,
> and temporarily remove the pieces that are on those squares in the current
> position, and replace them by all the pieces you can promote to in the
> current variant. (If there is more than one, that is; in Shatranj where you
> always promote to "Queen" promotion would be automatic.)
> 
> This would make the promotion procedure completely pictorial,
> and would thus also get rid of any lanuage issues. It would need
> a bit smart code, though, to decide how to best format the available
> choices into a rectangular area, and where to position it on the board.
> 
> 


-- 
Tim Mann  address@hidden  http://tim-mann.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]