Re: background/font capplets



Seth Nickell wrote:

On Wed, 2002-03-13 at 18:00, James Henstridge wrote:

Seth Nickell wrote:

On Wed, 2002-03-13 at 16:12, Richard Hestilow wrote:

On Wed, 2002-03-13 at 17:50, Seth Nickell wrote:

Which would be a lovely case of changing the interface to match ease of
implementation (and silly too since the implementation work is already
done).

bad hacker, no biscuit ;)

(this is getting increasingly-off topic but I'll bite)
I'd actually argue that the use of toggle buttons in a context which,
99% of the time, would normally be implemented using radio buttons or an
option menu counts as an inconsistent and potentially confusing UI.

Using toggle buttons as radio boxes is both HIG compliant, and not
uncommon in other systems. Its probably not used much in GNOME because
its a little tricky to implement without getting nasty signal loops.

"Only use toggle buttons in groups, so they are not mistaken for regular
buttons. Make the group behave like either a group of check boxes where
none, one or more of the buttons may be set at once, or a group of radio
buttons, where exactly one button may be set at once, and setting one
button unsets the others."

In general, radio buttons are the preferred control, but the image/label
mix works better with toggle buttons in this case.

If it is just appearance you are worried about, can't you just use GtkRadioButtons, and call gtk_toggle_button_set_mode(button, FALSE) (I think that is the correct function) to make them draw like toggle buttons?

Of course, if there are other reasons not to use GtkRadioButton, ignore the above :)


heh, I'm a dumb-shit. I didn't know you could do this. But I'm not sure
it would help here because I'm customizing the contents of the button,
so can you get access to the actual button contents bin if you change
the mode like that?

A GtkRadioButton is a GtkToggleButton (which is a bin) so yes. If you can pack it in a toggle button, you can pack it in a radio button. Calling set_mode(button, FALSE) gives you something that looks like GtkToggleButton but acts like a radio button -- it is what GIMP uses for the the toolbox.

James.

--
Email: james daa com au
WWW:   http://www.daa.com.au/~james/






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