Bug Hunting Session
Bug 31471 - EasyHacks: iDRAW-UI: context menu for grid shows opposite of current behaviour
Summary: EasyHacks: iDRAW-UI: context menu for grid shows opposite of current behaviour
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Draw (show other bugs)
Version:
(earliest affected)
Inherited From OOo
Hardware: x86 (IA32) Windows (All)
: medium normal
Assignee: Ivan Timofeev (retired)
URL:
Whiteboard:
Keywords: easyHack
: 41264 (view as bug list)
Depends on:
Blocks: 34413 43701
  Show dependency treegraph
 
Reported: 2010-11-08 08:34 UTC by Rainer Bielefeld Retired
Modified: 2015-12-18 09:56 UTC (History)
7 users (show)

See Also:
Crash report or crash signature:


Attachments
OpenOffice.org 3.3.0 behavior for comparison (95.08 KB, image/png)
2011-03-04 14:43 UTC, Christoph
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Rainer Bielefeld Retired 2010-11-08 08:34:54 UTC
I checked with LibreOffice 3.3.0  -  WIN XP DE [OOO330m9 (Build:1 - build 3.2.99.2)] 

Steps to reproduce:
1. open new DRAWing
   no grid visible
2. 'Rigtclick -> Grid'
    into DRAWing for context menu "Grid"
    expected: no grid symbol left from text "Grid" because no grid visible
    actual: grid symbol visible

Same problem with 'Snap to Grid'

Works fine in Menu
Comment 1 Petr Mladek 2010-11-16 08:52:01 UTC
I think that the meaning of the context menu is the following. The icon shows what you get when you select the menu entry.

The main menu "View/Grid/Display Grid" and "View /Grid/Snap to Grid" work a bit different. They try to show the status by the background color. It is shade when the feature is enabled and white when it is disabled.

I agree that it is confusing and inconsistent.

I suggest to use the usual check-box instead of icons. Rainer, what do you think?
Comment 2 Rainer Bielefeld Retired 2010-11-16 09:44:11 UTC
I think to show the checkbox checked consistently will cause a minimum of possible misunderstanding.
Comment 3 Petr Mladek 2010-11-18 06:00:57 UTC
Okay, so we should go this way and replace icons with check boxes.

I think that it is an easy tasks, so I marked it as such and mentioned at
http://wiki.documentfoundation.org/Development/Easy_Hacks#Easy_to_solve_bugs
Comment 4 Rainer Bielefeld Retired 2011-02-17 21:21:16 UTC
Not only DRAW is affected,we have the same inconsistence (or at least capability of being misunderstood) in other menus. 

@Petr Mladek:
I do no know all details concerning your intention, do you agree to see this as a more general, not only DRAW / grid problem?

My idea:
[TASK] EasyHacks UI: menus and context menus should always show checked checkbox for permanently enabled functions
Comment 5 Laurent BP 2011-02-18 09:05:12 UTC
Hello,

As indicated in issue 34413, View > Toolbars > Hyperlink bar has the same problem in all modules.
Also, insert a picture, right clic > Wrap : nothing is checked. You can not know what is the selection. You need to look in menu Format > Wrap

No problem if icon is NOT included in menu (Tools > Options > LibreOffice > View).
Comment 6 Petr Mladek 2011-03-03 12:17:23 UTC
I am sorry for the late response.

(In reply to comment #4)
> @Petr Mladek:
> I do no know all details concerning your intention, do you agree to see this as
> a more general, not only DRAW / grid problem?

Yes, it looks like a more general problem.

> My idea:
> [TASK] EasyHacks UI: menus and context menus should always show checked
> checkbox for permanently enabled functions

Great idea. Rainer, could you please enter it there?
Comment 7 Petr Mladek 2011-03-03 12:30:14 UTC
I have got the idea to double check it with the design team. I have sent a mail to design@libreoffice.org and put Rainer into CC.
Comment 8 Petr Mladek 2011-03-04 05:08:49 UTC
The design team might want another solution, please read the thread starting at
http://listarchives.libreoffice.org/www/design/msg01134.html
Comment 9 Christoph 2011-03-04 14:43:14 UTC
Created attachment 44142 [details]
OpenOffice.org 3.3.0 behavior for comparison

The attachment shows the behavior of OOo 3.3.0 which behaves correctly and according the "Menus" specification [1]. LibreOffice seems to omit drawing the icons from time to time, leading to the weird behavior described in this bug.

Consequently, LibreOffice should conform to the behavior of OpenOffice.org in this case to create a consistent behavior within the office suite.

[1] http://specs.openoffice.org/ui_in_general/menus/Menus.odt
Comment 10 Petr Mladek 2011-03-08 12:10:01 UTC
Okay, so the screenshot from Christoph shows the expected behavior:

  + GNOME system and menus_have_icons="false":
     + grid enabled - check box icon
     + grid disabled - no icon; blank place

  + otherwise:
     + grid enabled - schematic icon with dark background
     + grid disabled - schematic icon with bright background

Heh, the current state is an inverted mix of both approaches:

     + grid enabled - no icon; blank place
     + grid disabled - schematic icon with bright background

Another strange thing is that it works fine for some other menu entries, e.g.:

     + View/Data Sources
     + Tools/Gallery


It might be interesting to investigate the differences between these menu entries, ... I hope that someone would take this as an easy task soon.
Comment 11 Christian Dywan 2011-04-15 08:46:54 UTC
The menu items shown on the screenshot work for me exactly that way, git master from yesterday.

Is it decided to keep the confusing icon-with-background thing? Otherwise I would personally like to try getting rid of checkable icons.
Comment 12 Petr Mladek 2011-04-18 03:20:35 UTC
Christian, the preferred solution would be to fix the regression and restore the behavior from the plain OOo build. It is on the screenshots in the comment #9. It basically means to switch the icons for the two states.

If you could look at it that would be great.
Comment 13 Cor Nouws 2011-05-28 08:32:09 UTC
Working on Ubuntu (Unity)
Context menu 'Snap Lines > Snap Lines to Front' works with a checkbox.
So I thought that might be an interesing entry point to find out how it works. I tried to find some hooks in the code, but got stuck atm.
http://opengrok.libreoffice.org/xref/impress/sd/source/ui/app/menuids_tmpl.src#1045
http://opengrok.libreoffice.org/xref/impress/sd/source/ui/view/drviews7.cxx#501
http://opengrok.libreoffice.org/xref/impress/sd/sdi/sdraw.sdi#3176
Comment 14 Rainer Bielefeld Retired 2011-06-22 22:45:54 UTC
Now works for me due to Spec. 

WFM also due to Comment 13 and because I can not contribute any concrete fix.
Comment 15 Rainer Bielefeld Retired 2011-12-10 11:03:31 UTC
This still is inconsitent in 3.4.4 and Server Installation of  "LibreOffice 3.5.0 - WIN7 Home Premium (64bit) English UI [Build ID: 35c8573-95bcc5e-4c1bcb] Win-x86@6-fast  pull time 2011-12-09 12:44:50".

Correct behavior is en menu 'View -> Grid':
'Diplay Grid' and 'Snap to grid' have icons, dark background around icon 
shows active function
'Grid to front' has no icon, a marked checkbox shows active function

This has to be done in the same way in contents menu.

@Ivan:
Please feel free to reassign (or reset Assignee to default) if it’s not your area or if provided information is not sufficient. Please set Status to ASSIGNED if you accept this Bug.
Comment 17 Ivan Timofeev (retired) 2011-12-23 07:25:48 UTC
*** Bug 41264 has been marked as a duplicate of this bug. ***
Comment 18 Robinson Tryon (qubit) 2015-12-18 09:56:07 UTC
Migrating Whiteboard tags to Keywords: (EasyHack)
[NinjaEdit]