Hybrid View

    Success! Looks like we've fixed this one. According to our records the fix was applied for a bug in our system in a recent build.
  1. #1
    Ext GWT Premium Member
    Join Date
    Apr 2011
    Posts
    14
    Vote Rating
    1
    JHammann is on a distinguished road

      0  

    Default GXT 3 Charts: Specifying series colors in HSV and HSL

    GXT 3 Charts: Specifying series colors in HSV and HSL


    Hello,

    we are using GXT 2.2.x for over a year. Now, we are evaluating GXT 3 (3.0.0b). We are excited about the GXT 3 Charts. I used the Pie Chart example (http://www.sencha.com/examples/#ExamplePlace:piechart) to do some tests. I encountered a problem with specifying colors for a PieSeries. Maybe I'm doing something wrong.
    Instead of specifying a gradient, I tried to specify a HSV and HSL color, respectively. In both cases the pie chart has black segments. Using RGB colors the pie chart is rendered with the specified colors. To isolate the problem I used the following code:

    Code:
    series.addColor(new HSV(new RGB(148, 174, 10)));    // Black segment
    series.addColor(new HSL(new RGB(148, 174, 10)));    // Black segment
    series.addColor(new RGB(148, 174, 10));    // Works fine
    With the aid of Firebug: the following SVG paths are created within the resulting HTML:

    Code:
    <path d="M172.0,230.5 L143.39205047240992,111.90158001125454 A122.0,122.0,0.0,0,1,278.08990550028653,170.25938288048275 Z " stroke-width="0.0" fill="hsl(69.51219512195121, 0.891304347826087, 0.3607843137254902)"/>
    ...
    <path d="M172.0,230.5 L185.10052429302795,351.7945846410621 A122.0,122.0,0.0,0,1,52.813503881183834,256.5495516836551 Z " stroke-width="0.0" fill="hsv(70.0, 94.0, 68.0)"/>
    ...
    The "fill" attribute uses the color specification hsl() and hsv(), which leads to black segments. In case of rgb() the respective segment is colored correctly. Are hsl() and hsv() allowed SVG color specification?

    Regards

    Jochen.

  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 bug report. This has now been fixed and will be in the next release.

  3. #3
    Sencha User PhiLho's Avatar
    Join Date
    Nov 2011
    Location
    Near Paris, France
    Posts
    140
    Vote Rating
    1
    PhiLho is on a distinguished road

      0  

    Default


    I was curious, so I searched...
    SVG color definition send to the CSS2 color definition.
    Both indicate that color is defined in RGB terms.
    I suppose hsv and hsl are defined in CSS3, so are out of the scope of SVG 1.1.

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

      0  

    Default


    GXT 3.0.1 has been released and contains this fix.

Thread Participants: 2

Tags for this Thread