Good question.  You could think of it as a subtle but important
difference...for lists, the item renderer is often very specific to the
type of data being rendered.  For charts, it is sometime very specific
to the data schema, but just as often, purely a stylistic choice...do
you want round points on your line, or diamonds?  More importantly, do
you want round points on the first line, diamond points on the second
line, etc?  As a stylistic (and per-instance) option, we wanted people
to be able to develop style based themes for charts that just 'drop'
into place.  

 

Or, if you were less charitable, you could claim it's just a mistake on
our part, and itemRenderer should be a style everywhere J

 

 

Ely.

 

 

From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of Dirk Eismann
Sent: Friday, May 11, 2007 5:02 AM
To: flexcoders@yahoogroups.com
Subject: RE: [flexcoders] How to assign chart series itemRenderer in
AS3?

 

Btw, why there is this inconsistency that in the Charts API itemRenderer
is a Style whereas in the rest of the Flex 2 framework it is a property?

 

Dirk.

         

        
________________________________


        From: flexcoders@yahoogroups.com
[mailto:[EMAIL PROTECTED] On Behalf Of Ely Greenfield
        Sent: Thursday, May 10, 2007 8:00 PM
        To: flexcoders@yahoogroups.com
        Subject: RE: [flexcoders] How to assign chart series
itemRenderer in AS3?

         

         

        This should work fine:

         

        Import mx.charts.renderers.LineRenderer;

         

        lineSeries.setStyle("itemRenderer",new
ClassFactory(LineRenderer));

         

        Ely.

 

<<image001.jpg>>

<<image002.jpg>>

Reply via email to