1 Reply Latest reply on Nov 22, 2010 8:59 AM by Tanu Jain

    fx:Style for mx:lineStroke

    PaddyMc2010

      Hi there,

       

      I had a quick query that i cannot get fixed.  I have a Box with multiple panels.  Each Panel containing a mx:LineChart.  Each line chart has its own individual number of mx:LineSeries.  Some charts have 2 some have 8 etc.  Obviously when the charts get up to around 8 series, things started to get a little cluttered. 

       

      My question would be is it possilbe to style the mx:LineStroke weight so that this will shink down each of the lines?

       

      How i have this at present is by defining an individual Stoke like below for each line used in the LineSeries.

      <mx:Stroke id="line1" color="#008B8B" weight="1.5" alpha=".7" caps="round"/>

       

      But essentially i want just to adjust the weight, and keep the auto colors assigned by flex.

       

      Would anyone be able to advise if it is possilbe to locally define a <fx:Style> for just the lineStroke weight and how i would go about writing this?

       

      Im sure its something simple, but i cannot get around at this at present.

       

      Many thanks

        • 1. Re: fx:Style for mx:lineStroke
          Tanu Jain Level 2

          You can make a separate css file having content like given below:

           

          LineSeries
          {
              stroke: 1;
          }

           

          In your mxml application, specify the css file as given below:

          <mx:Style source="styles.css"/>

           

          This will make the stroke value = 1 for all lineSeries used in your application/mxml

           

          --


          Tanu