Issue 123592 - [non-pro] Warning about attribute svg:stroke-width="10px"
Summary: [non-pro] Warning about attribute svg:stroke-width="10px"
Status: CONFIRMED
Alias: None
Product: Draw
Classification: Application
Component: open-import (show other issues)
Version: 4.1.0-dev
Hardware: All All
: P4 Minor (vote)
Target Milestone: ---
Assignee: AOO issues mailing list
QA Contact:
URL: http://www.w3.org/TR/2001/REC-xsl-200...
Keywords:
Depends on:
Blocks:
 
Reported: 2013-10-30 21:47 UTC by Regina Henschel
Modified: 2017-05-20 10:44 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
File that produces such warning (11.17 KB, application/vnd.oasis.opendocument.graphics)
2013-11-05 18:53 UTC, Regina Henschel
no flags Details
Export from Inkscape (6.11 KB, application/vnd.oasis.opendocument.graphics)
2013-11-05 18:56 UTC, Regina Henschel
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description Regina Henschel 2013-10-30 21:47:49 UTC
Error: An error or a warning has occured during XML import/export!
Error-Id: 0x10020002
    Flags: 1 WARNING
    Class: 2 FORMAT
    Number: 2
Parameters:
    0: svg:stroke-width
    1: 10px
Exception-Message: 
Position:
    Public Identifier: 
    System Identifier: file:///C:/Users/pppregin/Desktop/BezierFollowedByLine.odg
    Row, Column: 7,6

The attached document is valid according http://odf-validator.rhcloud.com/

I have used a debug-build of r5136830.
Comment 1 Armin Le Grand 2013-11-05 17:31:41 UTC
ALG: Regina, do you have the file that caused this, please?
Comment 2 Regina Henschel 2013-11-05 18:53:53 UTC
Created attachment 81884 [details]
File that produces such warning
Comment 3 Regina Henschel 2013-11-05 18:56:51 UTC
Created attachment 81885 [details]
Export from Inkscape

The Inkscape file generates similar Warning/Errors:

Error: An error or a warning has occured during XML import/export!
Error-Id: 0x10020002
    Flags: 1 WARNING
    Class: 2 FORMAT
    Number: 2
Parameters:
    0: svg:stroke-width
    1: 0,000pt
Exception-Message: 
Position:
    Public Identifier: 
    System Identifier: file:///C:/Users/pppregin/Desktop/InkscapeSpirale.odg
    Row, Column: 55,2

Error: An error or a warning has occured during XML import/export!
Error-Id: 0x10020002
    Flags: 1 WARNING
    Class: 2 FORMAT
    Number: 2
Parameters:
    0: svg:stroke-opacity
    1: 100,000%
Exception-Message: 
Position:
    Public Identifier: 
    System Identifier: file:///C:/Users/pppregin/Desktop/InkscapeSpirale.odg
    Row, Column: 55,2
Comment 4 Armin Le Grand 2013-11-07 11:19:28 UTC
ALG: Indeed in the styles part of the ODF there is svg:stroke-width="0,000pt" and svg:stroke-opacity="100,000%". The colon is the wrong sign here, it should be a point as numerical separator (AFAIK). Thus, the warning is correct.
Comment 5 Regina Henschel 2013-11-07 15:57:39 UTC
So for the Inkscape export, it is an error in Inkscape. If I correct comma to dot, the file opens without warning.

But the other file still produces this error and has no decimal comma. It seems, that it is the special unit px, which does not work. Using pt for example gives no error.
Comment 6 Armin Le Grand 2013-11-08 09:00:11 UTC
ALG: So the question is, is px allowed in ODF? AFAIK it is no tallowed in the core, but that might be changed...
Comment 7 Regina Henschel 2013-11-08 14:36:17 UTC
[ODF 1.2]
20.400 svg:stroke-width
"The svg:stroke-width attribute has the data type length 18.3.18."

18.3.18 length
"A (positive or negative) length, consisting of magnitude and unit, in conformance with the Units of Measure defined in ยง5.9.13 of [XSL]."

[URL see Bugzilla field]
5.9.13 Definitions of Units of Measure
The units of measure in this Recommendation have the following definitions:
Name	Definition
cm	See [ISO31]
mm	See [ISO31]
in	2.54cm
pt	1/72in
pc	12pt
px	See [5.9.13.1 Pixels]
em	See [5.9.7.2 Relative Lengths]

So yes, px is a valid unit in ODF.
Comment 8 Armin Le Grand 2014-01-15 16:03:18 UTC
ALG> Re-checked with patched file InkscapeSpirale.odg, exchanged commatas in svg:stroke-width="0.000pt" and svg:stroke-opacity="100.000%". After that, load cproduces no warnings.
I also checked conversion from pt to 100thMm done in SvXMLUnitConverter::convertMeasure in xmloff, looks correct. Nearly all units listed here are processed. Here are the exceptions:

- em is missing (started, but commented out)
- px is missing
Comment 9 Regina Henschel 2014-08-01 13:19:25 UTC
Warning still there in AOO420m1(Build:9800)  -  Rev. 1614365
Comment 10 Marcus 2017-05-20 10:44:38 UTC
Reset the assignee to the default "issues@openoffice.apache.org".