Bug 75637 - LOCALHELP: Images not displayed with newer icon themes
Summary: LOCALHELP: Images not displayed with newer icon themes
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Documentation (show other bugs)
Version:
(earliest affected)
4.2.0.4 release
Hardware: Other All
: medium normal
Assignee: Stephan Bergmann
URL:
Whiteboard: target:5.1.0 target:5.0.4
Keywords:
: 75948 78576 82149 90830 95886 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-03-01 11:30 UTC by ace_dent
Modified: 2017-07-05 12:37 UTC (History)
13 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description ace_dent 2014-03-01 11:30:09 UTC
Newer Icon themes will increasingly use 'links.txt' to reduce duplicate icons, e.g.:
/icon-themes/tango/links.txt

This would suggest that online help supports the same run-time image replacement as occurs when rendering icons in the UI. I think the magic occurs in:
vcl/source/gdi/impimagetree.cxx

During testing, I discovered this doesn't occur; guessing all images are simply hardcoded links from help content to the current icon theme.

Testing:
- Select a different icon theme, e.g. Tango.
- View online help topics, such as:
> Text Formatting Bar - See missing images for: Font Color, Justify, Single Line.
> Line and Filling Bar - See missing images for: Area 
- These images are displayed for the Galaxy theme, but not for other themes. I presume this is due to links.txt image replacement not being used.

I'm not sure if this worked in the past? 
The 'fix' may not require that we use links.txt, but as duplicate images are removed from icon themes globally, we should ensure that help content points to the chosen canonical icon. ... However, for some icon themes relying heavily on links.txt, this may still not be sufficient.


Testing: Version: 4.2.0.4, Mac.
Build ID: 05dceb5d363845f2cf968344d7adab8dcfb2ba71
Comment 1 ace_dent 2014-03-01 11:32:14 UTC
Vaguely related examples of missing images...
https://bugs.freedesktop.org/show_bug.cgi?id=52318#c7
https://bugs.freedesktop.org/show_bug.cgi?id=37509#c2
Comment 2 sophie 2014-03-21 12:56:10 UTC
Confirmed with Version: 4.2.3.1
Build ID: 3d4fc3d9dbf8f4c0aeb61498a81f91c5b7922f13
This is how icons appears in my .po file:
--------
<image id="img_id3145744" src="cmd/sc_cut.png" width="0.2228in" height="0.2228in"><alt id="alt_id3145744">Icon</alt></image>
--------
Set as New - Sophie
Comment 3 sophie 2014-03-21 13:06:35 UTC
*** Bug 75948 has been marked as a duplicate of this bug. ***
Comment 4 Andras Timar 2014-05-12 20:05:13 UTC
*** Bug 78576 has been marked as a duplicate of this bug. ***
Comment 5 Regina Henschel 2014-07-24 21:35:33 UTC
The application help takes the path to the icon from the <image> element in the .xhp file. The help file is an XML format. It is transformed to HTML for the help viewer by the .xsl files in the help folder. They have the line <xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform">. XSLT version 1.0 is not able to use external text files. To get the chance to use the mapping given in links.txt file, the mapping needs to be in XML format. Or the code has to be changed, that XSLT version 2.0 can be used.
Comment 6 Yousuf Philips (jay) (retired) 2015-10-20 13:28:56 UTC
In addition to the links.txt issue, in 5.0 we no longer bundle parent icon theme icons in child icon themes, which results in more icons being missing, as mentioned in bug 82149 comment 23. It would be useful to close one of these two bugs as a duplicate.
Comment 7 Regina Henschel 2015-10-24 20:13:15 UTC
*** Bug 82149 has been marked as a duplicate of this bug. ***
Comment 8 Regina Henschel 2015-10-24 20:16:54 UTC
We had some discussion and tests on the Hackfest in Hamburg. Solving the problem in the xsl filter does not look promising. The next try should be, to fix it in core directly by improving or creating a protocol handler for use in the helpviewer.
Comment 9 Commit Notification 2015-10-26 17:05:40 UTC
Stephan Bergmann committed a patch related to this issue.
It has been pushed to "master":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=6948c546fdc00dddec7d58e03150dcc87921d6b2

tdf#75637: Resolve help images via a vnd.libreoffice.image UCP

It will be available in 5.1.0.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 10 Regina Henschel 2015-10-26 18:44:22 UTC
Wow! I would have need some weeks to get all the details correctly. I'm looking forward to the daily build.
Comment 11 Stephan Bergmann 2015-10-28 14:59:30 UTC
(requested backport to libreoffice-5-0 at <https://gerrit.libreoffice.org/#/c/19644/>)
Comment 12 Commit Notification 2015-10-28 16:22:46 UTC
Stephan Bergmann committed a patch related to this issue.
It has been pushed to "libreoffice-5-0":

http://cgit.freedesktop.org/libreoffice/core/commit/?id=74453dbed460c0c428ce989b07a65d5cac5db49a&h=libreoffice-5-0

tdf#75637: Resolve help images via a vnd.libreoffice.image UCP

It will be available in 5.0.4.

The patch should be included in the daily builds available at
http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
http://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 13 Maxim Monastirsky 2015-11-17 21:11:41 UTC
*** Bug 95886 has been marked as a duplicate of this bug. ***
Comment 14 Gabor Kelemen (allotropia) 2017-06-29 21:02:25 UTC
*** Bug 90830 has been marked as a duplicate of this bug. ***
Comment 15 Ulrich Windl 2017-07-05 12:37:30 UTC
At least bug 78576 seems to be fixed with LibreOffice_5.2.7_Win_x86.