Re: Three state check button

2006-07-07 Thread Atanas Atanasov
It worked but I would say partially. I tested with a GtkCheckButton
and its appearance is a shaded tick. However I cannot see how I can
get and set the third state.  Is the button supposed to change its
state automatically as it does with not-inconsistent buttons or I have
to receive the pressed and released and change the state accordingly
up to my preference.

I also have another problem. I would like to know whether the button
is pressed at some moment or not. I could not find a function which
returns this aspect of the button state. Is there any other solution
apart from trapping pressed and released and keeping a flag of the
state.

Atanas
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Three state check button

2006-07-07 Thread Yeti
On Fri, Jul 07, 2006 at 08:50:56AM +0200, Atanas Atanasov wrote:
 It worked but I would say partially. I tested with a GtkCheckButton
 and its appearance is a shaded tick. However I cannot see how I can
 get and set the third state.  Is the button supposed to change its
 state automatically as it does with not-inconsistent buttons or I have
 to receive the pressed and released and change the state accordingly
 up to my preference.

Is the documentation so unclear?

Normally you would turn off the inconsistent state again
if the user toggles the toggle button. This has to be
done manually, gtk_toggle_button_set_inconsistent() only
affects visual appearance, it doesn't affect the
semantics of the button.

 I would like to know whether the button
 is pressed at some moment or not. I could not find a function which
 returns this aspect of the button state. Is there any other solution
 apart from trapping pressed and released and keeping a flag of the
 state.

Is the documentation so unclear?

The state of a GtkToggleButton can be set specifically
using gtk_toggle_button_set_active(), and retrieved
using gtk_toggle_button_get_active().

Yeti


--
Anonyms eat their boogers.
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Three state check button

2006-07-06 Thread Atanas Atanasov
Is there an option that would make a check button have a third state.
What I am after is similar to BS_3STATE and BS_AUTO3STATE styles of
the BUTTON class in Windows.

Any suggestions are welcome.

Atanas
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list


Re: Three state check button

2006-07-06 Thread Yeti
On Thu, Jul 06, 2006 at 07:42:24PM +0200, Atanas Atanasov wrote:
 Is there an option that would make a check button have a third state.
 What I am after is similar to BS_3STATE and BS_AUTO3STATE styles of
 the BUTTON class in Windows.

I don't know Windows but I suppose you are looking for
gtk_toggle_button_set_inconsistent().

Yeti


--
Anonyms eat their boogers.
___
gtk-app-devel-list mailing list
gtk-app-devel-list@gnome.org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list