Jump to content
JChartFX Community
  • 0

configuring point attributes in jquery




I am using jquery in setting up my jchartfx chart. I have an intention of configuring the display properties (shape, color, etc.) of a specific point in a multiple series chart. The examples I found so far are for pure JS implementation,. Can you show me how to do that in jquery? e.g. how do you declare an instance of a pointAttribute class in jquery?

I appreciate any tips.



Link to comment
Share on other sites

2 answers to this question

Recommended Posts

  • 0

You can configure per-point attributes using our jQuery UI as follows

var points = $("div", ".demo2").chart("getPoints");

var pointAttr = new cfx.PointAttributes();

// Use this if you are NOT using jChartFX CSS

// pointAttr.setColor("#00FF40");

// Use this if you are using jChartFX CSS and make sure there is an entry

// in your CSS for this tag

// pointAttr.setTag("SpecialPoint");

points.setItem(0, 4, pointAttr);


Please note that whenever you want to access one of our complex properties, e.g. a property that represents a collection such as Points you get the collection as a method and then use a very similar code that you would use against a pure JS implementation.


Link to comment
Share on other sites

  • 0

 Thanks. worked well. I would have thought though that there was a way to do that within the chart declaration? like:

 $("div", ".demo2").chart({

                animations: {
                    load: {
                        enabled: true
                gallery: cfx.Gallery.Lines,
                data: {
                    series: 3
                axisY: {
                    min: 0,
                    max: 10,
                }, ........

                point attribute manipulation code somewhere here...





Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Answer this question...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...