You found a bug! We've classified it as EXTGWT-2413 . We encourage you to continue the discussion and to find an acceptable workaround while we work on a permanent fix.
  1. #1
    Sencha User
    Join Date
    Jul 2011
    Posts
    93
    Vote Rating
    6
    Andreas Samjeske is on a distinguished road

      0  

    Default Demo: Area Renderer Chart yAxis scaling problem

    Demo: Area Renderer Chart yAxis scaling problem


    You got to add the ValueProvider in the same order to axis and series.addYField. Otherwise the scale of the y-Axis is broken, if you choose to show one/some series via legend.

    Here is code of the AreaRendererExample:
    Code:
        NumericAxis<BrowserProxy> axis = new NumericAxis<BrowserProxy>();
        axis.setPosition(Position.LEFT);
        axis.addField(props.Chrome());
        axis.addField(props.Firefox());
        axis.addField(props.IE());
        axis.addField(props.Opera());
        axis.addField(props.Other());
        axis.addField(props.Safari());
    vs.
    Code:
        AreaSeries<BrowserProxy> series = new AreaSeries<BrowserProxy>();
        series.setHighlighting(true);
        series.setYAxisPosition(Position.LEFT);
        series.addYField(props.IE());
        series.addYField(props.Chrome());
        series.addYField(props.Firefox());
        series.addYField(props.Safari());
        series.addYField(props.Opera());
        series.addYField(props.Other());
    This leads to the described faulty behaviour.

    http://www.sencha.com/examples/#Exam...arendererchart

  2. #2
    Sencha - GXT Dev Team BrendanC's Avatar
    Join Date
    Aug 2010
    Posts
    534
    Vote Rating
    3
    BrendanC is on a distinguished road

      0  

    Default


    Thanks for the report! I have opened a bug in our bug tracker.

  3. #3
    Sencha - GXT Dev Team
    Join Date
    Feb 2009
    Location
    Minnesota
    Posts
    2,717
    Vote Rating
    89
    Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light

      0  

    Default


    I'm having a hard time reproducing this issue, though I may be missing something. The example has the ordering of the items as you've specified already (this is as of 3.0.1, it might have been different in an earlier version) - the axis field list is different from the series yfield list. The values seem to be correct - when I hide IE, the chart starts around 55% and ends just over 70%. What do you mean when you say "the scale of the y-Axis is broken"?

    Perhaps the issue is fixed, but we neglected to close this issue? This seems unlikely since 3.0.1 was released in August, but your ticket opened in September.

  4. #4
    Sencha User
    Join Date
    Jul 2011
    Posts
    93
    Vote Rating
    6
    Andreas Samjeske is on a distinguished road

      0  

    Default


    The problem still exists in 3.0.1 at http://www.sencha.com/examples/#Exam...arendererchart

    It becomes most obvious when you deactivate all but one series.

    Only IE active: series falls from 44.8 to 27.5; scale of yAxis is 0 to 25 ==> wrong
    Only Chrome active: series rises from 3.9 to 22.4; scale of yAxis is 0 to 50 ==> wrong (should have been 0 to 25 (0 to 24 with a step of 3))
    Only Firefox active: series highest value is 47.9; scale of yAxis is 0 to 45 ==> wrong
    It seems like IE, FF and Chrome switched their yAxis scales. This is due to the fact, that their adding order got messed up.

    Only Safari active: series highest value is 4.0; scale of yAxis is 0 to 3 ==> wrong
    Only Opera active: series highest value is 2.3; scale of yAxis is 0 to 1 ==> wrong
    Only Other active: series highest value is 0.9; scale of yAxis is 0 to 4 ==> wrong
    It seems like Safari, Opera and Other switched their yAxis scales. This is due to the fact, that their adding order got messed up.

    Do I have to be more precise?
    Even only deactivating IE, like you did, shows the problem in a minor way: sum of the remaining series ends up slightly above 70% while scale of yAxis is 0 to 100. Should have been 0 to 80.

    Regards,
    Andreas

  5. #5
    Sencha - GXT Dev Team
    Join Date
    Feb 2009
    Location
    Minnesota
    Posts
    2,717
    Vote Rating
    89
    Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light Colin Alworth is a glorious beacon of light

      0  

    Default


    Thanks for the additional detail, I clearly wasn't looking hard enough.

    The bug is in NumericAxis, but there isn't a clean workaround other than to order the insertion of the fields, as you have noted.

Thread Participants: 2

Tags for this Thread