1) write a custom renderer for your columnseries. This renderer should
fill the columns with the standard color, _unless_ it's filling the
selected index. Something like this:


Class MyCustomRenderer
{
        public var index:Number;
        public var selectedIndex:Number;
        function beginDraw(...)
        {
                index = 0;
        }

        function draw(...)
        {
                if (index == selectedindex)
                {
                        // draw in selected color
                }
                else
                {
                        // draw in normal color
                }
                index++;
        }
} 

Then set the selected index in a mouseOverData function:

<mx:ColumnChart
mouseOverData="event.hitData.element.renderer.selectedIndex =
event.hitData.index;event.hitData.element.invalidate()" >
        <mx:series>
                <mx:Array>
                        <mx:ColumnSeries>
                                <mx:renderer>
                                        <MyCustomRenderer />
                        

Or something to that effect.


2) not really possible in Flex 1.5.


Both of these are much more doable in Flex 2.


Ely.



                
-----Original Message-----
From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On
Behalf Of shemeshkale
Sent: Tuesday, April 11, 2006 3:02 AM
To: flexcoders@yahoogroups.com
Subject: [flexcoders] labelfuction and column chart questions

hi,
1) me using flex 1.5
i have a ColumnChart.
how can i change one column color on mouse hover on it?

2) how can i show images with labelFunction?
i m calling a function with labelFunction from a PieChart and want to
display images in the label.





--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives:
http://www.mail-archive.com/flexcoders%40yahoogroups.com
Yahoo! Groups Links



 





--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 



Reply via email to