After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 114055 - Lock/Unlock menu item is not HIG compliant.
Lock/Unlock menu item is not HIG compliant.
Status: RESOLVED FIXED
Product: gnome-panel
Classification: Other
Component: libpanel-applet
git master
Other All
: Normal normal
: ---
Assigned To: Panel Maintainers
Panel Maintainers
: 132967 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2003-05-30 19:50 UTC by Dennis Cranston
Modified: 2005-01-02 10:59 UTC
See Also:
GNOME target: ---
GNOME version: 2.9/2.10


Attachments
Patch to add a checkmenu item "Lock To Panel" (2.72 KB, patch)
2004-06-02 20:11 UTC, Madhan Raj M
none Details | Review
Patch to add a checkmenu item "Lock To Panel" and not to alter the sensitivity of the "Remove From Panel" menuitem (3.55 KB, patch)
2004-06-02 20:20 UTC, Madhan Raj M
none Details | Review
Revised Patch (5.60 KB, patch)
2004-06-05 20:14 UTC, Madhan Raj M
none Details | Review
Revised Patch to commit against the CVS HEAD (5.50 KB, patch)
2004-11-26 17:39 UTC, Madhan Raj M
none Details | Review
Revised Patch to commit against the CVS HEAD with comments (5.85 KB, patch)
2004-12-06 18:00 UTC, Madhan Raj M
none Details | Review

Description Dennis Cranston 2003-05-30 19:50:52 UTC
Please see Guidelines under the Checkbox Items section of the GNOME HIG...

http://developer.gnome.org/projects/gup/hig/1.0/menus.html#menu-item-types

"Never change the label of a checkbox menu item in response to the user
selecting the item."

The "Lock"/"Unlock" menu item is not HIG compliant.  It should be replaced
with a proper checkbox menu item using the label "Lock".

Thanks.
Comment 1 Mark McLoughlin 2003-06-03 12:37:12 UTC
Hold on. This *isn't* a check menu item, so the guidline doesn't
apply, right ?

But, in any case - this patch didn't start out using a check menu
item, but I didn't think it worked very well. i.e. you had

  Remove From Panel
  Locked
  Move

and then when locked

  Remove From Panel
x Locked
  Move

I just can't think of a good term to convey the concept as a "state"
rather than a "command".

Any ideas anyone ?

 
Comment 2 Dennis Cranston 2003-06-03 15:52:26 UTC
> Hold on. This *isn't* a check menu item, so the guidline doesn't
> apply, right ?

If it walks like a duck, quacks like a duck, then it a duck. ;-)  It's
a menu item that toggles between two different states which is a check
menu item.  I'd value calum's feedback on this, too.
Comment 3 Seth Nickell 2003-06-03 18:34:21 UTC
Its a mutable command item right now, but a checkbox is probably more
appropriate.
Comment 4 Mark McLoughlin 2003-06-04 11:42:01 UTC
Seth: I've tried using a check menu item but didn't feel it worked
very well. Could you comment on above and maybe suggest better
terminology?
Comment 5 Calum Benson 2003-06-04 19:01:00 UTC
Agree with the general feeling here... since "Lock" functions as both
a verb and a noun, it doesn't make for a very good menu item, mutable
or otherwise.  I agree a checkbox item called "Locked" is even worse
though, since as Mark says, that makes it unclear whether it's a
checkbox item indication the item isn't locked, or a mutable item
indicating it *is* locked.

If this property only affects an applet's movability and not any of
its preferences, perhaps making it a checkbox menu item labelled
"Movable" would be the most accurate solution, although that might
look a little peculiar right next to the "Move" command.  Perhaps the
docs guys have a better suggestion.

FWIW, on Windows the menu item for locking things is a bit of a mess
too IMHO... it's labelled "Lock the <object>" which makes it sound
like a command, whereas in fact it's a checkbox menu item.  Let's do
better :)
Comment 6 Mark McLoughlin 2003-06-05 12:13:16 UTC
I think I've heard Lock to Panel/Unlock suggested somewhere as well
... it makes it more obvious that "Lock" is a command ...
Comment 7 bsoft 2003-09-11 16:16:38 UTC
How about instead of "Locked", "Lock in place"?
Comment 8 Calum Benson 2003-11-26 13:55:29 UTC
Or "Lock Position", "Unlock Position"?  Although it does affect
removability too, so maybe that's not strictly accurate either...
Comment 9 Patrick Costello 2003-11-26 14:09:03 UTC
I support Mark's suggestion of "Lock to Panel" on the following
grounds: 

- Provides a clear command
- Uses the standard imperative style common to the GNOME Desktop
- Makes the locking parameter clear, i.e. the panel
- Eliminates ambiguity

Also, I support the earlier remark that this is a toggle situation
between two states, so you only need to have a checkbox with the label
"Lock to Panel" cleared or ticked. There is no need for the term
"Unlocked" to appear in the label.

Pat
Comment 10 Calum Benson 2003-11-26 15:19:47 UTC
Hmm, on the checkbox point, I know I'd find it pretty confusing if I
popped up a menu that said "Lccked to Panel" on it when it clearly
wasn't, but maybe I'm just a simple bloke who takes thing too
literally... :)
Comment 11 Patrick Costello 2003-11-26 15:24:17 UTC
The checkbox wouldn't say "Locked to Panel" the checkbox would say
"Lock to Panel": 

o Lock to Panel: the checkbox is clear, therefore the label is an
invitation to choose this option if you want to lock the applet to the
panel. 

x Lock to Panel: the checkbox is ticked, therefore you have accepted
the invitation offered by the label to lock the applet to the panel. 

This is exactly the same logic followed elsewhere in the GNOME Desktop
and applications.

Pat
Comment 12 Calum Benson 2003-11-26 15:30:17 UTC
Oops, quite right, a pox on Solaris 8 and its illegible Mozilla fonts...
Comment 13 Bryan W Clark 2004-05-17 19:39:23 UTC
bug 132967 has some followup discussion on this, which never made it into CVS. 
I would recommend that the suggestion from comment #11 be commited.
Comment 14 Mark McLoughlin 2004-06-02 12:33:40 UTC
Okay, we need a patch for

  [x] Lock to Panel
Comment 15 Mark McLoughlin 2004-06-02 12:33:58 UTC
*** Bug 132967 has been marked as a duplicate of this bug. ***
Comment 16 Madhan Raj M 2004-06-02 20:11:37 UTC
Created attachment 28281 [details] [review]
Patch to add a checkmenu item "Lock To Panel"

This Patch adds a check menu item,
[ ] Lock To Panel
It makes the "Remove From Panel" menu item to be insensitive, when the panel is
locked.
Comment 17 Madhan Raj M 2004-06-02 20:19:13 UTC
It must be possible to remove a Locked applet. 
The below patch adds a checkmenu item as well as resolves that bug.. 
ie The "Remove From Panel" menu item sensitivity is not altered. 
Comment 18 Madhan Raj M 2004-06-02 20:20:45 UTC
Created attachment 28283 [details] [review]
Patch to add a checkmenu item "Lock To Panel" and not to alter the sensitivity of the "Remove From Panel" menuitem
Comment 19 Mark McLoughlin 2004-06-02 21:27:53 UTC
Comments on the patch:

  1) I've already committed stuff to HEAD (earlier today) to allowing
     removing locked applets

  2) Follow the coding style of the rest of the code - i.e.

  gtk_check_menu_item_set_active (checkmenuitem, locked);

     rather than:

  gtk_check_menu_item_set_active(checkmenuitem,locked);

  3) You should be doing something like:

  panel_applet_set_locked (info, gtk_menu_item_get_active (...));

     rather than relying on the state of the applet to stay in sync
     with the menu item.

  4) You're completely ignoring whether the applet_id_list key is writable:

 	bonobo_ui_component_set_prop (frame->priv->ui_component,
-				      "/commands/RemoveAppletFromPanel",
-				      "sensitive",
-				      locked ? "0" : (removable ? "1" : "0"),
-				      NULL);

     the removable flag is there for a reason !

   5) How is this a check menu item:

+         <menuitem name="lock" verb="..." _label="..."/>

      ?
Comment 20 Madhan Raj M 2004-06-05 20:14:10 UTC
Created attachment 28379 [details] [review]
Revised Patch

Mark: I have changed the patch and i have followed the steps you have
mentioned. Thanks..
Comment 21 Madhan Raj M 2004-06-23 17:44:53 UTC
Mark: Any comment on the revised patch. Have sticked to the rules and style of coding. 
Comment 22 Madhan Raj M 2004-11-26 17:39:30 UTC
Created attachment 34163 [details] [review]
Revised Patch to commit against the CVS HEAD

Just attached the revised patch to commit against the recent source
Comment 23 Madhan Raj M 2004-12-06 18:00:46 UTC
Created attachment 34556 [details] [review]
Revised Patch to commit against the CVS HEAD with comments
Comment 24 Vincent Untz 2005-01-02 10:59:11 UTC
Madhan: thanks for the patch.
I committed a slightly modified version.