You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@openoffice.apache.org by "bo.tian" <bo...@cs2c.com.cn> on 2012/07/13 05:45:05 UTC

[Call-for-​​Review]Bug 120271 - Stock chart using Date as Category has Incorrect min/max candlestick value

I had fix the bug 120271
https://issues.apache.org/ooo/show_bug.cgi?id=120271
Could anyone help me to review the fix ?

And how was my last fix of bug 112701 ?
https://issues.apache.org/ooo/show_bug.cgi?id=112701



bo.tian

Re: [Call-for-​​Review]Bug 120271 - Stock chart using Date as Category has Incorrect min/max candlestick value

Posted by Clarence GUO <cl...@gmail.com>.
Hi~ Tian Bo,
Basically I can understand the root cause of this defect and your solution.
But could you please have a explanation in this issue in order to let more
people easily understand the problem?
I think the root cause is when update the chart view,
VSeriesPlotter::getMaximumYInRange will call
VDataSeriesGroup::getMinimumAndMaximiumYInContinuousXRange if the axis is
date format (if( !m_bCategoryXAxis || ( m_pExplicitCategoriesProvider &&
m_pExplicitCategoriesProvider->isDateAxis() ) )). That is why only when the
axis is changed to date format, the problem happen. But my question is, why
only for date axis, the maxinum and minimun Y values need to be
recalculated? Is it really necessary?
And about your solution, you add special handlig in
VDataSeriesGroup::getMinimumAndMaximiumYInContinuousXRange to detect
maxinum and minimum Y value. As your comment, it is for candle stick chart
only because I think only stock chart have maxinum and minimum Y values. my
concern is VDataSeriesGroup::getMinimumAndMaximiumYInContinuousXRange is a
common method, it is not very good to add special code here for only one
chart type because for most charts, they don't have maxinum and minimum Y
values. That means this code is redundant in most cases. My suggestion is
change CandleStickChart.cxx which is particually for stock chart view. Can
you make VSeriesPlotter::getMinimumAndMaximiumYInContinuousXRange to
virtual and have a new implementation in CandleStickChart which derive from
VSeriesPlotter and add your code in the new implementation?


2012/7/13 bo.tian <bo...@cs2c.com.cn>

> I had fix the bug 120271
> https://issues.apache.org/ooo/show_bug.cgi?id=120271
> Could anyone help me to review the fix ?
>
> And how was my last fix of bug 112701 ?
> https://issues.apache.org/ooo/show_bug.cgi?id=112701
>
>
>
> bo.tian

Re: [Call-for-​​Review]Bug 120271 - Stock chart using Date as Category has Incorrect min/max candlestick value

Posted by Andre Fischer <af...@a-w-f.de>.
On 13.07.2012 05:45, bo.tian wrote:
> I had fix the bug 120271
> https://issues.apache.org/ooo/show_bug.cgi?id=120271
> Could anyone help me to review the fix ?
>
> And how was my last fix of bug 112701 ?
> https://issues.apache.org/ooo/show_bug.cgi?id=112701

I took the liberty to set the flag for request of a preview for your 
patch of bug 112701 (and the modification provided by Pedro Giffuni). 
Without that flag the patch might go unnoticed for even longer.

-Andre

>
>
>
> bo.tian
>