Bug 31306

Summary: Icons don't get grayed even when disabled [UI]
Product: LibreOffice Reporter: Kohei Yoshida (inactive) <libreoffice>
Component: WriterAssignee: Caolán McNamara <caolanm>
Status: RESOLVED FIXED QA Contact:
Severity: enhancement    
Priority: medium CC: caolanm, detective.conan.1412, LibreOffice, timofeev.i.s
Version: 3.3.0 RC4   
Hardware: Other   
OS: All   
Whiteboard:
i915 platform: i915 features:
Attachments: Reproducible with "LibreOffice 3.3.0 RC4 - WIN7 Home Premium (64bit) German UI [OOO330m19 (build 6 / tag 3.3.0.4)]"

Description Kohei Yoshida (inactive) 2010-11-01 14:53:43 UTC
Icons for Table - Delete - Rows / Columns don't get grayed even when those menu items are disabled.

In fact, there are other icons that don't get grayed, such as

* Table - Split Cells
* Table - AutoFormat
* Table - Select - Table / Rows / Columns.

There may be other icons with similar problems.
Comment 1 Rainer Bielefeld Retired 2011-02-04 11:13:53 UTC
Created attachment 42937 [details]
Reproducible with "LibreOffice 3.3.0 RC4 - WIN7  Home Premium (64bit) German UI  [OOO330m19 (build 6 / tag 3.3.0.4)]"

I did not see so often because (for example) my WRITER Table toolbar disappears if no table is active. But further tests showed that the problem really exists
Comment 2 Björn Michaelsen 2011-12-23 11:35:23 UTC
[This is an automated message.]
This bug was filed before the changes to Bugzilla on 2011-10-16. Thus it
started right out as NEW without ever being explicitly confirmed. The bug is
changed to state NEEDINFO for this reason. To move this bug from NEEDINFO back
to NEW please check if the bug still persists with the 3.5.0 beta1 or beta2 prereleases.
Details on how to test the 3.5.0 beta1 can be found at:
http://wiki.documentfoundation.org/QA/BugHunting_Session_3.5.0.-1

more detail on this bulk operation: http://nabble.documentfoundation.org/RFC-Operation-Spamzilla-tp3607474p3607474.html
Comment 3 Korrawit Pruegsanusak 2011-12-29 06:39:57 UTC
Still exists with LOdev 3.5.0beta2
Build ID: 8589e48-760cc4d-f39cf3d-1b2857e-60db978
Windows XP
Comment 4 Rainer Bielefeld Retired 2011-12-29 10:48:28 UTC
@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 5 Ivan Timofeev (retired) 2012-01-06 06:22:59 UTC
Yeah, there is some problematic icons (maybe the ones without transparent pixels?).

Some (technical) details:
When drawing a disabled menu item, OutputDevice::DrawImage is called for drawing an icon. The nStyle parameter of that method has the IMAGE_DRAW_DISABLE flag in our case. But if rImage.mpImplData->meType == IMAGETYPE_BITMAP (see the code), then we just ignore nStyle and draw a bitmap as it is. 

I'm sorry but I don't know what to do here... Perhaps some VCL-expert knows.
Comment 6 Rainer Bielefeld Retired 2012-01-06 08:33:07 UTC
@Cáolan:
Can you help?
Comment 7 Caolán McNamara 2012-03-05 05:33:33 UTC
http://cgit.freedesktop.org/libreoffice/core/commit/?id=159b5088ee303f7adf6a4c0e5e72b32c37f9f910 should make it do the right thing for those non-alpha channel icons I think
Comment 8 Roman Eisele 2012-05-04 06:59:36 UTC
This is a Writer (or UI) issue, therefore changed the 'Component' field accordingly and added 'UI' to the Summary.

Set 'Version' field according to comment #1.

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.