Complete.Org: Mailing Lists: Archives: freeciv-dev: August 2004:
[Freeciv-Dev] Re: Esc in gtk2

[Freeciv-Dev] Re: Esc in gtk2

[Top] [All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index] [Thread Index]
To: Mateusz Stefek <mstefek@xxxxxxxxx>
Cc: Freeciv development <freeciv-dev@xxxxxxxxxxx>
Subject: [Freeciv-Dev] Re: Esc in gtk2
From: Vasco Alexandre Da Silva Costa <vasc@xxxxxxxxxxxxxx>
Date: Fri, 27 Aug 2004 21:00:24 +0100 (WET DST)

On Fri, 27 Aug 2004, Mateusz Stefek wrote:

> I don't understand when the Esc button close a gtk2 dialog.
> There is gtk_dialog_set_default_response(GtkDialog *dialog, gint
> response_id) for Enter, but there's no such thing for ESC.
> How does it work?
> I want to close Message window with ESC (It's impossible with Enter,
> because it's used by GtkTreeTreeView).
> The same problem with City report, Economy Report and City Dialog.

This used to work by default with early versions of GTK+ 2.x. Whenever
you pressed Esc in a dialog it sent a GTK_RESPONSE_DELETE_EVENT. But then
someone removed it for some whatever reason. I think the HIG people were
against it, but I think it was a good feature. Unfortunately kludging
around the library to put it back is a bit messy.

ALT+F4, or whatever is used in your window manager to close a window will
always work sanely in the GTK+ 2.x client, so you can use that.

Vasco Alexandre da Silva Costa @ Instituto Superior Tecnico, Lisboa

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