kdemultimedia (setCheckedState)

David Faure faure at kde.org
Wed May 19 08:14:57 BST 2004

On Tuesday 18 May 2004 21:15, Malte S. Stretz wrote:
> What do youn want to do about menus like KMail's "View->Attachments"? Or 
> even in the composer "Options->Set Encoding->..."? Ok, you could argument 
> that "Set Encoding" is an action and the submenu are the... options for the 
> action?
> Actually, the whole "Options" menu in KMail is a good example as all menu 
> items in there are options (I guess that's why the menu is called 
> "Options"). 

OK I shouldn't have said there are no options. Yes, some menu items
are options. But those are clearly options - they don't start with a verb,
so there is no ambiguity.

> And another point: The "Show" you don't like doesn't have to be an action 
> which ends after you clicked on the menu item. If your mother tells you 
> "show me your hands", she doesn't want to see them for a glimpse but wants 
> to inspect them so she can see if they are clean or something. Have you 
> ever tried in such a case to use "show" in the way you see it? :) So "show" 
> can also be a state, the application is "showing" the toolbars, until you 
> tell it otherwise -- not via "hide" but "don't show anymore".

OK let's step away from toolbars for a minute and take a look at the initial
reason why setCheckedState was introduced.

Konqueror has a "Case Insensitive Sort" menu item which was a toggleaction
When you see that menuitem, does that mean it's currently sorting that way 
or that one should click on it to sort that way? It's really really not obvious
which one it is, I myself got confused several times by it.
And why is so ambiguous? Because it's option with a verb in its description.

So there are two solutions: ensuring that options really look like options
(without a verb, like "Toolbar Foobar Visible"), or ensuring that those menu 
items are actions, where the description represents the action - so it has 
to change if the action changes.

David Faure, faure at kde.org, sponsored by Trolltech to work on KDE,
Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).

More information about the kde-core-devel mailing list