[REVIEW] fdo#33773 X-Axis Error Bars
Kohei Yoshida
kohei.yoshida at gmail.com
Fri Jun 1 14:03:04 PDT 2012
On Fri, 2012-06-01 at 14:05 -0400, Kohei Yoshida wrote:
> Hello Rafael,
>
> On Fri, 2012-06-01 at 11:13 -0430, Rafael Dominguez wrote:
>
> > i tried a lot of ideas and looked at how other code handle it but i
> > cant seem to get it work, if you could check it out and fix it or tell
> > me whats wrong, that would
> > be highly appreciated.
>
> As we chatted on IRC, I'll try to look into this and hopefully come up
> with an answer. The code around is a bit tricky so give me some time to
> get up to speed on this.
So, what I did is to build the latest version of master, and played with
X error bars in chart. Here is what I see.
When I set X error bars, specify the range for the positive and negative
error var values, it gets set correctly. This is good.
When I save that file, and inspects what gets saved in the XML stream of
that ods file, the ranges I set for X error bars are not saved. Only
those ranges for the Y error bars are saved.
Another thing I noticed is that, the ranges for the Y error bars are
saved in the style properties that are used by the <chart:series>
element. Those attribute names alone don't specify whether they are for
the X or Y bars, and during import we import them for Y error bars,
which is odd.
I don't know that the ODF spec specifies, but for this to work for both
X and Y error bars, we need to store these ranges in the style
properties that are used for the <chart:error-indicator> element.
Otherwise we won't be able to distinguish whether they are the X error
bars or Y error bars. I've checked the spec, but the spec is awfully
terse about this and I have no clue whether the spec even cares about
what element these attributes are used for. So, for the moment we will
assume that the spec doesn't impose any restriction regarding this.
Given all this, we will need to first work on the export side, to store
these attributes
chart:error-upper-indicator
chart:error-lower-indicator
chart:error-category
chart:error-upper-range
chart:error-lower-range
in the style properties that are used for the <chart:error-indicator>
element, instead of those that are used for the <chart:series> element.
Once that's taken care of, we can work on importing them properly.
I hope this makes sense. I don't know this was not an answer to your
original question, but in my view, this needs to be worked on first.
Best,
Kohei
--
Kohei Yoshida, LibreOffice hacker, Calc
More information about the LibreOffice
mailing list