Uploaded image for project: 'Apache Flex'
  1. Apache Flex
  2. FLEX-24650

spark.primitives.Graphic not displayed within UIComponent

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Minor
    • Resolution: Not A Problem
    • Adobe Flex SDK 4.0 (Release)
    • None
    • None
    • Affected OS(s): Windows
      Affected OS(s): Windows 7
      Browser: Firefox 3.x
      Language Found: English

    Description

      Steps to reproduce:
      1. Create a Graphic object which contains a Path with its data property set
      2. Add the Graphic object as a child of a UIComponent (I used an instance of UIComponent)
      3. Add the UIComponent as an element of a Spark Application

      Actual Results:
      The Graphic's path is not displayed

      Expected Results:
      The path is displayed

      Workaround (if any):
      Adding the Path to a Group, instead of a Graphic, allows the Path to be shown properly.

      ---------------Example to reproduce ----------------------------------

      <s:Application creationComplete="init()">

      <fx:Script>

      <![CDATA[

      import mx.core.UIComponent;
      import mx.graphics.SolidColor;

      import spark.primitives.Graphic;
      import spark.primitives.Path;

      private function init():void

      { var path : Path = new Path(); path.data = "M 0.0 0.0 L 100 0 L 100 100 L 0 10 L 0 0 Z"; path.fill = new SolidColor(0x030304); var graphic : Graphic = new Graphic(); graphic.addElement( path ); // This code displays the graphic correctly. addElement( graphic ); // When I add the graphic to a UIComponent, and add that to the stage, nothing is shown // var content : UIComponent = new UIComponent(); // content.addChild( graphic ); // addElement( content ); }

      ]]
      >

      </fx:Script></s:Application>

      Attachments

        Activity

          People

            adobejira Adobe JIRA
            adobejira Adobe JIRA
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: