Bug 89475 - Failure to load gradients from ods file
Summary: Failure to load gradients from ods file
Status: NEW
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
(earliest affected) release
Hardware: x86-64 (AMD64) All
: medium normal
Assignee: Not Assigned
Depends on:
Blocks: ODF-import
  Show dependency treegraph
Reported: 2015-02-19 16:53 UTC by mwelinder
Modified: 2018-05-30 21:29 UTC (History)
1 user (show)

See Also:
Crash report or crash signature:

Sample file with 45-degree gradient (6.00 KB, application/vnd.oasis.opendocument.spreadsheet)
2015-02-19 16:55 UTC, mwelinder
Sample file with 45-degree gradient (6.02 KB, application/vnd.oasis.opendocument.spreadsheet)
2015-02-19 16:55 UTC, mwelinder
Sample file with 45-degree gradient (xlsx for reference) (6.74 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2015-02-19 16:56 UTC, mwelinder
Sample file with -45-degree gradient (6.01 KB, application/vnd.oasis.opendocument.spreadsheet)
2015-02-19 19:47 UTC, mwelinder

Note You need to log in before you can comment on or make changes to this bug.
Description mwelinder 2015-02-19 16:53:39 UTC
LibreOffice 410m0(Build:2)

The to-be-attached file contains a circle with a gradient that should go
from red to yellow in the direction from upper left to lower right.

When localc loads this file, it incorrectly sees a 4 degree angle, not
a 45 degree angle.

    <draw:gradient draw:name="Gradient-0" draw:start-color="#ffff00" draw:end-color="#ff0000" draw:style="linear" draw:angle="45"/>

The ODF 1.2 language is...

18.3.1 angle
An angle, as defined in ยง4.1 of [SVG]. An angle is a double value that may be followed immediately by one of the following angle unit identifiers: deg (degrees), grad (gradiants) or rad (radians). If no unit identifier is specified, the value is assumed to be in degrees.
Note: OpenDocument v1.1 did not support angle specifications that contain an angle unit identifier. Angle unit identifiers should be omitted for compatibility with OpenDocument v1.1.

Changing the "45" to "45deg" causes LO to act as-if "0" was requested.
Comment 1 mwelinder 2015-02-19 16:55:12 UTC
Created attachment 113509 [details]
Sample file with 45-degree gradient

This file uses

Comment 2 mwelinder 2015-02-19 16:55:47 UTC
Created attachment 113510 [details]
Sample file with 45-degree gradient

This file uses

Comment 3 mwelinder 2015-02-19 16:56:27 UTC
Created attachment 113511 [details]
Sample file with 45-degree gradient (xlsx for reference)
Comment 4 mwelinder 2015-02-19 19:47:00 UTC
Created attachment 113523 [details]
Sample file with -45-degree gradient

On further investigation it looks like negative angles like "-45"
are ignored.  -45 degrees is a perfectly reasonable angle and the
spec doesn't appear to rule it out.

LO should not ignore, but normalize into whatever representation it
prefers internally.
Comment 5 Buovjaga 2015-02-25 08:56:00 UTC

Additional note: .xlsx has no gradient, but a solid red fill.

Win 7 Pro 64-bit, LibO Version:
Build ID: de093506bcdc5fafd9023ee680b8c60e3e0645d7
Locale: fi_FI
Comment 6 tommy27 2016-04-16 07:29:13 UTC Comment hidden (obsolete)
Comment 7 QA Administrators 2017-05-22 13:27:55 UTC
** Please read this message in its entirety before responding **

To make sure we're focusing on the bugs that affect our users today, LibreOffice QA is asking bug reporters and confirmers to retest open, confirmed bugs which have not been touched for over a year.

There have been thousands of bug fixes and commits since anyone checked on this bug report. During that time, it's possible that the bug has been fixed, or the details of the problem have changed. We'd really appreciate your help in getting confirmation that the bug is still present.

If you have time, please do the following:

Test to see if the bug is still present on a currently supported version of LibreOffice 
(5.2.7 or 5.3.3  https://www.libreoffice.org/download/

If the bug is present, please leave a comment that includes the version of LibreOffice and 
your operating system, and any changes you see in the bug behavior
If the bug is NOT present, please set the bug's Status field to RESOLVED-WORKSFORME and leave 
a short comment that includes your version of LibreOffice and Operating System

Please DO NOT

Update the version field
Reply via email (please reply directly on the bug tracker)
Set the bug's Status field to RESOLVED - FIXED (this status has a particular meaning that is not 
appropriate in this case)

If you want to do more to help you can test to see if your issue is a REGRESSION. To do so:
1. Download and install oldest version of LibreOffice (usually 3.3 unless your bug pertains to a feature added after 3.3)


2. Test your bug
3. Leave a comment with your results.
4a. If the bug was present with 3.3 - set version to "inherited from OOo";
4b. If the bug was not present in 3.3 - add "regression" to keyword

Feel free to come ask questions or to say hello in our QA chat: http://webchat.freenode.net/?channels=libreoffice-qa

Thank you for helping us make LibreOffice even better for everyone!

Warm Regards,
QA Team