Re: custom shapes fail to parse






On Sat, Sep 27, 2014 at 1:50 AM, Amit Kucheria <amit kucheria gmail com> wrote:
Hi,

I saved the UML class shape with a custome name "rtapp-thread" in order to try and customise the shape by adding it to my own sheet. But dia fails to parse back the shape in question.

Google led me to a similar problem[1] but that doesn't fix my issues. Any help is appreciated. Error message reproduced below the signature.

Regards,
Amit

-------- Begin Error messages ----------

/usr/share/dia/shapes/rtapp/rtapp-thread.shape:35: namespace error : Failed to parse QName 'fill:'
    <svg:text fill: #ffffff="fill: #000000; text-anchor:middle; font-family: san
                   ^
/usr/share/dia/shapes/rtapp/rtapp-thread.shape:35: parser error : Specification mandate value for attribute fill:
    <svg:text fill: #ffffff="fill: #000000; text-anchor:middle; font-family: san
                    ^
/usr/share/dia/shapes/rtapp/rtapp-thread.shape:35: parser error : attributes construct error
    <svg:text fill: #ffffff="fill: #000000; text-anchor:middle; font-family: san
                    ^
/usr/share/dia/shapes/rtapp/rtapp-thread.shape:35: parser error : Couldn't find end of Start Tag text line 35
    <svg:text fill: #ffffff="fill: #000000; text-anchor:middle; font-family: san
                    ^
/usr/share/dia/shapes/rtapp/rtapp-thread.shape:35: parser error : Opening and ending tag mismatch: svg line 32 and text
ht: 700" x="13.4825" y="11.65" font-size="1" textLength="3.165">Thread</svg:text
                                                                               ^
/usr/share/dia/shapes/rtapp/rtapp-thread.shape:40: parser error : Opening and ending tag mismatch: shape line 2 and svg:svg
  </svg:svg>
            ^
/usr/share/dia/shapes/rtapp/rtapp-thread.shape:41: parser error : Extra content at the end of the document
</shape>
^


I figured out the problem, I think.

In the <svg:svg> section of the exported shape, this is line 35:

    <svg:text fill: #ffffff="fill: #000000; text-anchor:middle; font-family: sans; font-style: normal; font-weight: 700" x="25.0325" y="13.4" font-size="1" textLength="3.165">Thread</svg:text>

It should be the following instead:

    <svg:text style="fill: #000000; text-anchor:middle; font-family: sans; font-style: normal; font-weight: 700" x="25.0325" y="13.4" font-size="1" textLength="3.165">Thread</svg:text>

This seems like a bug in the export to shape.

--
____________________________________________
Amit Kucheria


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]