Re: [gtk-list] Re: How to make GTK_STATE_INSENSITIVE look likeGTK_STATE_NORMAL



On Tue, 30 Mar 1999, Tim Jenkins wrote:
>
> I am writing an application in which I would like insensitive option menus
> to look like sensitive menus, except that they cannot be selected. After

Hi,

Haven't try this, but it should work:
- add callbacks to events/signals like press | enter | leave | focus.
- put a flag that control your state
- block the propagation of the signal with
gtk_signal_emit_stop_by_name()

I use somethig similar in a Text widget to process the ENTER key. When
ENTER key is pressed, the text from the widget is read, processed and
deleted. If I don't stop_by_name, I get an '\n' in the Text widget
(which spoils further processings), as that ENTER is introduced after
the return from my callback.

But, as people have already said, seems strange to not use the default
behaviour of gtk, aka gray the widgets which are disabled. Your users
will feel unconfortable with your program, unless this program is the
only thing they use and know about.

Ionutz


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