You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@royale.apache.org by ah...@apache.org on 2018/10/29 17:41:50 UTC

[royale-asjs] branch develop updated (513a54e -> eb8672f)

This is an automated email from the ASF dual-hosted git repository.

aharui pushed a change to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git.


    from 513a54e  Jewel SelectedItemNullValidator and example
     new 13ca9f0  clean compile of charts
     new a680f53  Merge branch 'develop' into MXCharts
     new 6e4390f  clean compile after merging develop branch
     new efa5c4f  Merge branch 'develop' into MXCharts
     new f165eea  Merge branch 'develop' into MXCharts
     new 835bd93  don't instantiate the view if not parented so the view can see all properties have been set when it gets created.  Otherwise, layout may not be set
     new d26a5a4  add charts to tree
     new 388671d  eliminate conflicting definitions
     new dd34351  a few more places were private overwrites protected or public methods
     new eb8672f  Merge branch 'MXCharts' into develop

The 10 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .../mxroyale/tourdeflexmodules/src/explorer.xml    |    2 -
 .../html/beads/DataProviderItemsChangeNotifier.as  |    2 +-
 .../apache/royale/html/beads/SimpleAlertView.as    |   12 +-
 .../org/apache/royale/html/beads/SliderView.as     |   16 +-
 .../royale/html/supportClasses/HScrollViewport.as  |   80 -
 .../html/supportClasses/ScrollingViewport.as       |   24 +-
 .../royale/html/supportClasses/VScrollViewport.as  |   80 -
 .../org/apache/royale/events/KeyboardEvent.as      |   12 +-
 .../royale/org/apache/royale/events/MouseEvent.as  |   12 +-
 .../royale/org/apache/royale/graphics/IStroke.as   |    7 +-
 .../org/apache/royale/graphics/SolidColorStroke.as |    4 +-
 .../apache/royale/jewel/beads/views/ListView.as    |    3 +-
 .../apache/royale/jewel/beads/views/TableView.as   |    3 +-
 .../src/main/resources/mx-royale-manifest.xml      |   70 +-
 .../src/main/royale/mx/charts/AreaChart.as         |  557 +-
 .../src/main/royale/mx/charts/AxisLabel.as         |  135 +
 .../src/main/royale/mx/charts/AxisRenderer.as      | 3964 ++++++++++++
 .../MXRoyale/src/main/royale/mx/charts/BarChart.as |  916 ++-
 .../src/main/royale/mx/charts/BubbleChart.as       |  322 +
 .../src/main/royale/mx/charts/CandlestickChart.as  |  322 +
 .../src/main/royale/mx/charts/CategoryAxis.as      |  808 ++-
 .../src/main/royale/mx/charts/ChartItem.as         |  191 +-
 .../src/main/royale/mx/charts/ColumnChart.as       | 1263 +++-
 .../src/main/royale/mx/charts/DateTimeAxis.as      | 2541 ++++++++
 .../src/main/royale/mx/charts/GridLines.as         |  674 ++
 .../src/main/royale/mx/charts/HLOCChart.as         |  321 +
 .../MXRoyale/src/main/royale/mx/charts/HitData.as  |  444 +-
 .../MXRoyale/src/main/royale/mx/charts/Legend.as   | 6651 +++++++++++++++++++-
 .../src/main/royale/mx/charts/LegendItem.as        |  681 ++
 .../src/main/royale/mx/charts/LineChart.as         |  219 +-
 .../src/main/royale/mx/charts/LinearAxis.as        |  701 ++-
 .../MXRoyale/src/main/royale/mx/charts/LogAxis.as  |  606 ++
 .../MXRoyale/src/main/royale/mx/charts/PieChart.as |  275 +-
 .../src/main/royale/mx/charts/PlotChart.as         |  349 +-
 .../main/royale/mx/charts/chartClasses/AxisBase.as |  341 +
 .../AxisLabelSet.as}                               |   77 +-
 .../royale/mx/charts/chartClasses/BoundedValue.as  |  134 +
 .../mx/charts/chartClasses/CartesianCanvasValue.as |  126 +
 .../mx/charts/chartClasses/CartesianChart.as       | 2032 ++++++
 .../mx/charts/chartClasses/CartesianDataCanvas.as  | 2030 ++++++
 .../mx/charts/chartClasses/CartesianTransform.as   |  184 +-
 .../royale/mx/charts/chartClasses/ChartBase.as     | 5533 +++++++++++++++-
 .../royale/mx/charts/chartClasses/ChartElement.as  |  663 ++
 .../mx/charts/chartClasses/ChartItemDragProxy.as   |  129 +
 .../royale/mx/charts/chartClasses/ChartLabel.as    |  340 +
 .../royale/mx/charts/chartClasses/ChartState.as    |   97 +
 .../mx/charts/chartClasses/DataDescription.as      |  208 +
 .../main/royale/mx/charts/chartClasses/DataTip.as  |  678 +-
 .../royale/mx/charts/chartClasses/DataTransform.as |  247 +-
 .../mx/charts/chartClasses/DateRangeUtilities.as   |  575 ++
 .../mx/charts/chartClasses/DualStyleObject.as      |  284 +
 .../mx/charts/chartClasses/GraphicsUtilities.as    | 1286 ++--
 .../mx/charts/chartClasses/HLOCSeriesBase.as       | 1467 +++++
 .../main/royale/mx/charts/chartClasses/IAxis.as    |  797 ++-
 .../royale/mx/charts/chartClasses/IAxisRenderer.as |  266 +
 .../src/main/royale/mx/charts/chartClasses/IBar.as |  105 +
 .../royale/mx/charts/chartClasses/IChartElement.as |  257 +
 .../mx/charts/chartClasses/IChartElement2.as       |  107 +
 .../main/royale/mx/charts/chartClasses/IColumn.as  |  111 +
 .../royale/mx/charts/chartClasses/IDataCanvas.as   |  140 +
 .../royale/mx/charts/chartClasses/IStackable.as    |  115 +
 .../royale/mx/charts/chartClasses/IStackable2.as   |   78 +
 .../royale/mx/charts/chartClasses/InstanceCache.as |  541 ++
 .../royale/mx/charts/chartClasses/LegendData.as    |  137 +
 .../royale/mx/charts/chartClasses/NumericAxis.as   | 1423 +++++
 .../royale/mx/charts/chartClasses/PolarChart.as    |  650 ++
 .../mx/charts/chartClasses/PolarDataCanvas.as      | 1948 ++++++
 .../mx/charts/chartClasses/PolarTransform.as       |  253 +
 .../royale/mx/charts/chartClasses/RenderData.as    |  141 +-
 .../main/royale/mx/charts/chartClasses/Series.as   |  886 ++-
 .../royale/mx/charts/chartClasses/StackedSeries.as |  932 +++
 .../main/royale/mx/charts/effects/SeriesEffect.as  |  229 +
 .../SeriesInterpolate.as}                          |   66 +-
 .../main/royale/mx/charts/effects/SeriesSlide.as   |  134 +
 .../main/royale/mx/charts/effects/SeriesZoom.as    |  207 +
 .../effects/effectClasses/SeriesEffectInstance.as  |  435 ++
 .../effectClasses/SeriesInterpolateInstance.as     |  154 +
 .../effects/effectClasses/SeriesSlideInstance.as   |  339 +
 .../effects/effectClasses/SeriesZoomInstance.as    |  875 +++
 .../src/main/royale/mx/charts/events/ChartEvent.as |  154 +
 .../main/royale/mx/charts/events/ChartItemEvent.as |  164 +-
 .../royale/mx/charts/events/LegendMouseEvent.as    |  239 +
 .../royale/mx/charts/renderers/AreaRenderer.as     |  202 +
 .../royale/mx/charts/renderers/BoxItemRenderer.as  |  196 +
 .../mx/charts/renderers/CandlestickItemRenderer.as |  252 +
 .../mx/charts/renderers/CircleItemRenderer.as      |  207 +
 .../mx/charts/renderers/CrossItemRenderer.as       |  244 +
 .../mx/charts/renderers/DiamondItemRenderer.as     |  212 +
 .../royale/mx/charts/renderers/HLOCItemRenderer.as |  359 ++
 .../royale/mx/charts/renderers/LineRenderer.as     |  132 +
 .../mx/charts/renderers/ShadowBoxItemRenderer.as   |  224 +
 .../mx/charts/renderers/ShadowLineRenderer.as      |   95 +-
 .../mx/charts/renderers/TriangleItemRenderer.as    |  213 +
 .../mx/charts/renderers/WedgeItemRenderer.as       |  245 +
 .../src/main/royale/mx/charts/series/AreaSeries.as | 2085 +++++-
 .../src/main/royale/mx/charts/series/AreaSet.as    |  190 +
 .../src/main/royale/mx/charts/series/BarSeries.as  | 2512 +++++++-
 .../src/main/royale/mx/charts/series/BarSet.as     |  525 ++
 .../main/royale/mx/charts/series/BubbleSeries.as   | 1541 +++++
 .../royale/mx/charts/series/CandlestickSeries.as   |  556 ++
 .../main/royale/mx/charts/series/ColumnSeries.as   | 2568 +++++++-
 .../src/main/royale/mx/charts/series/ColumnSet.as  |  450 ++
 .../src/main/royale/mx/charts/series/HLOCSeries.as |  422 ++
 .../src/main/royale/mx/charts/series/LineSeries.as | 4352 +++++++------
 .../src/main/royale/mx/charts/series/PieSeries.as  | 4071 +++++++++---
 .../src/main/royale/mx/charts/series/PlotSeries.as | 1478 ++++-
 .../mx/charts/series/items/AreaSeriesItem.as       |  300 +
 .../royale/mx/charts/series/items/BarSeriesItem.as |  330 +
 .../mx/charts/series/items/BubbleSeriesItem.as     |  293 +
 .../mx/charts/series/items/ColumnSeriesItem.as     |  231 +-
 .../mx/charts/series/items/HLOCSeriesItem.as       |  422 ++
 .../mx/charts/series/items/LineSeriesItem.as       |  231 +
 .../mx/charts/series/items/LineSeriesSegment.as    |  191 +
 .../royale/mx/charts/series/items/PieSeriesItem.as |  623 +-
 .../mx/charts/series/items/PlotSeriesItem.as       |  247 +
 .../renderData/AreaSeriesRenderData.as}            |  310 +-
 .../series/renderData/BarSeriesRenderData.as       |  179 +
 .../renderData/BubbleSeriesRenderData.as}          |   63 +-
 .../series/renderData/ColumnSeriesRenderData.as    |  179 +
 .../series/renderData/HLOCSeriesRenderData.as      |  121 +
 .../series/renderData/LineSeriesRenderData.as      |  148 +
 .../series/renderData/PieSeriesRenderData.as       |  131 +
 .../series/renderData/PlotSeriesRenderData.as      |  101 +
 .../halo/SelectionSkin.as}                         |   73 +-
 .../main/royale/mx/charts/styles/HaloDefaults.as   |  251 +
 .../styles/metadata/FillStrokeStyles.as}           |   33 +-
 .../styles/metadata/GapStyles.as}                  |   33 +-
 .../charts/styles/metadata/ItemRendererStyles.as   |   43 +
 .../styles/metadata/LeadingStyle.as}               |   63 +-
 .../styles/metadata/MarginStyles.as}               |   33 +-
 .../royale/mx/charts/styles/metadata/TextStyles.as |  280 +
 .../src/main/royale/mx/containers/Panel.as         |  101 +-
 .../main/royale/mx/containers/beads/PanelView.as   |   25 +-
 .../mx/containers/beads/models/PanelModel.as       |    8 +-
 .../src/main/royale/mx/controls/LinkBar.as         |    2 +-
 .../src/main/royale/mx/core/Application.as         |   11 +-
 .../src/main/royale/mx/core/ClassFactory.as        |    2 +-
 .../IProgrammaticSkin.as}                          |   42 +-
 .../src/main/royale/mx/core/ITextFieldFactory.as   |   71 +
 .../src/main/royale/mx/core/IUIComponent.as        |    4 +
 .../src/main/royale/mx/core/IUITextField.as        |  168 +
 .../src/main/royale/mx/core/UIComponent.as         |  380 +-
 .../src/main/royale/mx/core/UITextField.as         |    4 +-
 .../src/main/royale/mx/core/UITextFormat.as        |  594 ++
 .../src/main/royale/mx/display/Graphics.as         |   38 +-
 .../MXRoyale/src/main/royale/mx/effects/Effect.as  |    4 +
 .../src/main/royale/mx/effects/EffectInstance.as   |   62 +-
 .../mx/effects/effectClasses/ParallelInstance.as   |  609 ++
 .../effects/effectClasses/TweenEffectInstance.as   |   11 +-
 .../src/main/royale/mx/events/FlexEvent.as         |    2 +-
 .../src/main/royale/mx/events/TweenEvent.as        |  230 +
 .../MXRoyale/src/main/royale/mx/graphics/IFill.as  |   41 +-
 .../src/main/royale/mx/graphics/IStroke.as         |   28 +-
 .../src/main/royale/mx/graphics/LinearGradient.as  |   37 +-
 .../src/main/royale/mx/graphics/SolidColor.as      |   40 +-
 .../main/royale/mx/graphics/SolidColorStroke.as    |   57 +-
 .../MXRoyale/src/main/royale/mx/graphics/Stroke.as |   36 +-
 .../src/main/royale/mx/managers/SystemManager.as   |    5 +-
 .../src/main/royale/mx/skins/ProgrammaticSkin.as   |   19 +-
 .../main/royale/mx/styles/CSSStyleDeclaration.as   |   74 +
 .../main/royale/mx/styles/ISimpleStyleClient.as    |    6 +-
 .../src/main/royale/mx/styles/IStyleManager.as     |  565 ++
 .../src/main/royale/mx/styles/IStyleManager2.as    |    2 +-
 .../MXRoyale/src/main/royale/mx/text/TextFormat.as |   66 +
 .../org/apache/royale/site/TitledAnchorList.as     |    2 +-
 .../src/main/royale/spark/collections/Sort.as      |    8 +
 .../src/main/royale/spark/collections/SortField.as |    9 +-
 .../src/main/royale/spark/components/Group.as      |    7 +-
 .../spark/components/supportClasses/TextBase.as    |    9 +-
 169 files changed, 75072 insertions(+), 7128 deletions(-)
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/AxisLabel.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/AxisRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/BubbleChart.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/CandlestickChart.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/DateTimeAxis.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/GridLines.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/HLOCChart.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/LegendItem.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/LogAxis.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/AxisBase.as
 copy frameworks/projects/MXRoyale/src/main/royale/mx/charts/{series/items/ColumnSeriesItem.as => chartClasses/AxisLabelSet.as} (61%)
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/BoundedValue.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/CartesianCanvasValue.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/CartesianChart.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/CartesianDataCanvas.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/ChartElement.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/ChartItemDragProxy.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/ChartLabel.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/ChartState.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/DataDescription.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/DateRangeUtilities.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/DualStyleObject.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/HLOCSeriesBase.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/IAxisRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/IBar.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/IChartElement.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/IChartElement2.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/IColumn.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/IDataCanvas.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/IStackable.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/IStackable2.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/InstanceCache.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/LegendData.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/NumericAxis.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/PolarChart.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/PolarDataCanvas.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/PolarTransform.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/StackedSeries.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/effects/SeriesEffect.as
 copy frameworks/projects/MXRoyale/src/main/royale/mx/charts/{renderers/ShadowLineRenderer.as => effects/SeriesInterpolate.as} (54%)
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/effects/SeriesSlide.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/effects/SeriesZoom.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/effects/effectClasses/SeriesEffectInstance.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/effects/effectClasses/SeriesInterpolateInstance.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/effects/effectClasses/SeriesSlideInstance.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/effects/effectClasses/SeriesZoomInstance.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/events/ChartEvent.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/events/LegendMouseEvent.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/renderers/AreaRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/renderers/BoxItemRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/renderers/CandlestickItemRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/renderers/CircleItemRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/renderers/CrossItemRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/renderers/DiamondItemRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/renderers/HLOCItemRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/renderers/LineRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/renderers/ShadowBoxItemRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/renderers/TriangleItemRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/renderers/WedgeItemRenderer.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/AreaSet.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/BarSet.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/BubbleSeries.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/CandlestickSeries.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/ColumnSet.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/HLOCSeries.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/items/AreaSeriesItem.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/items/BarSeriesItem.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/items/BubbleSeriesItem.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/items/HLOCSeriesItem.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/items/LineSeriesItem.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/items/LineSeriesSegment.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/items/PlotSeriesItem.as
 copy frameworks/projects/MXRoyale/src/main/royale/mx/charts/{chartClasses/DataTip.as => series/renderData/AreaSeriesRenderData.as} (52%)
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/renderData/BarSeriesRenderData.as
 copy frameworks/projects/MXRoyale/src/main/royale/mx/charts/{chartClasses/CartesianTransform.as => series/renderData/BubbleSeriesRenderData.as} (55%)
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/renderData/ColumnSeriesRenderData.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/renderData/HLOCSeriesRenderData.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/renderData/LineSeriesRenderData.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/renderData/PieSeriesRenderData.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/renderData/PlotSeriesRenderData.as
 copy frameworks/projects/MXRoyale/src/main/royale/mx/charts/{renderers/ShadowLineRenderer.as => skins/halo/SelectionSkin.as} (52%)
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/styles/HaloDefaults.as
 copy frameworks/projects/MXRoyale/src/main/royale/mx/{styles/IStyleManager2.as => charts/styles/metadata/FillStrokeStyles.as} (66%)
 copy frameworks/projects/MXRoyale/src/main/royale/mx/{styles/IStyleManager2.as => charts/styles/metadata/GapStyles.as} (67%)
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/styles/metadata/ItemRendererStyles.as
 copy frameworks/projects/MXRoyale/src/main/royale/mx/{graphics/LinearGradient.as => charts/styles/metadata/LeadingStyle.as} (77%)
 copy frameworks/projects/MXRoyale/src/main/royale/mx/{styles/IStyleManager2.as => charts/styles/metadata/MarginStyles.as} (67%)
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/charts/styles/metadata/TextStyles.as
 copy frameworks/projects/MXRoyale/src/main/royale/mx/{styles/IStyleManager2.as => core/IProgrammaticSkin.as} (61%)
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/core/ITextFieldFactory.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/core/IUITextField.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/core/UITextFormat.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/effects/effectClasses/ParallelInstance.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/events/TweenEvent.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/styles/IStyleManager.as
 create mode 100644 frameworks/projects/MXRoyale/src/main/royale/mx/text/TextFormat.as


[royale-asjs] 07/10: add charts to tree

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

aharui pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git

commit d26a5a4fccbb198c95a9b7a3b3f11570d8ec7298
Author: Alex Harui <ah...@apache.org>
AuthorDate: Fri Oct 26 19:06:15 2018 -0700

    add charts to tree
---
 examples/mxroyale/tourdeflexmodules/src/explorer.xml | 2 --
 1 file changed, 2 deletions(-)

diff --git a/examples/mxroyale/tourdeflexmodules/src/explorer.xml b/examples/mxroyale/tourdeflexmodules/src/explorer.xml
index 3508f87..fcc00c6 100755
--- a/examples/mxroyale/tourdeflexmodules/src/explorer.xml
+++ b/examples/mxroyale/tourdeflexmodules/src/explorer.xml
@@ -195,7 +195,6 @@
 				</node>
 			</node>
 			<node label="Datavisualization Components">
-                <!--
 				<node label="Charts">
 					<node label="Chart Controls">
 						<node label="AreaChart" module="mx/charts/Line_AreaChartExample" />
@@ -232,7 +231,6 @@
 						<node label="SeriesZoom" module="mx/charts/SeriesZoomExample" />
 					</node>
 				</node>
-                 -->
 				<node label="AdancedDataGrid">
 					<node label="AdvancedDataGrid" module="mx/controls/AdvancedDataGridExample" />
 				</node>


[royale-asjs] 08/10: eliminate conflicting definitions

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

aharui pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git

commit 388671d688ba68aa5da9a4539353356f34d6f217
Author: Alex Harui <ah...@apache.org>
AuthorDate: Mon Oct 29 00:20:45 2018 -0700

    eliminate conflicting definitions
---
 .../html/beads/DataProviderItemsChangeNotifier.as  |   2 +-
 .../apache/royale/html/beads/SimpleAlertView.as    |  12 +-
 .../org/apache/royale/html/beads/SliderView.as     |  16 +-
 .../royale/html/supportClasses/HScrollViewport.as  |  80 ---------
 .../html/supportClasses/ScrollingViewport.as       |  24 +--
 .../royale/html/supportClasses/VScrollViewport.as  |  80 ---------
 .../org/apache/royale/events/KeyboardEvent.as      |  12 +-
 .../royale/org/apache/royale/events/MouseEvent.as  |  12 +-
 .../MXRoyale/src/main/royale/mx/charts/Legend.as   |   9 +-
 .../royale/mx/charts/chartClasses/ChartBase.as     |   1 +
 .../src/main/royale/mx/charts/series/AreaSet.as    |   2 +-
 .../src/main/royale/mx/core/Application.as         |  11 +-
 .../src/main/royale/mx/core/UIComponent.as         | 195 ++++++++++++++++++++-
 .../src/main/royale/mx/display/Graphics.as         |  25 ++-
 .../src/main/royale/mx/managers/SystemManager.as   |   5 +-
 .../org/apache/royale/site/TitledAnchorList.as     |   2 +-
 .../src/main/royale/spark/components/Group.as      |   7 +-
 17 files changed, 261 insertions(+), 234 deletions(-)

diff --git a/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/beads/DataProviderItemsChangeNotifier.as b/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/beads/DataProviderItemsChangeNotifier.as
index 0573536..53ccde9 100644
--- a/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/beads/DataProviderItemsChangeNotifier.as
+++ b/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/beads/DataProviderItemsChangeNotifier.as
@@ -48,7 +48,7 @@ package org.apache.royale.html.beads
 		{
 		}
 
-		private function destinationChangedHandler(event:Event):void
+		override protected function destinationChangedHandler(event:Event):void
 		{
 			var object:Object = document[sourceID];
 			if (dataProvider)
diff --git a/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/beads/SimpleAlertView.as b/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/beads/SimpleAlertView.as
index 1de8ce8..1e8cdd1 100644
--- a/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/beads/SimpleAlertView.as
+++ b/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/beads/SimpleAlertView.as
@@ -65,14 +65,6 @@ package org.apache.royale.html.beads
 		
 		private var messageLabel:Label;
 		private var okButton:TextButton;
-
-		/**
-		 * @royaleignorecoercion org.apache.royale.core.UIBase
-		 */
-		private function get host():UIBase
-		{
-			return _strand as UIBase;
-		}
 		
 		/**
 		 *  @copy org.apache.royale.core.IBead#strand
@@ -115,11 +107,11 @@ package org.apache.royale.html.beads
             messageLabel = new Label();
 			messageLabel.text = model.message;
 			messageLabel.html = model.htmlMessage;
-			host.addElement(messageLabel);
+            (host as IParent).addElement(messageLabel);
 			
 			okButton = new TextButton();
 			okButton.text = model.okLabel;
-			host.addElement(okButton);
+            (host as IParent).addElement(okButton);
 			okButton.addEventListener("click",handleOK);
 			
 			handleMessageChange(null);
diff --git a/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/beads/SliderView.as b/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/beads/SliderView.as
index e5765ef..8b7c018 100644
--- a/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/beads/SliderView.as
+++ b/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/beads/SliderView.as
@@ -29,6 +29,7 @@ package org.apache.royale.html.beads
     import org.apache.royale.core.IBeadModel;
     import org.apache.royale.core.IBeadView;
     import org.apache.royale.core.IRangeModel;
+    import org.apache.royale.core.IParent;
     import org.apache.royale.core.IStrand;
     import org.apache.royale.core.IUIBase;
     import org.apache.royale.core.UIBase;
@@ -71,6 +72,9 @@ package org.apache.royale.html.beads
 		 *  @playerversion Flash 10.2
 		 *  @playerversion AIR 2.6
 		 *  @productversion Royale 0.0
+         * 
+         *  @royaleignorecoercion org.apache.royale.core.IParent
+         * 
 		 */
 		override public function set strand(value:IStrand):void
 		{
@@ -101,13 +105,13 @@ package org.apache.royale.html.beads
 				_track = new Button();
 				_track.className = "SliderTrack";
 				_track.style = {"position": "absolute", "padding" : 0};
-				host.addElement(_track);
+				(host as IParent).addElement(_track);
 				
 				_thumb = new TextButton();
 				_thumb.className = "SliderThumb";
 				_thumb.style = {"position" : "absolute", "padding" : 0};
 				_thumb.text = '\u29BF';
-				host.addElement(_thumb);
+                (host as IParent).addElement(_thumb);
 			}
 			
 			rangeModel = _strand.getBeadByType(IBeadModel) as IRangeModel;
@@ -155,14 +159,6 @@ package org.apache.royale.html.beads
 		}
 		
 		/**
-		 * @royaleignorecoercion org.apache.royale.core.UIBase
-		 */
-		private function get host():UIBase
-		{
-			return _strand as UIBase;
-		}
-		
-		/**
 		 * @private
 		 */
 		private function modelChangeHandler( event:Event ) : void
diff --git a/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/supportClasses/HScrollViewport.as b/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/supportClasses/HScrollViewport.as
index 860e04b..0a96b42 100644
--- a/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/supportClasses/HScrollViewport.as
+++ b/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/supportClasses/HScrollViewport.as
@@ -110,55 +110,11 @@ package org.apache.royale.html.supportClasses
 			super();
 		}
 
-		private var _verticalScroller:ScrollBar;
-
-		override public function get verticalScroller():IViewportScroller
-		{
-			return _verticalScroller;
-		}
-
-		private var _horizontalScroller:ScrollBar
-
-		override public function get horizontalScroller():IViewportScroller
-		{
-			return _horizontalScroller;
-		}
-
-        override public function get verticalScrollPosition():Number
-        {
-			return 0;
-        }
         override public function set verticalScrollPosition(value:Number):void
         {
 			//do nothing
         }
 
-        private var _horizontalScrollPosition:Number = 0;
-
-        override public function get horizontalScrollPosition():Number
-        {
-			return _horizontalScrollPosition;
-        }
-        override public function set horizontalScrollPosition(value:Number):void
-        {
-			_horizontalScrollPosition = value;
-            dispatchEvent(new Event("horizontalScrollPositionChanged"));
-			handleHorizontalScrollChange();
-        }
-
-        private var viewportWidth:Number;
-        private var viewportHeight:Number;
-
-        /**
-         * @copy org.apache.royale.core.IViewport
-         */
-        override public function layoutViewportBeforeContentLayout(width:Number, height:Number):void
-        {
-           	super.layoutViewportBeforeContentLayout(width, height);
-           	viewportWidth = width;
-           	viewportHeight = height;
-        }
-
         /**
          * @copy org.apache.royale.core.IViewport
          *  @royaleignorecoercion org.apache.royale.core.IBorderPaddingMarginValuesImpl
@@ -217,41 +173,5 @@ package org.apache.royale.html.supportClasses
 			contentArea.scrollRect = rect;
 		}
 
-		private function createHorizontalScrollBar():ScrollBar
-		{
-			var hsbm:ScrollBarModel = new ScrollBarModel();
-			hsbm.minimum = 0;
-			hsbm.snapInterval = 1;
-			hsbm.stepSize = 1;
-			hsbm.value = 0;
-
-			var hsb:HScrollBar;
-			hsb = new HScrollBar();
-			hsb.model = hsbm;
-			hsb.visible = false;
-
-			hsb.addEventListener("scroll",handleHorizontalScroll);
-			return hsb;
-		}
-
-		private function handleHorizontalScroll(event:Event):void
-		{
-			var host:UIBase = UIBase(_strand);
-			var hpos:Number = ScrollBarModel(_horizontalScroller.model).value;
-			var rect:flash.geom.Rectangle = contentArea.scrollRect;
-			rect.x = hpos;
-			contentArea.scrollRect = rect;
-
-			_horizontalScrollPosition = hpos;
-            dispatchEvent(new Event("horizontalScrollPositionChanged"));
-		}
-
-		private function handleHorizontalScrollChange():void
-		{
-			if (_horizontalScroller) {
-				ScrollBarModel(_horizontalScroller.model).value = horizontalScrollPosition;
-			}
-		}
-
 	}
 }
diff --git a/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/supportClasses/ScrollingViewport.as b/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/supportClasses/ScrollingViewport.as
index 46a851c..807c1d6 100644
--- a/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/supportClasses/ScrollingViewport.as
+++ b/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/supportClasses/ScrollingViewport.as
@@ -138,21 +138,21 @@ package org.apache.royale.html.supportClasses
 			super();
 		}
 
-		private var _verticalScroller:ScrollBar;
+		protected var _verticalScroller:ScrollBar;
 
 		public function get verticalScroller():IViewportScroller
 		{
 			return _verticalScroller;
 		}
 
-		private var _horizontalScroller:ScrollBar
+		protected var _horizontalScroller:ScrollBar
 
 		public function get horizontalScroller():IViewportScroller
 		{
 			return _horizontalScroller;
 		}
 
-        private var _verticalScrollPosition:Number = 0;
+        protected var _verticalScrollPosition:Number = 0;
 
         public function get verticalScrollPosition():Number
         {
@@ -165,7 +165,7 @@ package org.apache.royale.html.supportClasses
 			handleVerticalScrollChange();
         }
 
-        private var _horizontalScrollPosition:Number = 0;
+        protected var _horizontalScrollPosition:Number = 0;
 
         public function get horizontalScrollPosition():Number
         {
@@ -178,8 +178,8 @@ package org.apache.royale.html.supportClasses
 			handleHorizontalScrollChange();
         }
 
-        private var viewportWidth:Number;
-        private var viewportHeight:Number;
+        protected var viewportWidth:Number;
+        protected var viewportHeight:Number;
 
         /**
          * @copy org.apache.royale.core.IViewport
@@ -281,7 +281,7 @@ package org.apache.royale.html.supportClasses
 			contentArea.scrollRect = rect;
 		}
 
-		private function createVerticalScrollBar():ScrollBar
+		protected function createVerticalScrollBar():ScrollBar
 		{
 			var vsbm:ScrollBarModel = new ScrollBarModel();
 			vsbm.minimum = 0;
@@ -298,7 +298,7 @@ package org.apache.royale.html.supportClasses
 			return vsb;
 		}
 
-		private function createHorizontalScrollBar():ScrollBar
+		protected function createHorizontalScrollBar():ScrollBar
 		{
 			var hsbm:ScrollBarModel = new ScrollBarModel();
 			hsbm.minimum = 0;
@@ -315,7 +315,7 @@ package org.apache.royale.html.supportClasses
 			return hsb;
 		}
 
-		private function handleVerticalScroll(event:Event):void
+		protected function handleVerticalScroll(event:Event):void
 		{
 			var host:UIBase = UIBase(_strand);
 			var vpos:Number = ScrollBarModel(_verticalScroller.model).value;
@@ -327,7 +327,7 @@ package org.apache.royale.html.supportClasses
             dispatchEvent(new Event("verticalScrollPositionChanged"));
 		}
 
-		private function handleHorizontalScroll(event:Event):void
+		protected function handleHorizontalScroll(event:Event):void
 		{
 			var host:UIBase = UIBase(_strand);
 			var hpos:Number = ScrollBarModel(_horizontalScroller.model).value;
@@ -339,14 +339,14 @@ package org.apache.royale.html.supportClasses
             dispatchEvent(new Event("horizontalScrollPositionChanged"));
 		}
 
-		private function handleVerticalScrollChange():void
+		protected function handleVerticalScrollChange():void
 		{
 			if (_verticalScroller) {
 				ScrollBarModel(_verticalScroller.model).value = verticalScrollPosition;
 			}
 		}
 
-		private function handleHorizontalScrollChange():void
+		protected function handleHorizontalScrollChange():void
 		{
 			if (_horizontalScroller) {
 				ScrollBarModel(_horizontalScroller.model).value = horizontalScrollPosition;
diff --git a/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/supportClasses/VScrollViewport.as b/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/supportClasses/VScrollViewport.as
index cc912d6..9feb90d 100644
--- a/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/supportClasses/VScrollViewport.as
+++ b/frameworks/projects/Basic/src/main/royale/org/apache/royale/html/supportClasses/VScrollViewport.as
@@ -110,38 +110,6 @@ package org.apache.royale.html.supportClasses
 			super();
 		}
 
-		private var _verticalScroller:ScrollBar;
-
-		override public function get verticalScroller():IViewportScroller
-		{
-			return _verticalScroller;
-		}
-
-		private var _horizontalScroller:ScrollBar
-
-		override public function get horizontalScroller():IViewportScroller
-		{
-			return _horizontalScroller;
-		}
-
-        private var _verticalScrollPosition:Number = 0;
-
-        override public function get verticalScrollPosition():Number
-        {
-			return _verticalScrollPosition;
-        }
-        override public function set verticalScrollPosition(value:Number):void
-        {
-			_verticalScrollPosition = value;
-			handleVerticalScrollChange();
-        }
-
-        private var _horizontalScrollPosition:Number = 0;
-
-        override public function get horizontalScrollPosition():Number
-        {
-			return _horizontalScrollPosition;
-        }
         override public function set horizontalScrollPosition(value:Number):void
         {
 			// Do nothing
@@ -149,19 +117,6 @@ package org.apache.royale.html.supportClasses
 			// handleHorizontalScrollChange();
         }
 
-        private var viewportWidth:Number;
-        private var viewportHeight:Number;
-
-        /**
-         * @copy org.apache.royale.core.IViewport
-         */
-        override public function layoutViewportBeforeContentLayout(width:Number, height:Number):void
-        {
-           	super.layoutViewportBeforeContentLayout(width, height);
-           	viewportWidth = width;
-           	viewportHeight = height;
-        }
-
         /**
          * @copy org.apache.royale.core.IViewport
          */
@@ -221,40 +176,5 @@ package org.apache.royale.html.supportClasses
 			contentArea.scrollRect = rect;
 		}
 
-		private function createVerticalScrollBar():ScrollBar
-		{
-			var vsbm:ScrollBarModel = new ScrollBarModel();
-			vsbm.minimum = 0;
-			vsbm.snapInterval = 1;
-			vsbm.stepSize = 1;
-			vsbm.value = 0;
-
-			var vsb:VScrollBar;
-			vsb = new VScrollBar();
-			vsb.model = vsbm;
-			vsb.visible = false;
-
-			vsb.addEventListener("scroll",handleVerticalScroll);
-			return vsb;
-		}
-
-		private function handleVerticalScroll(event:Event):void
-		{
-			var host:UIBase = UIBase(_strand);
-			var vpos:Number = ScrollBarModel(_verticalScroller.model).value;
-			var rect:flash.geom.Rectangle = contentArea.scrollRect;
-			rect.y = vpos;
-			contentArea.scrollRect = rect;
-
-			_verticalScrollPosition = vpos;
-		}
-
-		private function handleVerticalScrollChange():void
-		{
-			if (_verticalScroller) {
-				ScrollBarModel(_verticalScroller.model).value = verticalScrollPosition;
-			}
-		}
-
 	}
 }
diff --git a/frameworks/projects/Core/src/main/royale/org/apache/royale/events/KeyboardEvent.as b/frameworks/projects/Core/src/main/royale/org/apache/royale/events/KeyboardEvent.as
index d8f630e..a184ddd 100644
--- a/frameworks/projects/Core/src/main/royale/org/apache/royale/events/KeyboardEvent.as
+++ b/frameworks/projects/Core/src/main/royale/org/apache/royale/events/KeyboardEvent.as
@@ -94,13 +94,13 @@ package org.apache.royale.events
          * @productversion Royale 0.9
 		 */
         COMPILE::JS
-		public function get target():Object
+        override public function get target():Object
 		{
 			return wrappedEvent ? getTargetWrapper(wrappedEvent.target) : _target;
 		}
 
         COMPILE::JS
-		public function set target(value:Object):void
+        override public function set target(value:Object):void
 		{
 			_target = value;
 		}
@@ -114,13 +114,13 @@ package org.apache.royale.events
          * @productversion Royale 0.9
 		 */
         COMPILE::JS
-		public function get currentTarget():Object
+        override public function get currentTarget():Object
 		{
 			return wrappedEvent ? getTargetWrapper(wrappedEvent.currentTarget) : _target;
 		}
 
         COMPILE::JS
-		public function set currentTarget(value:Object):void
+        override public function set currentTarget(value:Object):void
 		{
 			_target = value;
 		}
@@ -258,12 +258,12 @@ package org.apache.royale.events
          * @productversion Royale 0.0
 		 */
         COMPILE::JS
-		public function get defaultPrevented():Boolean
+		override public function get defaultPrevented():Boolean
 		{
 			return wrappedEvent ? wrappedEvent.defaultPrevented : _defaultPrevented;
 		}
         COMPILE::JS
-		public function set defaultPrevented(value:Boolean):void
+        override public function set defaultPrevented(value:Boolean):void
 		{
 			_defaultPrevented = value;
 		}
diff --git a/frameworks/projects/Core/src/main/royale/org/apache/royale/events/MouseEvent.as b/frameworks/projects/Core/src/main/royale/org/apache/royale/events/MouseEvent.as
index 38acf6b..2a33632 100644
--- a/frameworks/projects/Core/src/main/royale/org/apache/royale/events/MouseEvent.as
+++ b/frameworks/projects/Core/src/main/royale/org/apache/royale/events/MouseEvent.as
@@ -421,11 +421,11 @@ package org.apache.royale.events
          * @playerversion AIR 2.6
          * @productversion Royale 0.0
 		 */
-		public function get target():Object
+        override public function get target():Object
 		{
 			return wrappedEvent ? getTargetWrapper(wrappedEvent.target) : _target;
 		}
-		public function set target(value:Object):void
+        override public function set target(value:Object):void
 		{
 			_target = value;
 		}
@@ -438,11 +438,11 @@ package org.apache.royale.events
          * @playerversion AIR 2.6
          * @productversion Royale 0.0
 		 */
-		public function get currentTarget():Object
+        override public function get currentTarget():Object
 		{
 			return wrappedEvent ? getTargetWrapper(wrappedEvent.currentTarget) : _target;
 		}
-		public function set currentTarget(value:Object):void
+        override public function set currentTarget(value:Object):void
 		{
 			_target = value;
 		}
@@ -575,11 +575,11 @@ package org.apache.royale.events
          * @playerversion AIR 2.6
          * @productversion Royale 0.0
 		 */
-		public function get defaultPrevented():Boolean
+        override public function get defaultPrevented():Boolean
 		{
 			return wrappedEvent ? wrappedEvent.defaultPrevented : _defaultPrevented;
 		}
-		public function set defaultPrevented(value:Boolean):void
+        override public function set defaultPrevented(value:Boolean):void
 		{
 			_defaultPrevented = value;
 		}
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/Legend.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/Legend.as
index a6640a3..7caa377 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/Legend.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/Legend.as
@@ -1320,6 +1320,7 @@ package mx.charts
          *  Note that this "base property" is final and cannot be overridden,
          *  so you can count on it to reflect what is happening at the player level.
          */
+        COMPILE::JS
         mx_internal final function get $numChildren():int
         {
             return super.numChildren;
@@ -4266,7 +4267,7 @@ package mx.charts
         /**
          *  @private
          */
-        /*override*/ mx_internal function addingChild(child:IUIComponent):void
+        override mx_internal function addingChild(child:IUIComponent):void
         {
             // Throw an RTE if child is not an IUIComponent.
             var uiChild:IUIComponent = IUIComponent(child);
@@ -4303,7 +4304,7 @@ package mx.charts
         /**
          *  @private
          */
-        /*override*/ mx_internal function childAdded(child:IUIComponent):void
+        override mx_internal function childAdded(child:IUIComponent):void
         {
             /*
             if (hasEventListener("childrenChanged"))
@@ -4328,7 +4329,7 @@ package mx.charts
         /**
          *  @private
          */
-        /*override*/ mx_internal function removingChild(child:IUIComponent):void
+        override mx_internal function removingChild(child:IUIComponent):void
         {
             /*
             super.removingChild(child);
@@ -4350,7 +4351,7 @@ package mx.charts
         /**
          *  @private
          */
-        /*override*/ mx_internal function childRemoved(child:IUIComponent):void
+        override mx_internal function childRemoved(child:IUIComponent):void
         {
             super.childRemoved(child);
             
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/ChartBase.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/ChartBase.as
index 2679f42..d4aea2d 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/ChartBase.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/chartClasses/ChartBase.as
@@ -2003,6 +2003,7 @@ public class ChartBase extends UIComponent implements IFocusManagerComponent
             cancelEffect();
         
         super.setActualSize(w, h);
+        updateDisplayList(w, h);
     }
 
     /**
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/AreaSet.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/AreaSet.as
index 94c7637..e9a6689 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/AreaSet.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/series/AreaSet.as
@@ -176,7 +176,7 @@ public class AreaSet extends StackedSeries
 
 		if (yName != "")
 			dt += "<i>" + yName + ":</i> ";
-		dt += vAxis..formatForScreen(Number(item.yValue) - Number(item.minValue)) + " (" +  percent + "%)\n";
+		dt += vAxis.formatForScreen(Number(item.yValue) - Number(item.minValue)) + " (" +  percent + "%)\n";
 		if (yName != "")
 			dt += "<i>" + yName + " (total):</i> ";
 		else
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/core/Application.as b/frameworks/projects/MXRoyale/src/main/royale/mx/core/Application.as
index 3fa3d06..49416df 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/core/Application.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/core/Application.as
@@ -567,16 +567,7 @@ public class Application extends Container implements IStrand, IParent, IEventDi
 	{
 		focusManager = new FocusManager(this);
 	}
-	
-	/**
-	 * @return {Object} The array of children.
-	 */
-	COMPILE::JS
-	protected function internalChildren():NodeList
-	{
-		return element.childNodes;
-	};
-	
+		
 	COMPILE::JS
 	protected var startupTimer:Timer;
 	
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/core/UIComponent.as b/frameworks/projects/MXRoyale/src/main/royale/mx/core/UIComponent.as
index beb598d..0b8c5d2 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/core/UIComponent.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/core/UIComponent.as
@@ -49,14 +49,21 @@ import mx.events.ResizeEvent;
 import mx.managers.ICursorManager;
 import mx.managers.IFocusManager;
 import mx.managers.IFocusManagerContainer;
+import mx.managers.ILayoutManagerClient;
 import mx.managers.ISystemManager;
 import mx.resources.IResourceManager;
 import mx.resources.ResourceManager;
+import mx.styles.ISimpleStyleClient;
+import mx.styles.IStyleClient;
 import mx.styles.IStyleManager2;
 import mx.styles.StyleManager;
 import mx.utils.StringUtil;
 
+import mx.core.mx_internal;
+use namespace mx_internal;
+
 import org.apache.royale.core.CallLaterBead;
+import org.apache.royale.core.IChild;
 import org.apache.royale.core.IStatesImpl;
 import org.apache.royale.core.IStatesObject;
 import org.apache.royale.core.IUIBase;
@@ -3043,11 +3050,13 @@ COMPILE::JS
     { override }
     public function addChild(child:IUIComponent):IUIComponent
     {
-        // this should probably call addingChild/childAdded
         return addElement(child) as IUIComponent;
     }
     
-    mx_internal function $addChild(child:IUIComponent):IUIComponent
+    [SWFOverride(params="flash.display.DisplayObject", altparams="mx.core.UIComponent", returns="flash.display.DisplayObject"))]
+    COMPILE::SWF 
+    { override }
+    public function $addChild(child:IUIComponent):IUIComponent
     {
         return addElement(child) as IUIComponent;
     }
@@ -3066,7 +3075,10 @@ COMPILE::JS
         return addElementAt(child, index) as IUIComponent;
     }
     
-    mx_internal function $addChildAt(child:IUIComponent,
+    [SWFOverride(params="flash.display.DisplayObject,int", altparams="mx.core.UIComponent,int", returns="flash.display.DisplayObject"))]
+    COMPILE::SWF 
+    { override }
+    public function $addChildAt(child:IUIComponent,
                                index:int):IUIComponent
     {
         return addElementAt(child, index) as IUIComponent;
@@ -3084,12 +3096,15 @@ COMPILE::JS
         return removeElement(child) as IUIComponent;
     }
     
-    mx_internal function $removeChild(child:IUIComponent):IUIComponent
+    [SWFOverride(params="flash.display.DisplayObject", altparams="mx.core.UIComponent", returns="flash.display.DisplayObject"))]
+    COMPILE::SWF 
+    { override }
+    public function $removeChild(child:IUIComponent):IUIComponent
     {
         // this should probably call the removingChild/childRemoved
         return removeElement(child) as IUIComponent;
     }
-
+    
     COMPILE::JS
 	public function swapChildren(child1:IUIComponent, child2:IUIComponent):void
 	{
@@ -3108,7 +3123,10 @@ COMPILE::JS
         return removeElement(getElementAt(index)) as IUIComponent;
     }
     
-    mx_internal function $removeChildAt(index:int):IUIComponent
+    [SWFOverride(returns="flash.display.DisplayObject"))]
+    COMPILE::SWF 
+    { override }
+    public function $removeChildAt(index:int):IUIComponent
     {
         return removeElement(getElementAt(index)) as IUIComponent;
     }
@@ -5100,6 +5118,171 @@ COMPILE::JS
         return textFormat;
     }
 
+    /**
+     *  @private
+     */
+    mx_internal function addingChild(child:IUIBase):void
+    {
+        // If the document property isn't already set on the child,
+        // set it to be the same as this component's document.
+        // The document setter will recursively set it on any
+        // descendants of the child that exist.
+        if (child is IUIComponent &&
+            !IUIComponent(child).component)
+        {
+            IUIComponent(child).component = component ?
+                component :
+                FlexGlobals.topLevelApplication;
+        }
+        
+        // Propagate moduleFactory to the child, but don't overwrite an existing moduleFactory.
+        if (child is IFlexModule && IFlexModule(child).moduleFactory == null)
+        {
+            if (moduleFactory != null)
+                IFlexModule(child).moduleFactory = moduleFactory;
+                
+            else if (component is IFlexModule && component.moduleFactory != null)
+                IFlexModule(child).moduleFactory = component.moduleFactory;
+                
+            else if (parent is IFlexModule && IFlexModule(parent).moduleFactory != null)
+                IFlexModule(child).moduleFactory = IFlexModule(parent).moduleFactory;
+        }
+        /*
+        
+        // Set the font context in non-UIComponent children.
+        // UIComponent children use moduleFactory.
+        if (child is IFontContextComponent && !(child is UIComponent) &&
+            IFontContextComponent(child).fontContext == null)
+            IFontContextComponent(child).fontContext = moduleFactory;
+        
+        if (child is IUIComponent)
+            IUIComponent(child).parentChanged(this);
+        
+        // Set the nestLevel of the child to be one greater
+        // than the nestLevel of this component.
+        // The nestLevel setter will recursively set it on any
+        // descendants of the child that exist.
+        if (child is ILayoutManagerClient)
+            ILayoutManagerClient(child).nestLevel = nestLevel + 1;
+        else if (child is IUITextField)
+            IUITextField(child).nestLevel = nestLevel + 1;
+        
+        if (child is InteractiveObject)
+            if (doubleClickEnabled)
+                InteractiveObject(child).doubleClickEnabled = true;
+        
+        // Sets up the inheritingStyles and nonInheritingStyles objects
+        // and their proto chains so that getStyle() works.
+        // If this object already has some children,
+        // then reinitialize the children's proto chains.
+        if (child is IStyleClient)
+            IStyleClient(child).regenerateStyleCache(true);
+        else if (child is IUITextField && IUITextField(child).inheritingStyles)
+            StyleProtoChain.initTextField(IUITextField(child));
+        
+        if (child is ISimpleStyleClient)
+            ISimpleStyleClient(child).styleChanged(null);
+        
+        if (child is IStyleClient)
+            IStyleClient(child).notifyStyleChangeInChildren(null, true);
+        
+        if (child is UIComponent)
+            UIComponent(child).initThemeColor();
+        
+        // Inform the component that it's style properties
+        // have been fully initialized. Most components won't care,
+        // but some need to react to even this early change.
+        if (child is UIComponent)
+            UIComponent(child).stylesInitialized();
+        */
+    }
+    
+    /**
+     *  @private
+     */
+    mx_internal function childAdded(child:IUIBase):void
+    {
+        /*
+        if (!UIComponentGlobals.designMode)
+        {
+            if (child is UIComponent)
+            {
+                if (!UIComponent(child).initialized)
+                    UIComponent(child).initialize();
+            }
+            else if (child is IUIComponent)
+            {
+                IUIComponent(child).initialize();
+            }
+        }
+        else
+        {
+            try
+            {
+                if (child is UIComponent)
+                {
+                    if (!UIComponent(child).initialized)
+                        UIComponent(child).initialize();
+                }
+                else if (child is IUIComponent)
+                {
+                    IUIComponent(child).initialize();
+                }               
+            }
+            catch (e:Error)
+            {
+                // Dispatch a initializeError dynamic event for tooling. 
+                var initializeErrorEvent:DynamicEvent = new DynamicEvent("initializeError");
+                initializeErrorEvent.error = e;
+                initializeErrorEvent.source = child; 
+                systemManager.dispatchEvent(initializeErrorEvent);
+            }
+        }
+        */
+    }
+    
+    /**
+     *  @private
+     */
+    mx_internal function removingChild(child:IUIBase):void
+    {
+    }
+    
+    /**
+     *  @private
+     */
+    mx_internal function childRemoved(child:IUIBase):void
+    {
+        if (child is IUIComponent)
+        {
+            // only reset document if the child isn't
+            // a document itself
+            if (IUIComponent(child).component != child)
+                IUIComponent(child).component = null;
+            //IUIComponent(child).parentChanged(null);
+        }
+    }
+    
+    override public function addElement(c:IChild, dispatchEvent:Boolean=true):void
+    {
+        addingChild(c as IUIBase);
+        super.addElement(c, dispatchEvent);
+        childAdded(c as IUIBase);
+    }
+
+    override public function addElementAt(c:IChild, index:int, dispatchEvent:Boolean=true):void
+    {
+        addingChild(c as IUIBase);
+        super.addElementAt(c, index, dispatchEvent);
+        childAdded(c as IUIBase);
+    }
+    
+    override public function removeElement(c:IChild, dispatchEvent:Boolean=true):void
+    {
+        removingChild(c as IUIBase);
+        super.removeElement(c, dispatchEvent);
+        childRemoved(c as IUIBase);
+    }
 }
 
 }
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/display/Graphics.as b/frameworks/projects/MXRoyale/src/main/royale/mx/display/Graphics.as
index ab98436..6d1886d 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/display/Graphics.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/display/Graphics.as
@@ -18,11 +18,11 @@
 
 package mx.display
 {
-	import org.apache.royale.svg.CompoundGraphic;
+	//import org.apache.royale.svg.CompoundGraphic;
 	import mx.geom.Matrix;
     import mx.core.UIComponent;
 
-	public class Graphics extends org.apache.royale.svg.CompoundGraphic
+	public class Graphics// extends org.apache.royale.svg.CompoundGraphic
 	{
 		private var displayObject:UIComponent;
 
@@ -32,6 +32,10 @@ package mx.display
 			this.displayObject = displayObject;
 		}
 
+        public function clear():void
+        {
+        }
+        
 		public function endFill(): void
 		{
 		}
@@ -58,6 +62,23 @@ package mx.display
 		public function curveTo(controlX:Number, controlY:Number, anchorX:Number, anchorY:Number):void
 		{
 		}
+        
+        public function drawEllipse(x:Number, y:Number, width:Number, height:Number):void
+        {
+        }
+        
+        public function drawRoundRect(x:Number, y:Number, width:Number, height:Number, radiusX:Number, radiusY:Number = NaN):void
+        {
+        }
+        
+        public function drawRect(x:Number, y:Number, width:Number, height:Number):void
+        {
+        }
+        
+        public function drawCircle(x:Number, y:Number, radius:Number):void
+        {
+        }
+
 	}
 	
 }
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/managers/SystemManager.as b/frameworks/projects/MXRoyale/src/main/royale/mx/managers/SystemManager.as
index 9fe17c6..59ce4e3 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/managers/SystemManager.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/managers/SystemManager.as
@@ -63,7 +63,6 @@ import flash.utils.getQualifiedClassName;
 import mx.core.FlexSprite;
 import mx.core.IChildList;
 import mx.core.IFlexDisplayObject;
-import mx.core.IFlexModuleFactory;
 import mx.core.IInvalidating;
 import mx.core.IRawChildrenContainer;
 import mx.core.IUIComponent;
@@ -89,6 +88,7 @@ use namespace mx_internal;
 
 import mx.core.IChildList;
 import mx.core.IFlexDisplayObject;
+import mx.core.IFlexModuleFactory;
 import mx.core.IUIComponent;
 
 import org.apache.royale.core.IChild;
@@ -191,7 +191,7 @@ import org.apache.royale.geom.Rectangle;
  *  @playerversion AIR 1.1
  *  @productversion Royale 0.9.4
  */
-public class SystemManager extends SystemManagerBase implements ISystemManager, IEventDispatcher, IPopUpHostParent, IChildList
+public class SystemManager extends SystemManagerBase implements ISystemManager, IFlexModuleFactory, IEventDispatcher, IPopUpHostParent, IChildList
 { //extends MovieClip implements IFlexDisplayObject,IFlexModuleFactory, ISystemManager
    // include "../core/Version.as";
 
@@ -2975,6 +2975,7 @@ public class SystemManager extends SystemManagerBase implements ISystemManager,
         
         // until preloader?
         component.addEventListener("applicationComplete", applicationCompleteHandler);
+        component.moduleFactory = this;
         addChild(component as IUIComponent);
         var screen:Rectangle = this.screen;
         component.setActualSize(screen.width, screen.height);            
diff --git a/frameworks/projects/RoyaleSite/src/main/royale/org/apache/royale/site/TitledAnchorList.as b/frameworks/projects/RoyaleSite/src/main/royale/org/apache/royale/site/TitledAnchorList.as
index d7cf0ed..c59d9b2 100644
--- a/frameworks/projects/RoyaleSite/src/main/royale/org/apache/royale/site/TitledAnchorList.as
+++ b/frameworks/projects/RoyaleSite/src/main/royale/org/apache/royale/site/TitledAnchorList.as
@@ -114,7 +114,7 @@ package org.apache.royale.site
          * @royaleignorecoercion HTMLLIElement
          */
         COMPILE::JS
-		protected function addedToParent():void
+		override public function addedToParent():void
 		{
 			super.addedToParent();
             var li:HTMLLIElement = document.createElement("li") as HTMLLIElement;
diff --git a/frameworks/projects/SparkRoyale/src/main/royale/spark/components/Group.as b/frameworks/projects/SparkRoyale/src/main/royale/spark/components/Group.as
index b23f002..4e2250c 100644
--- a/frameworks/projects/SparkRoyale/src/main/royale/spark/components/Group.as
+++ b/frameworks/projects/SparkRoyale/src/main/royale/spark/components/Group.as
@@ -456,10 +456,9 @@ public class Group extends GroupBase /*implements IVisualElementContainer,
      *  @playerversion Flash 10
      *  @playerversion AIR 1.5
      *  @productversion Flex 4
-     */
     public function set mxmlContent(value:Array):void
     {
-        /*if (createChildrenCalled)
+        if (createChildrenCalled)
         {
             setMXMLContent(value);
         }
@@ -468,8 +467,10 @@ public class Group extends GroupBase /*implements IVisualElementContainer,
             mxmlContentChanged = true;
             _mxmlContent = value;
             // we will validate this in createChildren();
-        }*/
+        }
     }
+     */
+    
     /**
      *  @private
      */


[royale-asjs] 06/10: don't instantiate the view if not parented so the view can see all properties have been set when it gets created. Otherwise, layout may not be set

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

aharui pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git

commit 835bd93479296f619ea63532c22a545ac13a2984
Author: Alex Harui <ah...@apache.org>
AuthorDate: Fri Oct 26 19:05:47 2018 -0700

    don't instantiate the view if not parented so the view can see all properties have been set when it gets created.  Otherwise, layout may not be set
---
 .../src/main/royale/mx/containers/Panel.as         | 101 ++++++++++++++++-----
 .../main/royale/mx/containers/beads/PanelView.as   |  25 ++++-
 .../mx/containers/beads/models/PanelModel.as       |   8 +-
 3 files changed, 106 insertions(+), 28 deletions(-)

diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/containers/Panel.as b/frameworks/projects/MXRoyale/src/main/royale/mx/containers/Panel.as
index 657ef72..8d46db7 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/containers/Panel.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/containers/Panel.as
@@ -773,13 +773,23 @@ public class Panel extends Container
         var contentView:UIComponent = panelView.contentArea as UIComponent;
         return contentView.paddingLeft;
     }
+    
+    /**
+     * @royaleignorecoercion mx.core.UIComponent 
+     * @royaleignorecoercion String
+     * @royaleignorecoercion mx.containers.beads.models.PanelModel 
+     */
     override public function set paddingLeft(value:Object):void
     {
         if (typeof(value) !== "string")
             value = value.toString() + "px";
-        var panelView:PanelView = view as PanelView;
-        var contentView:UIComponent = panelView.contentArea as UIComponent;
-        contentView.paddingLeft = value;
+        (model as PanelModel).paddingLeft = value as String;
+        if (parent)
+        {
+            var panelView:PanelView = view as PanelView;
+            var contentView:UIComponent = panelView.contentArea as UIComponent;
+            contentView.paddingLeft = value;
+        }
     }
     override public function get paddingRight():Object
     {
@@ -787,13 +797,23 @@ public class Panel extends Container
         var contentView:UIComponent = panelView.contentArea as UIComponent;
         return contentView.paddingRight;
     }
+    
+    /**
+     * @royaleignorecoercion mx.core.UIComponent 
+     * @royaleignorecoercion String
+     * @royaleignorecoercion mx.containers.beads.models.PanelModel 
+     */
     override public function set paddingRight(value:Object):void
     {
         if (typeof(value) !== "string")
             value = value.toString() + "px";
-        var panelView:PanelView = view as PanelView;
-        var contentView:UIComponent = panelView.contentArea as UIComponent;
-        contentView.paddingRight = value;
+        (model as PanelModel).paddingRight = value as String;
+        if (parent)
+        {
+            var panelView:PanelView = view as PanelView;
+            var contentView:UIComponent = panelView.contentArea as UIComponent;
+            contentView.paddingRight = value;
+        }
     }
     override public function get paddingTop():Object
     {
@@ -801,13 +821,23 @@ public class Panel extends Container
         var contentView:UIComponent = panelView.contentArea as UIComponent;
         return contentView.paddingTop;
     }
+    
+    /**
+     * @royaleignorecoercion mx.core.UIComponent 
+     * @royaleignorecoercion String
+     * @royaleignorecoercion mx.containers.beads.models.PanelModel 
+     */
     override public function set paddingTop(value:Object):void
     {
         if (typeof(value) !== "string")
             value = value.toString() + "px";
-        var panelView:PanelView = view as PanelView;
-        var contentView:UIComponent = panelView.contentArea as UIComponent;
-        contentView.paddingTop = value;
+        (model as PanelModel).paddingTop = value as String;
+        if (parent)
+        {
+            var panelView:PanelView = view as PanelView;
+            var contentView:UIComponent = panelView.contentArea as UIComponent;
+            contentView.paddingTop = value;
+        }
     }
     override public function get paddingBottom():Object
     {
@@ -815,13 +845,24 @@ public class Panel extends Container
         var contentView:UIComponent = panelView.contentArea as UIComponent;
         return contentView.paddingBottom;
     }
+    
+    /**
+     * @royaleignorecoercion mx.core.UIComponent 
+     * @royaleignorecoercion String
+     * @royaleignorecoercion mx.containers.beads.models.PanelModel 
+     */
     override public function set paddingBottom(value:Object):void
     {
+        
         if (typeof(value) !== "string")
             value = value.toString() + "px";
-        var panelView:PanelView = view as PanelView;
-        var contentView:UIComponent = panelView.contentArea as UIComponent;
-        contentView.paddingBottom = value;
+        (model as PanelModel).paddingBottom = value as String;
+        if (parent)
+        {
+            var panelView:PanelView = view as PanelView;
+            var contentView:UIComponent = panelView.contentArea as UIComponent;
+            contentView.paddingBottom = value;
+        }
     }
     
     // because padding creates the view early, the setuplayout logic
@@ -830,30 +871,42 @@ public class Panel extends Container
     override public function set percentWidth(value:Number):void
     {
         super.percentWidth = value;
-        var panelView:PanelView = view as PanelView;
-        var contentView:UIComponent = panelView.contentArea as UIComponent;
-        contentView.percentWidth = 100;
+        if (parent)
+        {
+            var panelView:PanelView = view as PanelView;
+            var contentView:UIComponent = panelView.contentArea as UIComponent;
+            contentView.percentWidth = 100;
+        }
     }
     override public function set explicitWidth(value:Number):void
     {
         super.explicitWidth = value;
-        var panelView:PanelView = view as PanelView;
-        var contentView:UIComponent = panelView.contentArea as UIComponent;
-        contentView.percentWidth = 100;
+        if (parent)
+        {
+            var panelView:PanelView = view as PanelView;
+            var contentView:UIComponent = panelView.contentArea as UIComponent;
+            contentView.percentWidth = 100;
+        }
     }
     override public function set percentHeight(value:Number):void
     {
         super.percentHeight = value;
-        var panelView:PanelView = view as PanelView;
-        var contentView:UIComponent = panelView.contentArea as UIComponent;
-        contentView.percentHeight = 100;
+        if (parent)
+        {
+            var panelView:PanelView = view as PanelView;
+            var contentView:UIComponent = panelView.contentArea as UIComponent;
+            contentView.percentHeight = 100;
+        }
     }
     override public function set explicitHeight(value:Number):void
     {
         super.explicitHeight = value;
-        var panelView:PanelView = view as PanelView;
-        var contentView:UIComponent = panelView.contentArea as UIComponent;
-        contentView.percentHeight = 100;
+        if (parent)
+        {
+            var panelView:PanelView = view as PanelView;
+            var contentView:UIComponent = panelView.contentArea as UIComponent;
+            contentView.percentHeight = 100;
+        }
     }
     
 
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/containers/beads/PanelView.as b/frameworks/projects/MXRoyale/src/main/royale/mx/containers/beads/PanelView.as
index 5d169a2..7b7aff3 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/containers/beads/PanelView.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/containers/beads/PanelView.as
@@ -27,6 +27,7 @@ import mx.containers.beads.BoxLayout;
 import mx.containers.beads.CanvasLayout;
 import mx.containers.beads.models.PanelModel;
 import mx.core.ContainerLayout;
+import mx.core.UIComponent;
 
 import org.apache.royale.core.IBead;
 import org.apache.royale.core.ILayoutChild;
@@ -61,8 +62,6 @@ public class PanelView extends org.apache.royale.html.beads.PanelView
 	}
 
     /**
-     * @royaleignorecoercion org.apache.royale.core.UIBase; 
-     * @royaleignorecoercion mx.containers.beads.models.PanelModel; 
      */
     override public function set strand(value:IStrand):void
     {
@@ -70,10 +69,30 @@ public class PanelView extends org.apache.royale.html.beads.PanelView
         super.strand = value;
     }
     
+    /**
+     * @royaleignorecoercion mx.core.UIComponent 
+     * @royaleignorecoercion org.apache.royale.core.UIBase
+     * @royaleignorecoercion mx.containers.beads.models.PanelModel 
+     */
     override protected function setupContentAreaLayout():void
     {
-        var model:PanelModel = (_strand as UIBase).model as PanelModel;
+        var host:UIBase = _strand as UIBase;
+        var model:PanelModel = host.model as PanelModel;
         var _layout:String = model.layout;
+        if (model.paddingBottom)
+            (contentArea as UIComponent).paddingBottom = model.paddingBottom;
+        if (model.paddingTop)
+            (contentArea as UIComponent).paddingTop = model.paddingTop;
+        if (model.paddingLeft)
+            (contentArea as UIComponent).paddingLeft = model.paddingLeft;
+        if (model.paddingRight)
+            (contentArea as UIComponent).paddingRight = model.paddingRight;
+        
+        if (!host.isWidthSizedToContent())
+            contentArea.percentWidth = 100;
+        if (!host.isHeightSizedToContent())
+            contentArea.percentHeight = 100;
+            
         var layoutObject:IBead;
         if (_layout == ContainerLayout.ABSOLUTE)
             layoutObject = new CanvasLayout();
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/containers/beads/models/PanelModel.as b/frameworks/projects/MXRoyale/src/main/royale/mx/containers/beads/models/PanelModel.as
index 0e6fb89..7561a62 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/containers/beads/models/PanelModel.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/containers/beads/models/PanelModel.as
@@ -20,9 +20,10 @@
 package mx.containers.beads.models
 {
 
-import org.apache.royale.html.beads.models.PanelModel;
 import mx.core.ContainerLayout;
 
+import org.apache.royale.html.beads.models.PanelModel;
+
 /**
  *  @private
  *  The PanelModel for emulation.
@@ -61,6 +62,11 @@ public class PanelModel extends org.apache.royale.html.beads.models.PanelModel
         _layout = value;
     }
 
+    public var paddingBottom:String;
+    public var paddingTop:String;
+    public var paddingLeft:String;
+    public var paddingRight:String;
+    
 }
 
 }


[royale-asjs] 01/10: clean compile of charts

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

aharui pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git

commit 13ca9f0703bd5b4cfbc8d8cd17693d1c6757ecf6
Author: Alex Harui <ah...@apache.org>
AuthorDate: Wed Oct 24 12:50:55 2018 -0700

    clean compile of charts
---
 .../royale/org/apache/royale/graphics/IStroke.as   |    7 +-
 .../org/apache/royale/graphics/SolidColorStroke.as |    4 +-
 .../src/main/resources/mx-royale-manifest.xml      |   70 +-
 .../src/main/royale/mx/charts/AreaChart.as         |  557 +-
 .../src/main/royale/mx/charts/AxisLabel.as         |  135 +
 .../src/main/royale/mx/charts/AxisRenderer.as      | 3964 ++++++++++++
 .../MXRoyale/src/main/royale/mx/charts/BarChart.as |  916 ++-
 .../src/main/royale/mx/charts/BubbleChart.as       |  322 +
 .../src/main/royale/mx/charts/CandlestickChart.as  |  322 +
 .../src/main/royale/mx/charts/CategoryAxis.as      |  808 ++-
 .../src/main/royale/mx/charts/ChartItem.as         |  191 +-
 .../src/main/royale/mx/charts/ColumnChart.as       | 1263 +++-
 .../src/main/royale/mx/charts/DateTimeAxis.as      | 2541 ++++++++
 .../src/main/royale/mx/charts/GridLines.as         |  674 ++
 .../src/main/royale/mx/charts/HLOCChart.as         |  321 +
 .../MXRoyale/src/main/royale/mx/charts/HitData.as  |  444 +-
 .../MXRoyale/src/main/royale/mx/charts/Legend.as   | 6650 +++++++++++++++++++-
 .../src/main/royale/mx/charts/LegendItem.as        |  681 ++
 .../src/main/royale/mx/charts/LineChart.as         |  219 +-
 .../src/main/royale/mx/charts/LinearAxis.as        |  701 ++-
 .../MXRoyale/src/main/royale/mx/charts/LogAxis.as  |  606 ++
 .../MXRoyale/src/main/royale/mx/charts/PieChart.as |  275 +-
 .../src/main/royale/mx/charts/PlotChart.as         |  349 +-
 .../main/royale/mx/charts/chartClasses/AxisBase.as |  341 +
 .../AxisLabelSet.as}                               |   77 +-
 .../royale/mx/charts/chartClasses/BoundedValue.as  |  134 +
 .../mx/charts/chartClasses/CartesianCanvasValue.as |  126 +
 .../mx/charts/chartClasses/CartesianChart.as       | 2032 ++++++
 .../mx/charts/chartClasses/CartesianDataCanvas.as  | 2030 ++++++
 .../mx/charts/chartClasses/CartesianTransform.as   |  184 +-
 .../royale/mx/charts/chartClasses/ChartBase.as     | 5532 +++++++++++++++-
 .../royale/mx/charts/chartClasses/ChartElement.as  |  663 ++
 .../mx/charts/chartClasses/ChartItemDragProxy.as   |  129 +
 .../royale/mx/charts/chartClasses/ChartLabel.as    |  340 +
 .../royale/mx/charts/chartClasses/ChartState.as    |   97 +
 .../mx/charts/chartClasses/DataDescription.as      |  208 +
 .../main/royale/mx/charts/chartClasses/DataTip.as  |  678 +-
 .../royale/mx/charts/chartClasses/DataTransform.as |  247 +-
 .../mx/charts/chartClasses/DateRangeUtilities.as   |  575 ++
 .../mx/charts/chartClasses/DualStyleObject.as      |  284 +
 .../mx/charts/chartClasses/GraphicsUtilities.as    | 1286 ++--
 .../mx/charts/chartClasses/HLOCSeriesBase.as       | 1467 +++++
 .../main/royale/mx/charts/chartClasses/IAxis.as    |  797 ++-
 .../royale/mx/charts/chartClasses/IAxisRenderer.as |  266 +
 .../src/main/royale/mx/charts/chartClasses/IBar.as |  105 +
 .../royale/mx/charts/chartClasses/IChartElement.as |  257 +
 .../mx/charts/chartClasses/IChartElement2.as       |  107 +
 .../main/royale/mx/charts/chartClasses/IColumn.as  |  111 +
 .../royale/mx/charts/chartClasses/IDataCanvas.as   |  140 +
 .../royale/mx/charts/chartClasses/IStackable.as    |  115 +
 .../royale/mx/charts/chartClasses/IStackable2.as   |   78 +
 .../royale/mx/charts/chartClasses/InstanceCache.as |  541 ++
 .../royale/mx/charts/chartClasses/LegendData.as    |  137 +
 .../royale/mx/charts/chartClasses/NumericAxis.as   | 1423 +++++
 .../royale/mx/charts/chartClasses/PolarChart.as    |  650 ++
 .../mx/charts/chartClasses/PolarDataCanvas.as      | 1948 ++++++
 .../mx/charts/chartClasses/PolarTransform.as       |  253 +
 .../royale/mx/charts/chartClasses/RenderData.as    |  141 +-
 .../main/royale/mx/charts/chartClasses/Series.as   |  886 ++-
 .../royale/mx/charts/chartClasses/StackedSeries.as |  932 +++
 .../main/royale/mx/charts/effects/SeriesEffect.as  |  229 +
 .../SeriesInterpolate.as}                          |   66 +-
 .../main/royale/mx/charts/effects/SeriesSlide.as   |  134 +
 .../main/royale/mx/charts/effects/SeriesZoom.as    |  207 +
 .../effects/effectClasses/SeriesEffectInstance.as  |  435 ++
 .../effectClasses/SeriesInterpolateInstance.as     |  154 +
 .../effects/effectClasses/SeriesSlideInstance.as   |  339 +
 .../effects/effectClasses/SeriesZoomInstance.as    |  875 +++
 .../src/main/royale/mx/charts/events/ChartEvent.as |  154 +
 .../main/royale/mx/charts/events/ChartItemEvent.as |  164 +-
 .../royale/mx/charts/events/LegendMouseEvent.as    |  239 +
 .../royale/mx/charts/renderers/AreaRenderer.as     |  202 +
 .../royale/mx/charts/renderers/BoxItemRenderer.as  |  196 +
 .../mx/charts/renderers/CandlestickItemRenderer.as |  252 +
 .../mx/charts/renderers/CircleItemRenderer.as      |  207 +
 .../mx/charts/renderers/CrossItemRenderer.as       |  244 +
 .../mx/charts/renderers/DiamondItemRenderer.as     |  212 +
 .../royale/mx/charts/renderers/HLOCItemRenderer.as |  359 ++
 .../royale/mx/charts/renderers/LineRenderer.as     |  132 +
 .../mx/charts/renderers/ShadowBoxItemRenderer.as   |  224 +
 .../mx/charts/renderers/ShadowLineRenderer.as      |   95 +-
 .../mx/charts/renderers/TriangleItemRenderer.as    |  213 +
 .../mx/charts/renderers/WedgeItemRenderer.as       |  245 +
 .../src/main/royale/mx/charts/series/AreaSeries.as | 2085 +++++-
 .../src/main/royale/mx/charts/series/AreaSet.as    |  190 +
 .../src/main/royale/mx/charts/series/BarSeries.as  | 2512 +++++++-
 .../src/main/royale/mx/charts/series/BarSet.as     |  525 ++
 .../main/royale/mx/charts/series/BubbleSeries.as   | 1541 +++++
 .../royale/mx/charts/series/CandlestickSeries.as   |  556 ++
 .../main/royale/mx/charts/series/ColumnSeries.as   | 2568 +++++++-
 .../src/main/royale/mx/charts/series/ColumnSet.as  |  450 ++
 .../src/main/royale/mx/charts/series/HLOCSeries.as |  422 ++
 .../src/main/royale/mx/charts/series/LineSeries.as | 4352 +++++++------
 .../src/main/royale/mx/charts/series/PieSeries.as  | 4071 +++++++++---
 .../src/main/royale/mx/charts/series/PlotSeries.as | 1478 ++++-
 .../mx/charts/series/items/AreaSeriesItem.as       |  300 +
 .../royale/mx/charts/series/items/BarSeriesItem.as |  330 +
 .../mx/charts/series/items/BubbleSeriesItem.as     |  293 +
 .../mx/charts/series/items/ColumnSeriesItem.as     |  231 +-
 .../mx/charts/series/items/HLOCSeriesItem.as       |  422 ++
 .../mx/charts/series/items/LineSeriesItem.as       |  231 +
 .../mx/charts/series/items/LineSeriesSegment.as    |  191 +
 .../royale/mx/charts/series/items/PieSeriesItem.as |  623 +-
 .../mx/charts/series/items/PlotSeriesItem.as       |  247 +
 .../renderData/AreaSeriesRenderData.as}            |  310 +-
 .../series/renderData/BarSeriesRenderData.as       |  179 +
 .../renderData/BubbleSeriesRenderData.as}          |   63 +-
 .../series/renderData/ColumnSeriesRenderData.as    |  179 +
 .../series/renderData/HLOCSeriesRenderData.as      |  121 +
 .../series/renderData/LineSeriesRenderData.as      |  148 +
 .../series/renderData/PieSeriesRenderData.as       |  131 +
 .../series/renderData/PlotSeriesRenderData.as      |  101 +
 .../halo/SelectionSkin.as}                         |   73 +-
 .../main/royale/mx/charts/styles/HaloDefaults.as   |  251 +
 .../styles/metadata/FillStrokeStyles.as}           |   33 +-
 .../styles/metadata/GapStyles.as}                  |   33 +-
 .../charts/styles/metadata/ItemRendererStyles.as   |   43 +
 .../styles/metadata/LeadingStyle.as}               |   63 +-
 .../styles/metadata/MarginStyles.as}               |   33 +-
 .../royale/mx/charts/styles/metadata/TextStyles.as |  280 +
 .../src/main/royale/mx/core/ClassFactory.as        |    2 +-
 .../IProgrammaticSkin.as}                          |   42 +-
 .../src/main/royale/mx/core/ITextFieldFactory.as   |   71 +
 .../src/main/royale/mx/core/IUIComponent.as        |    4 +
 .../src/main/royale/mx/core/IUITextField.as        |  168 +
 .../src/main/royale/mx/core/UIComponent.as         |  195 +-
 .../src/main/royale/mx/core/UITextField.as         |    4 +-
 .../src/main/royale/mx/core/UITextFormat.as        |  594 ++
 .../src/main/royale/mx/display/Graphics.as         |   13 +-
 .../MXRoyale/src/main/royale/mx/effects/Effect.as  |    4 +
 .../src/main/royale/mx/effects/EffectInstance.as   |   62 +-
 .../mx/effects/effectClasses/ParallelInstance.as   |  609 ++
 .../effects/effectClasses/TweenEffectInstance.as   |   11 +-
 .../src/main/royale/mx/events/FlexEvent.as         |    2 +-
 .../src/main/royale/mx/events/TweenEvent.as        |  230 +
 .../MXRoyale/src/main/royale/mx/graphics/IFill.as  |   41 +-
 .../src/main/royale/mx/graphics/IStroke.as         |   28 +-
 .../src/main/royale/mx/graphics/LinearGradient.as  |   26 +-
 .../src/main/royale/mx/graphics/SolidColor.as      |   29 +-
 .../main/royale/mx/graphics/SolidColorStroke.as    |   46 +-
 .../MXRoyale/src/main/royale/mx/graphics/Stroke.as |   36 +-
 .../src/main/royale/mx/skins/ProgrammaticSkin.as   |   19 +-
 .../main/royale/mx/styles/CSSStyleDeclaration.as   |   74 +
 .../main/royale/mx/styles/ISimpleStyleClient.as    |    6 +-
 .../src/main/royale/mx/styles/IStyleManager.as     |  565 ++
 .../src/main/royale/mx/styles/IStyleManager2.as    |    2 +-
 .../MXRoyale/src/main/royale/mx/text/TextFormat.as |   66 +
 147 files changed, 74658 insertions(+), 6864 deletions(-)

diff --git a/frameworks/projects/Graphics/src/main/royale/org/apache/royale/graphics/IStroke.as b/frameworks/projects/Graphics/src/main/royale/org/apache/royale/graphics/IStroke.as
index 11bb0d7..12af675 100644
--- a/frameworks/projects/Graphics/src/main/royale/org/apache/royale/graphics/IStroke.as
+++ b/frameworks/projects/Graphics/src/main/royale/org/apache/royale/graphics/IStroke.as
@@ -18,6 +18,9 @@
 
 package org.apache.royale.graphics
 {
+    import org.apache.royale.geom.Point;
+    import org.apache.royale.geom.Rectangle;
+
     COMPILE::SWF
     {
         import flash.display.Graphics;
@@ -25,10 +28,12 @@ package org.apache.royale.graphics
     public interface IStroke
     {
         COMPILE::SWF
-        function apply(s:Graphics):void;
+        function apply(s:Graphics, targetBounds:Rectangle = null, targetOrigin:Point = null):void;
         
         COMPILE::JS
         function get weight():Number;
+        COMPILE::JS
+        function set weight(value:Number):void;
         
         COMPILE::JS
         function addStrokeAttrib(s:IGraphicShape):String;
diff --git a/frameworks/projects/Graphics/src/main/royale/org/apache/royale/graphics/SolidColorStroke.as b/frameworks/projects/Graphics/src/main/royale/org/apache/royale/graphics/SolidColorStroke.as
index 8ed5636..8099355 100644
--- a/frameworks/projects/Graphics/src/main/royale/org/apache/royale/graphics/SolidColorStroke.as
+++ b/frameworks/projects/Graphics/src/main/royale/org/apache/royale/graphics/SolidColorStroke.as
@@ -18,6 +18,8 @@
 
 package org.apache.royale.graphics
 {
+    import org.apache.royale.geom.Point;
+    import org.apache.royale.geom.Rectangle;
     import org.apache.royale.utils.CSSUtils;
 
     COMPILE::SWF
@@ -128,7 +130,7 @@ package org.apache.royale.graphics
         }
         
         COMPILE::SWF
-        public function apply(g:Graphics):void
+        public function apply(g:Graphics, targetBounds:Rectangle = null, targetOrigin:Point = null):void
         {
             g.lineStyle(weight,color,alpha,false,"normal",CapsStyle.SQUARE,JointStyle.MITER);
         }
diff --git a/frameworks/projects/MXRoyale/src/main/resources/mx-royale-manifest.xml b/frameworks/projects/MXRoyale/src/main/resources/mx-royale-manifest.xml
index 0b0b659..60fe196 100644
--- a/frameworks/projects/MXRoyale/src/main/resources/mx-royale-manifest.xml
+++ b/frameworks/projects/MXRoyale/src/main/resources/mx-royale-manifest.xml
@@ -68,10 +68,6 @@
 	<component id="ModuleLoader" class="mx.modules.ModuleLoader"/>
 	<component id="State" class="mx.states.State" />
     <component id="Transition" class="mx.states.Transition" />
-  <component id="PlotChart" class="mx.charts.PlotChart" />
-	<component id="PieSeries" class="mx.charts.series.PieSeries" />
-	<component id="PlotSeries" class="mx.charts.series.PlotSeries" />
-	<component id="AreaChart" class="mx.charts.AreaChart" />
 	<component id="ListItemRenderer" class="mx.controls.listClasses.ListItemRenderer" />
 	<component id="ArrayList" class="mx.collections.ArrayList"/>
 	<component id="UIComponent" class="mx.core.UIComponent"/>
@@ -91,10 +87,6 @@
 	<component id="VRule" class="mx.controls.VRule"/>
 	<component id="HRule" class="mx.controls.HRule"/>
 	<component id="Sequence" class="mx.effects.Sequence"/>
-	<component id="LineChart" class="mx.charts.LineChart" />
-	<component id="PieChart" class="mx.charts.PieChart" />
-	<component id="BarChart" class="mx.charts.BarChart" />
-	<component id="ColumnChart" class="mx.charts.ColumnChart" />
 	<component id="Resize" class="mx.effects.Resize"/>
 	<component id="Move" class="mx.effects.Move"/>
 	<component id="LinearGradient" class="mx.graphics.LinearGradient"/>
@@ -106,15 +98,8 @@
     <component id="Form" class="mx.containers.Form" />
 	<component id="FormHeading" class="mx.containers.FormHeading"/>
     <component id="FormItem" class="mx.containers.FormItem" />
-	<component id="BarSeries" class="mx.charts.series.BarSeries" />
 	<component id="XMLListCollection" class="mx.collections.XMLListCollection"/>
 	<component id="TreeItemRenderer" class="mx.controls.treeClasses.TreeItemRenderer" />
-	<component id="ColumnSeries" class="mx.charts.series.ColumnSeries" />
-	<component id="CategoryAxis" class="mx.charts.CategoryAxis" />
-	<component id="LinearAxis" class="mx.charts.LinearAxis" />
-	<component id="ShadowLineRenderer" class="mx.charts.renderers.ShadowLineRenderer" />
-	<component id="Legend" class="mx.charts.Legend" />
-	<component id="AreaSeries" class="mx.charts.series.AreaSeries" />
 	<component id="ToggleButtonBar" class="mx.controls.ToggleButtonBar"/>
 	<component id="DragManager" class="mx.managers.DragManager" />
 	<component id="TraceTarget" class="mx.logging.targets.TraceTarget"/>
@@ -140,7 +125,6 @@
 	<component id="GridRow" class="mx.containers.GridRow"/>
 	<component id="Parallel" class="mx.effects.Parallel"/>
 	<component id="AdvancedDataGridItemRenderer" class="mx.controls.advancedDataGridClasses.AdvancedDataGridItemRenderer" />
-	<component id="LineSeries" class="mx.charts.series.LineSeries" />
 	<component id="Tree" class="mx.controls.Tree"/>
     
 	<component id="AMFChannel" class="mx.messaging.channels.AMFChannel" />
@@ -164,4 +148,58 @@
     <component id="WipeDown" class="mx.effects.WipeDown" />
     <component id="Pause" class="mx.effects.Pause" />
 
+    <!-- charts -->
+    <component id="AxisRenderer" class="mx.charts.AxisRenderer"/>
+    <component id="BarChart" class="mx.charts.BarChart"/>
+    <component id="BubbleChart" class="mx.charts.BubbleChart"/>
+    <component id="CategoryAxis" class="mx.charts.CategoryAxis"/>
+    <component id="ColumnChart" class="mx.charts.ColumnChart"/>
+    <component id="CandlestickChart" class="mx.charts.CandlestickChart"/>
+    <component id="DataTip" class="mx.charts.chartClasses.DataTip"/>
+    <component id="HLOCChart" class="mx.charts.HLOCChart"/>
+    <component id="AreaChart" class="mx.charts.AreaChart"/>
+    <component id="GridLines" class="mx.charts.GridLines"/>
+    <component id="Legend" class="mx.charts.Legend"/>
+    <component id="LegendItem" class="mx.charts.LegendItem"/>
+    <component id="LineChart" class="mx.charts.LineChart"/>
+    <component id="LinearAxis" class="mx.charts.LinearAxis"/>
+    <component id="LogAxis" class="mx.charts.LogAxis"/>
+    <component id="DateTimeAxis" class="mx.charts.DateTimeAxis"/>
+    <component id="PieChart" class="mx.charts.PieChart"/>
+    <component id="PlotChart" class="mx.charts.PlotChart"/>
+    <component id="PolarChart" class="mx.charts.chartClasses.PolarChart"/>
+    <component id="CartesianChart" class="mx.charts.chartClasses.CartesianChart"/>
+    <component id="ChartBase" class="mx.charts.chartClasses.ChartBase"/>
+    <component id="AreaSeries" class="mx.charts.series.AreaSeries"/>
+    <component id="AreaSet" class="mx.charts.series.AreaSet"/>
+    <component id="BarSeries" class="mx.charts.series.BarSeries"/>
+    <component id="BarSet" class="mx.charts.series.BarSet"/>
+    <component id="BubbleSeries" class="mx.charts.series.BubbleSeries"/>
+    <component id="ColumnSeries" class="mx.charts.series.ColumnSeries"/>
+    <component id="ColumnSet" class="mx.charts.series.ColumnSet"/>
+    <component id="CandlestickSeries" class="mx.charts.series.CandlestickSeries"/>
+    <component id="HLOCSeries" class="mx.charts.series.HLOCSeries"/>
+    <component id="LineSeries" class="mx.charts.series.LineSeries"/>
+    <component id="PieSeries" class="mx.charts.series.PieSeries"/>
+    <component id="PlotSeries" class="mx.charts.series.PlotSeries"/>
+    <component id="SeriesEffect" class="mx.charts.effects.SeriesEffect"/>
+    <component id="SeriesInterpolate" class="mx.charts.effects.SeriesInterpolate"/>
+    <component id="SeriesSlide" class="mx.charts.effects.SeriesSlide"/>
+    <component id="SeriesZoom" class="mx.charts.effects.SeriesZoom"/>
+
+    <component id="AreaRenderer" class="mx.charts.renderers.AreaRenderer"/>
+    <component id="BoxItemRenderer" class="mx.charts.renderers.BoxItemRenderer"/>
+    <component id="CandlestickItemRenderer" class="mx.charts.renderers.CandlestickItemRenderer"/>
+    <component id="CircleItemRenderer" class="mx.charts.renderers.CircleItemRenderer"/>
+    <component id="CrossItemRenderer" class="mx.charts.renderers.CrossItemRenderer"/>
+    <component id="DiamondItemRenderer" class="mx.charts.renderers.DiamondItemRenderer"/>
+    <component id="HLOCItemRenderer" class="mx.charts.renderers.HLOCItemRenderer"/>
+    <component id="LineRenderer" class="mx.charts.renderers.LineRenderer"/>
+    <component id="ShadowBoxItemRenderer" class="mx.charts.renderers.ShadowBoxItemRenderer"/>
+    <component id="ShadowLineRenderer" class="mx.charts.renderers.ShadowLineRenderer"/>
+    <component id="TriangleItemRenderer" class="mx.charts.renderers.TriangleItemRenderer"/>
+    <component id="WedgeItemRenderer" class="mx.charts.renderers.WedgeItemRenderer"/>
+
+    <component id="CartesianDataCanvas" class="mx.charts.chartClasses.CartesianDataCanvas"/>
+    <component id="PolarDataCanvas" class="mx.charts.chartClasses.PolarDataCanvas"/>
 </componentPackage>
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/AreaChart.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/AreaChart.as
index e1b1021..9350808 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/AreaChart.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/AreaChart.as
@@ -1,235 +1,322 @@
-////////////////////////////////////////////////////////////////////////////////
-//
-//  Licensed to the Apache Software Foundation (ASF) under one or more
-//  contributor license agreements.  See the NOTICE file distributed with
-//  this work for additional information regarding copyright ownership.
-//  The ASF licenses this file to You under the Apache License, Version 2.0
-//  (the "License"); you may not use this file except in compliance with
-//  the License.  You may obtain a copy of the License at
-//
-//      http://www.apache.org/licenses/LICENSE-2.0
-//
-//  Unless required by applicable law or agreed to in writing, software
-//  distributed under the License is distributed on an "AS IS" BASIS,
-//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//  See the License for the specific language governing permissions and
-//  limitations under the License.
-//
-////////////////////////////////////////////////////////////////////////////////
-
-package mx.charts
-{
-import mx.charts.chartClasses.IAxis;
-import mx.graphics.IFill;
-import mx.graphics.SolidColor;
-import mx.graphics.SolidColorStroke;
-import mx.graphics.Stroke;
-import mx.charts.chartClasses.ChartBase;
-/*
-import flash.utils.Dictionary;
-
-import mx.charts.chartClasses.CartesianChart;
-import mx.charts.chartClasses.DataTip;
-import mx.charts.chartClasses.DataTransform;
-import mx.charts.chartClasses.IAxis;
-import mx.charts.chartClasses.Series;
-import mx.charts.series.AreaSeries;
-import mx.charts.series.AreaSet;
-import mx.charts.styles.HaloDefaults;
-import mx.core.IFlexModuleFactory;
-import mx.core.mx_internal;
-import mx.graphics.IFill;
-import mx.graphics.SolidColor;
-import mx.graphics.SolidColorStroke;
-import mx.graphics.Stroke;
-import mx.styles.CSSStyleDeclaration;
-
-use namespace mx_internal;
-*/
-[DefaultBindingProperty(destination="dataProvider")]
-
-//[DefaultTriggerEvent("itemClick")]
-
-//[IconFile("AreaChart.png")]
-
-/**
- *  The AreaChart control represents data as an area
- *  bounded by a line connecting the values in the data.
- *  The AreaChart control can be used to represent different variations,
- *  including simple areas, stacked, 100% stacked, and high/low.
- *  
- *  <p>The AreaChart control expects its <code>series</code> property
- *  to contain an Array of AreaSeries objects.</p>
- *  
- *  <p>Stacked and 100% area charts override the <code>minField</code>
- *  property of their AreaSeries objects.</p>
- *
- *  @mxml
- *  
- *  <p>The <code>&lt;mx:AreaChart&gt;</code> tag inherits all the properties
- *  of its parent classes, and adds the following properties:</p>
- *  
- *  <pre>
- *  &lt;mx:AreaChart
- *    <strong>Properties</strong>
- *    type="<i>overlaid|stacked|100%</i>"
- *  /&gt;
- *  </pre>
- *  
- *  @includeExample examples/Line_AreaChartExample.mxml
- *  
- *  @see mx.charts.series.AreaSeries
- *  
- *  @langversion 3.0
- *  @playerversion Flash 9
- *  @playerversion AIR 1.1
- *  @productversion Royale 0.9.3
- */
-public class AreaChart extends ChartBase
-//extends CartesianChart
-{
-    //include "../core/Version.as";
-
-    //--------------------------------------------------------------------------
-    //
-    //  Class initialization
-    //
-    //--------------------------------------------------------------------------
-    
-    //--------------------------------------------------------------------------
-    //
-    //  Constructor
-    //
-    //--------------------------------------------------------------------------
-    
-    /**
-     *  Constructor.
-     *  
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Royale 0.9.3
-     */
-    public function AreaChart()
-    {
-        super();
-
-        //LinearAxis(horizontalAxis).autoAdjust = false;
-    }
-
-    //--------------------------------------------------------------------------
-    //
-    //  Variables
-    //
-    //--------------------------------------------------------------------------
-    
-    /**
-     *  @private
-     */
-    //private static var _moduleFactoryInitialized:Dictionary = new Dictionary(true);
-
-    //--------------------------------------------------------------------------
-    //
-    //  Overridden properties
-    //
-    //--------------------------------------------------------------------------
-
-    //----------------------------------
-    //  horizontalAxis
-    //----------------------------------
-
-    //[Inspectable(category="Data")]
-
-    /**
-     *  @private
-     */
-    /*override*/  /* public function set horizontalAxis(value:IAxis):void
-    {
-        //if (value is CategoryAxis)
-        //    CategoryAxis(value).padding = 0;
-
-        //super.horizontalAxis = value;
-    } */   
-
-    //--------------------------------------------------------------------------
-    //
-    //  Properties
-    //
-    //--------------------------------------------------------------------------
-
-    //----------------------------------
-    //  type
-    //----------------------------------
-
-    /**
-     *  @private
-     *  Storage for the type property.
-     */
-    private var _type:String = "overlaid";
-
-    //[Inspectable(category="General", enumeration="overlaid,stacked,100%", defaultValue="overlaid")]
-
-    /**
-     *  Type of area chart to render.
-     *
-     *  <p>Possible values are:</p>
-     *  <ul>
-     *    <li><code>"overlaid"</code>:
-     *    Multiple areas are rendered on top of each other,
-     *    with the last series specified on top.
-     *    This is the default value.</li>
-     *    <li><code>"stacked"</code>:
-     *    Areas are stacked on top of each other and grouped by category.
-     *    Each area represents the cumulative value
-     *    of the areas beneath it.</li>
-     *    <li><code>"100%"</code>:
-     *    Areas are stacked on top of each other, adding up to 100%.
-     *    Each area represents the percent that series contributes
-     *    to the sum of the whole.</li>
-     *  </ul>
-     *  
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Royale 0.9.3
-     */
-    public function get type():String
-    {
-        return _type;
-    }
-
-    /**
-     *  @private
-     */
-    public function set type(value:String):void
-    {
-        _type = value;
-        //invalidateSeries();
-        //invalidateData();
-    }
-
-    /**
-     *  Sets a style property on this component instance.
-     *
-     *  <p>This can override a style that was set globally.</p>
-     *
-     *  <p>Calling the <code>setStyle()</code> method can result in decreased performance.
-     *  Use it only when necessary.</p>
-     *
-     *  @param styleProp Name of the style property.
-     *
-     *  @param newValue New value for the style.
-     *  
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Royale 0.9.3
-     */
-    override public function setStyle(styleProp:String, newValue:*):void
-    {
-        trace("setStyle not implemented");
-    }
-
-}
-
-}
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.charts
+{
+
+import mx.charts.chartClasses.CartesianChart;
+import mx.charts.chartClasses.DataTip;
+import mx.charts.chartClasses.DataTransform;
+import mx.charts.chartClasses.IAxis;
+import mx.charts.chartClasses.Series;
+import mx.charts.series.AreaSeries;
+import mx.charts.series.AreaSet;
+import mx.charts.styles.HaloDefaults;
+import mx.core.IFlexModuleFactory;
+import mx.core.mx_internal;
+import mx.graphics.IFill;
+import mx.graphics.SolidColor;
+import mx.graphics.SolidColorStroke;
+import mx.graphics.Stroke;
+import mx.styles.CSSStyleDeclaration;
+
+use namespace mx_internal;
+
+[DefaultBindingProperty(destination="dataProvider")]
+
+[DefaultTriggerEvent("itemClick")]
+
+//[IconFile("AreaChart.png")]
+
+/**
+ *  The AreaChart control represents data as an area
+ *  bounded by a line connecting the values in the data.
+ *  The AreaChart control can be used to represent different variations,
+ *  including simple areas, stacked, 100% stacked, and high/low.
+ *  
+ *  <p>The AreaChart control expects its <code>series</code> property
+ *  to contain an Array of AreaSeries objects.</p>
+ *  
+ *  <p>Stacked and 100% area charts override the <code>minField</code>
+ *  property of their AreaSeries objects.</p>
+ *
+ *  @mxml
+ *  
+ *  <p>The <code>&lt;mx:AreaChart&gt;</code> tag inherits all the properties
+ *  of its parent classes, and adds the following properties:</p>
+ *  
+ *  <pre>
+ *  &lt;mx:AreaChart
+ *    <strong>Properties</strong>
+ *    type="<i>overlaid|stacked|100%</i>"
+ *  /&gt;
+ *  </pre>
+ *  
+ *  @includeExample examples/Line_AreaChartExample.mxml
+ *  
+ *  @see mx.charts.series.AreaSeries
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public class AreaChart extends CartesianChart
+{
+//    include "../core/Version.as";
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class initialization
+    //
+    //--------------------------------------------------------------------------
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  Constructor.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function AreaChart()
+    {
+        super();
+
+        LinearAxis(horizontalAxis).autoAdjust = false;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  @private
+     */
+//    private static var _moduleFactoryInitialized:Dictionary = new Dictionary(true);
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden properties
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  horizontalAxis
+    //----------------------------------
+
+    [Inspectable(category="Data")]
+
+    /**
+     *  @private
+     */
+    override public function set horizontalAxis(value:IAxis):void
+    {
+        if (value is CategoryAxis)
+            CategoryAxis(value).padding = 0;
+
+        super.horizontalAxis = value;
+    }   
+
+    //--------------------------------------------------------------------------
+    //
+    //  Properties
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  type
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the type property.
+     */
+    private var _type:String = "overlaid";
+
+    [Inspectable(category="General", enumeration="overlaid,stacked,100%", defaultValue="overlaid")]
+
+    /**
+     *  Type of area chart to render.
+     *
+     *  <p>Possible values are:</p>
+     *  <ul>
+     *    <li><code>"overlaid"</code>:
+     *    Multiple areas are rendered on top of each other,
+     *    with the last series specified on top.
+     *    This is the default value.</li>
+     *    <li><code>"stacked"</code>:
+     *    Areas are stacked on top of each other and grouped by category.
+     *    Each area represents the cumulative value
+     *    of the areas beneath it.</li>
+     *    <li><code>"100%"</code>:
+     *    Areas are stacked on top of each other, adding up to 100%.
+     *    Each area represents the percent that series contributes
+     *    to the sum of the whole.</li>
+     *  </ul>
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get type():String
+    {
+        return _type;
+    }
+
+    /**
+     *  @private
+     */
+    public function set type(value:String):void
+    {
+        _type = value;
+        invalidateSeries();
+        invalidateData();
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: UIComponent
+    //
+    //--------------------------------------------------------------------------
+    
+	/**
+     *  @private
+     */
+    private function initStyles():Boolean
+    {
+        HaloDefaults.init(styleManager);
+        
+      	var areaChartSeriesStyles:Array /* of Object */ = [];
+        
+        var n:int = HaloDefaults.defaultFills.length;
+        for (var i:int = 0; i < n; i++)
+        {
+            var styleName:String = "haloAreaSeries" + i;
+            areaChartSeriesStyles[i] = styleName;
+            
+            var o:CSSStyleDeclaration =
+                HaloDefaults.createSelector("." + styleName, styleManager);
+            
+            var f:Function = function(o:CSSStyleDeclaration, stroke:Stroke,
+                                      fill:IFill):void
+            {
+                o.defaultFactory = function():void
+                {
+                    this.areaFill = fill;
+                    this.fill = fill;
+                }
+            }
+            
+            f(o, null, HaloDefaults.defaultFills[i]);
+        }
+		
+		var areaChartStyle:CSSStyleDeclaration = HaloDefaults.findStyleDeclaration(styleManager, "mx.charts.AreaChart");
+		if (areaChartStyle)
+		{
+			areaChartStyle.setStyle("chartSeriesStyles", areaChartSeriesStyles);
+			areaChartStyle.setStyle("fill", new SolidColor(0xFFFFFF, 0));
+			areaChartStyle.setStyle("calloutStroke", new SolidColorStroke(0x888888,2));
+			areaChartStyle.setStyle("horizontalAxisStyleNames", ["hangingCategoryAxis"]);
+			areaChartStyle.setStyle("verticalAxisStyleNames", ["blockNumericAxis"]);
+		}
+		
+        return true;
+    }
+    
+    /**
+     *   A module factory is used as context for using embedded fonts and for finding the style manager that controls the styles for this component.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function set moduleFactory(factory:IFlexModuleFactory):void
+    {
+        super.moduleFactory = factory;
+        
+        /*
+        if (_moduleFactoryInitialized[factory])
+            return;
+        
+        _moduleFactoryInitialized[factory] = true;
+        */
+        
+        // our style settings
+        initStyles();
+    }
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: ChartBase
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    override protected function customizeSeries(seriesGlyph:Series,
+                                                i:uint):void
+    {
+        var aSeries:AreaSeries = seriesGlyph as AreaSeries;
+
+        if (aSeries)
+        {
+            aSeries.stacker = null;
+            aSeries.stackTotals = null;
+        }
+    }
+
+    /**
+     *  @private
+     */
+    override protected function applySeriesSet(seriesSet:Array /* of Series */,
+                                               transform:DataTransform):Array /* of Series */
+    {
+        switch (_type)
+        {
+            case "stacked":
+            case "100%":
+            {
+                var newSeriesGlyph:AreaSet = new AreaSet();
+                newSeriesGlyph.series = seriesSet;
+                newSeriesGlyph.type = _type;
+                return [ newSeriesGlyph ];
+            }               
+
+            case "overlaid":
+            default:
+            {
+                return super.applySeriesSet(seriesSet, transform);
+            }
+        }
+    }
+}
+
+}
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/AxisLabel.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/AxisLabel.as
new file mode 100644
index 0000000..2b24ab0
--- /dev/null
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/AxisLabel.as
@@ -0,0 +1,135 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.charts
+{
+
+/**
+ *  An AxisLabel object represents a single label on the chart axis.
+ *  AxisLabel objects are generated by IAxis objects.
+ *  The AxisLabel object is also passed as the data
+ *  to custom AxisLabel objects that implement the IDataRenderer interface.
+ *  	
+ *  @see mx.charts.AxisRenderer
+ *  @see mx.charts.chartClasses.IAxis
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public class AxisLabel 
+{
+//    include "../core/Version.as";
+
+	//--------------------------------------------------------------------------
+	//
+	//  Constructor
+	//
+	//--------------------------------------------------------------------------
+
+	/**
+	 *  Constructor.
+	 *
+	 *  @param position The position, specified as a value between 0 and 1,
+	 *  of the label along the axis.
+	 *
+	 *  @param value The value the label represents.
+	 *
+	 *  @param text The text label that is actually rendered along the axis.
+	 *  
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
+	 */
+	public function AxisLabel(position:Number = 0, value:Object = null,
+							  text:String = null) 
+	{
+		super();
+
+		this.position = position;
+		this.value = value;
+		this.text = text;
+	}
+
+	//--------------------------------------------------------------------------
+	//
+	//  Properties
+	//
+	//--------------------------------------------------------------------------
+
+	//----------------------------------
+	//  position
+	//----------------------------------
+
+	[Inspectable(environment="none")]
+
+	/**
+	 *  The position, specified as a value between 0 and 1,
+	 *  of the label along the axis.
+	 *  An AxisLabel with a position of 0 is placed at the minimum value
+	 *  of the axis, while an AxisLabel with a position of 1 is placed
+	 *  at the maximum value of the axis.
+	 *  
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
+	 */
+	public var position:Number;	
+
+	//----------------------------------
+	//  text
+	//----------------------------------
+
+	[Inspectable(environment="none")]
+
+	/**
+	 *  The text label that is actually rendered along the axis.
+	 *  
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
+	 */
+	public var text:String;
+
+	//----------------------------------
+	//  value
+	//----------------------------------
+
+	[Inspectable(environment="none")]
+
+	/**
+	 *  The value that the label represents.
+	 *  The particular type of the value property
+	 *  is specific to the axis that generated the label.
+	 *  For example, a LinearAxis might generate numeric values,
+	 *  while a DateTimeAxis might generate Date instance values.
+	 *  
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
+	 */
+	public var value:Object;
+}
+
+}
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/AxisRenderer.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/AxisRenderer.as
new file mode 100644
index 0000000..a28b0ab
--- /dev/null
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/AxisRenderer.as
@@ -0,0 +1,3964 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.charts
+{
+
+import mx.display.Graphics;
+import org.apache.royale.events.Event;
+import org.apache.royale.events.MouseEvent;
+import org.apache.royale.geom.Matrix;
+import org.apache.royale.geom.Point;
+import org.apache.royale.geom.Rectangle;
+import org.apache.royale.reflection.getDefinitionByName;
+import mx.text.TextFormat;
+import org.apache.royale.reflection.getQualifiedClassName;
+
+import mx.charts.chartClasses.AxisBase;
+import mx.charts.chartClasses.AxisLabelSet;
+import mx.charts.chartClasses.ChartBase;
+import mx.charts.chartClasses.ChartLabel;
+import mx.charts.chartClasses.ChartState;
+import mx.charts.chartClasses.DualStyleObject;
+import mx.charts.chartClasses.IAxis;
+import mx.charts.chartClasses.IAxisRenderer;
+import mx.charts.chartClasses.InstanceCache;
+import mx.charts.styles.HaloDefaults;
+import mx.core.ClassFactory;
+//import mx.core.ContextualClassFactory;
+import mx.core.IDataRenderer;
+import mx.core.IFactory;
+import mx.core.IFlexDisplayObject;
+import mx.core.IFlexModuleFactory;
+import mx.core.IUIComponent;
+import mx.core.IUITextField;
+//import mx.core.LayoutDirection;
+import mx.core.UIComponent;
+import mx.core.UITextField;
+import mx.core.UITextFormat;
+import mx.core.mx_internal;
+import mx.graphics.IStroke;
+import mx.graphics.SolidColorStroke;
+import mx.graphics.Stroke;
+import mx.managers.ILayoutManagerClient;
+import mx.managers.ISystemManager;
+import mx.resources.IResourceManager;
+import mx.resources.ResourceManager;
+import mx.styles.CSSStyleDeclaration;
+import mx.styles.ISimpleStyleClient;
+
+use namespace mx_internal;
+
+//--------------------------------------
+//  Styles
+//--------------------------------------
+
+include "styles/metadata/TextStyles.as"
+
+/**
+ *  Specifies the characteristics of the line for the axis.
+ *  This style must be an instance of the Stroke class.  
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="axisStroke", type="mx.graphics.IStroke", inherit="no")]
+
+/**
+ *  The name of the CSS class selector to use when formatting the axis title.
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="axisTitleStyleName", type="String", inherit="yes")]
+
+/**
+ *  Specifies whether the AxisRenderer should drop labels
+ *  as necessary to lay out correctly.
+ *
+ *  <p>Set to <code>true</code> to cause the AxisRenderer
+ *  to drop overlapping labels when rendering.
+ *  Labels are always rendered at regular intervals.
+ *  If necessary, the AxisRenderer will render every other label,
+ *  or every third label, but never drop two or more consecutive labels.</p>
+ *
+ *  <p>Set to <code>false</code> to cause the AxisRenderer
+ *  to use other schemes (rotation, scaling) to lay out the labels.</p>
+ *
+ *  <p>If you do not explicitly set this style, the AxisRenderer defaults
+ *  to an appropriate value based on the type of axis being rendered.</p>
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="canDropLabels", type="Boolean", inherit="no")]
+
+/** 
+ *  Specifies whether to stagger labels on two label rows.
+ *  Use this setting to minimize the space required for the labels.  
+ *  The default value is <code>true</code>, which staggers the labels. 
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="canStagger", type="Boolean", inherit="no")]
+
+/**
+ *  Specifies the alignment of label with respect to
+ *  the position of the value it points to.
+ * 
+ *  @default center
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="labelAlign", type="String", enumeration="left,top,right,bottom,center", inherit="no")]
+
+/**
+ *  The class that is used by this component to render labels.
+ *
+ *  <p>It can be set to either the mx.controls.Label class
+ *  or the spark.components.Label class.</p>
+ *
+ *  @default spark.components.Label
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 10.2
+ *  @playerversion AIR 2.0
+ *  @productversion Flex 4
+ */
+[Style(name="labelClass", type="Class", inherit="no")]
+/** 
+ *  Specifies the gap between the end of the tick marks
+ *  and the top of the labels, in pixels. 
+ *  
+ *  @default 3 
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="labelGap", type="Number", format="Length", inherit="no")]
+
+/** 
+ *  Specifies the label rotation.
+ *  If the labels are rendered with device fonts,
+ *  the labels are always drawn horizontally.
+ *  If this style is any negative value,
+ *  the AxisRenderer determines an optimal angle to render
+ *  the labels in the smallest area without overlapping.
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="labelRotation", type="Number", inherit="no")]
+
+/**
+ *  Specifies the length of the minor tick marks on the axis, in pixels. 
+ *  
+ *  @default 0
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="minorTickLength", type="Number", format="Length", inherit="no")]
+
+/**
+ *  Specifies where to draw the minor tick marks. Options are:
+ *  <ul>
+ *    <li><code>"inside"</code> -
+ *    Draw minor tick marks inside the data area.</li>
+ *
+ *    <li><code>"outside"</code> -
+ *    Draw minor tick marks in the label area.</li>
+ *
+ *    <li><code>"cross"</code> -
+ *    Draw minor tick marks across the axis.</li>
+ *
+ *    <li><code>"none"</code> -
+ *    Draw no minor tick marks.</li>
+ *  </ul>
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="minorTickPlacement", type="String", enumeration="inside,outside,cross,none", inherit="no")]
+
+/**
+ *  Specifies the characteristics of the minor tick marks on the axis.
+ *  This style must be an instance of the Stroke class.  
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="minorTickStroke", type="mx.graphics.IStroke", inherit="no")]
+
+/**
+ *  Specifies whether labels should appear along the axis. 
+ *  
+ *  @default true 
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="showLabels", type="Boolean", inherit="no")]
+
+/**
+ *  Specifies whether to display the axis. 
+ *  
+ *  @default true 
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="showLine", type="Boolean", inherit="no")]
+
+/**
+ *  Specifies the length of the tick marks on the axis, in pixels. 
+ *  
+ *  @default 3  
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="tickLength", type="Number", format="Length", inherit="no")]
+
+/**
+ *  Specifies where to draw the tick marks. Options are:
+ *  <ul>
+ *    <li><code>"inside"</code> -
+ *    Draw tick marks inside the data area.</li>
+ *
+ *    <li><code>"outside"</code> -
+ *    Draw tick marks in the label area.</li>
+ *
+ *    <li><code>"cross"</code> -
+ *    Draw tick marks across the axis.</li>
+ *
+ *    <li><code>"none"</code> -
+ *    Draw no tick marks.</li>
+ *  </ul>
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="tickPlacement", type="String", enumeration="inside,outside,cross,none", inherit="no")]
+
+/**
+ *  Specifies the characteristics of the tick marks on the axis.
+ *  This style must be an instance of the Stroke class.  
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="tickStroke", type="mx.graphics.IStroke", inherit="no")]
+
+/**
+ *  Specifies how vertical axis title is to be rendered.
+ *  <code>flippedVertical</code> renders the title top to bottom
+ *  <code>vertical</code> renders the title bottom to top
+ * 
+ *  @default flippedVertical
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="verticalAxisTitleAlignment", type="String", enumeration="flippedVertical,vertical", inherit="no")]
+
+//[ResourceBundle("charts")]
+
+/**
+ *  You use the AxisRenderer class to describe
+ *  the horizontal and vertical axes of a chart. 
+ *  An axis is responsible for rendering
+ *  the labels, tick marks, and title along its length. 
+ *   
+ *  <p>AxisRenderer objects inherit some of their visual properties
+ *  from the enclosing chart object. 
+ *  The text format of the labels and title defaults
+ *  to the CSS text properties of the renderer.
+ *  You can control the formatting of the axis title separately
+ *  by specifying a <code>axisTitleStyleName</code>,
+ *  either on the AxisRenderer or on the enclosing chart.</p> 
+ *  
+ *  <p>When positioning and sizing labels, the AxisRenderer
+ *  takes a minimum amount of the chart's available space.
+ *  If labels take too much space, then the AxisRenderer scales them.
+ *  However, the AxisRenderer does not scale the labels
+ *  to too small of a point size.
+ *  To increase readability, the AxisRenderer chooses one
+ *  of the following layout methods based on the one
+ *  that requires the least scaling:</p>
+ *
+ *  <ul>
+ *    <li>Render the labels horizontally end to end.</li> 
+ *    <li>Stagger the labels horizontally in two rows.</li> 
+ *    <li>Rotate the labels to fit them in the space provided.
+ *    The AxisRenderer rotates the labels to the minimum angle
+ *    needed to prevent them from overlapping.
+ *    The maximum angle is 90 degrees.</li>
+ *  </ul>
+ *  
+ *  <p>The AxisRenderer adjusts the boundaries of the chart's data area
+ *  to ensure that it can draw the labels without pushing outside
+ *  of the boundaries.</p>
+ *  
+ *  @mxml
+ *  
+ *  <p>The <code>&lt;mx:AxisRenderer&gt;</code> tag inherits all the properties
+ *  of its parent classes, and adds the following properties:</p>
+ *  
+ *  <pre>
+ *  &lt;mx:AxisRenderer
+ *    <strong>Properties</strong>
+ *    axis="<i>IAxis</i>"
+ *    chart="<i>ChartBase</i>"
+ *    gutters="<i>Rectangle</i>"
+ *    heightLimit="<i>Number</i>"
+ *    labelRenderer="<i>IFactory</i>"
+ *    labelFunction="<i>Function</i>"
+ *    length="<i>Number</i>"
+ *    otherAxes="<i>Array</i>"
+ *    placement="right|left|bottom|top"
+ *    ticks="<i>Array</i>"
+ *    titleRenderer="<i>IFactory</i>"
+ *     
+ *    <strong>Styles</strong>
+ *    axisStroke="<i>No default</i>"
+ *    axisTitleStyleName="<i>No default</i>"
+ *    canDropLabels="true|false"
+ *    canStagger="true|false"
+ *    labelAlign="center|left|right" (horizontal axes) or "center|top|bottom" (vertical axes)
+ *    labelGap="3"
+ *    labelRotation="<i>No default</i>"
+ *    minorTickLength="<i>Default depends on axis</i>"
+ *    minorTickPlacement="none|inside|outside|cross"
+ *    minorTickStroke="<i>No default</i>"
+ *    showLabels="true|false"
+ *    showLine="true|false"
+ *    tickLength="<i>Default depends on axis</i>"
+ *    tickPlacement="inside|outside|cross|none"
+ *    tickStroke="<i>No default</i>"
+ *    verticalAxisTitleAlignment="flippedVertical|vertical"
+ *  /&gt;
+ *  </pre>
+ *    
+ *  @includeExample examples/HLOCChartExample.mxml
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public class AxisRenderer extends DualStyleObject implements IAxisRenderer
+{
+//    include "../core/Version.as";
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class initialization
+    //
+    //--------------------------------------------------------------------------
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Class variables
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    private static var textFieldFactory:/*Contextual*/ClassFactory;
+    
+    /**
+     *  @private
+     */
+    private static var resourceManager:IResourceManager =
+                                ResourceManager.getInstance();
+	
+	/**
+	 *  @private
+	 */
+//	private static var _moduleFactoryInitialized:Dictionary = new Dictionary(true);
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  Constructor.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function AxisRenderer()
+    {
+        super();        
+        var labelClass:Class = getLabelClass();
+        textFieldFactory =  new /*Contextual*/ClassFactory(labelClass/*, moduleFactory*/);
+        
+        _labelCache = new InstanceCache(labelClass, this);
+        
+       	_labelCache.discard = true;
+        _labelCache.remove = true;
+        
+        updateRotation();
+        
+        //super.showInAutomationHierarchy = false;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  @private
+     */
+    private var _cacheDirty:Boolean = true;
+    
+    /**
+     *  @private
+     */
+    private var _labelFormatCache:TextFormat;
+    
+    /**
+     *  @private
+     */
+    private var _otherAxes:Array /* of AxisRenderer */; 
+    
+    /**
+     *  @private
+     */
+    private var _ticks:Array /* of Number */ = [];
+    
+    /**
+     *  @private
+     */
+    private var _minorTicks:Array /* of Number */ = [];
+    
+    /**
+     *  @private
+     */
+    private var _heightLimit:Number;
+    
+    /**
+     *  @private
+     */
+    private var _maxLabelHeight:Number;
+
+    /**
+     *  @private
+     */
+    private var _maxLabelWidth:Number;
+
+    /**
+     *  @private
+     */
+    private var _maxRotatedLabelHeight:Number;
+    
+    /**
+     *  @private
+     */
+    private var _axisLabelSet:AxisLabelSet;
+    
+    /**
+     *  @private
+     */
+    private var _labels:Array /* of ARLabelData */ = [];
+    
+    /**
+     *  @private
+     */
+    private var _labelPlacement:Object;
+
+    /**
+     *  @private
+     */
+    private var _forceLabelUpdate:Boolean = false;  
+    
+    /**
+     *  @private
+     */
+    private var _labelCache:InstanceCache;  
+    
+    /**
+     *  @private
+     */
+    private var _horizontal:Boolean;
+    
+    /**
+     *  @private
+     */
+    private var _titleField:UIComponent;
+    
+    /**
+     *  @private
+     */
+    private var _titleFieldChanged:Boolean;
+
+    /**
+     *  @private
+     */
+    private var _canRotate:Boolean; 
+    
+    /**
+     *  @private
+     */
+    private var _inverted:Boolean = false;
+    
+    /**
+     *  @private
+     */
+    private var _bGuttersAdjusted:Boolean = false;
+
+    /**
+     *  @private
+     */
+    private var _supressInvalidations:int = 0;
+    
+    /**
+     *  @private
+     */
+    private var _measuringField:UIComponent;
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden properties
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  showInAutomationHierarchy
+    //----------------------------------
+
+    /**
+     *  @private
+    override public function set showInAutomationHierarchy(value:Boolean):void
+    {
+        //do not allow value changes
+    }
+     */
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Properties
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  axis
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the axis property.
+     */
+    private var _axis:IAxis = null;
+    
+    [Inspectable(category="General")]
+
+    /**
+     *  The axis object associated with this renderer.
+     *  This property is managed by the enclosing chart,
+     *  and could be explicitly set if multiple axes renderers are used.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */ 
+    public function get axis():IAxis
+    {
+        return _axis;       
+    }
+
+    /**
+     *  @private
+     */ 
+    public function set axis(value:IAxis):void
+    {
+        if (_axis)
+        {
+            _axis.removeEventListener("axisChange", axisChangeHandler, false);
+            _axis.removeEventListener("titleChange", titleChangeHandler, false);
+        }
+
+        _axis = value;
+
+		if (_axis) {
+        	value.addEventListener("axisChange", axisChangeHandler/*, false, 0, true*/);
+        	value.addEventListener("titleChange", titleChangeHandler/*, false, 0, true*/);
+		}
+    }
+    
+    //----------------------------------
+    //  chart
+    //----------------------------------
+
+    [Inspectable(environment="none")]
+
+    /**
+     *  The base chart for this AxisRenderer.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    protected function get chart():ChartBase
+    {
+        var p:UIComponent = parent as UIComponent;
+        while (!(p is ChartBase) && p)
+        {
+            p = p.parent as UIComponent;
+        }           
+        return p as ChartBase;
+    }
+
+    //----------------------------------
+    //  gutters
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the gutters property.
+     */
+    private var _gutters:Rectangle = new Rectangle();
+    
+    [Inspectable(category="General")]
+    
+
+    /** 
+    * @inheritDoc
+    *  
+    *  @langversion 3.0
+    *  @playerversion Flash 9
+    *  @playerversion AIR 1.1
+    *  @productversion Flex 3
+    */
+    public function get gutters():Rectangle
+    {
+        if (_horizontal == false)
+        {
+            return new Rectangle(_gutters.bottom, _gutters.left,
+                                 -_gutters.height, _gutters.width);
+        }
+        else
+        {
+            return _gutters;
+        }
+    }
+    
+    /**
+     *  @private
+     */ 
+    public function set gutters(value:Rectangle):void
+    {
+        var correctedGutters:Rectangle = value;
+        
+        // This check will rarely succeed, because _gutters
+        // have been tweaked to represent placement.
+        if (_gutters && 
+            _gutters.left == correctedGutters.left && 
+            _gutters.right == correctedGutters.right && 
+            _gutters.top == correctedGutters.top && 
+            _gutters.bottom == correctedGutters.bottom)
+        {
+            _gutters = correctedGutters;
+            return;
+        }
+        else
+        {
+            adjustGutters(value,
+                { left: false, top: false, right: false, bottom: false });
+        }       
+    }
+
+    //----------------------------------
+    //  heightLimit
+    //----------------------------------
+
+    [Inspectable(category="Size")]
+    
+    /** 
+    * @inheritDoc
+    *  
+    *  @langversion 3.0
+    *  @playerversion Flash 9
+    *  @playerversion AIR 1.1
+    *  @productversion Flex 3
+    */
+    public function get heightLimit():Number
+    {
+        return _heightLimit;
+    }
+
+    /**
+     *  @private
+     */ 
+    public function set heightLimit(value:Number):void
+    {
+        _heightLimit = value;
+    }
+
+    //----------------------------------
+    //  highlightElements
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the highlightElements.
+     */
+    private var _highlightElements:Boolean = false;
+
+    [Inspectable(category="General", defaltValue = "false")]
+    
+    /**
+     *  Specifies wheter to highlight chart elements like Series on mouse rollover.
+     *  
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get highlightElements():Boolean
+    {
+        return _highlightElements;
+    }
+    
+    /**
+     *  @private
+     */
+    public function set highlightElements(value:Boolean):void
+    {
+        if (value == _highlightElements)
+            return;
+            
+        _highlightElements = value;
+        invalidateProperties();
+    }
+    
+    //----------------------------------
+    //  horizontal
+    //----------------------------------
+
+    [Inspectable(category="General")]
+    
+    /**
+    *   @inheritDoc
+    *  
+    *  @langversion 3.0
+    *  @playerversion Flash 9
+    *  @playerversion AIR 1.1
+    *  @productversion Flex 3
+    */
+    public function get horizontal():Boolean
+    {
+        return _horizontal;
+    }
+    
+    /**
+     *  @private
+     */ 
+    public function set horizontal(value:Boolean):void
+    {
+        _horizontal = value;
+
+        updateRotation();
+    }
+
+    //----------------------------------
+    //  labelFunction
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the labelFunction property.
+     */
+    private var _labelFunction:Function = null;
+
+    [Inspectable(category="General")]
+    
+    /**
+     *  Called to format axis renderer values for display as labels.
+     *  A <code>labelFunction</code> has the following signature:
+     *  <pre>
+     *  function labelFunction(<i>axisRenderer</i>:IAxisRenderer, <i>label</i>:String):String { ... }
+     *  </pre>
+     *  
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get labelFunction():Function
+    {
+        return _labelFunction;
+    }
+    
+    /**
+     *  @private
+     */
+    public function set labelFunction(value:Function):void
+    {
+        _labelFunction = value;
+        
+        if (chart)
+            chart.invalidateDisplayList();
+
+        _forceLabelUpdate  = true;
+        _cacheDirty = true;
+        _axisLabelSet = null;
+
+        invalidateDisplayList();
+    }
+
+    //----------------------------------
+    //  labelRenderer
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the labelRenderer property.
+     */
+    private var _labelRenderer:IFactory = null;
+    
+    [Inspectable(category="General")]
+    
+    /** 
+     *  A reference to the factory used to render the axis labels. 
+     *  This type must implement the IDataRenderer
+     *  and IFlexDisplayObject interfaces.
+     *  <p>The AxisRenderer will create one instance of this class
+     *  for each label on the axis.
+     *  The labelRenderer's data property is assigned an AxisLabel 
+     *  object containing the value and label to be rendered.</p>
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get labelRenderer():IFactory
+    {
+        return _labelRenderer;
+    }
+
+    /**
+     *  @private
+     */ 
+    public function set labelRenderer(value:IFactory):void
+    {
+        var oldLR:IFactory = _labelRenderer;
+        _labelRenderer = value;
+        if (oldLR == value)
+            return;
+
+        if (_measuringField)
+        {
+            removeChild(_measuringField);           
+            _measuringField = null;
+        }
+		_labelCache.discard = true;
+        _labelCache.count = 0;
+		_labelCache.discard = false;
+        if (!value) 
+            _labelCache.factory = textFieldFactory;
+        else 
+            _labelCache.factory = _labelRenderer;
+
+        if (chart)
+            chart.invalidateDisplayList();
+
+        _forceLabelUpdate  = true;
+        _cacheDirty = true;
+
+        invalidateDisplayList();
+    }
+
+    //----------------------------------
+    //  length
+    //----------------------------------
+
+    [Inspectable(environment="none")]
+
+    /** 
+     *  Specifies the length of the axis, in screen coordinates.
+     *  The default length depends on a number of factors, 
+     *  including the size of the chart, the size of the labels,
+     *  how the AxisRenderer chooses to lay out labels, 
+     *  and any requirements imposed by other portions of the chart.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get length():Number
+    {
+        return unscaledWidth - _gutters.left - _gutters.right;
+    }
+
+    //----------------------------------
+    //  minorTicks
+    //----------------------------------
+
+    /**
+    *   @inheritDoc
+    *  
+    *  @langversion 3.0
+    *  @playerversion Flash 9
+    *  @playerversion AIR 1.1
+    *  @productversion Flex 3
+    */
+    public function get minorTicks():Array /* of Number */
+    {
+        return _minorTicks;
+    }
+
+    //----------------------------------
+    //  otherAxes
+    //----------------------------------
+
+    /**
+    *   @inheritDoc
+    *  
+    *  @langversion 3.0
+    *  @playerversion Flash 9
+    *  @playerversion AIR 1.1
+    *  @productversion Flex 3
+    */
+    public function set otherAxes(value:Array /* of AxisRenderer */):void
+    {
+        _otherAxes = value;
+    }
+
+    //----------------------------------
+    //  placement
+    //----------------------------------
+    
+    private var _placement:String = "";
+
+    [Inspectable(category="General", enumeration="left,top,right,bottom")]
+
+    /**
+    *   @inheritDoc
+    *  
+    *  @langversion 3.0
+    *  @playerversion Flash 9
+    *  @playerversion AIR 1.1
+    *  @productversion Flex 3
+    */
+    public function get placement():String
+    {
+        return _placement;
+    }
+    
+    /**
+     *  @private
+     */ 
+    public function set placement(value:String):void
+    {
+        _placement = value;
+        _inverted = value == "right" || value == "top";
+        
+        if (chart)
+        {
+        	dispatchEvent(new Event("axisPlacementChange",true));
+        }
+
+        _forceLabelUpdate  = true;
+        _cacheDirty = true;
+        
+        invalidateDisplayList();
+    }
+    
+    //----------------------------------
+    //  ticks
+    //----------------------------------
+
+    [Inspectable(environment="none")]
+
+    /**
+    *   @inheritDoc
+    *  
+    *  @langversion 3.0
+    *  @playerversion Flash 9
+    *  @playerversion AIR 1.1
+    *  @productversion Flex 3
+    */
+    public function get ticks():Array /* of Number */
+    {
+        return _ticks;
+    }
+
+	//----------------------------------
+    //  titleRenderer
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the titleRenderer property.
+     */
+    private var _titleRenderer:IFactory = null;
+    
+    [Inspectable(category="General")]
+    
+    /** 
+     *  A reference to the factory used to render the axis title. 
+     *  This type must extend UIComponent and 
+     *  implement the IDataRenderer and IFlexDisplayObject interfaces.
+     *  <p>The AxisRenderer will create an instance of this class
+     *  for title of the axis.
+     *  The titleRenderer's data property is assigned the title
+     *  to be rendered.</p>
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get titleRenderer():IFactory
+    {
+        return _titleRenderer;
+    }
+
+    /**
+     *  @private
+     */ 
+    public function set titleRenderer(value:IFactory):void
+    {
+        var oldTR:IFactory = _titleRenderer;
+        _titleRenderer = value;
+        if (oldTR == value)
+            return;
+        if (chart)
+            chart.invalidateDisplayList();
+        invalidateDisplayList();
+    }
+    
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: UIComponent
+    //
+    //--------------------------------------------------------------------------
+	
+	/**
+	 *  @private
+	 */
+	private function initStyles():Boolean
+	{
+		HaloDefaults.init(styleManager);
+		var axisRenderer:CSSStyleDeclaration = HaloDefaults.findStyleDeclaration(styleManager, "mx.charts.AxisRenderer");
+		if (axisRenderer)
+		{
+			axisRenderer.setStyle("axisStroke", new SolidColorStroke(0, 0, 1));
+			axisRenderer.setStyle("tickStroke", new SolidColorStroke(0, 0, 1));
+			axisRenderer.setStyle("minorTickStroke", new SolidColorStroke(0, 0, 1));
+		}
+		
+		var blockCategoryAxis:CSSStyleDeclaration = HaloDefaults.findStyleDeclaration(styleManager, ".blockCategoryAxis");
+		if (blockCategoryAxis)
+		{
+			blockCategoryAxis.setStyle("axisStroke", new SolidColorStroke(0xBBCCDD, 8, 1, false, "normal", "none"));
+			blockCategoryAxis.setStyle("tickStroke", new SolidColorStroke(0xFFFFFF, 2, 1, false, "normal", "none"));
+		}
+		
+		var blockNumericAxis:CSSStyleDeclaration = HaloDefaults.findStyleDeclaration(styleManager, ".blockNumericAxis");
+		if (blockNumericAxis)
+		{
+			blockNumericAxis.setStyle("axisStroke", new SolidColorStroke(0xBBCCDD, 8, 1, false, "normal", "none"));
+			blockNumericAxis.setStyle("tickStroke", new SolidColorStroke(0xBBCCDD, 1, 1,false, "normal", "none"));
+			blockNumericAxis.setStyle("minorTickStroke", new SolidColorStroke(0xFFFFFF, 1, 1, false, "normal", "none"));
+		}
+		
+		var lineNumericAxis:CSSStyleDeclaration = HaloDefaults.findStyleDeclaration(styleManager, ".linedNumericAxis");
+		if (lineNumericAxis)
+		{
+			lineNumericAxis.setStyle("axisStroke", new SolidColorStroke(0xBBCCDD, 1, 1, false, "normal", "none"));
+			lineNumericAxis.setStyle("tickStroke", new SolidColorStroke(0xBBCCDD, 1, 1,false, "normal", "none"));
+			lineNumericAxis.setStyle("minorTickStroke", new SolidColorStroke(0xBBCCDD, 1, 1, false, "normal", "none"));
+		}
+		
+		var dashedNumericAxis:CSSStyleDeclaration = HaloDefaults.findStyleDeclaration(styleManager, ".dashedNumericAxis");
+		if (dashedNumericAxis)
+		{
+			dashedNumericAxis.setStyle("tickStroke", new SolidColorStroke(0xBBCCDD, 1, 1,false, "normal", "none"));
+			dashedNumericAxis.setStyle("minorTickStroke", new SolidColorStroke(0xBBCCDD, 1, 1, false, "normal", "none"));
+		}
+		
+		var dashedCategoryAxis:CSSStyleDeclaration = HaloDefaults.findStyleDeclaration(styleManager, ".dashedCategoryAxis");
+		if (dashedCategoryAxis)
+		{
+			dashedCategoryAxis.setStyle("axisStroke", new SolidColorStroke(0xBBCCDD, 1, 1,false, "normal", "none"));
+			dashedCategoryAxis.setStyle("tickStroke", new SolidColorStroke(0xFFFFFF, 2, 1, false, "normal", "none"));
+		}
+		
+		var hangingCategoryAxis:CSSStyleDeclaration = HaloDefaults.findStyleDeclaration(styleManager, ".hangingCategoryAxis");
+		if (hangingCategoryAxis)
+		{
+			hangingCategoryAxis.setStyle("axisStroke", new SolidColorStroke(0xBBCCDD, 1, 1,false, "normal", "none"));
+			hangingCategoryAxis.setStyle("tickStroke", new SolidColorStroke(0xBBCCDD, 1, 1, false, "normal", "none"));
+			hangingCategoryAxis.setStyle("minorTickStroke", new SolidColorStroke(0,0,0));
+		}
+		return true;
+	}
+
+	/**
+	 *  @inheritDoc
+	 *  
+	 *  @langversion 3.0
+	 *  @playerversion Flash 9
+	 *  @playerversion AIR 1.1
+	 *  @productversion Flex 3
+	 */
+	override public function set moduleFactory(factory:IFlexModuleFactory):void
+	{
+		super.moduleFactory = factory;
+		
+        /*
+		if (_moduleFactoryInitialized[factory])
+			return;
+		
+		_moduleFactoryInitialized[factory] = true;
+		*/
+        
+		// our style settings
+		initStyles();
+	}
+	
+    /**
+     *  @private
+     */
+    override protected function commitProperties():void
+    {
+        super.commitProperties();
+        
+		if (!labelRenderer)
+		{
+			var labelClass:Class = getLabelClass();
+			
+			textFieldFactory = new /*Contextual*/ClassFactory(labelClass/*, moduleFactory*/);
+			
+			_labelCache.factory = textFieldFactory;
+		}
+        
+        setupMouseDispatching();
+    }
+
+    /**
+     *  @inheritDoc
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function invalidateSize():void
+    {
+        if (_supressInvalidations == 0)
+            super.invalidateSize();
+    }
+
+    /**
+     *  @inheritDoc
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function invalidateDisplayList():void
+    {
+        if (_supressInvalidations == 0)
+            super.invalidateDisplayList();
+    }
+
+    /**
+     *  @inheritDoc
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override protected function measure():void
+    {
+        var calcSize:Number = 0;
+        
+        // showlabels comes through CSS as a string
+        var showLabelsStyle:Object = getStyle("showLabels");
+        var showLabels:Boolean = showLabelsStyle != false &&
+                                 showLabelsStyle != "false";
+        
+        var showLineStyle:Object = getStyle("showLine");        
+        var showLine:Boolean = showLineStyle != false &&
+                               showLineStyle != "false";
+        
+        var axisStroke:IStroke = getStyle("axisStroke");
+
+        calcSize += tickSize(showLine);
+        
+        calcSize += getStyle("labelGap");
+        
+        calcSize += Number(showLine == true && axisStroke ?
+                           axisStroke.weight :
+                           0);
+
+        // If we have a title, we subtract off space for it.
+        var titleHeight:Number = 0;
+        var titleScale:Number = 1;
+        var titleSize:Point = measureTitle();
+
+        titleHeight = titleSize.y;
+        calcSize += titleHeight;
+
+        if (_horizontal)
+            measuredMinHeight = calcSize;
+        else
+            measuredMinWidth = calcSize;
+    }
+    
+    /**
+     *  @inheritDoc
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override protected function updateDisplayList(unscaledWidth:Number,
+                                                  unscaledHeight:Number):void
+    {
+        super.updateDisplayList(unscaledWidth, unscaledHeight);
+
+        _supressInvalidations++;
+
+        var chart:ChartBase = this.chart;
+
+        if (_bGuttersAdjusted == true &&
+            chart.chartState != ChartState.PREPARING_TO_HIDE_DATA &&
+            chart.chartState != ChartState.HIDING_DATA)
+        {
+            updateCaches();
+                
+            graphics.clear();
+    
+            var lineVisible:Boolean = getStyle("showLine");
+            
+            var labelBottom:Number = drawLabels(lineVisible);
+            
+            drawTitle(labelBottom);     
+            
+            drawAxis(lineVisible);  
+            
+            drawTicks(lineVisible);
+        }
+        _supressInvalidations--;
+    }
+    
+    /**
+     *  @inheritDoc
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function move(x:Number, y:Number):void
+    {
+        if (_horizontal)
+            super.move(x, y);
+        else
+            super.move(x + unscaledHeight, y);
+    }
+    
+    /**
+     *  @inheritDoc
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function setActualSize(w:Number, h:Number):void
+    {
+        if (_horizontal)
+        {
+            super.setActualSize(w, h);
+        }
+        else
+        {
+            var oldX:Number = x - unscaledHeight;
+            super.setActualSize(h, w);
+            move(oldX + w, y);
+        }       
+    }
+
+    /**
+     *  @private
+     */
+    override public function styleChanged(styleProp:String):void
+    {
+
+        if (styleProp == null || styleProp == "axisTitleStyleName")
+        {
+            _titleFieldChanged= true;
+        }
+        
+        // This is unfortunately necessary.
+        // Many style properties don't change the measured size of the axis,
+        // but rather changes how the chart will affect its layout.
+        // So we can't just invalidate our size...
+        // that only triggers a measure().
+        // Instead, we must invalidate the chart's displayList().
+        if (chart)
+            chart.invalidateDisplayList();
+        
+        _axisLabelSet = null;
+        _forceLabelUpdate = true;
+        _cacheDirty = true;
+        
+        invalidateDisplayList();
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Methods
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Called by the chart to indicate
+     *  when its current transition state has changed.
+     *
+     *  @param oldState A number representing the old state.
+     *
+     *  @param newState A number representing the new state.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function chartStateChanged(oldState:uint, newState:uint):void
+    {
+        invalidateDisplayList();
+    }
+
+    /**
+    *   @inheritDoc
+    *  
+    *  @langversion 3.0
+    *  @playerversion Flash 9
+    *  @playerversion AIR 1.1
+    *  @productversion Flex 3
+    */
+    public function adjustGutters(workingGutters:Rectangle,
+                                  adjustable:Object):Rectangle
+    {   
+        _bGuttersAdjusted = true;
+
+        var axisStroke:IStroke = getStyle("axisStroke");
+
+        updateCaches();
+
+        var width:Number = unscaledWidth;
+        var height:Number = unscaledHeight;
+        var scale:Number = 1;
+        var tmpGutter:Number;
+        
+        if (_horizontal == false)
+        {
+            var rotatedGutters:Rectangle =
+                new Rectangle(workingGutters.top, workingGutters.right, 0, 0);
+            
+            rotatedGutters.right = workingGutters.bottom;
+            rotatedGutters.bottom = workingGutters.left; 
+            
+            _gutters = workingGutters = rotatedGutters; 
+            
+            adjustable = { left: adjustable.top,
+                           top: adjustable.right,
+                           right:adjustable.bottom,
+                           bottom:adjustable.left };
+        }
+        else
+        {
+            _gutters = workingGutters = workingGutters.clone();
+        }
+
+        if (_inverted)
+        {
+            tmpGutter = workingGutters.top;
+            workingGutters.top = workingGutters.bottom;
+            workingGutters.bottom = tmpGutter;
+        }
+
+        var calcSize:Number = 0;
+        
+        // showLabels comes through CSS as a string
+        var showLabelsStyle:Object = getStyle("showLabels");
+        var showLabels:Boolean = showLabelsStyle != false &&
+                                 showLabelsStyle != "false";
+        
+        var showLineStyle:Object = getStyle("showLine");        
+        var showLine:Boolean = showLineStyle != false &&
+                               showLineStyle != "false";
+
+        calcSize += tickSize(showLine);
+
+        calcSize += getStyle("labelGap");
+
+        calcSize += Number(showLine == true && axisStroke ?
+                           axisStroke.weight :
+                           0);
+        
+        // If we have a title, we subtract off space for it.
+        var titleHeight:Number = 0;
+        var titleScale:Number = 1;
+
+        var titleSize:Point = measureTitle();
+
+        titleHeight = titleSize.y;
+        
+        // First, calculate the angle for the labels.               
+        var targetHeight:Number;
+
+        // Add in the size required by the title.
+        calcSize += titleHeight * titleScale;
+
+        if (adjustable.bottom == false)
+            targetHeight = Math.max(0,workingGutters.bottom - calcSize);
+        else if (!isNaN(heightLimit))
+            targetHeight = Math.max(0,heightLimit - calcSize);
+
+        // Adjust for any ticks that might be hanging over the edge.        
+        var tickStroke:IStroke = getStyle("tickStroke");
+        if (tickStroke)
+        {
+            workingGutters.left = Math.max(workingGutters.left,
+                                           tickStroke.weight / 2);
+            workingGutters.right = Math.max(workingGutters.right,
+                                            tickStroke.weight / 2);
+        }
+
+        tickStroke = getStyle("minorTickStroke");
+        if (tickStroke)
+        {
+            workingGutters.left = Math.max(workingGutters.left,
+                                           tickStroke.weight / 2);
+            workingGutters.right = Math.max(workingGutters.right,
+                                            tickStroke.weight / 2);
+        }
+
+        if (showLabels)
+        {
+            _labelPlacement = calcRotationAndSpacing(
+                width, height, targetHeight, workingGutters, adjustable);
+                
+            var label:ARLabelData = _labels[0];
+            var n:int = _labels.length;    
+                
+            // Calculate the height required by those labels.           
+            if (_labelPlacement.rotation == 0)
+            {
+                if (_labelPlacement.staggered)
+                    calcSize += 2 * label.height * _labelPlacement.scale;
+                else
+                    calcSize += _maxLabelHeight * _labelPlacement.scale;
+            }
+            else
+            {
+                var c:Number = Math.cos(Math.abs(_labelPlacement.rotation));
+                var s:Number = Math.sin(Math.abs(_labelPlacement.rotation));
+
+                var heightContribution:Number = 1 - this.labelAlignOffset;
+                var labelHeight:Number = 0;
+                scale = _labelPlacement.scale;
+
+                for (var i:int = 0; i < n; i++)
+                {
+                    var ldi:ARLabelData = _labels[i];
+                    var rotatedHeight:Number =
+                        c * ldi.height * heightContribution * scale +
+                        s * ldi.width * scale;
+                    labelHeight = Math.max(rotatedHeight, labelHeight);
+                }
+
+                _maxRotatedLabelHeight = labelHeight;
+                calcSize += labelHeight;
+            }
+        }
+        else
+        {
+            // For gridlines, we still need to measure out our labels.
+            measureLabels(false, width);
+
+            _labelPlacement = { rotation: 0, left: 0, right: 0,
+                                scale: 1, staggered: false };           
+        }
+        
+        var wmLeft:Number = Math.max(workingGutters.left,_labelPlacement.left);
+
+        workingGutters = new Rectangle(
+            wmLeft, workingGutters.top,
+            Math.max(workingGutters.right, _labelPlacement.right) - wmLeft,
+            Math.max(workingGutters.bottom, calcSize) - workingGutters.top);
+
+        if (_inverted)
+        {
+            tmpGutter = workingGutters.top;
+            workingGutters.top = workingGutters.bottom;
+            workingGutters.bottom = tmpGutter;
+        }
+
+        _gutters = workingGutters;
+        
+        invalidateDisplayList();
+
+        return gutters;
+    }
+
+    /**
+     *  @private
+     */
+    private function measureTitle():Point
+    {
+        if (!_axis || !(_axis.title) || _axis.title.length == 0)
+            return new Point(0, 0);
+
+        renderTitle();
+        
+        _supressInvalidations++;
+
+        (_titleField as IDataRenderer).data = _axis ? _axis.title : "";
+                
+        _titleField.validateProperties();
+        _titleField.validateSize(true);
+        
+        _supressInvalidations--;
+        
+        return new Point(_titleField.measuredWidth,
+                         _titleField.measuredHeight);       
+        
+    }
+
+    /**
+     *  @private
+     */
+    private function renderTitle():void
+    {
+        if (!_titleField || (getQualifiedClassName(_titleField) == "mx.charts.chartClasses::ChartLabel" && _titleRenderer) 
+          || (!(getQualifiedClassName(_titleField) == "mx.charts.chartClasses::ChartLabel") && !_titleRenderer)){
+          	if (_titleField)
+           		removeChild(_titleField);
+        	if (_titleRenderer)
+            	_titleField = _titleRenderer.newInstance();
+        	else
+            	_titleField = new ChartLabel();
+        
+       		_titleField.visible= false;        
+       		addChild(_titleField);
+          }    
+        _titleFieldChanged = true;
+        
+        if (_titleFieldChanged)
+        {
+            _titleFieldChanged = false;
+            var styleName:Object = getStyle("axisTitleStyleName");
+
+            if (styleName != null)
+                _titleField.styleName = styleName;
+            else
+                _titleField.styleName = this;
+        }
+    }
+	
+	private function getLabelClass():Class
+	{
+		var labelClass:Class = getStyle("labelClass");
+		if(labelClass == null)
+		{
+			try{
+				labelClass = Class(getDefinitionByName("spark.components::Label"));
+			}
+			catch(e:Error)
+			{
+				labelClass = Class(getDefinitionByName("mx.controls::Label"));
+			}
+		}
+		return labelClass;
+	}
+
+    /**
+     *  @private
+     */
+    private function calcRotationAndSpacing(width:Number, height:Number,
+                                            targetHeight:Number,
+                                            workingGutters:Rectangle,
+                                            adjustable:Object):Object
+    {
+        updateCaches();
+
+        var leftGutter:Number = workingGutters.left;
+        var rightGutter:Number = workingGutters.right;
+        
+        
+        // First, ask our range to estimate what our labels will be,
+        // and do a measurement pass on them.
+        var bEstimateIsAccurate:Boolean = measureLabels(true, 0);
+		var n:int  = _labels.length;
+        // If we have no labels, we're done.
+        if (n == 0)
+        {
+            return { rotation: 0, left: leftGutter, right: rightGutter,
+                     scale: 1, staggered: false };          
+        }       
+        
+        // First check and see if a rotation has been specified.
+        // If it has, go with what the author requested.    
+        var labelRotation:Number = getStyle("labelRotation");       
+        if (labelRotation > 90)
+            labelRotation = 0 / 0;
+
+        if (_horizontal == false)
+        {
+            if (isNaN(labelRotation))
+                labelRotation = 0;
+            if (labelRotation >= 0)
+                labelRotation = 90 - labelRotation;
+            else
+                labelRotation =- (90 + labelRotation);
+        }
+                
+        // Decide if it's OK to drop labels.
+        // We look for a style, and if we can't find it,
+        // we check the Axis to see what the default should be.     
+        var canDropLabelsStyle:Object = getStyle("canDropLabels");
+        var canDropLabels:Boolean;
+        
+        if (canDropLabelsStyle == null)
+        {
+            // Since style cache fails with unset styles, we store
+            // this off so we won't hit the style code over and over.
+            canDropLabels = Boolean(_axis.preferDropLabels());
+        }
+        else
+        {
+            canDropLabels = canDropLabelsStyle != false &&
+                            canDropLabelsStyle != "false";
+            
+        }
+        
+        var firstLabel:ARLabelData = _labels[0];
+        //Decide the last label based on the canDropLabels
+        var lastLabel:ARLabelData;
+        
+        if (canDropLabels)
+        {
+        	
+         	var prevLabel:ARLabelData = firstLabel;
+        	var thisLabel:ARLabelData;
+        	var spaceBetween:Number;
+        	var requiredSpace:Number;
+        	var axisLength:Number = width - leftGutter - rightGutter;
+        	var scalingRequired:Boolean = true;
+            var base:int;
+            var dir:int;
+            var maxSkipCount:int = 0;
+            var bLabelsReduced:Boolean;
+            var bSkipRequired:Boolean = true;
+			var skipCount:int = 0;
+            n = _labels.length;    
+            if (_horizontal)
+            {
+                if (n > 0)
+                    prevLabel = _labels[0];
+                base = 0;
+                dir = 1;                    
+            }
+            else
+            {
+                if (n > 0)
+                    prevLabel = _labels[n - 1];
+                base = n - 1;
+                dir = -1;
+            }
+                            
+            for (var i:int = 1; i < n; i++)
+            {
+                thisLabel = _labels[base + dir * i];
+                spaceBetween =
+                    Math.abs(thisLabel.position - prevLabel.position) *
+                    axisLength;
+                requiredSpace = (thisLabel.width + prevLabel.width) / 2;
+                if (requiredSpace > spaceBetween)
+	            {
+                    skipCount++;
+                }
+                else
+                {
+                    if (skipCount > maxSkipCount)
+                    {
+                        maxSkipCount = skipCount;
+                    }                       
+                    skipCount = 0;
+                    prevLabel = thisLabel;
+                }
+            }
+    
+            if (skipCount > maxSkipCount)
+            {
+                maxSkipCount = skipCount;
+            }
+			if(maxSkipCount == 0)
+				lastLabel = _labels[_labels.length - 1];
+			else
+				lastLabel = _labels[maxSkipCount + 1] ? _labels[maxSkipCount + 1] : _labels[_labels.length - 1];
+			//lastLabel = prevLabel;
+        }
+        	
+        else
+            lastLabel = _labels[_labels.length - 1];        
+         
+        
+        
+        // Layout vertical if:
+        // 1. horizontal, and label is 90 and canRotate is true
+        // 2. (vertical, and rotation is null, 90), or (canRotate is false)
+        
+        var mustLayoutVertical:Boolean =
+            (_horizontal && _canRotate && labelRotation == 90) ||
+            (_horizontal == false &&
+             ((isNaN(labelRotation) ||
+               labelRotation == 90) ||
+               _canRotate == false));
+    
+        var canLayoutHorizontal:Boolean =
+            mustLayoutVertical == false &&
+            ((isNaN(labelRotation) && _horizontal == true) ||
+            (labelRotation == 0) || (_canRotate == false));
+        
+        var horizontalScale:Number = 0;
+        
+        var canStaggerStyle:Object = getStyle("canStagger");
+        var canStagger:Boolean =
+            canStaggerStyle == null ||
+            (canStaggerStyle != false &&
+             canStaggerStyle != "false");
+
+        var canLayoutStaggered:Boolean =
+            mustLayoutVertical == false &&
+            ((canDropLabels == false) &&
+            canLayoutHorizontal &&
+            (false != canStaggerStyle));
+        
+        var staggeredScale:Number = 0;
+        
+        var canLayoutAngled:Boolean =
+            (mustLayoutVertical == false && 
+            ((_canRotate == true) && 
+             labelRotation != 0 && 
+             ((canDropLabels == false) || 
+              !isNaN(labelRotation))));
+
+        var angledScale:Number = 0;
+        var minimumAxisLength:Number = width - leftGutter - rightGutter;
+        
+        var verticalData:Object;
+        var horizontalGutterData:Object;
+        var angledGutterData:Object;
+        var angledSpacingData:Object;
+        var horizontalSpacingData:Object;
+        var staggeredSpacingData:Object;
+        
+        if (bEstimateIsAccurate)
+        {
+            // First, determine the gutter adjustments for vertical labels.
+            if (mustLayoutVertical)
+            {
+                verticalData = calcVerticalGutters(
+                    width, leftGutter, rightGutter,
+                    firstLabel, lastLabel, adjustable);
+
+                return calcVerticalSpacing(
+                    width, verticalData, targetHeight,
+                    firstLabel, lastLabel, canDropLabels);
+            }
+
+            // Now, determine the gutter and/or dropLabel adjustments
+            // for horizontal labels.
+            if (canLayoutHorizontal || canLayoutStaggered)
+            {
+                horizontalGutterData = measureHorizontalGutters(
+                    width, leftGutter, rightGutter,
+                    firstLabel, lastLabel, adjustable);
+
+                horizontalSpacingData = calcHorizontalSpacing(
+                    width, horizontalGutterData, targetHeight,
+                    firstLabel, lastLabel, canDropLabels,
+                    adjustable, minimumAxisLength);
+                
+                horizontalScale = horizontalSpacingData.scale;
+                
+                if (horizontalScale != 1 && canLayoutStaggered)
+                {
+                    staggeredSpacingData = calcStaggeredSpacing(
+                        width, horizontalGutterData, targetHeight,
+                        firstLabel, lastLabel, canDropLabels, adjustable);
+
+                    staggeredScale = staggeredSpacingData.scale;
+                }
+            }
+
+            // Now we're going to determine the optimal angle,
+            // and gutter adjustments, for angled labels.
+            if (horizontalScale != 1 && staggeredScale != 1 && canLayoutAngled)
+            {
+                angledGutterData = measureAngledGutters(
+                    width, labelRotation, targetHeight,
+                    firstLabel, leftGutter, rightGutter, adjustable);
+
+                angledSpacingData = calcAngledSpacing(angledGutterData);
+
+                angledScale = angledSpacingData.scale;
+            }
+
+            if (horizontalScale >= staggeredScale &&
+                horizontalScale >= angledScale)
+            {
+                if (horizontalSpacingData != null)
+                    return horizontalSpacingData;
+                return angledSpacingData;
+            }
+            else if (staggeredScale >= angledScale)
+            {
+                if (staggeredSpacingData != null)
+                    return staggeredSpacingData;
+                return angledSpacingData;
+            }
+            else
+            {
+                return angledSpacingData;
+            }
+        }
+        else
+        {
+            // First, determine the gutter adjustments for vertical labels.
+            if (mustLayoutVertical)
+            {
+                verticalData = calcVerticalGutters(
+                    width, leftGutter, rightGutter,
+                    firstLabel, lastLabel, adjustable);
+
+                minimumAxisLength = Math.min(minimumAxisLength,
+                                             verticalData.minimumAxisLength);
+            }
+
+            // Now, determine the gutter and/or dropLabel adjustments
+            // for horizontal labels.
+            if (canLayoutHorizontal || canLayoutStaggered)
+            {
+                horizontalGutterData = measureHorizontalGutters(
+                    width, leftGutter, rightGutter,
+                    firstLabel, lastLabel, adjustable);
+
+                minimumAxisLength = Math.min(
+                    minimumAxisLength, horizontalGutterData.minimumAxisLength);         
+            }
+
+            // Now we're going to determine the optimal angle,
+            // and gutter adjustments, for angled labels
+            if (canLayoutAngled)
+            {
+                angledGutterData = measureAngledGutters(
+                    width, labelRotation, targetHeight,
+                    firstLabel, leftGutter, rightGutter, adjustable);
+
+                minimumAxisLength = Math.min(
+                    minimumAxisLength, angledGutterData.minimumAxisLength);         
+            }
+
+            // We've effectively measured our maximum gutter reduction.
+            // Now our range can adjust based on any gutters
+            // in the range required by specific renderers.
+            measureLabels(false, minimumAxisLength);
+
+            // Now that we have an accurate set of labels, it's entirely possible we have no labels anymore.
+            // if that's the case, bail out.
+            if (_labels.length == 0)
+            {
+                return { rotation: 0, left: leftGutter, right: rightGutter,
+                         scale: 1, staggered: false };          
+            }
+    
+            // Now, determine either the scale factor or the drop factor
+            // for vertical titles
+            if (mustLayoutVertical)
+            {
+                return calcVerticalSpacing(
+                    width, verticalData, targetHeight,
+                    firstLabel, lastLabel, canDropLabels);
+            }
+
+            // Now determine the scale adjustments for horizontal labels.
+            if (canLayoutHorizontal)
+            {
+                horizontalSpacingData = calcHorizontalSpacing(
+                    width, horizontalGutterData, targetHeight,
+                    firstLabel, lastLabel, canDropLabels,
+                    adjustable, minimumAxisLength);
+
+                horizontalScale = horizontalSpacingData.scale;
+            }
+
+            // And the scale adjustments for staggered labels.
+            if (canLayoutStaggered)
+            {
+                staggeredSpacingData = calcStaggeredSpacing(
+                    width, horizontalGutterData, targetHeight,
+                    firstLabel, lastLabel, canDropLabels, adjustable);
+
+                staggeredScale = staggeredSpacingData.scale;
+            }
+
+            if (canLayoutAngled)
+            {
+                angledSpacingData = calcAngledSpacing(angledGutterData);
+                angledScale = angledSpacingData.scale;
+            }
+
+            if (horizontalScale  >= staggeredScale &&
+                horizontalScale >= angledScale)
+            {
+                if (horizontalSpacingData != null)
+                    return horizontalSpacingData;
+                return angledSpacingData;
+            }
+            else if (staggeredScale >= angledScale)
+            {
+                if (staggeredSpacingData != null)
+                    return staggeredSpacingData;
+                return angledSpacingData;
+            }
+            else
+            {
+                return angledSpacingData;
+            }
+        }
+    }
+    
+    /**
+     *  @private
+     */
+    private function measureLabels(bEstimate:Boolean,
+                                   minimumAxisLength:Number):Boolean
+    {
+        var newLabelData:AxisLabelSet;
+        
+        if (!_axis)
+        	throw(new Error(resourceManager.getString("charts", "noAxisSet")));
+        else if (bEstimate)
+            newLabelData = _axis.getLabelEstimate();
+        else
+            newLabelData = _axis.getLabels(minimumAxisLength);
+        
+        if (newLabelData == _axisLabelSet && _forceLabelUpdate == false)
+            return newLabelData.accurate;
+
+        var bResult:Boolean = processAxisLabels(newLabelData);
+
+        _axisLabelSet = newLabelData;
+
+        return bResult;
+    }
+
+    /**
+     *  @private
+     */
+    private function calcVerticalGutters(width:Number,
+                                         leftGutter:Number,
+                                         rightGutter:Number,
+                                         firstLabel:ARLabelData,
+                                         lastLabel:ARLabelData,
+                                         adjustable:Object):Object
+    {
+        var labelAlignOffset:Number = this.labelAlignOffset;
+        var axisLength:Number = width - leftGutter - rightGutter;
+        
+        var LS:Number = firstLabel.height * labelAlignOffset;
+        var RS:Number = firstLabel.height * (1 - labelAlignOffset);
+        var P1:Number = firstLabel.position;
+        var P2:Number = 1 - lastLabel.position;
+
+        var lhm:Number;
+        var rhm:Number;
+
+        var leftOverlaps:Boolean = adjustable.left != false &&
+                                   LS > leftGutter + P1 * axisLength;
+
+        var rightOverlaps:Boolean = adjustable.right != false &&
+                                    RS > rightGutter + P2 * axisLength;
+
+        if (leftOverlaps == false && rightOverlaps == false)
+        {
+            lhm = leftGutter;
+            rhm = rightGutter;
+        }
+        else if (leftOverlaps == true && rightOverlaps == false)
+        {
+            axisLength = (width - rightGutter - LS) / (1 - P1);
+            lhm = width - rightGutter - axisLength;
+            rhm = rightGutter;
+            rightOverlaps = RS > rhm + P2 * axisLength;             
+        }
+        else if (leftOverlaps == false && rightOverlaps == true)
+        {
+            axisLength = (width - leftGutter - RS) / (1 - P2);
+            lhm = leftGutter;
+            rhm = width - leftGutter - axisLength;
+            leftOverlaps = LS > lhm + P1 * axisLength;
+        }
+
+        if (leftOverlaps && rightOverlaps)
+        {
+            axisLength = (width - LS - RS) / (1 - P1 - P2);
+
+            lhm = LS - P1 * axisLength;
+            rhm = RS - P2 * axisLength;
+        }
+
+        return { hlm:lhm, hrm:rhm, minimumAxisLength:width - lhm - rhm };
+    }
+    
+    /**
+     *  @private
+     */
+    private function calcVerticalSpacing(width:Number, verticalData:Object,
+                                         targetHeight:Number,
+                                         firstLabel:ARLabelData,
+                                         lastLabel:ARLabelData,
+                                         canDropLabels:Boolean):Object
+    {
+        // Check for max height violations.
+        var scale:Number;
+        var axisLength:Number = width - verticalData.hlm - verticalData.hrm;
+        if (!isNaN(targetHeight))
+            scale = Math.min(1, targetHeight / _maxLabelWidth);
+        else
+            scale = 1;
+            
+        var prevLabel:ARLabelData = firstLabel;
+        var thisLabel:ARLabelData;
+        var spaceBetween:Number;
+        var requiredSpace:Number;
+        var scalingRequired:Boolean = true;
+        var n:int  = _labels.length;
+
+        // If we can drop labels, do that.
+        if (canDropLabels)
+        {
+            var base:int;
+            var dir:int;
+            var maxSkipCount:int = 0;
+            var bLabelsReduced:Boolean;
+            var bSkipRequired:Boolean = true;
+            
+            do
+            {           
+                maxSkipCount = 0;
+                var skipCount:int = 0;
+                
+                if (_horizontal)
+                {
+                    if (_labels.length > 0)
+                        prevLabel = _labels[0];
+                    base = 0;
+                    dir = 1;                    
+                }
+                else
+                {
+                    if (_labels.length > 0)
+                        prevLabel = _labels[_labels.length - 1];
+                    base = _labels.length - 1;
+                    dir = -1;
+                }
+
+                var firstIntervalLabel:Object;
+                var lastIntervalLabel:Object;
+				n  = _labels.length;
+                for (var i:int = 1; i < n; i++)
+                {
+                    thisLabel = _labels[base + dir * i];
+                    spaceBetween =
+                        Math.abs(thisLabel.position - prevLabel.position) *
+                        axisLength;
+                    requiredSpace = (thisLabel.height + prevLabel.height) / 2;
+                    if (requiredSpace > spaceBetween)
+                    {
+                        skipCount++;
+                    }
+                    else
+                    {
+                        if (skipCount > maxSkipCount)
+                        {
+                            maxSkipCount = skipCount;
+                            firstIntervalLabel = prevLabel;
+                            lastIntervalLabel = _labels[base + dir * (i - 1)];
+                        }                       
+                        // If we're going vertical, we assume they are all
+                        // the same height, and just count until we get
+                        // an initial skip count.
+                        break;
+                        skipCount = 0;
+                        prevLabel = thisLabel;
+                    }
+                }
+
+                if (skipCount > maxSkipCount)
+                {
+                    maxSkipCount = skipCount;
+                    firstIntervalLabel = prevLabel;
+                    lastIntervalLabel = _labels[base + dir * (i  -1)];
+                }                       
+                
+                if (maxSkipCount)
+                {
+                    // Here's where we increase the interval.
+                    bLabelsReduced = reduceLabels(firstIntervalLabel.value,
+                                                  lastIntervalLabel.value);
+                }
+                else
+                {
+                    bSkipRequired = false;
+                    scalingRequired = false;
+                }
+            }
+            while (bSkipRequired && bLabelsReduced);
+        }
+
+        if (scalingRequired)
+        {
+            prevLabel = _labels[0];
+            // Scale down until they don't overlap.
+            n  = _labels.length;
+            for (i = 1; i < n; i++)
+            {
+                thisLabel = _labels[i];
+                spaceBetween = (thisLabel.position - prevLabel.position) *
+                               axisLength;
+                requiredSpace = (thisLabel.height + prevLabel.height) / 2;
+                scale = Math.min(scale, spaceBetween / requiredSpace);
+                prevLabel = thisLabel;
+            }
+        }
+
+        return { rotation: Math.PI/2, 
+                 left: verticalData.hlm,
+                 right: verticalData.hrm,
+                 scale: Math.max(0, scale), 
+                 staggered: false };            
+    }
+
+    /**
+     *  @private
+     */
+    private function measureHorizontalGutters(width:Number,
+                                              leftGutter:Number,
+                                              rightGutter:Number,
+                                              firstLabel:ARLabelData,
+                                              lastLabel:ARLabelData,
+                                              adjustable:Object):Object
+    {
+        // With staggered labels, it's possible to have a very long
+        // 2nd or 2nd-to-last label that pushes past the borders
+        // before the end labels do. We should be checking those too.
+
+        var labelAlignOffset:Number=  this.labelAlignOffset;
+        var axisLength:Number = width - leftGutter - rightGutter;
+
+        var LS:Number = firstLabel.width * labelAlignOffset;
+        var RS:Number = lastLabel.width * (1 - labelAlignOffset);
+        var P1:Number = firstLabel.position;
+        var P2:Number = 1 - lastLabel.position;
+
+        var lhm:Number;
+        var rhm:Number;
+
+        // First, see if we need to push the gutters in.
+        var leftOverlaps:Boolean = adjustable.left != false &&
+                                   LS > leftGutter + P1 * axisLength;
+
+        var rightOverlaps:Boolean = adjustable.right != false &&
+                                    RS > rightGutter + P2 * axisLength;
+
+        if (leftOverlaps == false && rightOverlaps == false)
+        {
+            lhm = leftGutter;
+            rhm = rightGutter;
+        }
+        else if (leftOverlaps == true && rightOverlaps == false)
+        {
+            axisLength = (width - rightGutter - LS) / (1 - P1);
+            lhm = width - rightGutter - axisLength;
+            rhm = rightGutter;
+            rightOverlaps = RS > rhm + P2 * axisLength;             
+        }
+        else if (leftOverlaps == false && rightOverlaps == true)
+        {
+            axisLength = (width - leftGutter - RS) / (1 - P2);
+            lhm = leftGutter;
+            rhm = width - leftGutter - axisLength;
+            leftOverlaps = LS > lhm + P1 * axisLength;
+        }
+        
+        if (leftOverlaps && rightOverlaps)
+        {
+            axisLength = (width - LS - RS) / (1 - P1 - P2);
+
+            lhm = LS - P1 * axisLength;
+            rhm = RS - P2 * axisLength;
+        }
+
+        return { horizontalleftGutter: lhm,
+                 horizontalrightGutter: rhm,
+                 minimumAxisLength: width - lhm - rhm };
+    }
+    
+    /**
+     *  @private
+     */
+    private function calcHorizontalSpacing(width:Number,
+                                           horizontalGutterData:Object,
+                                           targetHeight:Number,
+                                           firstLabel:ARLabelData,
+                                           lastLabel:ARLabelData,
+                                           canDropLabels:Boolean,
+                                           adjustable:Object,
+                                           minimumAxisLength:Number):Object
+    {
+        var horizontalleftGutter:Number =
+            horizontalGutterData.horizontalleftGutter;
+        var horizontalrightGutter:Number =
+            horizontalGutterData.horizontalrightGutter;
+
+        var horizontalScale:Number = 1;
+
+        // Now check to see if we need to scale
+        // to make up for max height violations.
+        if (!isNaN(targetHeight))
+            horizontalScale = Math.min(1, targetHeight / _maxLabelHeight);          
+
+        var thisLabel:ARLabelData;
+        var prevLabel:ARLabelData = firstLabel;
+        
+        var n:int = _labels.length;
+        
+        var axisLength:Number = width - horizontalleftGutter -
+                                horizontalrightGutter;
+
+        var spaceBetween:Number;
+        var requiredSpace:Number;
+        var scalingRequired:Boolean = true;
+        
+        // If we can drop labels, do that.
+        if (canDropLabels)
+        {
+            var base:int;
+            var dir:int;
+            var maxSkipCount:int = 0;
+            var bLabelsReduced:Boolean;
+            var bSkipRequired:Boolean = true;
+
+            do
+            {
+                maxSkipCount = 0;
+                var skipCount:int = 0;
+                
+                if (_horizontal)
+                {
+                    if (_labels.length > 0)
+                        prevLabel = _labels[0];
+                    base = 0;
+                    dir = 1;                    
+                }
+                else
+                {
+                    if (_labels.length > 0)
+                        prevLabel = _labels[_labels.length - 1];
+                    base = _labels.length - 1;
+                    dir = -1;
+                }
+
+                var firstIntervalLabel:Object;
+                var lastIntervalLabel:Object;
+                n  = _labels.length;            
+                for (var i:int = 1; i < n; i++)
+                {
+                    thisLabel = _labels[base + dir * i];
+                    spaceBetween =
+                        Math.abs(thisLabel.position - prevLabel.position) *
+                        axisLength;
+                    requiredSpace = (thisLabel.width + prevLabel.width) / 2;
+                    if (requiredSpace > spaceBetween)
+                    {
+                        skipCount++;
+                    }
+                    else
+                    {
+                        if (skipCount > maxSkipCount)
+                        {
+                            maxSkipCount = skipCount;
+                            firstIntervalLabel = prevLabel;
+                            lastIntervalLabel = _labels[base + dir * (i - 1)];
+                        }                       
+                        skipCount = 0;
+                        prevLabel = thisLabel;
+                    }
+                }
+    
+                if (skipCount > maxSkipCount)
+                {
+                    maxSkipCount = skipCount;
+                    firstIntervalLabel = prevLabel;
+                    lastIntervalLabel = _labels[base + dir * (i - 1)];
+                }                       
+                
+                if (maxSkipCount)
+                {
+                    // Here's where we increase the interval.
+                    bLabelsReduced = reduceLabels(firstIntervalLabel.value,
+                                                  lastIntervalLabel.value);
+                }
+                else
+                {
+                    bSkipRequired = false;
+                    scalingRequired = false;                    
+                }
+            }
+            while (bSkipRequired && bLabelsReduced);
+        }
+        
+        if (scalingRequired)
+        {
+            if (adjustable.left == false)
+            {
+                horizontalScale = Math.min(horizontalScale,
+                    (horizontalleftGutter +
+                     firstLabel.position * axisLength) /
+                    (firstLabel.width / 2));                
+            }
+
+            if (adjustable.right == false)
+            {
+                horizontalScale = Math.min(horizontalScale,
+                    (horizontalrightGutter +
+                     (1 - lastLabel.position) * axisLength) /
+                    (lastLabel.width / 2));             
+            }
+
+            // Never mind, we'll have to scale it..
+            prevLabel = _labels[0];
+            n = _labels.length;
+            for (i = 1; i < n; i++)
+            {
+                thisLabel = _labels[i];
+                spaceBetween = (thisLabel.position - prevLabel.position) *
+                               axisLength;
+                requiredSpace = (thisLabel.width + prevLabel.width) / 2;
+                horizontalScale = Math.min(horizontalScale,
+                                           spaceBetween / requiredSpace);
+                prevLabel = thisLabel;
+            }
+        }
+        return { rotation: 0, 
+                 left: horizontalleftGutter,
+                 right: horizontalrightGutter,
+                 scale: Math.max(0, horizontalScale), 
+                 staggered: false };            
+    }
+    
+    /**
+     *  @private
+     */
+    private function calcStaggeredSpacing(width:Number,
+                                          horizontalGutterData:Object,
+                                          targetHeight:Number,
+                                          firstLabel:ARLabelData,
+                                          lastLabel:ARLabelData,
+                                          canDropLabels:Boolean,
+                                          adjustable:Object):Object
+    {
+        // We're assuming that we never can layout staggered
+        // without being able to layout flat horizontal.
+        var staggeredleftGutter:Number = horizontalGutterData.horizontalleftGutter;
+        var staggeredrightGutter:Number = horizontalGutterData.horizontalrightGutter;
+        var staggeredScale:Number;
+        var axisLength:Number = width - staggeredleftGutter - staggeredrightGutter;
+        
+        // Check for scale to correct for max height violations.
+        if (!isNaN(targetHeight))
+            staggeredScale = Math.min(1, targetHeight / (2 * _maxLabelHeight));
+        else
+            staggeredScale = 1;
+
+        var skipLabel:ARLabelData = firstLabel;
+        lastLabel = _labels[1];
+
+        if (adjustable.left == false)
+        {
+            staggeredScale = Math.min(
+                staggeredScale,
+                staggeredleftGutter / (firstLabel.width / 2));              
+        }
+
+        if (adjustable.right == false)
+        {
+            staggeredScale = Math.min(
+                staggeredScale,
+                staggeredrightGutter / (lastLabel.width / 2));              
+        }
+
+        // Now check for scaling due to overlap.
+        // Note that we don't drop labels here...
+        // if we can drop labels, then we always prefer horizontal
+        // to staggered, and currently there's no way to force staggering.
+        var n:int  = _labels.length;
+        for (var i:int = 2; i < n; i++)
+        {
+            var thisLabel:ARLabelData = _labels[i];
+            var spaceBetween:Number =
+                (thisLabel.position - skipLabel.position) * axisLength;
+            var requiredSpace:Number = (thisLabel.width + skipLabel.width) / 2;
+            staggeredScale = Math.min(staggeredScale,
+                                      spaceBetween / requiredSpace);
+            skipLabel = lastLabel;
+            lastLabel = thisLabel;
+        }
+
+        return { rotation: 0, 
+                 left: staggeredleftGutter,
+                 right:staggeredrightGutter,
+                 scale: Math.max(0, staggeredScale), 
+                 staggered: true };         
+    }
+
+    /**
+     *  @private
+     */
+    private function measureAngledGutters(width:Number,
+                                          labelRotation:Number,
+                                          targetHeight:Number,
+                                          firstLabel:ARLabelData,
+                                          leftGutter:Number,
+                                          rightGutter:Number,
+                                          adjustable:Object):Object
+    {
+        var sint:Number;
+        var cost:Number;
+        var angle:Number;
+        var angledleftGutter:Number = leftGutter;
+        var angledrightGutter:Number = rightGutter;
+        var axisLength:Number;
+        var sigLabel:ARLabelData;
+        var maxPosition:Number;
+        var preferredPosition:Number;
+        var minPosition:Number;
+        var angledScale:Number = 1;
+        var minDist:Number = 1;
+        var lastLabel:ARLabelData = _labels[0];
+        var n:int = _labels.length;
+        var i:int;
+        
+        for (i = 1; i < n; i++)
+        {
+            var thisLabel:ARLabelData = _labels[i];
+            minDist = Math.min(minDist,
+                               thisLabel.position - lastLabel.position);
+            lastLabel = thisLabel;
+        }
+
+        if (!isNaN(labelRotation))
+            angle = labelRotation / 180 * Math.PI;
+        else if (_horizontal == false)
+            angle = Math.PI / 2;
+
+        // This code now only applies if labelRotation is >= 0, or null.
+        // We need to check the right side if angle is negative.
+        if (adjustable.left == false &&
+            (labelRotation >= 0 || isNaN(labelRotation)))
+        {
+            axisLength = width - angledleftGutter - angledrightGutter;
+
+            if (isNaN(angle))
+            {
+                sint = _maxLabelHeight / (minDist * axisLength);
+
+                if (sint >= 1)
+                {
+                    angle = Math.PI / 2;
+                    sint = 1;
+                    angledScale = Math.min(angledScale,
+                        (firstLabel.position * axisLength + angledleftGutter) /
+                        (firstLabel.height / 2));
+                }
+                else
+                {
+                    angle = Math.asin(sint);
+                    if (Math.cos(angle) * firstLabel.width >
+                        firstLabel.position * axisLength + angledleftGutter)
+                    {
+                        angle = Math.acos((firstLabel.position * axisLength +
+                                          angledleftGutter) / firstLabel.width);
+                        sint = Math.sin(angle);
+                    }
+
+                }
+            }
+            else
+            {
+                sint = Math.sin(angle);
+                if (sint < 1)
+                {
+                    angledScale = Math.min(angledScale,
+                        (firstLabel.position * axisLength + angledleftGutter) /
+                        (Math.cos(angle) * firstLabel.width));
+                }
+                else
+                {
+                    angledScale = Math.min(angledScale,
+                        (firstLabel.position * axisLength + angledleftGutter) /
+                        (firstLabel.height / 2));
+                }                   
+            }
+            
+            // Mow check to see what angle we'd need to make sure
+            // the leftmost label doesn't stick off the edge.
+            if (!isNaN(targetHeight))
+            {
+                angledScale = Math.min(angledScale, targetHeight /
+                    (_maxLabelWidth * sint +
+                     _maxLabelHeight * Math.cos(angle)));
+            }
+        }
+        else if (adjustable.right == false && (labelRotation < 0))
+        {
+            axisLength = width - angledleftGutter - angledrightGutter;
+
+            sint = Math.sin(-angle);
+            if (sint < 1)
+            {
+                angledScale = Math.min(angledScale,
+                    ((1 - lastLabel.position) * axisLength +
+                     angledrightGutter) /
+                    (Math.cos(angle) * lastLabel.width));
+            }
+            else
+            {
+                angledScale = Math.min(angledScale,
+                    ((1 - lastLabel.position) * axisLength +
+                     angledrightGutter) /
+                    (firstLabel.height / 2));
+            }               
+            
+            // Now check to see what angle we'd need to make sure
+            // the leftmost label doesn't stick off the edge.
+            if (!isNaN(targetHeight))
+            {
+                angledScale = Math.min(angledScale,
+                    targetHeight / (_maxLabelWidth * sint +
+                    _maxLabelHeight * Math.cos(-angle)));
+            }
+            
+        }
+        else if (angle > 0)
+        {
+            sint = Math.sin(angle);
+            cost = Math.cos(angle);
+
+            sigLabel = firstLabel;
+
+            if (!isNaN(targetHeight))
+            {
+                angledScale = Math.min(1,
+                    targetHeight / (_maxLabelWidth * sint));
+            }
+            
+            if (adjustable.right != false)
+            {
+                angledrightGutter = Math.max(angledrightGutter,
+                    _labels[n - 1].height / 2 * angledScale);
+            }
+            
+            axisLength = width - angledleftGutter - angledrightGutter;
+
+            for (i = 0; i < n; i++)
+            {
+                sigLabel = _labels[i];
+
+                // We should be scaling down if there's a max height.
+
+                // First find out what the minimum position
+                // this label is willing to be.
+                minPosition = cost * sigLabel.width * angledScale +
+                              sigLabel.height / 2 * angledScale * sint;
+                
+                // Now find out where the current gutters
+                // wants this label to fall.
+                preferredPosition = angledleftGutter +
+                                    axisLength * sigLabel.position;
+                if (minPosition > preferredPosition)
+                {
+                    // Adjust the left gutter accordingly.
+                    axisLength = (width - angledrightGutter - minPosition) /
+                                 (1 - sigLabel.position);
+                    angledleftGutter = width - axisLength - angledrightGutter;
+                }
+            }
+        }
+        else if (angle < 0)
+        {
+            sint = Math.sin(-angle);
+            cost = Math.cos(-angle);
+            
+            sigLabel = lastLabel;
+
+            if (!isNaN(targetHeight))
+            {
+                angledScale = Math.min(1,
+                    targetHeight / (_maxLabelWidth * sint));
+            }
+
+            if (adjustable.left != false)
+            {
+                angledleftGutter = Math.max(angledleftGutter,
+                    _labels[0].height / 2 * angledScale);
+            }
+            
+            axisLength = width - angledleftGutter - angledrightGutter;
+            
+            for (i = n - 1; i >= 0; i--)
+            {
+                sigLabel = _labels[i];
+                
+                // We should be scaling down if there's a max height.
+
+                // First find out what the minimum position
+                // this label is willing to be.
+                maxPosition = width -
+                              cost * sigLabel.width * angledScale -
+                              sint * sigLabel.height / 2 * angledScale;
+                
+                // Now find out where the current gutters
+                // wants this label to fall.
+                preferredPosition = angledleftGutter +
+                                    axisLength * sigLabel.position;
+                if (maxPosition < preferredPosition)
+                {
+                    // Adjust the left gutter accordingly.
+                    axisLength = (maxPosition - angledleftGutter) /
+                                 sigLabel.position;
+                    angledrightGutter = width - axisLength - angledleftGutter;
+                }
+            }
+        }
+        else
+        {
+            angledrightGutter = rightGutter;
+            angledleftGutter = leftGutter;
+			n = _labels.length;
+            for (i = 0; i < n; i++)
+            {
+                sigLabel = _labels[i];
+
+                var bOutsideBounds : Boolean = true;
+                
+                if (!isNaN(angle))
+                {
+                    bOutsideBounds = sigLabel.width * cost >
+                        angledleftGutter + axisLength * sigLabel.position;
+                }
+
+                if (bOutsideBounds)
+                {
+                    var upperBound:Number = Math.PI / 2;
+                    var lowerBound:Number = 0;
+
+                    angle = upperBound;
+
+                    do
+                    {
+                        sint = Math.sin(angle);
+                        cost = Math.cos(angle);
+
+                        if (!isNaN(targetHeight))
+                        {
+                            angledScale = Math.min(1, targetHeight /
+                                (_maxLabelWidth * sint +
+                                 _maxLabelHeight * cost));
+                        }
+
+                        minPosition = cost * sigLabel.width * angledScale;
+                        
+                        var currentPosition:Number = Math.max(minPosition,
+                            leftGutter + (width - leftGutter -
+                            rightGutter) * sigLabel.position);
+
+                        axisLength =
+                            (width - angledrightGutter - currentPosition) /
+                            (1 - sigLabel.position);
+
+                        angledleftGutter = Math.max(leftGutter,
+                            width - axisLength - angledrightGutter);
+
+                        var actualDistance:Number = minDist * axisLength;                   
+                        var stackedDistance:Number =
+                            _maxLabelHeight * angledScale / sint;
+
+                        var diff:Number = actualDistance - stackedDistance;                     
+                        if (diff > 0 && diff < 1)
+                        {
+                            break;
+                        }
+                        else if (actualDistance > stackedDistance)
+                        {
+                            // They're too far apart; let's lower the angle.
+                            if (lowerBound >= angle)
+                                break;
+                            upperBound = angle;
+                        }
+                        else
+                        {
+                            // Too close; let's raise the angle.
+                            if (upperBound <= angle)
+                                break;
+                            lowerBound = angle;
+                        }
+                        // sanity check.  sometimes, due to rounding errors, upper and lower bound never converge.
+                        // if it gets below one one-hundred-thousands of a radian, that's probably close enough.
+                        if (upperBound - lowerBound < .00001)
+                            break;
+                        angle = lowerBound + (upperBound - lowerBound) / 2;
+                    }
+                    while (1);
+                }
+            }
+
+            // If the current suggested angle is null,
+            // or pushes the current label out of bounds,
+            // then binary search until we find an angle that matches
+            // the angle suggested by the two closest labels.
+            // Make sure we take into account scaling
+            // as a result of the max height.
+        }
+
+        return { minimumAxisLength: width - angledleftGutter -
+                                    angledrightGutter,
+                 left: angledleftGutter,
+                 right: angledrightGutter,
+                 scale: angledScale,
+                 rotation: angle,
+                 sint: sint,
+                 minDist: minDist };
+    }
+
+    /**
+     *  @private
+     */
+    private function calcAngledSpacing(angledGutterData:Object):Object
+    {       
+        // At this point we know the AxisRenderer length,
+        // and the distance between labels.
+        // That means we can figure out how much we need to scale them down
+        // to make sure they don't run into each other.
+
+        var halfMaxStackedHeight:Number =
+            angledGutterData.sint *
+            angledGutterData.minDist *
+            angledGutterData.minimumAxisLength;
+
+        angledGutterData.scale = Math.max(0,
+            Math.min(angledGutterData.scale,
+            halfMaxStackedHeight / _maxLabelHeight));
+        
+        return angledGutterData;
+    }
+
+    /**
+     *  @private
+     */
+    private function updateCaches():void
+    {
+        if (_cacheDirty)
+        {
+            /*
+            _labelFormatCache = determineTextFormatFromStyles();
+
+            var sm:ISystemManager = systemManager as ISystemManager;
+            var embedFonts:Boolean = _canRotate =
+                sm.isFontFaceEmbedded(_labelFormatCache);
+            */
+            
+            if (!_labelRenderer)
+            {
+                _labelCache.properties =
+                    { styleName: this};
+            }
+            else
+            {
+                _labelCache.properties = {};
+            }           
+
+            _cacheDirty = false;
+        }       
+    }
+
+    /**
+     *  @private
+     */
+    private function drawLabels(showLine:Boolean):Number
+    {
+        var axisStroke:IStroke = getStyle("axisStroke");
+
+        var labelBottom:Number;     
+        var labelY:Number;
+        var xAdjustment:Number;
+        var ldi:ARLabelData;
+        var r:Number;
+        
+        renderLabels();
+        
+        var firstLabel:ARLabelData = _labels[0];
+
+        var baseline:Number;
+        if (_inverted)
+        {
+            baseline = _gutters.top -
+                       Number(showLine == true ? axisStroke.weight : 0) -
+                       tickSize(showLine);
+        }
+        else
+        {
+            baseline = unscaledHeight -
+                       _gutters.bottom +
+                       Number(showLine == true ? axisStroke.weight : 0) +
+                       tickSize(showLine);
+        }
+
+        var scale:Number = _labelPlacement.scale;
+        var n:int = _labels.length;
+        
+        // showLabels comes through CSS as a string
+        var showLabelsStyle:Object = getStyle("showLabels");
+        var showLabels:Boolean = showLabelsStyle != false &&
+                                 showLabelsStyle != "false";
+        
+        if (showLabels == false)
+            return baseline;
+        
+        // Place the labels.
+        // If they have no rotation, we need to center them,
+        // and potentially offset them (if they're staggered).
+        var hscale:Number = scale;
+        for (var i:int = 0; i < n; i++)
+        {
+            ldi = _labels[i];
+            ldi.instance.scaleX = ldi.instance.scaleY = hscale;
+        }
+        
+        var axisWidth:Number = unscaledWidth - _gutters.left - _gutters.right;
+        var labelGap:Number = getStyle("labelGap");
+        var alignOffset:Number = this.labelAlignOffset;
+
+        if (_labelPlacement.rotation == 0)
+        {
+            var oddLabelYOffset:Number = 0;
+
+            if (_labelPlacement.staggered)
+            {
+                oddLabelYOffset = scale * _maxLabelHeight *
+                                  (Number(_inverted ? -1 : 1));
+            }
+
+            if (_inverted)
+            {
+                labelY = baseline - labelGap - _maxLabelHeight * scale;
+                labelBottom = labelY - oddLabelYOffset;
+            }
+            else
+            {
+                labelY = baseline + labelGap;
+                labelBottom = labelY +
+                              _maxLabelHeight * scale +
+                              oddLabelYOffset;
+            }
+            
+            var staggerCount:int = 0;
+            for (i = 0; i < n; i++)
+            {
+                var thisLabel:ARLabelData = _labels[i];
+                
+                thisLabel.instance.rotation = 0;
+                thisLabel.instance.x = _gutters.left +
+                                       axisWidth * thisLabel.position -
+                                       thisLabel.width * scale * alignOffset;
+                thisLabel.instance.y = labelY + staggerCount * oddLabelYOffset;
+                
+                staggerCount = 1 - staggerCount;
+            }           
+        }           
+        else if (_labelPlacement.rotation > 0)
+        {
+            xAdjustment = 2 + Math.sin(_labelPlacement.rotation) *
+                          firstLabel.height * scale / 2;
+            
+            var c:Number;
+            var s:Number;
+                        
+            if (_inverted)
+            {
+                labelY = baseline - labelGap;
+
+                if (_horizontal) // top, positive
+                {
+                    r = _labelPlacement.rotation / Math.PI * 180;
+                    
+                    c = Math.cos(Math.abs(_labelPlacement.rotation));
+                    s = Math.sin(Math.abs(_labelPlacement.rotation));
+                    
+                    alignOffset = 1 - alignOffset;
+                    
+                    for (i = 0; i < n; i++)
+                    {
+                        ldi = _labels[i];
+
+                        ldi.instance.rotation = r;
+
+                        ldi.instance.x = _gutters.left +
+                                         axisWidth * ldi.position -
+                                         ldi.width * scale * c +
+                                         ldi.height * alignOffset * scale * s;
+
+                        ldi.instance.y = labelY -
+                                         ldi.width * scale * s -
+                                         ldi.height * alignOffset * scale * c;
+                    }
+
+                    labelBottom = labelY - _maxRotatedLabelHeight;
+                }
+                else // right, positive
+                {
+                    r = -90 -
+                        (90 - ((_labelPlacement.rotation) / Math.PI * 180));
+                    
+                    c = Math.cos(Math.abs(_labelPlacement.rotation));
+                    s = Math.sin(Math.abs(_labelPlacement.rotation));
+                    
+                    for (i = 0; i < n; i++)
+                    {
+                        ldi = _labels[i];
+
+                        ldi.instance.rotation = r;
+
+                        ldi.instance.x = _gutters.left +
+                                         axisWidth * ldi.position -
+                                         ldi.height * alignOffset * scale * s;
+
+                        ldi.instance.y = labelY +
+                                         ldi.height * alignOffset * scale * c;
+						
+                    }
+
+                    labelBottom = labelY - _maxRotatedLabelHeight;
+                }       
+            }
+            else // bottom or left, positive values
+            {
+                c = Math.cos(Math.abs(_labelPlacement.rotation));
+                s = Math.sin(Math.abs(_labelPlacement.rotation));
+                                
+                r = -_labelPlacement.rotation / Math.PI * 180;
+                labelY = baseline + labelGap;
+				var sparkLabelClass:Class;
+				try
+				{
+					if(getDefinitionByName("spark.components.Label"))
+					{
+						sparkLabelClass = Class(getDefinitionByName("spark.components.Label"));
+					}
+				}
+				catch(e:Error)
+				{
+					// We need not do any thing here because we came here for projects which do not have spark.swc
+					// It might be an MX-only or in compatible mode and hence using MX Label
+				}
+				for (i = 0; i < n; i++)
+				{
+					ldi = _labels[i];
+					
+					ldi.instance.rotation = r;
+					
+                    ldi.instance.x = _gutters.left +
+                                     axisWidth * ldi.position -
+                                     ldi.width * scale * c -
+                                     ldi.height * alignOffset * scale * s;
+					
+					ldi.instance.y = labelY +
+									 ldi.width * scale * s -
+									 ldi.height * alignOffset * scale * c;
+					
+                    /*
+					if(sparkLabelClass && ldi.instance is sparkLabelClass && layoutDirection == LayoutDirection.RTL)
+					{
+						ldi.instance.x = ldi.instance.x - ldi.width;
+						ldi.instance.y = labelY;
+					}*/
+                }
+                
+                labelBottom = labelY + _maxRotatedLabelHeight;
+            }
+        }
+        else // labelRotation < 0
+        {
+            if (_inverted)
+            {
+                if (_horizontal) //top, negative
+                {
+                    r = _labelPlacement.rotation / Math.PI * 180;
+                    
+                    c = Math.cos(Math.abs(_labelPlacement.rotation));
+                    s = Math.sin(Math.abs(_labelPlacement.rotation));
+                    
+                    labelY = baseline - labelGap;
+
+                    for (i = 0; i < n; i++)
+                    {
+                        ldi = _labels[i];
+
+                        ldi.instance.rotation = r;
+                        
+                        ldi.instance.x = _gutters.left +
+                                         axisWidth * ldi.position -
+                                         ldi.height * alignOffset * scale * s;
+                        
+                        ldi.instance.y = labelY -
+                                         ldi.height * alignOffset * scale * c;
+                    }
+
+                    labelBottom = labelY + _maxRotatedLabelHeight;
+                }
+                else // right, negative
+                {
+                    r = _labelPlacement.rotation / Math.PI * 180;
+                    
+                    c = Math.cos(Math.abs(_labelPlacement.rotation));
+                    s = Math.sin(Math.abs(_labelPlacement.rotation));
+
+                    labelY = baseline - labelGap;
+
+                    for (i = 0; i < n; i++)
+                    {
+                        ldi = _labels[i];
+
+                        ldi.instance.rotation = r;
+
+                        ldi.instance.x = _gutters.left +
+                                         axisWidth * ldi.position -
+                                         ldi.height * alignOffset * scale * s;
+
+                        ldi.instance.y = labelY -
+                                         ldi.height * alignOffset * scale * c;
+                    }
+                }
+            }
+            else
+            {
+                if (_horizontal) // bottom, negative
+                {
+                    r = -_labelPlacement.rotation / Math.PI * 180;
+
+                    c = Math.cos(Math.abs(_labelPlacement.rotation));
+                    s = Math.sin(Math.abs(_labelPlacement.rotation));
+
+                    labelY = baseline + labelGap;
+
+                    for (i = 0; i < n; i++)
+                    {
+                        ldi = _labels[i];
+
+                        ldi.instance.rotation = r;
+
+                        ldi.instance.x =_gutters.left +
+                                        axisWidth * ldi.position +
+                                        s * ldi.height * scale * alignOffset;
+
+                        ldi.instance.y = labelY -
+                                         c * ldi.height * scale * alignOffset;
+                    }
+
+                    labelBottom = labelY + _maxRotatedLabelHeight;
+                }
+                else // left, negative
+                {
+                    r = -180 - _labelPlacement.rotation / Math.PI * 180;
+
+                    c = Math.cos(Math.abs(_labelPlacement.rotation + Math.PI/2));
+                    s = Math.sin(Math.abs(_labelPlacement.rotation + Math.PI/2));
+
+                    labelY = baseline + labelGap;
+
+                    for (i = 0; i < n; i++)
+                    {
+                        ldi = _labels[i];
+
+                        ldi.instance.rotation = r;
+
+                        ldi.instance.x = _gutters.left +
+                                         axisWidth * ldi.position -
+                                         ldi.height * alignOffset * scale * c +
+                                         ldi.width * scale * s;
+
+                        ldi.instance.y = labelY +
+                                         ldi.height * alignOffset * scale * s +
+                                         ldi.width * scale * c;
+                    }
+					labelBottom = labelY + _maxRotatedLabelHeight;
+                }
+            }
+        }
+        return labelBottom;
+    }
+
+    /**
+     *  @private
+     */
+    private function renderLabels():void
+    {
+        var visCount:int = 0;
+        var i:int;
+        var labelData:ARLabelData;
+        
+        // showLabels comes through CSS as a string
+        var showLabelsStyle:Object = getStyle("showLabels");
+        var showLabels:Boolean = showLabelsStyle != false &&
+                                 showLabelsStyle != "false";
+		var sparkLabelClass:Class;
+		try
+		{
+			if(getDefinitionByName("spark.components.Label"))
+			{
+				sparkLabelClass = Class(getDefinitionByName("spark.components.Label"));
+			}
+		}
+		catch(e:Error)
+		{
+			// We need not do any thing here because we came here for projects which do not have spark.swc
+			// It might be an MX-only or in compatible mode and hence using MX Label
+		}
+        
+        if (showLabels == false)
+        {
+            _labelCache.count = 0;
+        }
+        else
+        {
+            _labelCache.count = _labels.length;
+            var n:int = _labels.length;
+            if (!_labelRenderer)
+            {
+                for (i = 0; i < n; i++)
+                {
+                    labelData = _labels[i];
+                    labelData.instance = _labelCache.instances[visCount++];
+					var label:Object = labelData.instance;// as Label;
+                    
+					if(label.hasOwnProperty("htmlText"))
+						label.htmlText = labelData.text;
+					else
+                    label.text = labelData.text;
+					if(sparkLabelClass && labelData.instance is sparkLabelClass)
+					{
+						label.setStyle("paddingTop", 5);
+						label.setStyle("paddingLeft", 2);
+					}
+                    labelData.instance.width = labelData.width;
+                    labelData.instance.height = labelData.height;
+                }
+            }
+            else
+            {
+                for (i; i < n; i++)
+                {
+                    labelData = _labels[i];
+                    labelData.instance = _labelCache.instances[visCount++];
+                    
+                    (labelData.instance as IDataRenderer).data =
+                        labelData.value;
+                    
+                    (labelData.instance as IFlexDisplayObject).setActualSize(
+                        labelData.width * _labelPlacement.scale,
+                        labelData.height * _labelPlacement.scale);
+                }           
+            }
+        }
+    }
+
+    /**
+     *  @private
+     */
+    private function drawTitle(labelBottom:Number):void
+    {
+        // If we have a title, we need to create it here.
+        if (_axis.title == "")
+        {
+            if (_titleField)
+                _titleField.visible = false;
+            return;
+        }
+        
+        _titleField.visible = true;
+
+        _titleField.setActualSize(_titleField.measuredWidth,
+                                  _titleField.measuredHeight);
+        
+        /*
+        var m:Matrix = _titleField.transform.matrix;
+        m.a = Math.min(1,
+            (unscaledWidth - _gutters.left - _gutters.right) /
+            _titleField.measuredWidth);
+        if (m.a < 0)
+            m.a = 0;
+        m.d = Math.min(1, 1.3 * m.a);
+        _titleField.transform.matrix = m;
+        */
+        
+        _titleField.y = Number(_inverted ?
+                               labelBottom - _titleField.measuredHeight :
+                               labelBottom);
+
+        _titleField.x = _gutters.left + (unscaledWidth - _gutters.left -
+                        _gutters.right - _titleField.measuredWidth/* * m.a*/) / 2;
+    }
+
+    /**
+     *  @private
+     */
+    private function drawAxis(showLine:Boolean):void
+    {
+        var axisStroke:IStroke = getStyle("axisStroke");
+        
+        if (showLine == true)
+        {
+            var w:Number = Number(axisStroke.weight == 0 ?
+                                  1 :
+                                  axisStroke.weight);
+
+            var baseline:Number = Number(_inverted ?
+                                         _gutters.top - w :
+                                         unscaledHeight - _gutters.bottom);
+
+            graphics.lineStyle(0, 0, 0);
+
+            var leftJoin:Number = 0;
+            var rightJoin:Number = 0;
+
+            if (_horizontal && _otherAxes)
+            {
+            	var n:int  = _otherAxes.length;
+                for (var i:int = 0; i < n; i++)
+                {
+                    var otherAxis:IAxisRenderer = _otherAxes[i];
+                    var otherLineStyle:IStroke;
+                    
+                    var otherShowLine:Boolean;
+                    if (otherAxis is AxisRenderer)
+                    {
+                        otherLineStyle = AxisRenderer(otherAxis).getStyle("axisStroke");
+                        otherShowLine = AxisRenderer(otherAxis).getStyle("showLine");
+                    }
+                    var placement:String = otherAxis.placement;
+                    
+                    if (otherLineStyle && otherShowLine)
+                    {
+                        if (placement == "right" || placement == "top")
+                            rightJoin += otherLineStyle.weight;
+                        else
+                            leftJoin += otherLineStyle.weight;
+                    }
+                }
+            }
+            
+            graphics.moveTo(_gutters.left - leftJoin,
+                            baseline + w / 2);
+
+            axisStroke.apply(graphics,null,null);
+			
+            graphics.lineTo(unscaledWidth - _gutters.right + rightJoin,
+                            baseline + w / 2);
+        }
+    }
+    
+    /**
+     *  @private
+     */
+    private function drawTicks(showLine:Boolean):Number
+    {
+        var axisStroke:IStroke = getStyle("axisStroke");
+
+        var axisWeight:Number = Number(showLine == true ?
+                                       axisStroke.weight :
+                                       0);
+
+        var baseline:Number = Number(_inverted ?
+                                     _gutters.top :
+                                     unscaledHeight - _gutters.bottom);
+
+        var w:Number;
+        var a:Number;
+        var left:Number;
+        var right:Number;
+        var axisStart:Number;
+        var axisLength:Number;
+        var tickStart:Number;
+        var tickEnd:Number;
+        var tickLen:Number = getStyle("tickLength");
+        var tickPlacement:String = getStyle("tickPlacement");
+        var oldWeight:Number;
+        
+        if (_inverted)
+        {
+            tickLen *= -1;
+            axisWeight *= -1;
+        }
+
+        var tickStroke:IStroke = getStyle("tickStroke");
+        
+        switch (tickPlacement)
+        {
+            case "inside":
+            {
+                tickStart = baseline - tickLen;
+                tickEnd = baseline;
+                break;
+            }
+
+            case "outside": 
+            default:
+            {
+                tickStart  = baseline + axisWeight;
+                tickEnd = baseline + axisWeight + tickLen; 
+                break;
+            }
+
+            case "cross":
+            {
+                tickStart = baseline -tickLen;
+                tickEnd = baseline + axisWeight + tickLen;
+                break;
+            }
+
+            case "none":
+            {
+                tickStart  = 0;
+                tickEnd = 0;
+                break;
+            }
+        }
+
+        var tickCount:int = _ticks.length;
+		var n:int;
+        axisStart = _gutters.left;
+        axisLength = unscaledWidth - _gutters.left - _gutters.right;
+
+        var g:Graphics = graphics;
+        
+        if (tickStart != tickEnd)
+        {
+            oldWeight = tickStroke.weight;
+            tickStroke.weight = _labelPlacement.scale *
+                Number(tickStroke.weight == 0 ? 1 : tickStroke.weight);
+
+            tickStroke.apply(g,null,null);
+            tickStroke.weight = oldWeight;
+			
+			n  = tickCount;
+            for (var i:int = 0; i < n; i++)
+            {
+                left = axisStart + axisLength * _ticks[i];
+                g.moveTo(left, tickStart);
+                g.lineTo(left, tickEnd);
+            }
+
+        }   
+
+        var minorTickStroke:IStroke = getStyle("minorTickStroke");
+
+        axisStart = _gutters.left;
+        axisLength = unscaledWidth - _gutters.left - _gutters.right;
+
+        tickLen = getStyle("minorTickLength");
+        tickPlacement = getStyle("minorTickPlacement");
+        tickStart = tickEnd = 0;
+        
+        if (_inverted)
+            tickLen *= -1;
+
+        switch (tickPlacement)
+        {
+            case "inside":
+            {
+                tickStart = baseline - tickLen;
+                tickEnd = baseline;
+                break;
+            }
+
+            case "outside": 
+            default:
+            {
+                tickStart  = baseline + axisWeight;
+                tickEnd = baseline + axisWeight + tickLen; 
+                break;
+            }
+
+            case "cross":
+            {
+                tickStart = baseline -tickLen;
+                tickEnd = baseline + axisWeight + tickLen;
+                break;
+            }
+
+            case "none":
+            {
+                tickStart  = 0;
+                tickEnd = 0;
+                break;
+            }
+        }
+
+        if (tickStart != tickEnd)
+        {
+            var minorTicks:Array /* of Number */ = _minorTicks;
+            tickCount = minorTicks ? minorTicks.length : 0;
+
+            oldWeight = minorTickStroke.weight;
+            minorTickStroke.weight = _labelPlacement.scale *
+                Number(minorTickStroke.weight == 0 ? 1 : minorTickStroke.weight);
+
+            minorTickStroke.apply(g,null,null);
+            minorTickStroke.weight = oldWeight;
+			
+			n = tickCount;
+            for (i = 0; i < n; i++)
+            {
+                left = axisStart + axisLength * minorTicks[i];
+                g.moveTo(left, tickStart);
+                g.lineTo(left, tickEnd);
+            }
+        }
+
+        return baseline + tickEnd;
+    }
+
+    /**
+     *  @private
+     */
+    private function get labelAlignOffset():Number  
+    {
+        var result:Number;
+        var labelAlign:String = getStyle("labelAlign");
+
+        switch (labelAlign)
+        {
+            case "left":
+            case "top":
+            {
+                result = 1;
+                break;
+            }
+
+            case "right":
+            case "bottom":
+            {
+                result= 0;
+                break;
+            }
+
+            case "center":
+            default:
+            {
+                result = 0.5;
+                break;
+            }
+        }
+
+        return result;
+    }
+    
+    /**
+     *  @private
+     */
+    private function updateRotation():void
+    {
+        rotation = Number(_horizontal ? 0 : 90);
+    }
+
+    /**
+     *  @private
+     */
+    private function processAxisLabels(newLabelData:AxisLabelSet):Boolean
+    {
+        var n:int;
+        var labelValues:Array /* of String */ = [];
+        var bUseRenderer:Boolean =  (_labelRenderer != null);
+        var i:int;
+        
+        _supressInvalidations++;
+        n = newLabelData.labels.length;
+
+        _labels = [];
+        
+        // Initialize the labelvalues with the text.
+        for (i = 0; i < n; i++)
+        {
+            labelValues.push(newLabelData.labels[i].text);
+        }
+
+        if (newLabelData != _axisLabelSet)
+        {
+            if (_labelFunction != null)
+            {
+                labelValues = [];
+                for (i = 0; i < n; i++)
+                {
+                    labelValues.push(_labelFunction(this,newLabelData.labels[i].text));
+                }
+            }
+        }
+
+        var maxLabelWidth:Number = 0;
+        var maxLabelHeight:Number = 0;
+        var ltext:AxisLabel; 
+        var labelData:ARLabelData;
+        
+        if (!bUseRenderer)
+        {       
+            var systemManager:ISystemManager = systemManager as ISystemManager;
+            var measuringField:IUITextField = _measuringField as IUITextField;
+            if (!_measuringField)
+            {
+                measuringField = IUITextField(/*createInFontContext(UITextField)*/ new UITextField);
+                _measuringField = UIComponent(measuringField);
+            }
+            
+            COMPILE::SWF
+            {
+            var tf:UITextFormat = determineTextFormatFromStyles();
+            //measuringField.defaultTextFormat = tf;
+            measuringField.setTextFormat(tf);
+            //measuringField.multiline = true;
+
+            // this information is carried around in the UITextFormat, but not automatically applied.
+            // at some future date, this code should not need to set styles directly, but rather just inherit them through the style system.
+            //measuringField.antiAliasType = tf.antiAliasType;
+            //measuringField.gridFitType = tf.gridFitType;
+            //measuringField.sharpness = tf.sharpness;
+            //measuringField.thickness = tf.thickness;
+            
+            //measuringField.autoSize = "left";
+            //measuringField.embedFonts =
+            //    systemManager && systemManager.isFontFaceEmbedded(tf);
+            }
+        }
+        else
+        {
+            var measuringLabel:IUIComponent = _measuringField as IUIComponent;
+            if (!measuringLabel)
+            {
+                measuringLabel = _labelRenderer.newInstance();
+                _measuringField = measuringLabel as UIComponent;
+                if (measuringLabel is ISimpleStyleClient)
+                    (measuringLabel as ISimpleStyleClient).styleName = this;
+                measuringLabel.visible = false;
+                addChild(UIComponent(measuringLabel));
+            }
+
+            var ilcMeasuringLabel:ILayoutManagerClient =
+                measuringLabel as ILayoutManagerClient;
+
+            var doMeasuringLabel:IDataRenderer =
+                measuringLabel as IDataRenderer;
+        }
+        
+        if (_horizontal)
+        {
+            for (i = 0; i < n; i++)
+            {
+                ltext = newLabelData.labels[i];
+                labelData = new ARLabelData(ltext, ltext.position, labelValues[i]);
+                
+                if (!bUseRenderer)
+                {
+                    measuringField.htmlText = labelValues[i];
+                    
+                    labelData.width = measuringField.width + 5;
+                    labelData.height = measuringField.height;
+                }
+                else
+                {
+                    doMeasuringLabel.data = ltext;
+                    
+                    if (ilcMeasuringLabel)
+                        ilcMeasuringLabel.validateSize(true);
+
+                    labelData.width = measuringLabel.measuredWidth + 5;
+                    labelData.height = measuringLabel.measuredHeight;                                           
+                }
+
+                maxLabelWidth = Math.max(maxLabelWidth, labelData.width);
+                maxLabelHeight = Math.max(maxLabelHeight, labelData.height);
+                
+                _labels[i] = labelData;                         
+            }
+
+            _ticks = newLabelData.ticks == null ?
+                     [] :
+                     newLabelData.ticks;
+
+            _minorTicks = newLabelData.minorTicks == null ?
+                          [] :
+                          newLabelData.minorTicks;
+        }
+        else
+        {
+            var base:int = n - 1;
+            for (i = 0; i < n; i++)
+            {
+                ltext = newLabelData.labels[i];
+                labelData = new ARLabelData(ltext,1-ltext.position, labelValues[i]);
+
+                if (!bUseRenderer)
+                {
+                    measuringField.htmlText = labelValues[i];
+                    
+                    labelData.width = measuringField.width + 5;
+                    labelData.height = measuringField.height;
+                }
+                else
+                {
+                    doMeasuringLabel.data = ltext;
+                    
+                    if (ilcMeasuringLabel)
+                        ilcMeasuringLabel.validateSize(true);
+    
+                    labelData.width = measuringLabel.measuredWidth + 5;
+                    labelData.height = measuringLabel.measuredHeight;                                           
+                }
+
+                maxLabelWidth = Math.max(maxLabelWidth, labelData.width);
+                maxLabelHeight = Math.max(maxLabelHeight, labelData.height);
+                
+                _labels[base - i] = labelData;                          
+            }
+
+            _ticks = [];
+            if (newLabelData.ticks)
+            {
+                var forwardTicks:Array /* of Number */ = newLabelData.ticks;
+                n = forwardTicks.length;
+                for (i = n - 1; i >= 0; i--) 
+                {
+                    _ticks.push(1 - forwardTicks[i]);
+                }
+            }
+
+            _minorTicks = [];
+            if (newLabelData.minorTicks)
+            {
+                forwardTicks = newLabelData.minorTicks;
+                n = forwardTicks.length;
+                for (i = n - 1; i >= 0; i--) 
+                {
+                    _minorTicks.push(1 - forwardTicks[i]);
+                }
+            }
+        }
+
+        _maxLabelWidth = maxLabelWidth;
+        _maxLabelHeight = maxLabelHeight;
+        
+        _forceLabelUpdate = false;
+
+        _supressInvalidations--;
+
+        return newLabelData.accurate == true;
+    }
+    
+    /**
+     *  @private
+     */
+    private function reduceLabels(intervalStart:AxisLabel,
+                                  intervalEnd:AxisLabel):Boolean
+    {
+        var newLabelData:AxisLabelSet =
+            _axis.reduceLabels(intervalStart, intervalEnd);
+
+        if (!newLabelData || newLabelData == _axisLabelSet || newLabelData.labels.length >= _axisLabelSet.labels.length)
+            return false;
+
+        processAxisLabels(newLabelData);
+
+        _axisLabelSet = newLabelData;
+
+        return true;
+    }
+
+    /**
+     *  @private
+     */
+    private function tickSize(showLine:Boolean):Number
+    {
+        var tickLength:Number = getStyle("tickLength");
+        var tickPlacement:String = getStyle("tickPlacement");
+        var axisStroke:IStroke = getStyle("axisStroke");
+        var rv:Number = 0;
+        
+        switch (tickPlacement)
+        {           
+            case "cross":
+            {
+                if (showLine)
+                    rv = tickLength + axisStroke.weight;
+                else
+                    rv = tickLength;
+                break;
+            }
+
+            case "inside":
+            {
+                rv = 0;
+                break;
+            }
+
+            case "none":
+            {
+                rv = 0;
+                break;
+            }
+
+            default:
+            case "outside": 
+            {
+                rv = tickLength;
+                break;
+            }
+        }
+
+        return rv;
+    }
+
+    /**
+     *  @private
+     *  accessor function for automation
+     */
+    mx_internal function getAxisLabelSet():AxisLabelSet
+    {
+        return _axisLabelSet;
+    }
+    
+    private function setupMouseDispatching():void
+    {
+        if (_highlightElements)
+        {
+            addEventListener(MouseEvent.MOUSE_OVER, mouseOverHandler);
+            addEventListener(MouseEvent.MOUSE_OUT, mouseOutHandler);
+            addEventListener(MouseEvent.MOUSE_MOVE, mouseOverHandler);
+        }
+        else
+        {
+            removeEventListener(MouseEvent.MOUSE_OVER, mouseOverHandler);
+            removeEventListener(MouseEvent.MOUSE_OUT, mouseOutHandler);
+            removeEventListener(MouseEvent.MOUSE_MOVE, mouseOverHandler);
+        }
+    }
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Event handlers
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    private function axisChangeHandler(event:Event):void
+    {
+        if (chart)
+            chart.invalidateDisplayList();
+
+        invalidateDisplayList();
+    }
+
+    /**
+     *  @private
+     */
+    private function titleChangeHandler(event:Event):void
+    {
+        if (chart)
+            chart.invalidateDisplayList();
+
+        invalidateDisplayList();        
+    } 
+   
+    
+    /**
+     *  @private
+     */
+    private function mouseOutHandler(event:MouseEvent):void
+    {
+        AxisBase(_axis).highlightElements(false);
+    }
+    
+    /**
+     *  @private
+     */
+    private function mouseOverHandler(event:MouseEvent):void
+    {
+        AxisBase(_axis).highlightElements(true);
+    }
+
+}
+
+}
+
+////////////////////////////////////////////////////////////////////////////////
+
+import mx.core.UIComponent;
+
+import mx.charts.AxisLabel;
+import mx.styles.ISimpleStyleClient;
+
+/**
+ *  @private
+ */
+class ARLabelData
+{
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Constructor.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function ARLabelData(value:AxisLabel, position:Number, text:String)
+    {
+        super();
+
+        this.value = value;
+        this.position = position;
+        this.text = text;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    public var value:AxisLabel;
+
+    /**
+     *  @private
+     *  Copied from value for performance.
+     */
+    public var position:Number;
+    
+    /**
+     *  @private
+     */
+    public var width:Number;
+    
+    /**
+     *  @private
+     */
+    public var height:Number;
+    
+    /**
+     *  @private
+     */
+    public var instance:UIComponent;
+    
+    /**
+     *  @private
+     *  Modified version of value.text as part of AxisRenderer's label function
+     */
+    public var text:String;
+}
+
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/BarChart.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/BarChart.as
index d924e8c..5623b95 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/BarChart.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/BarChart.as
@@ -1,48 +1,868 @@
-////////////////////////////////////////////////////////////////////////////////
-//
-//  Licensed to the Apache Software Foundation (ASF) under one or more
-//  contributor license agreements.  See the NOTICE file distributed with
-//  this work for additional information regarding copyright ownership.
-//  The ASF licenses this file to You under the Apache License, Version 2.0
-//  (the "License"); you may not use this file except in compliance with
-//  the License.  You may obtain a copy of the License at
-//
-//      http://www.apache.org/licenses/LICENSE-2.0
-//
-//  Unless required by applicable law or agreed to in writing, software
-//  distributed under the License is distributed on an "AS IS" BASIS,
-//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//  See the License for the specific language governing permissions and
-//  limitations under the License.
-//
-////////////////////////////////////////////////////////////////////////////////
-package mx.charts
-{
-	import org.apache.royale.charts.BarChart;
-	import mx.charts.chartClasses.ChartBase;
-	/**
-	 *  The BarChart class draws a multi-series graph of data using vertical
-	 *  columns. The series property is an array of BarChartSeries instances
-	 *  that represent the data in the model.
-	 *  
-	 *  @langversion 3.0
-	 *  @playerversion Flash 10.2
-	 *  @playerversion AIR 2.6
-	 *  @productversion Royale 0.0
-	 */
-	public class BarChart extends ChartBase
-	{
-		/**
-		 *  constructor.
-		 *
-		 *  @langversion 3.0
-		 *  @playerversion Flash 10.2
-		 *  @playerversion AIR 2.6
-		 *  @productversion Royale 0.0
-		 */
-		public function BarChart()
-		{
-			super();
-		}
-	}
-}
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.charts
+{
+
+import mx.core.UIComponent;
+//import flash.filters.DropShadowFilter;
+import org.apache.royale.reflection.getDefinitionByName;
+
+import mx.charts.chartClasses.CartesianChart;
+import mx.charts.chartClasses.CartesianTransform;
+import mx.charts.chartClasses.DataTip;
+import mx.charts.chartClasses.DataTransform;
+import mx.charts.chartClasses.IChartElement;
+import mx.charts.chartClasses.NumericAxis;
+import mx.charts.chartClasses.Series;
+import mx.charts.series.BarSeries;
+import mx.charts.series.BarSet;
+import mx.charts.series.items.BarSeriesItem;
+import mx.charts.styles.HaloDefaults;
+import mx.core.IFlexModuleFactory;
+import mx.core.mx_internal;
+import mx.graphics.SolidColor;
+import mx.graphics.SolidColorStroke;
+import mx.graphics.Stroke;
+import mx.styles.CSSStyleDeclaration;
+
+use namespace mx_internal;
+
+//--------------------------------------
+//  Styles
+//--------------------------------------
+
+/**
+ *  Specifies how wide to draw the bars relative to the category width,
+ *  as a percentage in the range of 0 to 1. 
+ *  A value of 1 uses the entire space, while a value of 0.6
+ *  uses 60% of the bar's available space.  
+ *  The actual bar width used is the smaller of the
+ *  <code>barWidthRatio</code> property and the
+ *  <code>maxbarWidth</code> property
+ *  Clustered bars divide this space proportionally
+ *  among the bars in each cluster.
+ *  The default value is 0.65.
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="barWidthRatio", type="Number", inherit="no")]
+
+/**
+ *  Specifies how wide to draw the bars, in pixels.
+ *  The actual bar width used is the smaller of this property
+ *  and the <code>barWidthRatio</code> property.
+ *  Clustered bars divide this space proportionally
+ *  among the bars in each cluster. 
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="maxBarWidth", type="Number", format="Length", inherit="no")]
+
+/**
+ *  The class that is used by this component to render labels.
+ *
+ *  <p>It can be set to either the mx.controls.Label class
+ *  or the spark.components.Label class.</p>
+ *
+ *  @default spark.components.Label
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 10.2
+ *  @playerversion AIR 2.0
+ *  @productversion Flex 4
+ */
+[Style(name="labelClass", type="Class", inherit="no")]
+
+//--------------------------------------
+//  Other metadata
+//--------------------------------------
+
+[DefaultBindingProperty(destination="dataProvider")]
+
+[DefaultTriggerEvent("itemClick")]
+
+//[IconFile("BarChart.png")]
+
+/**
+ *  The BarChart control represents data as a series of horizontal bars
+ *  whose length is determined by values in the data.
+ *  A BarChart control can represent different chart variations,
+ *  including simple bars, clustered bars, stacked, 100% stacked, and high/low.
+ *  
+ *  <p>The BarChart control expects its <code>series</code> property
+ *  to contain an array of BarSeries objects.</p>
+ *  
+ *  <p>Stacked and 100% bar charts override the <code>minField</code>
+ *  property of their BarSeries objects.</p>
+ *
+ *  @mxml
+ *  
+ *  <p>The <code>&lt;mx:BarChart&gt;</code> tag inherits all the properties
+ *  of its parent classes, and adds the following properties:</p>
+ *  
+ *  <pre>
+ *  &lt;mx:BarChart
+ *    <strong>Properties</strong>
+ *    type="clustered|overlaid|stacked|100%"
+ *    
+ *    <strong>Styles</strong>
+ *    barWidthRatio=".65"
+ *    maxBarWidth="<i>No default</i>"
+ *  /&gt;
+ *  </pre>
+ *  
+ *  @includeExample examples/Column_BarChartExample.mxml
+ *  
+ *  @see mx.charts.series.BarSeries
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public class BarChart extends CartesianChart
+{
+//    include "../core/Version.as";
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class initialization
+    //
+    //--------------------------------------------------------------------------
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Class constants
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  @private
+     */
+    private static var INVALIDATING_STYLES:Object =
+    {
+        barWidthRatio: 1,
+        maxBarWidth: 1
+    }
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Constructor.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function BarChart()
+    {
+        super();
+
+        LinearAxis(verticalAxis).autoAdjust = false;
+
+        dataTipMode = "single";
+
+        seriesFilters = [ /*new DropShadowFilter(2, 45, 0.2 * 0xFFFFFF)*/];
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+//    private static var _moduleFactoryInitialized:Dictionary = new Dictionary(true);
+    
+    /**
+     *  @private
+     */
+    private var _perSeriesBarWidthRatio:Number;
+    
+    /**
+     *  @private
+     */
+    private var _perSeriesMaxBarWidth:Number;
+    
+    /**
+     *  @private
+     */
+    private var _rightOffset:Number;
+    
+    /**
+     *  @private
+     */
+    private var _wasStacked:Boolean = false;
+    
+    /**
+     * @private
+     */
+    mx_internal var allLabelsMeasured:Boolean = false;
+    
+    /**
+     * @private
+     */
+    private var _allItems:Array /* of ChartItem */ = [];
+    
+    /**
+     * @private
+     */
+    private var _barSeriesLen:Number;
+    
+    /**
+     * @private
+     */
+    private var _needLabels:Boolean = false;
+    
+    /**
+     * @private
+     */
+    private var _tempField:Object; 
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Properties
+    //
+    //--------------------------------------------------------------------------
+    
+    //----------------------------------
+    //  type
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the type property.
+     */
+    private var _type:String = "clustered";
+
+    [Inspectable(category="General", enumeration="stacked,100%,clustered,overlaid", defaultValue="clustered")]
+
+    /**
+     *  The type of bar chart to render. Possible values are:    
+     *  <ul>
+     *    <li><code>"clustered"</code>:
+     *    Bars are grouped by category.
+     *    This is the default value.</li>
+     *  
+     *    <li><code>"overlaid"</code>:
+     *    Multiple bars are rendered on top of each other by category,
+     *    with the last series specified on top.</li>
+     *  
+     *    <li><code>"stacked"</code>:
+     *    Bars are stacked end to end and grouped by category.
+     *    Each bar represents the cumulative value of the values beneath it.</li>
+     *  
+     *    <li><code>"100%"</code>:
+     *    Bars are stacked end to end, adding up to 100%.
+     *    Each bar represents the percent that it contributes
+     *    to the sum of the values for that category.</li>
+     *  </ul>
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get type():String
+    {
+        return _type;
+    }
+
+    /**
+     *  @private
+     */
+    public function set type(value:String):void
+    {
+        _type = value;
+
+        invalidateSeries();
+        invalidateData();
+    }
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: UIComponent
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  @private
+     */
+    private function initStyles():Boolean
+    {
+        HaloDefaults.init(styleManager);
+		var barChartStyle:CSSStyleDeclaration = HaloDefaults.findStyleDeclaration(styleManager, "mx.charts.BarChart");
+		if (barChartStyle)
+		{
+			barChartStyle.setStyle("chartSeriesStyles", HaloDefaults.chartBaseChartSeriesStyles);
+			barChartStyle.setStyle("fill", new SolidColor(0xFFFFFF, 0));
+			barChartStyle.setStyle("calloutStroke", new SolidColorStroke(0x888888,2));
+			barChartStyle.setStyle("horizontalAxisStyleNames", ["blockNumericAxis"]);
+			barChartStyle.setStyle("verticalAxisStyleNames", ["blockCategoryAxis"]);
+		}
+		
+        return true;
+    }
+
+    
+    /**
+     *   A module factory is used as context for using embedded fonts and for finding the style manager that controls the styles for this component.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function set moduleFactory(factory:IFlexModuleFactory):void
+    {
+        super.moduleFactory = factory;
+        
+        /*
+        if (_moduleFactoryInitialized[factory])
+            return;
+        
+        _moduleFactoryInitialized[factory] = true;
+        */
+        
+        // our style settings
+        initStyles();
+    }
+    
+    /**
+     * @private
+     */
+    override protected function createChildren():void
+    {
+        super.createChildren();
+        var labelClass:Class = getLabelClass();
+        _tempField = new labelClass();
+        _tempField.visible = false;
+        _tempField.text="W...";
+        _tempField.toolTip = "";
+        addChild(_tempField as UIComponent);
+        _tempField.validateNow();
+    }
+    
+    private function getLabelClass():Class
+    {
+        var labelClass:Class = getStyle("labelClass");
+        if(labelClass == null)
+        {
+            try{
+                labelClass = Class(getDefinitionByName("spark.components::Label"));
+            }
+            catch(e:Error)
+            {
+                labelClass = Class(getDefinitionByName("mx.controls::Label"));
+            }
+        }
+        return labelClass;
+    }
+
+
+    /**
+     *  @private
+     */
+    override public function styleChanged(styleProp:String):void
+    {
+        if (styleProp == null || INVALIDATING_STYLES[styleProp] != undefined)
+            invalidateSeries();
+
+        super.styleChanged(styleProp);
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: ChartBase
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  @private
+     */
+    override protected function customizeSeries(seriesGlyph:Series, i:uint):void
+    {
+        if ((seriesGlyph is BarSeries) || (seriesGlyph is BarSet))
+        {
+            var series:Object = seriesGlyph;
+
+            if (!isNaN(_perSeriesBarWidthRatio))
+                series.barWidthRatio = _perSeriesBarWidthRatio;
+    
+            if (!isNaN(_perSeriesMaxBarWidth))
+                series.maxBarWidth = _perSeriesMaxBarWidth;
+                
+            if (_type == "overlaid")        
+                series.offset = 0;
+            else
+                series.offset = _rightOffset - i * _perSeriesBarWidthRatio;
+            
+            if (series is BarSeries)
+            {
+                series.stacker = null;
+                series.stackTotals = null;
+            }
+        }
+    }
+    
+    /**
+     *  @private
+     */
+    override protected function applySeriesSet(seriesSet:Array /* of Series */,
+                                               transform:DataTransform):Array /* of Series */
+    {
+        
+        var barWidthRatio:Number = getStyle("barWidthRatio");
+        var maxBarWidth:Number = getStyle("maxBarWidth");
+        var g:IChartElement;
+        var n:int = seriesSet.length;
+
+        switch (_type)
+        {
+            case "stacked":
+            case "100%":
+            {
+                _wasStacked = true;
+
+                for (var i:int = 0; i < n; i++)
+                {
+                    seriesSet[i].offset = 0;
+                }
+
+                var newSeriesGlyph:BarSet = new BarSet();
+                newSeriesGlyph.series = seriesSet;
+                for (i = 0; i < n; i++)
+                {
+                    g = seriesSet[i] as IChartElement;
+                    if (!g)
+                        continue;
+                    if (g.labelContainer)           
+                        newSeriesGlyph.labelContainer.addChild(seriesSet[i].labelContainer);
+                }
+
+                if (!isNaN(barWidthRatio))
+                    newSeriesGlyph.barWidthRatio = barWidthRatio;
+
+                if (!isNaN(maxBarWidth))
+                    newSeriesGlyph.maxBarWidth = maxBarWidth;
+
+                newSeriesGlyph.type = _type;
+
+                invalidateData();
+                return [ newSeriesGlyph ];
+            }
+                            
+            case "clustered":
+            default:
+            {
+                
+                var barSeriesCount:int = 0;
+                for each(var series:Series in seriesSet) {
+                    if(series is BarSet || series is BarSeries)
+                        barSeriesCount++;
+                }
+                
+                _perSeriesBarWidthRatio = barWidthRatio / barSeriesCount;
+                _perSeriesMaxBarWidth = maxBarWidth / barSeriesCount;
+                _rightOffset = barWidthRatio / 2 - _perSeriesBarWidthRatio / 2;
+                n = seriesSet.length;
+                var count:int = 0;
+                for (i = 0; i < n; i++)
+                {
+                    var newSeries:IChartElement = seriesSet[i];
+                    if (newSeries is BarSeries || newSeries is BarSet)
+                    {
+                        customizeSeries(Series(seriesSet[i]), count);
+                        count++;
+                    }
+                }
+                
+                return seriesSet;
+            }
+
+            case "overlaid":
+            {
+                _perSeriesBarWidthRatio = barWidthRatio;
+                _perSeriesMaxBarWidth = maxBarWidth;
+
+                _rightOffset = 0;
+                super.applySeriesSet(seriesSet, transform);
+                break;
+            }
+        }
+
+        return seriesSet;
+    }
+                
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: CartesianChart
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     * Determines positions and dimensions of labels for all series in the chart
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override mx_internal function measureLabels():Object
+    {
+        getSeriesLabelPosSet();
+        if (!_needLabels)
+            return null;
+        var n:int = series.length;
+        var allSeriesTransform:Boolean = true;
+        
+        if (type == "stacked" || type == "overlaid" || type == "100%")
+            allLabelsMeasured = false;
+        
+        _allItems = [];
+        _barSeriesLen = 0;
+        for (var i:int = 0; i < n; i++)
+        {
+            findChartItems(series[i]);          
+        }
+        _allItems.sort(sortOnY);    //sort all items with respect to thier position along Y-axis
+        var itemsLen:Number = _allItems.length;
+        for (i = itemsLen - 1; i >= 0; i--)
+        {
+            var v:BarSeriesItem = _allItems[i];
+            var barSeries:BarSeries = BarSeries(BarSeriesItem(_allItems[i]).element);
+            var labelPosition:String = barSeries.labelPos;      
+        
+            if (labelPosition == "inside" || labelPosition == "outside")
+            {
+                
+                var base:Number = barSeries.seriesRenderData.renderedBase;
+                var size:Number = barSeries.getStyle('fontSize');
+                if (barSeries.labelFunction != null)
+                    barSeries.measuringField.text = v.labelText = barSeries.labelFunction(v, barSeries);
+                else if (barSeries.labelField != null)
+                    barSeries.measuringField.text = v.labelText = v.item[barSeries.labelField];
+                else if (barSeries.dataFunction != null)
+                    barSeries.measuringField.text = v.labelText = barSeries.dataFunction(barSeries, v.item, 'xNumber');
+                else
+                    barSeries.measuringField.text = v.labelText = v.item[barSeries.xField];     
+            
+                //barSeries.measuringField.validateNow();
+                
+                var labelRotation:Number = barSeries.labelAngle;
+                var labelSizeLimit:Number = barSeries.maxLabelSize;
+                if (labelPosition == "outside" && (type == "stacked" || type == "overlaid" || type == "100%"))
+                {
+                    labelPosition = "inside";
+                    barSeries.labelPos = 'inside';
+                        //today, labelPosition = inside is only supported for stacked, 100% and overlaid
+                }       
+                            
+            
+                if (labelPosition == 'outside')
+                {
+                    v.labelHeight = 2 * barSeries.seriesRenderData.renderedHalfWidth;
+                    /*
+                    if (!(isNaN(labelRotation)) && labelRotation != 0 && barSeries.measuringField.embedFonts)
+                    {
+                        var r:Number = -labelRotation / Math.PI * 180;
+                                //for future enhancement
+                                //check for type of chart if we need to support labelPosition = outside for all types of charts
+                        if (type == "clustered")
+                        {
+                            if (i > n - 1)
+                                v.labelWidth = Math.abs((_allItems[i - i%n - 1].y + BarSeries(_allItems[i - i%n - 1].element).seriesRenderData.renderedYOffset
+                                               + BarSeries(_allItems[i - i%n - 1].element).seriesRenderData.renderedHalfWidth -
+                                               (v.y + barSeries.seriesRenderData.renderedYOffset - 
+                                               barSeries.seriesRenderData.renderedHalfWidth))/ Math.cos(r));
+                            else
+                                v.labelWidth = Math.abs((_allItems[0].y + BarSeries(_allItems[0].element).seriesRenderData.renderedYOffset
+                                               - BarSeries(_allItems[0].element).seriesRenderData.renderedHalfWidth - 
+                                               (v.y + barSeries.seriesRenderData.renderedYOffset - 
+                                               barSeries.seriesRenderData.renderedHalfWidth))/ Math.cos(r));
+                        }
+                        else
+                        {
+                            if (i > n - 1)
+                                v.labelWidth = Math.abs((_allItems[i - n].y + BarSeries(_allItems[i - n].element).seriesRenderData.renderedYOffset
+                                               + BarSeries(_allItems[i - n].element).seriesRenderData.renderedHalfWidth - 
+                                               (v.y + barSeries.seriesRenderData.renderedYOffset - 
+                                               barSeries.seriesRenderData.renderedHalfWidth))/ Math.cos(r));
+                            else
+                                v.labelWidth = Math.abs((_allItems[0].y + BarSeries(_allItems[0].element).seriesRenderData.renderedYOffset
+                                               - BarSeries(_allItems[0].element).seriesRenderData.renderedHalfWidth - 
+                                               (v.y + barSeries.seriesRenderData.renderedYOffset - 
+                                               barSeries.seriesRenderData.renderedHalfWidth))/ Math.cos(r));
+                        }
+                        v.labelY=v.y + barSeries.seriesRenderData.renderedYOffset + barSeries.seriesRenderData.renderedHalfWidth;
+                    }
+                    else
+                    {*/
+                        if (v.x > (isNaN(v.min) ? base : v.min))
+                        {
+                            v.labelWidth = barSeries.dataToLocal(NumericAxis(barSeries.dataTransform.getAxis(CartesianTransform.HORIZONTAL_AXIS)).computedMaximum,0).x - barSeries.dataToLocal(v.xNumber,0).x;
+                            v.labelX = v.x;
+                            if (v.labelWidth == 0)
+                            {
+                                v.labelWidth = Math.abs(v.x -(isNaN(v.min) ? base : v.min));
+                                v.labelX = isNaN(v.min) ? base : v.min;
+                            }
+                        }
+                        else
+                        {
+                            v.labelWidth = barSeries.dataToLocal(v.xNumber,0).x - barSeries.dataToLocal(NumericAxis(barSeries.dataTransform.getAxis(CartesianTransform.HORIZONTAL_AXIS)).computedMinimum,0).x;
+                            v.labelX = v.x - v.labelWidth;
+                            if (v.labelWidth == 0)
+                            {
+                                v.labelWidth = Math.abs(v.x -(isNaN(v.min) ? base : v.min));
+                                v.labelX = v.x;
+                            }
+                        }
+                        v.labelY=v.y + barSeries.seriesRenderData.renderedYOffset - barSeries.seriesRenderData.renderedHalfWidth;
+                    /*}*/
+                    var labelScale:Number = 1;
+                    if (barSeries.measuringField.textWidth > v.labelWidth || barSeries.measuringField.textHeight > v.labelHeight)
+                    {
+                        labelScale = v.labelWidth / barSeries.measuringField.textWidth;
+                        labelScale = Math.min(labelScale, v.labelHeight / barSeries.measuringField.textHeight);
+                        if (size * labelScale > labelSizeLimit)
+                            barSeries.seriesRenderData.labelScale = Math.min(labelScale,barSeries.seriesRenderData.labelScale);
+                        else
+                        {
+                            _tempField.setStyle('fontSize',size);
+                            _tempField.validateNow();
+                            if (_tempField.measuredWidth > v.labelWidth || _tempField.measuredHeight > v.labelHeight)
+                            {
+                                labelScale = v.labelWidth / _tempField.measuredWidth;                       
+                                labelScale = Math.min(labelScale, v.labelHeight / _tempField.measuredHeight);
+                                if (size * labelScale > labelSizeLimit)
+                                    barSeries.seriesRenderData.labelScale = Math.min(labelScale,barSeries.seriesRenderData.labelScale); 
+                                else
+                                {
+                                    v.labelText = "";
+                                    v.labelWidth = 1;
+                                }
+                            }
+                        }
+                    }
+                            
+                    /*
+                    if (!isNaN(labelRotation) && labelRotation!=0 && barSeries.measuringField.embedFonts)
+                    {
+                        v.labelHeight = barSeries.measuringField.textHeight + 2;
+                        if (v.x > (isNaN(v.min) ? base : v.min))
+                            v.labelX = v.x + v.labelHeight;
+                        else
+                            v.labelX = v.x - 2 * v.labelHeight;
+                        v.labelY = v.labelY - v.labelHeight;
+                        v.labelWidth = v.labelWidth - v.labelHeight;
+                    }*/
+                }
+                else if (labelPosition == "inside")
+                {
+                    v.labelWidth = Math.abs(v.x -(isNaN(v.min) ? base : v.min));
+                    v.labelHeight = 2 * barSeries.seriesRenderData.renderedHalfWidth;
+                    v.labelY=v.y + barSeries.seriesRenderData.renderedYOffset - barSeries.seriesRenderData.renderedHalfWidth;
+            
+                    if (v.x > (isNaN(v.min) ? base : v.min))
+                        v.labelX = isNaN(v.min) ? base : v.min;
+                    else
+                        v.labelX = v.x;
+                    labelScale = 1;
+                    if (barSeries.measuringField.textWidth > v.labelWidth || (barSeries.measuringField.textHeight) > v.labelHeight)
+                    {
+                        labelScale = v.labelWidth / barSeries.measuringField.textWidth;
+                        labelScale = Math.min(labelScale, v.labelHeight / barSeries.measuringField.textHeight);
+                        if (size * labelScale > labelSizeLimit)
+                            barSeries.seriesRenderData.labelScale = Math.min(labelScale,barSeries.seriesRenderData.labelScale);
+                        else
+                        {
+                            _tempField.setStyle('fontSize',size);
+                            _tempField.validateNow();
+                            if (_tempField.measuredWidth > v.labelWidth || _tempField.measuredHeight + 2 > v.labelHeight)
+                            {
+                                labelScale = v.labelWidth / _tempField.measuredWidth;                       
+                                labelScale = Math.min(labelScale, v.labelHeight / _tempField.measuredHeight);
+                                if (size * labelScale > labelSizeLimit)
+                                    barSeries.seriesRenderData.labelScale = Math.min(labelScale,barSeries.seriesRenderData.labelScale); 
+                                else
+                                {
+                                    v.labelText = "";
+                                    v.labelWidth = 1;
+                                }
+                            }
+                        }
+                    }
+                    var prevItemsCount:int =_barSeriesLen - 1 - (i % _barSeriesLen);
+                    for (var j:int = 1; j <= prevItemsCount; j++)
+                            //test for overlaps with previous labels
+                    {
+                        var tempItem:BarSeriesItem = _allItems[i + j];
+                        if (v.labelY == tempItem.labelY)
+                        {
+                            if (((v.labelX >= tempItem.labelX) && (v.labelX < (tempItem.labelX + tempItem.labelWidth))) ||
+                                    ((v.labelX <= tempItem.labelX) && ((v.labelX + v.labelWidth) > tempItem.labelX)))
+                            {
+                                v.labelText = "";
+                                v.labelWidth = 1;
+                            }
+                        }
+                    }                       
+                }
+            }
+            else
+            {
+                barSeries.seriesRenderData.labelData = null;
+                barSeries.labelCache.count = 0;
+            }
+        }
+        allLabelsMeasured = true;
+        for (i = 0; i < n; i++)
+        {
+            invalidateDisplay(series[i]);
+        }
+        return null;
+    }
+    
+    //------------------------------------------------------------------------------------
+    //
+    // Methods
+    //
+    //------------------------------------------------------------------------------------
+    
+    mx_internal function getSeriesLabelPos(series:Series):void
+    {
+        if (series is BarSeries)
+        {
+            var barSeries:BarSeries = BarSeries(series);
+            var position:String = barSeries.labelPos;
+            if (position == "inside" || position == "outside" || position == "none")
+                _needLabels = true; 
+        }
+        else if (series is BarSet)
+        {
+            var setSeries:Array /* of Series */ = BarSet(series).series;
+            var n:int = setSeries.length;
+            for (var i:int = 0; i < n; i++)
+            {
+                getSeriesLabelPos(setSeries[i]);
+            }
+        }   
+    }
+    
+    mx_internal function getSeriesLabelPosSet():void
+    {
+        var n:int = series.length;
+        _needLabels = false;
+        for (var i:int = 0; i < n; i++)
+        {
+            if (_needLabels)
+                return;
+            getSeriesLabelPos(series[i]);
+        }
+    }
+     
+    /**
+     * @private
+     */
+     private function sortOnY(a:BarSeriesItem,b:BarSeriesItem):int
+     {
+        var offset1:Number = BarSeries(a.element).seriesRenderData.renderedYOffset;
+        var offset2:Number = BarSeries(b.element).seriesRenderData.renderedYOffset;
+        if (a.y + offset1 > b.y + offset2)
+            return 1;
+        else if (a.y + offset1 < b.y + offset2)
+            return -1;
+        else
+        {
+            if (a.xNumber > b.xNumber)
+                return 1;
+            else if (a.xNumber < b.xNumber)
+                return -1;
+            else
+                return 0;
+        }           
+     }
+     
+    /**
+     * @private
+     */
+     private function findChartItems(series:Series):void
+     {
+        var n:int;
+        var i:int;
+        if (series is BarSeries)
+        {
+            _barSeriesLen = _barSeriesLen + 1;
+            var barSeries:BarSeries = BarSeries(series);
+            var seriesItems:Array /* of BarSeriesItem */ = barSeries.seriesRenderData.filteredCache;
+            n = seriesItems.length;
+            barSeries.labelCache.count = n;
+            barSeries.seriesRenderData.labelScale = 1;
+            
+            for (i = 0; i < n; i++)
+            {
+                _allItems.push(BarSeriesItem(seriesItems[i]));
+            }           
+        }
+        else if (series is BarSet)
+        {
+            var setSeries:Array /* of Series */ = BarSet(series).series;
+            n = setSeries.length;
+            for (i = 0; i < n; i++)
+            {
+                findChartItems(setSeries[i]);
+            }
+        }
+     }
+    /**
+     * @private
+     */
+     private function invalidateDisplay(series:Series):void
+     {
+        if (series is BarSeries)
+            BarSeries(series).updateLabels();
+        else if (series is BarSet)
+        {
+            var setSeries:Array /* of Series */ = BarSet(series).series;
+            var n:int = setSeries.length;
+            for (var i:int = 0; i < n; i++)
+            {
+                invalidateDisplay(setSeries[i]);
+            }
+        }
+     }
+    
+}
+
+}
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/BubbleChart.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/BubbleChart.as
new file mode 100644
index 0000000..b8ae33a
--- /dev/null
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/BubbleChart.as
@@ -0,0 +1,322 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.charts
+{
+
+import mx.charts.chartClasses.CartesianChart;
+import mx.charts.chartClasses.DataTip;
+import mx.charts.chartClasses.IAxis;
+import mx.charts.chartClasses.Series;
+import mx.charts.series.BubbleSeries;
+import mx.charts.styles.HaloDefaults;
+import mx.core.IFlexModuleFactory;
+import mx.core.mx_internal;
+import mx.graphics.SolidColor;
+import mx.graphics.SolidColorStroke;
+import mx.graphics.Stroke;
+import mx.styles.CSSStyleDeclaration;
+
+use namespace mx_internal;
+
+//--------------------------------------
+//  Styles
+//--------------------------------------
+
+/**
+ *  The maximum radius of the largest chart element, in pixels
+ *  Flex assigns this radius to the data point with the largest value;
+ *  all other data points are assigned a smaller radius
+ *  based on their value relative to the smallest and largest value.
+ *  The default value is 50 pixels.
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="maxRadius", type="Number", format="Length", inherit="no")]
+
+/**
+ *  The minimum radius of the smallest chart element, in pixels
+ *  Flex assigns this radius to the data point with the smallest value;
+ *  all other data points are assigned a larger radius
+ *  based on their value relative to the smallest and largest value.
+ *  The default value is 0 pixels.
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="minRadius", type="Number", format="Length", inherit="no")]
+
+//--------------------------------------
+//  Other metadata
+//--------------------------------------
+
+[DefaultBindingProperty(destination="dataProvider")]
+
+[DefaultTriggerEvent("itemClick")]
+
+//[IconFile("BubbleChart.png")]
+
+/**
+ *  The BubbleChart control represents data with three values
+ *  for each data point.
+ *  Each data point is defined by a value determining its position
+ *  along the horizontal axis, a value determining its position
+ *  along the vertical axis, and a value determining the size
+ *  of the chart element, relative to the other data points on the chart.
+ *  
+ *  <p>The BubbleChart control expects its <code>series</code> property
+ *  to contain an array of BubbleSeries objects.</p>
+ *  
+ *  @mxml
+ *  
+ *  The <code>&lt;mx:BubbleChart&gt;</code> tag inherits all the properties
+ *  of its parent classes and adds the following properties:</p>
+ *  
+ *  <pre>
+ *  &lt;mx:BubbleChart
+ *    <strong>Properties</strong>
+ *    radiusAxis="<i>LinearAxis</i>"
+ * 
+ *    <strong>Styles</strong>
+ *    maxRadius="50"
+ *    minRadius="0"
+ *  /&gt;
+ *  </pre>
+ *  
+ *  @includeExample examples/BubbleChartExample.mxml
+ *  
+ *  @see mx.charts.series.BubbleSeries
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public class BubbleChart extends CartesianChart
+{
+//    include "../core/Version.as";
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class initialization
+    //
+    //--------------------------------------------------------------------------
+    
+
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Constructor.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function BubbleChart()
+    {
+        super();
+
+        var zAxis:LinearAxis = new LinearAxis();
+        zAxis.autoAdjust = false;
+        zAxis.minimum = 0;
+        zAxis.interval = 1;
+        radiusAxis = zAxis;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  @private
+     */
+//    private static var _moduleFactoryInitialized:Dictionary = new Dictionary(true);
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Properties
+    //
+    //--------------------------------------------------------------------------
+    
+    //----------------------------------
+    //  radiusAxis
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the radiusAxis property.
+     */
+    private var _radiusAxis:IAxis;
+    
+    [Inspectable(category="Data")]
+
+    /**
+     *  The axis the bubble radius is mapped against
+     *  Bubble charts treat the size of the individual bubbles
+     *  as a third dimension of data which is transformed
+     *  in a similar manner to how x and y position is transformed.  
+     *  By default, the <code>radiusAxis</code> is a LinearAxis
+     *  with the <code>autoAdjust</code> property set to <code>false</code>.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get radiusAxis():IAxis
+    {
+        return _transforms[0].getAxis(BubbleSeries.RADIUS_AXIS);
+    }
+
+    /**
+     *  @private
+     */
+    public function set radiusAxis(value:IAxis):void
+    {
+        _radiusAxis = value;
+        _transforms[0].setAxis(BubbleSeries.RADIUS_AXIS, value);
+        
+        invalidateData();
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: UIComponent
+    //
+    //--------------------------------------------------------------------------
+
+	/**
+     *  @private
+     */
+    private function initStyles():Boolean
+    {
+        HaloDefaults.init(styleManager);
+		
+		var bubbleChartStyle:CSSStyleDeclaration = HaloDefaults.findStyleDeclaration(styleManager, "mx.charts.BubbleChart");
+		if (bubbleChartStyle)
+		{
+			bubbleChartStyle.setStyle("chartSeriesStyles", HaloDefaults.chartBaseChartSeriesStyles);
+			bubbleChartStyle.setStyle("dataTipCalloutStroke", new SolidColorStroke(2,0));
+			bubbleChartStyle.setStyle("fill", new SolidColor(0xFFFFFF, 0));
+			bubbleChartStyle.setStyle("calloutStroke", new SolidColorStroke(0x888888,2));
+			bubbleChartStyle.setStyle("horizontalAxisStyleNames", ["blockNumericAxis"]);
+			bubbleChartStyle.setStyle("verticalAxisStyleNames", ["blockNumericAxis"]);
+		}
+		
+        return true;
+    }
+    
+    /**
+     *   A module factory is used as context for using embedded fonts and for finding the style manager that controls the styles for this component.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function set moduleFactory(factory:IFlexModuleFactory):void
+    {
+        super.moduleFactory = factory;
+        
+        /*
+        if (_moduleFactoryInitialized[factory])
+            return;
+        
+        _moduleFactoryInitialized[factory] = true;
+        */
+        
+        // our style settings
+        initStyles();
+    }
+    
+    /**
+     *  @private
+     */
+    override public function styleChanged(styleProp:String):void
+    {
+        var series:Array /* of Series */;
+        var n:int;
+        var i:int;
+        
+        if (styleProp == null || styleProp == "maxRadius")
+        {
+            var maxRadius:Number = getStyle("maxRadius");
+            
+            series = this.series;
+            n = series.length;
+            for (i = 0; i < n; i++)
+            {
+                if (series[i] is BubbleSeries)
+                {
+                    series[i].maxRadius = maxRadius;
+                    series[i].invalidateDisplayList();
+                }
+            }                       
+        }
+        if (styleProp == null || styleProp == "minRadius")
+        {
+            var minRadius:Number = getStyle("minRadius");
+            
+            series = this.series;
+            n = series.length;
+            for (i = 0; i < n; i++)
+            {
+                if (series[i] is BubbleSeries)
+                {
+                    series[i].minRadius = minRadius;
+                    series[i].invalidateDisplayList();
+                }
+            }                   
+        }
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: ChartBase
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    override protected function customizeSeries(seriesGlyph:Series, i:uint):void
+    {
+        var maxRadius:Number = getStyle("maxRadius");
+        var minRadius:Number = getStyle("minRadius");
+
+        if ((seriesGlyph is BubbleSeries) && !isNaN(maxRadius))
+            BubbleSeries(seriesGlyph).maxRadius = maxRadius;
+        if ((seriesGlyph is BubbleSeries) && !isNaN(minRadius))
+            BubbleSeries(seriesGlyph).minRadius = minRadius;
+    }
+}
+
+}
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/CandlestickChart.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/CandlestickChart.as
new file mode 100644
index 0000000..81dde35
--- /dev/null
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/CandlestickChart.as
@@ -0,0 +1,322 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.charts
+{
+
+import mx.charts.chartClasses.CartesianChart;
+import mx.charts.chartClasses.DataTip;
+import mx.charts.chartClasses.DataTransform;
+import mx.charts.chartClasses.Series;
+import mx.charts.series.CandlestickSeries;
+import mx.charts.styles.HaloDefaults;
+import mx.core.IFlexModuleFactory;
+import mx.core.mx_internal;
+import mx.graphics.IFill;
+import mx.graphics.SolidColor;
+import mx.graphics.SolidColorStroke;
+import mx.graphics.Stroke;
+import mx.styles.CSSStyleDeclaration;
+
+use namespace mx_internal;
+
+//--------------------------------------
+//  Styles
+//--------------------------------------
+
+/**
+ *  Specifies a ratio of how wide to draw the candlesticks
+ *  relative to the horizontal axis's category widths,
+ *  as a percentage in the range of 0 to 1. 
+ *  A value of 1 uses the entire space,
+ *  while a value of 0.6 uses 60% of the column's available space.  
+ *  The actual candlestick width used is the smaller of the
+ *  <code>columnWidthRatio</code> property and the
+ *  <code>maxColumnWidth</code> property.
+ *  Multiple candlestick series divide this space proportionally.
+ *  The default value is 0.65.
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="columnWidthRatio", type="Number", inherit="no")]
+
+/**
+ *  Specifies how wide to draw the candlesticks, in pixels.
+ *  The actual column width used is the smaller of this property
+ *  and the <code>columnWidthRatio</code> property.
+ *  Multiple candlestick series divide this space proportionally.
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="maxColumnWidth", type="Number", format="Length", inherit="no")]
+
+//--------------------------------------
+//  Other metadata
+//--------------------------------------
+
+[DefaultBindingProperty(destination="dataProvider")]
+
+[DefaultTriggerEvent("itemClick")]
+
+//[IconFile("CandlestickChart.png")]
+
+/**
+ *  The CandlestickChart control represents financial data
+ *  as a series of candlesticks representing the high, low,
+ *  opening, and closing values of a data series.
+ *  The top and bottom of the vertical line in each candlestick
+ *  represent the high and low values for the datapoint,
+ *  while the top and bottom of the filled box
+ *  represents the opening and closing values.
+ *  Each candlestick is filled differently depending on
+ *  whether the closing value for the datapoint
+ *  is higher or lower than the opening value.
+ *   
+ *  <p>A CandlestickChart control expects its <code>series</code> property
+ *  to contain an array of CandlestickSeries objects.</p>
+ *
+ *  @mxml
+ *  
+ *  The <code>&lt;mx:CandlestickChart&gt;</code> tag inherits all the properties
+ *  of its parent classes and adds the following properties:</p>
+ *  
+ *  <pre>
+ *  &lt;mx:CandlestickChart
+ *    <strong>Styles</strong>
+ *    columnWidthRatio=".65"
+ *    maxColumnWidth="<i>No default</i>"
+ *  /&gt;
+ *  </pre> 
+ * 
+ *  @see mx.charts.series.CandlestickSeries
+ *
+ *  @includeExample examples/CandlestickChartExample.mxml
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public class CandlestickChart extends CartesianChart
+{
+//    include "../core/Version.as";
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class initialization
+    //
+    //--------------------------------------------------------------------------
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class constants
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    private static var INVALIDATING_STYLES:Object =
+    {
+        columnWidthRatio: 1,
+        maxColumnWidth: 1
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Constructor.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function CandlestickChart()
+    {
+        super();
+
+        dataTipMode = "single";
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  @private
+     */
+//    private static var _moduleFactoryInitialized:Dictionary = new Dictionary(true); 
+    
+    /**
+     *  @private
+     */
+    private var _perSeriescolumnWidthRatio:Number;
+    
+    /**
+     *  @private
+     */
+    private var _perSeriesMaxColumnWidth:Number;
+    
+    /**
+     *  @private
+     */
+    private var _leftOffset:Number;
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: UIComponent
+    //
+    //--------------------------------------------------------------------------
+
+	/**
+     *  @private
+     */
+    private function initStyles():Boolean
+    {
+        HaloDefaults.init(styleManager);
+		
+		var candlestickChartSeriesStyles:Array /* of Object */ = [];
+		var csChartStyle:CSSStyleDeclaration = HaloDefaults.findStyleDeclaration(styleManager, "mx.charts.CandlestickChart");
+		if (csChartStyle)
+		{
+			csChartStyle.setStyle("chartSeriesStyles", candlestickChartSeriesStyles);
+			csChartStyle.setStyle("fill", new SolidColor(0xFFFFFF, 0));
+			csChartStyle.setStyle("calloutStroke", new SolidColorStroke(0x888888,2));
+			csChartStyle.setStyle("horizontalAxisStyleNames", ["blockCategoryAxis"]);
+			csChartStyle.setStyle("verticalAxisStyleNames", ["blockNumericAxis"]);
+				
+	        var n:int = HaloDefaults.defaultColors.length;
+	        for (var i:int = 0; i < n; i++)
+	        {
+	            var styleName:String = "haloCandlestickSeries" + i;
+	            candlestickChartSeriesStyles[i] = styleName;
+	            
+	            var o:CSSStyleDeclaration =
+	                HaloDefaults.createSelector("." + styleName, styleManager);
+	            
+	            var f:Function = function(o:CSSStyleDeclaration, boxStroke:Stroke,
+	                                      declineFill:IFill):void
+	            {
+	                o.defaultFactory = function():void
+	                {
+	                    this.boxStroke = boxStroke;
+	                    this.declineFill = declineFill;
+	                }
+	            }
+	            
+	            f(o, new Stroke(HaloDefaults.defaultColors[i], 0, 1),
+	                new SolidColor(HaloDefaults.defaultColors[i]));
+	        }
+		}
+		
+        return true;
+    }
+    
+    /**
+     *   A module factory is used as context for using embedded fonts and for finding the style manager that controls the styles for this component.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function set moduleFactory(factory:IFlexModuleFactory):void
+    {
+        super.moduleFactory = factory;
+        
+        /*
+        if (_moduleFactoryInitialized[factory])
+            return;
+        
+        _moduleFactoryInitialized[factory] = true;
+        */
+        
+        // our style settings
+        initStyles();
+    }
+    
+    /**
+     *  @private
+     */
+    override public function styleChanged(styleProp:String):void
+    {
+        if (styleProp == null || INVALIDATING_STYLES[styleProp] != undefined)
+            invalidateSeries();
+
+        super.styleChanged(styleProp);
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: ChartBase
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    override protected function customizeSeries(seriesGlyph:Series, i:uint):void
+    {
+        var series:CandlestickSeries = seriesGlyph as CandlestickSeries;
+        if (series)
+        {
+            if (!isNaN(_perSeriescolumnWidthRatio))
+                series.columnWidthRatio = _perSeriescolumnWidthRatio;
+            
+            if (!isNaN(_perSeriesMaxColumnWidth))
+                series.maxColumnWidth = _perSeriesMaxColumnWidth;
+
+            series.offset = _leftOffset + i * _perSeriescolumnWidthRatio;
+        }
+    }
+    
+    /**
+     *  @private
+     */
+    override protected function applySeriesSet(seriesSet:Array /* of Series */,
+                                               transform:DataTransform):Array /* of Series */
+    {
+            
+        var columnWidthRatio:Number = getStyle("columnWidthRatio");
+        var maxColumnWidth:Number = getStyle("maxColumnWidth");
+
+        _perSeriescolumnWidthRatio = columnWidthRatio / seriesSet.length;
+        _perSeriesMaxColumnWidth = maxColumnWidth / seriesSet.length;
+        
+        _leftOffset = (1 - columnWidthRatio) / 2 +
+                      _perSeriescolumnWidthRatio / 2 - 0.5;
+        
+        return super.applySeriesSet(seriesSet, transform);
+    }           
+}
+
+}
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/CategoryAxis.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/CategoryAxis.as
index 949e4a8..8dff8cb 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/CategoryAxis.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/CategoryAxis.as
@@ -20,21 +20,20 @@
 package mx.charts
 {
 
-/* import flash.events.Event;
+import org.apache.royale.events.Event;
 
 import mx.charts.chartClasses.AxisBase;
 import mx.charts.chartClasses.AxisLabelSet;
+import mx.charts.chartClasses.IAxis;
 import mx.collections.ArrayCollection;
 import mx.collections.CursorBookmark;
+import mx.collections.ICollectionView;
 import mx.collections.IViewCursor;
 import mx.collections.XMLListCollection;
 import mx.core.mx_internal;
 import mx.events.CollectionEvent;
 import mx.events.CollectionEventKind;
-use namespace mx_internal; */
-import mx.collections.ICollectionView;
-import mx.core.UIComponent;
-import mx.charts.chartClasses.IAxis;
+use namespace mx_internal;
 
 /**
  *  The CategoryAxis class lets charts represent data
@@ -84,13 +83,11 @@ import mx.charts.chartClasses.IAxis;
  *  @langversion 3.0
  *  @playerversion Flash 9
  *  @playerversion AIR 1.1
- *  @productversion Royale 0.9.3
+ *  @productversion Flex 3
  */
-public class CategoryAxis extends UIComponent implements IAxis
+public class CategoryAxis extends AxisBase implements IAxis
 {
-//extends AxisBase implements IAxis
-   
-   // include "../core/Version.as";
+//    include "../core/Version.as";
 
     //--------------------------------------------------------------------------
     //
@@ -104,55 +101,110 @@ public class CategoryAxis extends UIComponent implements IAxis
      *  @langversion 3.0
      *  @playerversion Flash 9
      *  @playerversion AIR 1.1
-     *  @productversion Royale 0.9.3
+     *  @productversion Flex 3
      */
     public function CategoryAxis()
     {
-       /*  super();
+        super();
 
-        workingDataProvider = new ArrayCollection(); */
+        workingDataProvider = new ArrayCollection();
     }
 
-	// displayName property copied from AxisBase
-    //----------------------------------
-    //  displayName
-    //----------------------------------
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  @private
+     */
+    private var _cursor:IViewCursor;
+    
+    /**
+     *  @private
+     */
+    private var _catMap:Object;
 
     /**
      *  @private
-     *  Storage for the name property.
      */
-    private var _displayName:String = "";
+    private var _categoryValues:Array /* of Object */;
+    
+    /**
+     *  @private
+     */
+    private var _labelsMatchToCategoryValuesByIndex:Array /* of AxisLabel */;
 
-    [Inspectable(category="Display")]
+    /**
+     *  @private
+     */
+    private var _cachedMinorTicks:Array /* of Number */ = null; 
+    
+    /**
+     *  @private
+     */
+    private var _cachedTicks:Array /* of Number */ = null;  
 
     /**
-     *  @copy mx.charts.chartClasses.IAxis#displayName
-     *  
-     *  @langversion 3.0
-     *  @playerversion Flash 9
-     *  @playerversion AIR 1.1
-     *  @productversion Royale 0.9.3
+     *  @private
      */
-    public function get displayName():String
-    {
-        return _displayName;
-    }
+    private var _labelSet:AxisLabelSet;
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden properties
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  chartDataProvider
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the chartDataProvider property.
+     */
+    private var _chartDataProvider:Object;
     
     /**
      *  @private
      */
-    public function set displayName(value:String):void
+    override public function set chartDataProvider(value:Object):void
     {
-        _displayName = value;
+		if(_chartDataProvider != value)
+		{
+        	_chartDataProvider = value;
+
+	        if (!_userDataProvider)
+    	        workingDataProvider = _chartDataProvider;
+		}
     }
+    
     //--------------------------------------------------------------------------
     //
-    //  Overridden properties
+    //  Properties
     //
     //--------------------------------------------------------------------------
-
     
+    //----------------------------------
+    //  baseline
+    //----------------------------------
+
+    [Inspectable(environment="none")]
+
+    /**
+     *  @inheritDoc
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get baseline():Number
+    {
+        return -_padding;
+    }
 
     //----------------------------------
     //  categoryField
@@ -177,7 +229,7 @@ public class CategoryAxis extends UIComponent implements IAxis
      *  @langversion 3.0
      *  @playerversion Flash 9
      *  @playerversion AIR 1.1
-     *  @productversion Royale 0.9.3
+     *  @productversion Flex 3
      */
     public function get categoryField():String
     {
@@ -191,10 +243,69 @@ public class CategoryAxis extends UIComponent implements IAxis
     {
         _categoryField = value;
 
-     //   collectionChangeHandler();
+        collectionChangeHandler();
+    }
+    
+    //---------------------------------
+    // dataFunction
+    //---------------------------------
+    
+    [Bindable]
+    [Inspectable(category="General")]
+    
+    /**
+     *  @private
+     * Storage for dataFunction property
+     */
+     private var _dataFunction:Function = null;
+     
+    /**
+     * Specifies a method that returns the value that should be used as
+     * categoryValue for current item.If this property is set, the return 
+     * value of the custom data function takes precedence over 
+     * <code>categoryField</code>
+     * 
+     * <p>The custom <code>dataFunction</code> has the following signature:
+     *  
+     * <pre>
+     * <i>function_name</i> (axis:CategoryAxis, item:Object):Object { ... }
+     * </pre>
+     * 
+     * <code>axis</code> is the current axis that uses this <code>dataFunction</code>
+     * <code>item</code> is the item in the dataProvider that is considered.
+     * This function returns an object.
+     * </p>
+     *  
+     * <p>An example usage of a customized <code>dataFunction</code> is to return a value
+     * from a dataProvider that has items with nested fields</p>
+     *   
+     * @example
+     * <pre>
+     * public function myFunction(axis:CategoryAxis,item:Object):Object {
+     *      return(item.Country.State);
+     * }     
+     * </pre>
+     *
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get dataFunction():Function
+    {
+        return _dataFunction;
     }
     
-   
+    /**
+     *  @private
+     */
+    public function set dataFunction(value:Function):void
+    {
+        _dataFunction = value;
+        collectionChangeHandler();
+    }
+
 
     //----------------------------------
     //  dataProvider
@@ -227,7 +338,7 @@ public class CategoryAxis extends UIComponent implements IAxis
      *  @langversion 3.0
      *  @playerversion Flash 9
      *  @playerversion AIR 1.1
-     *  @productversion Royale 0.9.3
+     *  @productversion Flex 3
      */
     public function get dataProvider():Object
     {
@@ -239,12 +350,12 @@ public class CategoryAxis extends UIComponent implements IAxis
      */
     public function set dataProvider(value:Object):void
     {
-       /*  _userDataProvider = value;
+        _userDataProvider = value;
 
         if (_userDataProvider != null)
             workingDataProvider = _userDataProvider;
         else
-            workingDataProvider = _chartDataProvider; */
+            workingDataProvider = _chartDataProvider;
     }
 
     //----------------------------------
@@ -288,7 +399,7 @@ public class CategoryAxis extends UIComponent implements IAxis
      *  @langversion 3.0
      *  @playerversion Flash 9
      *  @playerversion AIR 1.1
-     *  @productversion Royale 0.9.3
+     *  @productversion Flex 3
      */ 
     public function get labelFunction():Function
     {
@@ -302,10 +413,332 @@ public class CategoryAxis extends UIComponent implements IAxis
     {
         _labelFunction = value;
 
-     //   invalidateCategories();
+        invalidateCategories();
+    }
+    
+    //----------------------------------
+    //  minorTicks (private)
+    //----------------------------------
+ 
+    /**
+     *  @private
+     */
+    private function get minorTicks():Array /* of Number */
+    {
+        if (!_cachedMinorTicks)
+        {
+            _cachedMinorTicks = [];
+
+            var n:int;
+            var min:Number;
+            var max:Number;
+            var alen:Number;
+            var i:Number;
+            
+            if (_ticksBetweenLabels == false)
+            {
+                n = _categoryValues.length;
+                min = -_padding;
+                max = n - 1 + _padding;
+                alen = max - min;
+                
+                var start:Number = min <= -0.5 ? 0 : 1;
+                var end:Number = max >= n - 0.5 ? n : n - 1
+                
+                for (i = start; i <= end; i++) // <= to draw final tick
+                {
+                    _cachedMinorTicks.push((i - 0.5 - min) / alen);
+                }
+            }
+            else
+            {
+                n = _categoryValues.length;
+                min = -_padding;
+                max = n - 1 + _padding;
+                alen = max - min;
+                
+                for (i = 0; i < n; i++) // <= to draw final tick
+                {
+                    _cachedMinorTicks.push((i - min) / alen);
+                }
+            }
+        }
+
+        return _cachedMinorTicks;
+    }
+
+    //----------------------------------
+    //  padding
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the padding property.
+     */
+    private var _padding:Number = 0.5;
+    
+    [Inspectable(category="General")]
+
+    /**
+     *  Specifies the padding added to either side of the axis
+     *  when rendering data on the screen.
+     *  Set to 0 to map the first category to the
+     *  very beginning of the axis and the last category to the end.
+     *  Set to 0.5 to leave padding of half the width
+     *  of a category on the axis between the beginning of the axis
+     *  and the first category and between the last category
+     *  and the end of the axis.
+     *  
+     *  <p>This is useful for chart types that render beyond the bounds
+     *  of the category, such as columns and bars.
+     *  However, when used as the horizontalAxis in a LineChart or AreaChart,
+     *  it is reset to 0.</p>
+     *  
+     *  @default 0.5
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get padding():Number
+    {
+        return _padding;
+    }
+    
+    /**
+     *  @private
+     */
+    public function set padding(value:Number):void
+    {
+        _padding = value;
+
+        invalidateCategories();
+
+        dispatchEvent(new Event("mappingChange"));
+        dispatchEvent(new Event("axisChange"));
     }
     
+    //----------------------------------
+    //  ticksBetweenLabels
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the tickBetweenLabels property.
+     */
+    private var _ticksBetweenLabels:Boolean = true;
     
+    [Inspectable]
+
+    /**
+     *  Specifies the location of major tick marks on the axis,
+     *  relative to the category labels.
+     *  If <code>true</code>, tick marks (and any associated grid lines)
+     *  appear between the categories.
+     *  If <code>false</code>, tick marks appear in the middle of the category,
+     *  aligned with the label.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get ticksBetweenLabels():Boolean
+    {
+        return _ticksBetweenLabels;
+    }
+
+    /**
+     *  @private
+     */
+    public function set ticksBetweenLabels(value:Boolean):void
+    {
+        _ticksBetweenLabels = value;
+    }
+
+    //----------------------------------
+    //  workingDataProvider
+    //----------------------------------
+
+    /**
+     *  @private
+     */
+    private function set workingDataProvider(value:Object):void
+    {
+        if (_dataProvider != null)
+        {
+            _dataProvider.removeEventListener(
+                CollectionEvent.COLLECTION_CHANGE, collectionChangeHandler);
+        }
+        
+        if (value is Array)
+        {
+            value = new ArrayCollection(value as Array);
+        }
+        else if (value is ICollectionView)
+        {
+        }
+        else if (value is XMLList)
+        {
+            value = new XMLListCollection(XMLList(value));
+        }
+        else if (value != null)
+        {
+            value = new ArrayCollection([ value ]);
+        } 
+        else 
+        {
+            value = new ArrayCollection();
+        }
+            
+        _dataProvider = ICollectionView(value);
+
+        _cursor = value.createCursor();
+
+        if (_dataProvider) 
+        {
+            // weak listeners to collections and dataproviders
+            _dataProvider.addEventListener(
+                CollectionEvent.COLLECTION_CHANGE, collectionChangeHandler/*, false, 0, true*/);
+        }
+
+        collectionChangeHandler();
+    }
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Methods
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  @copy mx.charts.chartClasses.IAxis#mapCache()
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function mapCache(cache:Array /* of ChartItem */, field:String,
+                             convertedField:String,
+                             indexValues:Boolean = false):void
+    {
+        update();
+
+        var n:int = cache.length;
+        
+        // Find the first non null item in the cache so we can determine type.
+        // Since these initial values are null,
+        // we can safely skip assigning values for them.
+        for (var i:int = 0; i < n; i++)
+        {
+            if (cache[i][field] != null)
+                break;
+        }
+        if (i == n)
+            return;
+        
+        var value:Object = cache[i][field]
+        if (value is XML ||
+                 value is XMLList)
+        {
+            for (; i < n; i++)
+            {
+                cache[i][convertedField] = _catMap[cache[i][field].toString()];             
+            }
+        }
+        else if ((value is Number || value is int || value is uint) &&
+                 indexValues == true)
+        {
+            for (i = 0; i < n; i++)
+            {
+                var v:Object = cache[i];
+                v[convertedField] = v[field];
+            }
+        }
+        else
+        {
+            for (; i < n; i++)
+            {
+                cache[i][convertedField] = _catMap[cache[i][field]];                
+            }
+        }
+        
+    }
+
+    /**
+     *  @copy mx.charts.chartClasses.IAxis#filterCache()
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function filterCache(cache:Array /* of ChartItem */, field:String,
+                                filteredField:String):void
+    {
+        update();
+
+        // Our bounds are the categories, plus/minus padding,
+        // plus a little fudge factor to account for floating point errors.
+        var computedMaximum:Number = _categoryValues.length - 1 +
+                                     _padding + 0.000001;
+        var computedMinimum:Number = -_padding - 0.000001;
+        
+        var n:int = cache.length;
+        for (var i:int = 0; i < n; i++)
+        {
+            var v:Number =  cache[i][field];
+            cache[i][filteredField] = v >= computedMinimum &&
+                                      v < computedMaximum ?
+                                      v :
+                                      NaN;
+        }
+    }
+
+    /**
+     *  @copy mx.charts.chartClasses.IAxis#transformCache()
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function transformCache(cache:Array /* of ChartItem */, field:String,
+                                   convertedField:String):void
+    {
+        update();
+
+        var min:Number = -_padding;
+        var max:Number = _categoryValues.length - 1 + _padding;
+        var alen:Number = max - min;
+
+        var n:int = cache.length;
+        for (var i:int = 0; i < n; i++)
+        {
+            cache[i][convertedField] = (cache[i][field] - min) / alen;
+        }
+    }
+
+    /**
+     *  @copy mx.charts.chartClasses.IAxis#invertTransform()
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function invertTransform(value:Number):Object
+    {
+        update();
+
+        var min:Number = -_padding;
+        var max:Number = _categoryValues.length - 1 + _padding;
+        var alen:Number = max - min;
+
+        return _categoryValues[Math.round((value * alen) + min)];
+    }
 
     /**
      *  @copy mx.charts.chartClasses.IAxis#formatForScreen()
@@ -313,20 +746,305 @@ public class CategoryAxis extends UIComponent implements IAxis
      *  @langversion 3.0
      *  @playerversion Flash 9
      *  @playerversion AIR 1.1
-     *  @productversion Royale 0.9.3
+     *  @productversion Flex 3
      */
     public function formatForScreen(value:Object):String    
     {
-       /*  if (value is Number && value < _categoryValues.length)
+        if (value is Number && value < _categoryValues.length)
         {
             var catValue:Object = _categoryValues[Math.round(Number(value))];
             return catValue == null ? value.toString() : catValue.toString();
         }
-		*/ 
+
         return value.toString();    
     }
 
+    /**
+     *  @copy mx.charts.chartClasses.IAxis#getLabelEstimate()
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function getLabelEstimate():AxisLabelSet
+    {
+        update();
+
+        return _labelSet;
+    }
+
+    /**
+     *  @copy mx.charts.chartClasses.IAxis#preferDropLabels()
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function preferDropLabels():Boolean
+    {
+        return false;
+    }
+
+    /**
+     *  @copy mx.charts.chartClasses.IAxis#getLabels()
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function getLabels(minimumAxisLength:Number):AxisLabelSet
+    {
+        update();
+
+        return _labelSet;
+    }
+
+    /**
+     *  @copy mx.charts.chartClasses.IAxis#reduceLabels()
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function reduceLabels(intervalStart:AxisLabel,intervalEnd:AxisLabel):AxisLabelSet
+    {
+        var skipCount:int = _catMap[intervalEnd.value] - _catMap[intervalStart.value] + 1;
+        
+        if (skipCount <= 0)
+            return null;
+            
+        var newLabels:Array /* of AxisLabel */ = [];
+        var newTicks:Array /* of Number */ = [];
+        
+        var min:Number = -_padding;
+        var max:Number = _categoryValues.length - 1 + _padding;
+        var alen:Number = (max-min);
+		
+		var n:int  = _categoryValues.length;
+		for (var i:int = 0; i < n; i += skipCount)
+        {
+            newLabels.push(_labelsMatchToCategoryValuesByIndex[i]);
+            newTicks.push(_labelsMatchToCategoryValuesByIndex[i].position);
+        }
+        
+        var axisLabelSet:AxisLabelSet = new AxisLabelSet();
+        axisLabelSet.labels = newLabels;
+        axisLabelSet.minorTicks = minorTicks;
+        axisLabelSet.ticks = generateTicks();
+        return axisLabelSet;
+    }
+
+    /**
+     *  @copy mx.charts.chartClasses.IAxis#update()
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function update():void
+    {
+        if (!_labelSet)
+        {
+            var prop:Object;
+            
+            _catMap = {};
+            _categoryValues = [];
+            _labelsMatchToCategoryValuesByIndex = [];
+
+            var categoryItems:Array = [];
+            var i:int;
+            
+            if (_dataFunction != null)
+            {
+                _cursor.seek(CursorBookmark.FIRST);
+                i = 0;
+                while (!_cursor.afterLast)
+                {
+                    categoryItems[i] = _cursor.current;
+                    prop = dataFunction(this,categoryItems[i]);
+                    if (prop)
+                      _catMap[prop.toString()] = i;                   
+                    _categoryValues[i] = prop;
+                    i++;
+                    _cursor.moveNext()
+                }
+            }
+            
+            else if (_categoryField == "")
+            {
+                _cursor.seek(CursorBookmark.FIRST);
+                i = 0;
+                while (!_cursor.afterLast)
+                {
+                    prop = _cursor.current;
+                    if (prop != null)
+                        _catMap[prop.toString()] = i;                   
+                    _categoryValues[i] = categoryItems[i] = prop;
+                    _cursor.moveNext();
+                    i++;
+                }
+            }
+            else
+            {
+                _cursor.seek(CursorBookmark.FIRST);
+                i = 0;
+                while (!_cursor.afterLast)
+                {
+                    categoryItems[i] = _cursor.current;
+                    if (categoryItems[i] && _categoryField in categoryItems[i])
+                    {
+                        prop = categoryItems[i][_categoryField];
+                        if (prop != null)
+                            _catMap[prop.toString()] = i;                   
+                        _categoryValues[i] = prop;
+                    }
+                    else
+                    {
+                        _categoryValues[i] = null;
+                    }
+                    i++;
+                    _cursor.moveNext()
+                }
+            }
+
+            var axisLabels:Array /* of AxisLabel */ = [];
+            
+            var min:Number = -_padding;
+            var max:Number = _categoryValues.length - 1 + _padding;
+            var alen:Number = max - min;
+            var label:AxisLabel;
+
+            var n:int = _categoryValues.length;
+            if (_labelFunction != null)
+            {
+                var previousValue:Object = null;
+                for (i = 0; i < n; i++)
+                {
+                    if (_categoryValues[i] == null)
+                        continue;
+                        
+                    label = new AxisLabel((i - min) / alen, _categoryValues[i],
+                        _labelFunction(_categoryValues[i], previousValue,
+                        this, categoryItems[i]));
+                    _labelsMatchToCategoryValuesByIndex[i] = label;
+                    axisLabels.push(label);
+
+                    previousValue = _categoryValues[i];
+                }
+            }
+            else
+            {
+                for (i = 0; i < n; i++)
+                {
+                    if (!_categoryValues[i])
+                        continue;
+                    
+                    label = new AxisLabel((i - min) / alen, _categoryValues[i],
+                        _categoryValues[i].toString());
+                    _labelsMatchToCategoryValuesByIndex[i] = label;
+                    axisLabels.push(label);
+                }               
+            }
+
+            _labelSet = new AxisLabelSet();
+            _labelSet.labels = axisLabels;
+            _labelSet.accurate = true;
+            _labelSet.minorTicks = minorTicks;
+            _labelSet.ticks = generateTicks();          
+        }
+    }
+
+    /**
+     *  @private
+     */
+    private function generateTicks():Array /* of Number */
+    {
+        if (!_cachedTicks)
+        {
+            _cachedTicks = [];
+
+            var n:int;
+            var min:Number;
+            var max:Number;
+            var alen:Number;
+            var i:Number;
+            
+            if (_ticksBetweenLabels == false)
+            {
+                n = _categoryValues.length;
+                min = -_padding;
+                max = n - 1 + _padding;
+                alen = max - min;
+                
+                for (i = 0; i < n; i++) // <= to draw final tick
+                {
+                    _cachedTicks.push((i - min) / alen);
+                }
+            }
+            else
+            {
+                _cachedMinorTicks = [];
+                
+                n = _categoryValues.length;
+                min = -_padding;
+                max = n - 1 + _padding;
+                alen = max - min;
+                
+                var start:Number = _padding < 0.5 ? 0.5 : -0.5;
+                var end:Number = _padding < 0.5 ? n - 1.5 : n - 0.5;
+                
+                for (i = start; i <= end; i += 1)
+                {
+                    _cachedTicks.push((i - min) / alen);
+                }
+            }
+        }
+
+        return _cachedTicks;
+    }
+    
+    /**
+     *  @private
+     */
+    private function invalidateCategories():void
+    {
+        _labelSet = null;
+        _cachedMinorTicks = null;
+        _cachedTicks = null;
+
+        dispatchEvent(new Event("mappingChange"));
+        dispatchEvent(new Event("axisChange"));
+    }
+    
+    /**
+     *  @private
+     */
+    mx_internal function getCategoryValues():Array /* of Object */
+    {
+        return _categoryValues;
+    }
     
+    //--------------------------------------------------------------------------
+    //
+    //  Event handlers
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    private function collectionChangeHandler(event:CollectionEvent = null):void
+    {
+        if (event && event.kind == CollectionEventKind.RESET)
+            _cursor = _dataProvider.createCursor();
+
+        invalidateCategories();
+    }
     
 }
 
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/ChartItem.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/ChartItem.as
index 8405abc..8f72978 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/ChartItem.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/ChartItem.as
@@ -20,15 +20,13 @@
 package mx.charts
 {
 
-
 import org.apache.royale.events.Event;
 import org.apache.royale.events.EventDispatcher;
-import org.apache.royale.events.IEventDispatcher;
+import mx.charts.chartClasses.IChartElement;
 import mx.core.IFlexDisplayObject;
 import mx.core.IInvalidating;
-/* import mx.core.IProgrammaticSkin;
- */
- import mx.core.IUIComponent;
+import mx.core.IProgrammaticSkin;
+import mx.core.IUIComponent;
 
 /**
  *  A ChartItem represents a single item in a ChartSeries.
@@ -42,14 +40,73 @@ import mx.core.IInvalidating;
  *  @langversion 3.0
  *  @playerversion Flash 9
  *  @playerversion AIR 1.1
- *  @productversion Royale 0.9.3
- *  @royalesuppresspublicvarwarning
+ *  @productversion Flex 3
  */
 public class ChartItem extends EventDispatcher
 {
-/*     include "../core/Version.as";
- */
-   
+//    include "../core/Version.as";
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class Constants
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  Value that indicates the ChartItem has focus but does not appear to be selected.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public static const FOCUSED:String = "focused";
+    /**
+     *  Value that indicates the ChartItem appears selected but does not have focus.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public static const SELECTED:String = "selected";
+    /**
+     *  Value that indicates the ChartItem appears to have focus and appears to be selected.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public static const FOCUSEDSELECTED:String = "focusedSelected";
+    /**
+     *  Value that indicates the ChartItem appears as if the mouse was over it.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public static const ROLLOVER:String = "rollOver";
+    /**
+     *  Value that indicates the ChartItem appears disabled and cannot be selected.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public static const DISABLED:String = "disabled";
+    /**
+     *  Value that indicates the ChartItem does not appear to be selected, does not have focus, and is not being rolled over.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public static const NONE:String = "none";
+        
     //--------------------------------------------------------------------------
     //
     //  Constructor
@@ -70,17 +127,17 @@ public class ChartItem extends EventDispatcher
      *  @langversion 3.0
      *  @playerversion Flash 9
      *  @playerversion AIR 1.1
-     *  @productversion Royale 0.9.3
+     *  @productversion Flex 3
      */
-    public function ChartItem(element:Object = null,
+    public function ChartItem(element:IChartElement = null,
                               item:Object = null, index:uint = 0)
     {
         super();
 
-     //   this.element = element;
+        this.element = element;
         this.item = item;
         this.index = index;
-     //   this._currentState = ChartItem.NONE;
+        this._currentState = ChartItem.NONE;
     }
     
     //--------------------------------------------------------------------------
@@ -89,7 +146,67 @@ public class ChartItem extends EventDispatcher
     //
     //--------------------------------------------------------------------------
 
-  
+    //----------------------------------
+    //  currentstate
+    //----------------------------------
+    
+    /**
+     *  @private
+     *  Storage for the currentState property.
+     */
+    private var _currentState:String = "";
+    
+    [Inspectable(environment="none")]
+    
+   /**
+     *  Defines the appearance of the ChartItem.
+     *  The <code>currentState</code> property can be set to <code>none</code>, <code>rollOver</code>, 
+     *  <code>selected</code>, <code>disabled</code>, <code>focusSelected</code>, and <code>focused</code>.
+     * 
+     *  <P>Setting the state of the item does not add it to the selectedItems Array. It only changes 
+     *  the appearance of the chart item. Setting the value of this property also does not trigger a 
+     *  <code>change</code> event.</P>
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get currentState():String
+    {
+        return _currentState;
+    }
+
+    /**
+     *  @private
+     */     
+    public function set currentState(value:String):void
+    {
+        if (_currentState != value)
+        {
+            _currentState = value;
+            
+            if (itemRenderer && (itemRenderer is IProgrammaticSkin || itemRenderer is IUIComponent))
+                (itemRenderer as Object).invalidateDisplayList();   
+        }
+    }
+    
+    //----------------------------------
+    //  element
+    //----------------------------------
+
+    [Inspectable(environment="none")]
+
+    /**
+     *  The series or element that owns the ChartItem.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public var element:IChartElement;
+    
     //----------------------------------
     //  index
     //----------------------------------
@@ -103,7 +220,7 @@ public class ChartItem extends EventDispatcher
      *  @langversion 3.0
      *  @playerversion Flash 9
      *  @playerversion AIR 1.1
-     *  @productversion Royale 0.9.3
+     *  @productversion Flex 3
      */
     public var index:int;
     
@@ -119,13 +236,49 @@ public class ChartItem extends EventDispatcher
      *  @langversion 3.0
      *  @playerversion Flash 9
      *  @playerversion AIR 1.1
-     *  @productversion Royale 0.9.3
+     *  @productversion Flex 3
      */
     public var item:Object;
 
-   
+    //----------------------------------
+    //  itemRenderer
+    //----------------------------------
 
-   
+    [Inspectable(environment="none")]
+
+    /**
+     *  The instance of the chart's itemRenderer
+     *  that represents this ChartItem.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public var itemRenderer:IFlexDisplayObject;
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Methods
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Returns a copy of this ChartItem.
+     * 
+     *  @return A copy of this ChartItem.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function clone():ChartItem
+    {       
+        var result:ChartItem = new ChartItem(element, item, index);
+        result.itemRenderer = itemRenderer;
+        return result;
+    }
 }
     
 }
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/ColumnChart.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/ColumnChart.as
index 70579ae..093cb79 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/ColumnChart.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/ColumnChart.as
@@ -1,47 +1,1216 @@
-////////////////////////////////////////////////////////////////////////////////
-//
-//  Licensed to the Apache Software Foundation (ASF) under one or more
-//  contributor license agreements.  See the NOTICE file distributed with
-//  this work for additional information regarding copyright ownership.
-//  The ASF licenses this file to You under the Apache License, Version 2.0
-//  (the "License"); you may not use this file except in compliance with
-//  the License.  You may obtain a copy of the License at
-//
-//      http://www.apache.org/licenses/LICENSE-2.0
-//
-//  Unless required by applicable law or agreed to in writing, software
-//  distributed under the License is distributed on an "AS IS" BASIS,
-//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-//  See the License for the specific language governing permissions and
-//  limitations under the License.
-//
-////////////////////////////////////////////////////////////////////////////////
-package mx.charts
-{
-	import org.apache.royale.charts.ColumnChart;
-	import mx.charts.chartClasses.ChartBase;
-	/**
-	 *  The ColumnChart displays a histogram chart where each series in
-	 *  in the chart is a vertical column placed side by side. 
-	 *  
-	 *  @langversion 3.0
-	 *  @playerversion Flash 10.2
-	 *  @playerversion AIR 2.6
-	 *  @productversion Royale 0.0
-	 */
-	public class ColumnChart extends ChartBase
-	{
-		/**
-		 *  constructor. 
-		 *  
-		 *  @langversion 3.0
-		 *  @playerversion Flash 10.2
-		 *  @playerversion AIR 2.6
-		 *  @productversion Royale 0.0
-		 */
-		public function ColumnChart()
-		{
-			super();
-		}
-	}
-}
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.charts
+{
+
+//import flash.filters.DropShadowFilter;
+import org.apache.royale.reflection.getDefinitionByName;
+
+import mx.charts.chartClasses.CartesianChart;
+import mx.charts.chartClasses.CartesianTransform;
+import mx.charts.chartClasses.DataTip;
+import mx.charts.chartClasses.DataTransform;
+import mx.charts.chartClasses.IChartElement;
+import mx.charts.chartClasses.IStackable;
+import mx.charts.chartClasses.NumericAxis;
+import mx.charts.chartClasses.Series;
+import mx.charts.series.ColumnSeries;
+import mx.charts.series.ColumnSet;
+import mx.charts.series.items.ColumnSeriesItem;
+import mx.charts.styles.HaloDefaults;
+import mx.core.IFlexModuleFactory;
+import mx.core.UIComponent;
+import mx.core.mx_internal;
+import mx.graphics.SolidColor;
+import mx.graphics.SolidColorStroke;
+import mx.graphics.Stroke;
+import mx.styles.CSSStyleDeclaration;
+
+use namespace mx_internal;
+
+//--------------------------------------
+//  Styles
+//--------------------------------------
+
+/**
+ *  Specifies a ratio of wide to draw the columns relative to
+ *  the category width, as a percentage in the range of 0 to 1. 
+ *  A value of 1 uses the entire space, while a value of 0.6
+ *  uses 60% of the column's available space.  
+ *  The actual column width used is the smaller of the
+ *  <code>columnWidthRatio</code> property and the
+ *  <code>maxColumnWidth</code> property.
+ *  Clustered columns divide this space proportionally
+ *  among the columns in each cluster. 
+ *  The default value is 0.65.
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="columnWidthRatio", type="Number", inherit="no")]
+
+/**
+ *  Specifies how wide to draw the columns, in pixels.
+ *  The actual column width used is the smaller of this property
+ *  and the <code>columnWidthRatio</code> property.
+ *  Clustered columns divide this space proportionally
+ *  among the columns in each cluster. 
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+[Style(name="maxColumnWidth", type="Number", format="Length", inherit="no")]
+
+/**
+ *  The class that is used by this component to render labels.
+ *
+ *  <p>It can be set to either the mx.controls.Label class
+ *  or the spark.components.Label class.</p>
+ *
+ *  @default spark.components.Label
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 10.2
+ *  @playerversion AIR 2.0
+ *  @productversion Flex 4
+ */
+[Style(name="labelClass", type="Class", inherit="no")]
+
+//--------------------------------------
+//  Other metadata
+//--------------------------------------
+
+[DefaultBindingProperty(destination="dataProvider")]
+
+[DefaultTriggerEvent("itemClick")]
+
+//[IconFile("ColumnChart.png")]
+
+/**
+ *  The ColumnChart control represents data as a series of vertical columns
+ *  whose height is determined by values in the data.  
+ *  You can use the ColumnChart to represent a variety of different charts
+ *  including simple columns, clustered columns, stacked,
+ *  100% stacked, and high/low. 
+ *  
+ *  <p>A ColumnChart control expects its <code>series</code> property
+ *  to contain an array of ColumnSeries objects.</p>
+ *
+ *  <p>Stacked and 100% column charts override the <code>minField</code>
+ *  property of their ColumnSeries objects.</p>
+ *
+ *  @mxml
+ *  
+ *  <p>The <code>&lt;mx:ColumnChart&gt;</code> tag inherits all the properties
+ *  of its parent classes and adds the following properties:</p>
+ *  
+ *  <pre>
+ *  &lt;mx:ColumnChart
+ *    <strong>Properties</strong>
+ *    extendLabelToEnd="false|true"
+ *    maxLabelWidth="<i>50</i>"
+ *    showLabelVertically="false|true"
+ *    type="<i>clustered|overlaid|stacked|100%</i>"
+ * 
+ *    <strong>Styles</strong>
+ *    columnWidthRatio=".65"
+ *    maxColumnWidth="<i>No default</i>"
+ *  /&gt;
+ *  </pre>
+ *  
+ *  @includeExample examples/Column_BarChartExample.mxml
+ *  
+ *  @see mx.charts.series.ColumnSeries
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public class ColumnChart extends CartesianChart
+{
+//    include "../core/Version.as";
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class initialization
+    //
+    //--------------------------------------------------------------------------
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class constants
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    private static var INVALIDATING_STYLES:Object =
+    {
+        columnWidthRatio: 1,
+        maxColumnWidth: 1
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  Constructor.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function ColumnChart()
+    {
+        super();
+
+        LinearAxis(horizontalAxis).autoAdjust = false;
+        
+        dataTipMode = "single";
+
+        seriesFilters = [ /*new DropShadowFilter(2, 45, 0.2 * 0xFFFFFF)*/];
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  @private
+     */
+//    private static var _moduleFactoryInitialized:Dictionary = new Dictionary(true);
+    
+    
+    /**
+     *  @private
+     */
+    private var _perSeriescolumnWidthRatio:Number;
+    
+    /**
+     *  @private
+     */
+    private var _perSeriesMaxColumnWidth:Number;
+    
+    /**
+     *  @private
+     */
+    private var _leftOffset:Number;
+    
+    /**
+     * @private
+     */
+    mx_internal var allLabelsMeasured: Boolean = false;
+    
+    /**
+     * @private
+     */
+    private var _allItems:Array /* of ChartItem */ = [];
+    
+    /**
+     * @private
+     */
+    private var _needLabels:Boolean = false;
+    
+    /**
+     * @private
+     */
+    private var _tempField:Object;   
+    //--------------------------------------------------------------------------
+    //
+    //  Properties
+    //
+    //--------------------------------------------------------------------------
+    
+    //---------------------------------
+    // extendLabelToEnd
+    //---------------------------------
+    /**
+     * @private
+     * Storage for extendLabelToEnd property
+     */
+    private var _extendLabelToEnd:Boolean = false;
+    
+    [Inspectable(category="General")]
+    
+    /**
+     * Determines whether or not data labels can extend to the end of the chart.
+     * If you set this to true, labels can use the whole space between the item
+     * and the boundary of the chart to show its label. Otherwise, data labels are
+     * restricted to the area defined by their chart item.
+     * 
+     * @default false
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+     public function get extendLabelToEnd():Boolean
+     {
+        return _extendLabelToEnd;
+     }
+     
+    /**
+     * @private
+     */
+     public function set extendLabelToEnd(value:Boolean):void
+     {
+        _extendLabelToEnd = value;
+        measureLabels();
+     }
+    
+    //---------------------------------
+    // maxLabelWidth
+    //---------------------------------
+    
+    /**
+     * @private
+     * Storage for maxLabelWidth property
+     */
+    private var _maxLabelWidth:int = 50;
+    
+    [Inspectable(category="General")]
+    
+    /**
+     * Determines maximum width in pixels of label of items.
+     * 
+     * @default 50
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+     public function get maxLabelWidth():int
+     {
+        return _maxLabelWidth;
+     }
+     
+    /**
+     * @private
+     */
+     public function set maxLabelWidth(value:int):void
+     {
+        _maxLabelWidth = value;
+        measureLabels();
+     }
+     
+    //---------------------------------
+    // showLabelVertically
+    //---------------------------------
+    /**
+     * @private
+     * Storage for showLabelVertically property
+     */
+    private var _showLabelVertically:Boolean = false;
+    
+    [Inspectable(category="General")]
+    
+    /**
+     * Determines whether or not the data labels can be shown vertically.
+     * If you set this to true and if embedded fonts are used, labels will be shown vertically
+     * if they cannot be fit horizontally within the column width.
+     * 
+     * @default false
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+     public function get showLabelVertically():Boolean
+     {
+        return _showLabelVertically;
+     }
+     
+    /**
+     * @private
+     */
+     public function set showLabelVertically(value:Boolean):void
+     {
+        _showLabelVertically = value;
+        measureLabels();
+     }
+    
+    //----------------------------------
+    //  type
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the type property.
+     */
+    private var _type:String = "clustered";
+    
+    [Inspectable(category="General", enumeration="stacked,100%,clustered,overlaid", defaultValue="clustered")]
+
+    /**
+     *  The type of the column chart.
+     *
+     *  <p>Possible values are:</p>
+     *  <ul>
+     *    <li><code>"clustered"</code>:
+     *    Values from different series are grouped by category.
+     *    This is the default type.</li>
+     *    <li><code>"overlaid"</code>:
+     *    Multiple values are rendered on top of one another by category,
+     *    with the last series on top. </li>
+     *    <li><code>"stacked"</code>:
+     *    Columns are stacked on top of each other and grouped by category. 
+     *    Each column represents the cumulative value
+     *    of the columns beneath it. </li>
+     *    <li><code>"100%"</code>:
+     *    Columns are stacked on top of each other, adding up to 100%. 
+     *    Each column represents the percent that it contributes
+     *    to the sum of the values for that category.</li>
+     *  </ul>
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get type():String
+    {
+        return _type;
+    }
+
+    /**
+     *  @private
+     */
+    public function set type(value:String):void
+    {
+        if (_type == value)
+            return;
+            
+        _type = value;
+
+        invalidateSeries();
+        invalidateData();
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: UIComponent
+    //
+    //--------------------------------------------------------------------------
+    
+	/**
+     *  @private
+     */
+    private function initStyles():Boolean
+    {
+        HaloDefaults.init(styleManager);
+		
+		var columnChartStyle:CSSStyleDeclaration = HaloDefaults.findStyleDeclaration(styleManager, "mx.charts.ColumnChart");
+		if (columnChartStyle)
+		{
+			columnChartStyle.setStyle("chartSeriesStyles", HaloDefaults.chartBaseChartSeriesStyles);
+			columnChartStyle.setStyle("fill", new SolidColor(0xFFFFFF, 0));
+			columnChartStyle.setStyle("calloutStroke", new SolidColorStroke(0x888888,2));
+			columnChartStyle.setStyle("horizontalAxisStyleNames", ["blockCategoryAxis"]);
+			columnChartStyle.setStyle("verticalAxisStyleNames", ["blockNumericAxis"]);
+		}		
+        return true;
+    }
+
+    
+    /**
+     *   A module factory is used as context for using embedded fonts and for finding the style manager that controls the styles for this component.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function set moduleFactory(factory:IFlexModuleFactory):void
+    {
+        super.moduleFactory = factory;
+        
+        /*
+        if (_moduleFactoryInitialized[factory])
+            return;
+        
+        _moduleFactoryInitialized[factory] = true;
+        */
+        
+        // our style settings
+        initStyles();
+    }
+    
+    /**
+     * @private
+     */
+    override protected function createChildren():void
+    {
+        super.createChildren();
+        var labelClass:Class = getLabelClass();
+        _tempField = new labelClass();
+        _tempField.visible = false;
+        _tempField.text = "W...";
+        _tempField.toolTip = "";
+        addChild(_tempField as UIComponent);
+        _tempField.validateNow();
+    }
+    
+    private function getLabelClass():Class
+    {
+        var labelClass:Class = getStyle("labelClass");
+        if(labelClass == null)
+        {
+            try{
+                labelClass = Class(getDefinitionByName("spark.components::Label"));
+            }
+            catch(e:Error)
+            {
+                labelClass = Class(getDefinitionByName("mx.controls::Label"));
+            }
+        }
+        return labelClass;
+    }
+
+    /**
+     *  @private
+     */
+    override public function styleChanged(styleProp:String):void
+    {
+        if (styleProp == null || INVALIDATING_STYLES[styleProp] != undefined)
+            invalidateSeries();
+
+        super.styleChanged(styleProp);
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden methods: ChartBase
+    //
+    //--------------------------------------------------------------------------
+
+    /**
+     *  @private
+     */
+    override protected function customizeSeries(seriesGlyph:Series, i:uint):void
+    {
+        if (seriesGlyph is ColumnSeries || seriesGlyph is ColumnSet)
+        {
+            var series:Object = seriesGlyph;
+            
+            if (!isNaN(_perSeriescolumnWidthRatio))
+                series.columnWidthRatio = _perSeriescolumnWidthRatio;
+
+            if (!isNaN(_perSeriesMaxColumnWidth))
+                series.maxColumnWidth = _perSeriesMaxColumnWidth;
+
+            if (_type == "overlaid")        
+                series.offset = 0;
+            else
+                series.offset = _leftOffset + i * _perSeriescolumnWidthRatio;
+    
+            if (series is IStackable)
+            {
+                var stackSeries:IStackable = IStackable(series);
+                stackSeries.stacker = null;
+                stackSeries.stackTotals = null;
+            }
+        }
+    }
+    
+    /**
+     *  @private
+     */
+    override protected function applySeriesSet(seriesSet:Array /* of Series */,
+                                               transform:DataTransform):Array /* of Series */
+    {
+        var columnWidthRatio:Number = getStyle("columnWidthRatio");
+        var maxColumnWidth:Number = getStyle("maxColumnWidth");
+        var g:IChartElement;
+        
+        switch (_type)
+        {
+            case "stacked":
+            case "100%":
+            {
+                var n:int = seriesSet.length;
+                var i:int;
+                for (i = 0; i < n; i++)
+                {
+                    seriesSet[i].offset = 0;
+                }
+
+                var newSeriesGlyph:ColumnSet = new ColumnSet();
+                newSeriesGlyph.owner = this;
+                newSeriesGlyph.series = seriesSet;
+                for (i = 0; i < n; i++)
+                {
+                    g = seriesSet[i] as IChartElement;
+                    newSeriesGlyph.series[i].owner = newSeriesGlyph;
+                    if (!g)
+                        continue;
+                    if (g.labelContainer)           
+                        newSeriesGlyph.labelContainer.addChild(seriesSet[i].labelContainer);
+                }
+                
+                if (!isNaN(columnWidthRatio))
+                    newSeriesGlyph.columnWidthRatio = _perSeriescolumnWidthRatio;
+
+                if (!isNaN(maxColumnWidth))
+                    newSeriesGlyph.maxColumnWidth = _perSeriesMaxColumnWidth;
+
+                newSeriesGlyph.type = _type;
+
+                invalidateData();
+            
+                return [ newSeriesGlyph ];
+            }               
+
+            case "clustered":
+            default:
+            {
+                
+                var columnSeriesCount:int = 0;
+                for each(var series:Series in seriesSet) {
+                    if(series is ColumnSet || series is ColumnSeries)
+                        columnSeriesCount++;
+                }
+                
+                _perSeriescolumnWidthRatio = columnWidthRatio / columnSeriesCount;
+                _perSeriesMaxColumnWidth = maxColumnWidth / columnSeriesCount;
+                
+                _leftOffset = (1 - columnWidthRatio) / 2 +
+                              _perSeriescolumnWidthRatio / 2 - 0.5;
+
+                n = seriesSet.length;
+                var count:int = 0;
+                for (i = 0; i < n; i++)
+                {
+                    var newSeries:IChartElement = seriesSet[i];
+                    if (newSeries is ColumnSeries || newSeries is ColumnSet)
+                    {
+                        customizeSeries(Series(seriesSet[i]), count);
+                        count++;
+                    }
+                }
+                
+                return seriesSet;
+            }
+
+            case "overlaid":
+            {
+                _perSeriescolumnWidthRatio = columnWidthRatio;
+                _perSeriesMaxColumnWidth = maxColumnWidth;
+
+                _leftOffset = 0;
+                return super.applySeriesSet(seriesSet, transform);
+            }
+        }
+    }           
+    
+    /**
+     * Determines positions and dimensions of labels for all series in the chart
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override mx_internal function measureLabels():Object
+    {
+        getSeriesLabelPosSet();
+        if (!_needLabels)
+            return null;
+        var len:int = series.length;
+        var n:int;
+        var allSeriesTransform:Boolean = true;
+        
+        if (type == "stacked" || type == "overlaid" || type == "100%")
+            allLabelsMeasured = false;
+        
+        _allItems = [];
+        n = len;
+        for (var i:int = 0; i < n; i++)
+        {
+            findChartItems(series[i]);           
+        }
+        
+        _allItems.sort(sortOnX);    //sort all items with respect to their position along X-axis
+        
+        var itemsLen:Number = _allItems.length;
+        n = itemsLen;
+        for (i = 0; i < n; i++)
+        {
+            var v:ColumnSeriesItem = _allItems[i];
+            var columnSeries:ColumnSeries = ColumnSeries(ColumnSeriesItem(_allItems[i]).element);
+            var labelPosition:String = columnSeries.labelPos;
+                
+            if (labelPosition == "inside" || labelPosition == "outside")
+            {
+                var base:Number = columnSeries.seriesRenderData.renderedBase;
+                var size:Number = columnSeries.getStyle('fontSize');
+                if (columnSeries.labelFunction != null)
+                    columnSeries.measuringField.text = v.labelText = columnSeries.labelFunction(v, columnSeries);
+                else if (columnSeries.labelField != null)
+                    columnSeries.measuringField.text = v.labelText = v.item[columnSeries.labelField];
+                else if (columnSeries.dataFunction != null)
+                    columnSeries.measuringField.text = v.labelText = columnSeries.dataFunction(columnSeries, v.item, 'yNumber');
+                else
+                    columnSeries.measuringField.text = v.labelText = v.item[columnSeries.yField];       
+        
+                //columnSeries.measuringField.validateNow();
+            
+                var labelRotation:Number = columnSeries.labelAngle;
+                var labelSizeLimit:Number = columnSeries.maxLabelSize;
+            
+                if (labelPosition == "outside" && (type == "overlaid" || type == "stacked" || type == "100%"))
+                {
+                    columnSeries.labelPos = 'inside';
+                    labelPosition = "inside";
+                        // today, labelPosition = inside is only supported for 100%, stacked and overlaid charts
+                }   
+                           
+        
+                if (labelPosition == 'outside')
+                {
+                    if (!showLabelVertically)
+                    {  
+                        v.labelIsHorizontal = true;
+                        if (extendLabelToEnd)
+                        {
+                            v.labelWidth = Math.abs((this.dataRegion.right - 
+                                           (v.x + columnSeries.seriesRenderData.renderedXOffset - 
+                                           columnSeries.seriesRenderData.renderedHalfWidth))/ Math.cos(0));
+                        }
+                        else
+                        {
+                            v.labelWidth = Math.min(Math.abs((this.dataRegion.right -  
+                                           (v.x + columnSeries.seriesRenderData.renderedXOffset - 
+                                           columnSeries.seriesRenderData.renderedHalfWidth))/ Math.cos(0)),maxLabelWidth);
+                        }                           
+                        v.labelHeight = columnSeries.measuringField.textHeight + 2;
+                    }
+                    else
+                    {                   //check whether labels can be rendered horizontally
+                        v.labelIsHorizontal = true;
+                        v.labelWidth = 2 * columnSeries.seriesRenderData.renderedHalfWidth;
+                        v.labelHeight = columnSeries.measuringField.textHeight + 2;
+                        
+                        /*
+                        if (columnSeries.measuringField.textWidth + 5 > 2 * columnSeries.seriesRenderData.renderedHalfWidth &&
+                        columnSeries.measuringField.embedFonts)
+                        {
+                            v.labelIsHorizontal = false;
+                            v.labelHeight = 2 * columnSeries.seriesRenderData.renderedHalfWidth;
+                            if (!(isNaN(labelRotation)) && labelRotation!=-90)
+                            {
+                                var r:Number = -labelRotation / Math.PI * 180;
+                                        //for future enhancement
+                                        //check for type of chart if we need to support labelPosition = outside for all types of charts
+                                if (type == "clustered")
+                                {
+                                    if (i < itemsLen - len)
+                                    {
+                                        v.labelWidth = Math.abs((_allItems[i + len - i%len].x + ColumnSeries(_allItems[i + len - i%len].element).seriesRenderData.renderedXOffset
+                                                       - ColumnSeries(_allItems[i + len - i%len].element).seriesRenderData.renderedHalfWidth -
+                                                       (v.x + columnSeries.seriesRenderData.renderedXOffset - 
+                                                       columnSeries.seriesRenderData.renderedHalfWidth))/ Math.cos(r));
+                                    }
+                                    else
+                                        v.labelWidth = Math.abs((_allItems[itemsLen -1].x + ColumnSeries(_allItems[itemsLen - 1].element).seriesRenderData.renderedXOffset
+                                                       + ColumnSeries(_allItems[itemsLen - 1].element).seriesRenderData.renderedHalfWidth - 
+                                                       (v.x + columnSeries.seriesRenderData.renderedXOffset - 
+                                                       columnSeries.seriesRenderData.renderedHalfWidth))/ Math.cos(r));
+                                }
+                            }
+                            else
+                            {
+                                if (v.y < (isNaN(v.min) ? base : v.min))
+                                {   
+                                    v.labelWidth = columnSeries.dataToLocal(0,v.yNumber).y - columnSeries.dataToLocal(0,NumericAxis(columnSeries.dataTransform.getAxis(CartesianTransform.VERTICAL_AXIS)).computedMaximum).y;
+                                    v.labelY = v.y;
+                                    if (v.labelY < this.dataRegion.top)
+                                    {
+                                        v.labelWidth = Math.abs(v.y -(isNaN(v.min) ? base : v.min));
+                                        v.labelY = isNaN(v.min) ? base : v.min;
+                                    }
+                                }
+                                else
+                                {
+                                    v.labelWidth = columnSeries.dataToLocal(0,NumericAxis(columnSeries.dataTransform.getAxis(CartesianTransform.VERTICAL_AXIS)).computedMinimum).y - columnSeries.dataToLocal(0,v.yNumber).y;
+                                    v.labelY = v.y + v.labelWidth;
+                                    if (v.labelY > this.dataRegion.bottom)
+                                    {
+                                        v.labelWidth = Math.abs(v.y -(isNaN(v.min) ? base : v.min));
+                                        v.labelY = v.y;
+                                    }
+                                }
+                            }
+                    
+                            v.labelX = v.x - columnSeries.seriesRenderData.renderedHalfWidth + columnSeries.seriesRenderData.renderedXOffset;
+                        }*/
+                    }
+            
+                    var labelScale:Number = 1;
+                    if (columnSeries.measuringField.textWidth + 5 > v.labelWidth || (columnSeries.measuringField.textHeight) > v.labelHeight)
+                    {
+                        labelScale = v.labelWidth / (columnSeries.measuringField.textWidth + 5);
+                        labelScale = Math.min(labelScale, v.labelHeight / (columnSeries.measuringField.textHeight));
+                        if (size * labelScale > labelSizeLimit)
+                        {
+                            columnSeries.seriesRenderData.labelScale = Math.min(labelScale,columnSeries.seriesRenderData.labelScale);
+                            /* if (v.labelIsHorizontal)
+                            {
+                                _tempField.setStyle('fontSize',size * columnSeries.seriesRenderData.labelScale);
+                                v.labelHeight = _tempField.textHeight + 2;
+                            } */
+                        }
+                        else
+                        {
+                            _tempField.setStyle('fontSize',size);
+                            _tempField.validateNow();
+                            if (_tempField.measuredWidth > v.labelWidth || columnSeries.measuringField.textHeight > v.labelHeight)
+                            {
+                                labelScale = v.labelWidth / _tempField.measuredWidth;
+                                labelScale = Math.min(labelScale, v.labelHeight / (columnSeries.measuringField.measuredHeight));
+                                if (size * labelScale > labelSizeLimit)
+                                {
+                                    columnSeries.seriesRenderData.labelScale = Math.min(labelScale,columnSeries.seriesRenderData.labelScale);   
+                                    /* if (v.labelIsHorizontal)
+                                    {
+                                        _tempField.setStyle('fontSize',size * columnSeries.seriesRenderData.labelScale);
+                                        v.labelHeight = _tempField.textHeight + 2;
+                                    } */
+                                }
+                                else
+                                {
+                                    v.labelText = "";
+                                    v.labelWidth = 1;
+                                    v.labelHeight = 0;
+                                }
+                            }
+                            
+                        }
+                    }
+                    /*
+                    if (!isNaN(labelRotation) && labelRotation!=-90 && columnSeries.measuringField.embedFonts)
+                    {
+                        v.labelHeight = columnSeries.measuringField.textHeight + 2;
+                        if (v.y < (isNaN(v.min) ? base : v.min))
+                            v.labelY = v.y - v.labelHeight;
+                        else
+                            v.labelY = v.y + v.labelHeight;                         
+                    }
+                    */
+                    if (v.labelIsHorizontal)
+                    {
+                        if (v.y < (isNaN(v.min) ? base : v.min))
+                        {
+                            v.labelY = v.y - v.labelHeight;
+                            if (v.labelY < this.dataRegion.top)
+                                v.labelY = v.y;
+                        }
+                            
+                        else
+                        {
+                            v.labelY = v.y;
+                            if (v.labelY > this.dataRegion.bottom)
+                                v.labelY = v.y - v.labelHeight;
+                            
+                        }
+                        v.labelX = v.x - columnSeries.seriesRenderData.renderedHalfWidth +columnSeries.seriesRenderData.renderedXOffset;
+                    }
+                    v.labelTextWidth = columnSeries.measuringField.textWidth;
+                    var j:int = 0;
+                    if (!extendLabelToEnd)
+                    {
+                        //maxLabelWidth
+                        for (j = (i-1); j >= 1;)
+                        {
+                            if (_allItems[j].x >= v.x - maxLabelWidth)
+                                j--;
+                            else
+                                break;
+                        }
+                        if (j < 0)
+                            j = i;
+                    }
+                    
+                    for (var k:int = j; k < i; k++)
+                    {
+                        var tempItem:ColumnSeriesItem = _allItems[k];
+                                    //test for overlaps with previous labels
+                        if (tempItem.labelIsHorizontal)
+                        {
+                            if (v.labelX + 0.0001 < Math.min(tempItem.labelX + tempItem.labelWidth , tempItem.labelX + tempItem.labelTextWidth))
+                            {
+                                if (v.labelIsHorizontal)
+                                {
+                                    if ((((v.labelY + v.labelHeight) > tempItem.labelY) && ((v.labelY + v.labelHeight) < (tempItem.labelY + tempItem.labelHeight))) || 
+                                        ((v.labelY > tempItem.labelY) && (v.labelY < (tempItem.labelY + tempItem.labelHeight))) ||
+                                        ((v.labelY == tempItem.labelY) && ((tempItem.labelY + tempItem.labelHeight) == (v.labelY + v.labelHeight)) && (v.labelX > tempItem.labelX) && (v.labelX < (tempItem.labelX + tempItem.labelWidth))) ||
+                                        ((v.labelY <= tempItem.labelY) && ((v.labelY + v.labelHeight) > (tempItem.labelY + tempItem.labelHeight))) ||
+                                        ((v.labelY < tempItem.labelY) && ((v.labelY + v.labelHeight) >= (tempItem.labelY + tempItem.labelHeight))))
+                                    {
+                                        if (v.y < (isNaN(v.min) ? base : v.min))
+                                            v.labelY = tempItem.labelY - v.labelHeight;
+                                        else
+                                            v.labelY = tempItem.labelY + tempItem.labelHeight;
+                                    }
+                                }
+                                else
+                                {
+                                    if (((v.labelY > tempItem.labelY) && ((v.labelY - v.labelWidth) < (tempItem.labelY))) ||
+                                        (((v.labelY - v.labelWidth) >= tempItem.labelY) && (v.labelY > (tempItem.labelY - tempItem.labelHeight))))
+                                    {
+                                        var prevY:Number = v.labelY;
+                                        if (v.y < (isNaN(v.min) ? base : v.min))
+                                        {
+                                            v.labelY = tempItem.labelY - tempItem.labelHeight;
+                                            v.labelWidth = v.labelWidth - (prevY - v.labelY);
+                                        }
+                                        else
+                                        {
+                                            v.labelY = tempItem.labelY + tempItem.labelHeight;
+                                            v.labelWidth = v.labelWidth - (v.labelY - prevY);
+                                        }
+                                    }
+                                }
+                            }
+                        }
+                    }   
+                }
+                else if (labelPosition == "inside")
+                {
+                    v.labelIsHorizontal = true;
+                    v.labelWidth = 2 * columnSeries.seriesRenderData.renderedHalfWidth;                 
+                    v.labelHeight = columnSeries.measuringField.textHeight + 2;
+                    
+                    /*
+                    if (columnSeries.measuringField.textWidth + 5 > 2 * columnSeries.seriesRenderData.renderedHalfWidth && 
+                        columnSeries.measuringField.embedFonts)
+                    {
+                        v.labelIsHorizontal = false;
+                        v.labelWidth = Math.abs(v.y -(isNaN(v.min) ? base : v.min));
+                        v.labelHeight = 2 * columnSeries.seriesRenderData.renderedHalfWidth;
+                        if (v.y < (isNaN(v.min) ? base : v.min))
+                            v.labelY = isNaN(v.min) ? base : v.min;
+                        else
+                            v.labelY = v.y;
+                    
+                        v.labelX = v.x - v.labelHeight/2 + columnSeries.seriesRenderData.renderedXOffset;
+                    }*/
+                    
+                    labelScale = 1;
+                    if (columnSeries.measuringField.textWidth + 5 > v.labelWidth || columnSeries.measuringField.textHeight > v.labelHeight)
+                    {
+                        labelScale = v.labelWidth / (columnSeries.measuringField.textWidth + 5);
+                        labelScale = Math.min(labelScale, v.labelHeight / columnSeries.measuringField.textHeight);
+                        if (size * labelScale > labelSizeLimit)
+                        {
+                            columnSeries.seriesRenderData.labelScale = Math.min(labelScale,columnSeries.seriesRenderData.labelScale);
+                            /* if (v.labelIsHorizontal)
+                            {
+                                _tempField.setStyle('fontSize',size * columnSeries.seriesRenderData.labelScale);
+                                v.labelHeight = _tempField.textHeight + 2;
+                            } */
+                        }
+                        else
+                        {
+                            _tempField.setStyle('fontSize',size);
+                            _tempField.validateNow();
+                            if (_tempField.measuredWidth > v.labelWidth || columnSeries.measuringField.textHeight > v.labelHeight)
+                            {
+                                labelScale = v.labelWidth / _tempField.measuredWidth;
+                                labelScale = Math.min(labelScale, v.labelHeight / (columnSeries.measuringField.textHeight));
+                                if (size * labelScale > labelSizeLimit)
+                                {
+                                    columnSeries.seriesRenderData.labelScale = Math.min(labelScale,columnSeries.seriesRenderData.labelScale);   
+                                    /* if (v.labelIsHorizontal)
+                                    {
+                                        _tempField.setStyle('fontSize',size * columnSeries.seriesRenderData.labelScale);
+                                        v.labelHeight = _tempField.textHeight + 2;
+                                    } */
+                                }
+                                else
+                                {
+                                    v.labelText = "";
+                                    v.labelWidth = 1;
+                                    v.labelHeight = 0;
+                                }
+                            }
+                        }
+                    }
+                    if (v.labelIsHorizontal)
+                    {
+                        var align:String = columnSeries.getStyle('labelAlign');
+                        if (align == "top")
+                        {
+                            if (v.y < (isNaN(v.min) ? base : v.min))
+                                v.labelY = v.y;
+                            else
+                                v.labelY = v.y - v.labelHeight;
+                        }
+                        else if (align == "bottom")
+                        {
+                            if (v.y < (isNaN(v.min) ? base : v.min))
+                                v.labelY = (isNaN(v.min) ? base : v.min) - v.labelHeight;
+                            else
+                                v.labelY = isNaN(v.min) ? base : v.min;
+                        }
+                        else
+                        {
+                            if (v.y < (isNaN(v.min) ? base : v.min))
+                                v.labelY = v.y + Math.abs(v.y - (isNaN(v.min) ? base : v.min))/2 - v.labelHeight/2;
+                            else
+                                v.labelY = v.y - Math.abs(v.y - (isNaN(v.min) ? base : v.min))/2 + v.labelHeight/2;
+                        }
+                        v.labelX = v.x - columnSeries.seriesRenderData.renderedHalfWidth + columnSeries.seriesRenderData.renderedXOffset;
+                    }   
+                    v.labelTextWidth = columnSeries.measuringField.textWidth;
+                    j = 0;
+                    if (!extendLabelToEnd)
+                    {
+                        //maxLabelWidth
+                        for (j = (i-1); j >= 1;)
+                        {
+                            if (_allItems[j].x >= v.x - maxLabelWidth)
+                                j--;
+                            else
+                                break;
+                        }
+                        if (j < 0)
+                            j = i;
+                    }
+                    
+                    for (k = j; k < i; k++)
+                    {
+                        tempItem = _allItems[k];
+                        if (tempItem.labelIsHorizontal)
+                        {
+                            if (v.labelX + 0.0001 < Math.min(tempItem.labelX + tempItem.labelWidth , tempItem.labelX + tempItem.labelTextWidth))
+                            {
+                                if (v.labelIsHorizontal)
+                                {
+                                    if ((((v.labelY + v.labelHeight) > tempItem.labelY) && ((v.labelY + v.labelHeight) < (tempItem.labelY + tempItem.labelHeight))) || 
+                                        ((v.labelY > tempItem.labelY) && (v.labelY < (tempItem.labelY + tempItem.labelHeight))) ||
+                                        ((v.labelY == tempItem.labelY) && ((tempItem.labelY + tempItem.labelHeight) == (v.labelY + v.labelHeight)) && (v.labelX > tempItem.labelX) && (v.labelX < (tempItem.labelX + tempItem.labelWidth))) ||
+                                        ((v.labelY <= tempItem.labelY) && ((v.labelY + v.labelHeight) > (tempItem.labelY + tempItem.labelHeight))) ||
+                                        ((v.labelY < tempItem.labelY) && ((v.labelY + v.labelHeight) >= (tempItem.labelY + tempItem.labelHeight))))
+                                    {
+                                        if (v.y < (isNaN(v.min) ? base : v.min))
+                                            v.labelY = tempItem.labelY - v.labelHeight;
+                                        else
+                                            v.labelY = tempItem.labelY + tempItem.labelHeight;
+                                    }
+                                    else if (((v.labelY < tempItem.labelY) && ((v.labelY + v.labelHeight) > tempItem.labelY)) ||
+                                        ((v.labelY > tempItem.labelY) && (v.labelY < (tempItem.labelY + tempItem.labelHeight))) ||
+                                        (v.labelY == tempItem.labelY))
+                                    {
+                                        if (v.yNumber >= tempItem.yNumber)
+                                        {
+                                            tempItem.labelText = "";
+                                            tempItem.labelWidth = 1;
+                                        }
+                                        else
+                                        {
+                                            v.labelText = "";
+                                            v.labelWidth = 1;
+                                        }
+                                    }
+                                }
+                                else
+                                {
+                                    if (((v.labelY > tempItem.labelY) && ((v.labelY - Math.min(v.labelWidth,v.labelTextWidth)) < (tempItem.labelY))) ||
+                                        (((v.labelY - v.labelWidth) >= tempItem.labelY) && (v.labelY > (tempItem.labelY - tempItem.labelHeight))))
+                                    {
+                                        prevY = v.labelY;
+                                        if (v.y < (isNaN(v.min) ? base : v.min))
+                                        {
+                                            v.labelY = tempItem.labelY - tempItem.labelHeight;
+                                            v.labelWidth = v.labelWidth - (prevY - v.labelY);
+                                        }
+                                        else
+                                        {
+                                            v.labelY = tempItem.labelY + tempItem.labelHeight;
+                                            v.labelWidth = v.labelWidth - (v.labelY - prevY);
+                                        }
+                                    }
+                                }
+                            }
+                        }
+                        else
+                        {
+                            if (v.labelX == tempItem.labelX)
+                            {
+                                if (((v.labelY <= tempItem.labelY) && (v.labelY > (tempItem.labelY - Math.min(tempItem.labelWidth, tempItem.labelTextWidth) + 0.0001))) ||
+                                    ((v.labelY >= tempItem.labelY) && ((v.labelY - Math.min(v.labelWidth, v.labelTextWidth) + 0.0001) < tempItem.labelY)))
+                                {
+                                    if (v.yNumber < tempItem.yNumber)
+                                    {
+                                        v.labelText = "";
+                                        v.labelWidth = 1;
+                                    }
+                                    else
+                                    {
+                                        tempItem.labelText = "";
+                                        tempItem.labelWidth = 1;
+                                    }
+                                }
+                            }
+                        }
+                    }
+                }
+            }
+            else
+            {
+                columnSeries.seriesRenderData.labelData = null;
+                columnSeries.labelCache.count = 0;
+            }
+        }
+        allLabelsMeasured = true;
+        n = len;
+        for (i = 0; i < n; i++)
+        {
+            invalidateDisplay(series[i]);
+        }
+        return null;
+    }
+    
+    
+    //---------------------------------------------------------------------------------
+    //
+    // Methods
+    //
+    //---------------------------------------------------------------------------------
+    mx_internal function getSeriesLabelPos(series:Series):void
+    {
+        if (series is ColumnSeries)
+        {
+            var columnSeries:ColumnSeries = ColumnSeries(series);
+            var position:String = columnSeries.labelPos;
+            if (position == "inside" || position == "outside" || position == "none")
+                _needLabels = true; 
+        }
+        else if (series is ColumnSet)
+        {
+            var setSeries:Array /* of Series */ = ColumnSet(series).series;
+            var n:int  = setSeries.length;
+            for (var i:int = 0; i < n; i++)
+            {
+                getSeriesLabelPos(setSeries[i]);
+            }
+        }   
+    }
+    
+    mx_internal function getSeriesLabelPosSet():void
+    {
+        var n:int = series.length;
+        _needLabels = false;
+        for (var i:int = 0; i < n; i++)
+        {
+            if (_needLabels)
+                return;
+            getSeriesLabelPos(series[i]);
+        }
+    }
+    
+    /**
+     * @private
+     */
+     private function sortOnX(a:ColumnSeriesItem,b:ColumnSeriesItem):int
+     {
+        var offset1:Number = ColumnSeries(a.element).seriesRenderData.renderedXOffset;
+        var offset2:Number = ColumnSeries(b.element).seriesRenderData.renderedXOffset;
+        if (a.x + offset1 > b.x + offset2)
+            return 1;
+        else if (a.x + offset1 < b.x + offset2)
+            return -1;
+        else
+        {
+            if (a.yNumber > b.yNumber)
+                return 1;
+            else if (a.yNumber < b.yNumber)
+                return -1;
+            else
+                return 0;
+        }
+            
+     }
+     
+     /**
+     * @private
+     */
+     private function findChartItems(series:Series):void
+     {
+        var n:int;
+        var i:int;
+        if (series is ColumnSeries)
+        {
+            var columnSeries:ColumnSeries = ColumnSeries(series);
+            var seriesItems:Array /* of ColumnSeriesItem */ = columnSeries.seriesRenderData.filteredCache;
+            n = seriesItems.length;
+            columnSeries.labelCache.count = n;
+            columnSeries.seriesRenderData.labelData = columnSeries.labelContainer;
+            columnSeries.seriesRenderData.labelScale = 1;
+            for (i = 0; i < n; i++)
+            {
+                _allItems.push(ColumnSeriesItem(seriesItems[i]));
+            }           
+        }
+        else if (series is ColumnSet)
+        {
+            var setSeries:Array /* of Series */ = ColumnSet(series).series;
+            n = setSeries.length;
+            for (i = 0; i < n; i++)
+            {
+                findChartItems(setSeries[i]);
+            }
+        }
+     }
+    /**
+     * @private
+     */
+     private function invalidateDisplay(series:Series):void
+     {
+        if (series is ColumnSeries)
+            ColumnSeries(series).updateLabels();
+        else if (series is ColumnSet)
+        {
+            var setSeries:Array /* of Series */ = ColumnSet(series).series;
+            var n:int = setSeries.length;
+            for (var i:int = 0; i < n; i++)
+            {
+                invalidateDisplay(setSeries[i]);
+            }
+        }
+     }
+}
+
+}
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/charts/DateTimeAxis.as b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/DateTimeAxis.as
new file mode 100644
index 0000000..9a65699
--- /dev/null
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/charts/DateTimeAxis.as
@@ -0,0 +1,2541 @@
+////////////////////////////////////////////////////////////////////////////////
+//
+//  Licensed to the Apache Software Foundation (ASF) under one or more
+//  contributor license agreements.  See the NOTICE file distributed with
+//  this work for additional information regarding copyright ownership.
+//  The ASF licenses this file to You under the Apache License, Version 2.0
+//  (the "License"); you may not use this file except in compliance with
+//  the License.  You may obtain a copy of the License at
+//
+//      http://www.apache.org/licenses/LICENSE-2.0
+//
+//  Unless required by applicable law or agreed to in writing, software
+//  distributed under the License is distributed on an "AS IS" BASIS,
+//  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+//  See the License for the specific language governing permissions and
+//  limitations under the License.
+//
+////////////////////////////////////////////////////////////////////////////////
+
+package mx.charts
+{
+
+import org.apache.royale.events.Event;
+
+import mx.charts.chartClasses.AxisLabelSet;
+import mx.charts.chartClasses.DataDescription;
+import mx.charts.chartClasses.DateRangeUtilities;
+import mx.charts.chartClasses.NumericAxis;
+import mx.core.mx_internal;
+
+
+use namespace mx_internal;
+
+/**
+ *  The DateTimeAxis class maps time values evenly
+ *  between a minimum and maximum value along a chart axis.
+ *  It can plot values represented either as instances of the Date class,
+ *  as numeric values representing the number of milliseconds
+ *  since the epoch (midnight on January 1, 1970, GMT),
+ *  or as String values when you provide a custom parsing function.  
+ *
+ *  <p>The DateTimeAxis chooses the most reasonable units
+ *  to mark the axis by examining the range between the minimum and maximum
+ *  values of the axis.
+ *  The Axis chooses the largest unit that generates
+ *  a reasonable number of labels for the given range.
+ *  You can restrict the set of units the chart considers,
+ *  or specify exactly which units it should use,
+ *  by setting the <code>labelUnits</code> property.</p>
+ *
+ *  <p>You can specifiy the minimum and maximum values explicitly,
+ *  or let the axis automatically determine them by examining
+ *  the values being renderered in the chart.
+ *  By default, the DateTimeAxis chooses the smallest possible range
+ *  to contain all the values represented in the chart.
+ *  Optionally, you can request that the minimum and maximum values
+ *  be rounded to whole units
+ *  (milliseconds, seconds, minutes, hours, days, weeks, months, years)
+ *  by setting the <code>autoAdjust</code> property to <code>true</code>.</p>
+ *  
+ *  <p>You can specify disabled days of a week and disabled ranges of dates
+ *  in order to show only working days on the axis but not all days
+ *  between minimum and maximum. It also filters data and shows only data corresponding
+ *  to working days on the chart</p>
+ *  @see mx.charts.chartClasses.IAxis
+ * 
+ *  @mxml
+ *  
+ *  <p>The <code>&lt;mx:DateTimeAxis&gt;</code> tag inherits all the properties
+ *  of its parent classes and adds the following properties:</p>
+ *  
+ *  <pre>
+ *  &lt;mx:DateTimeAxis
+ *    <strong>Properties</strong>
+ *    alignLabelsToUnits="true|false"
+ *    dataUnits="milliseconds|seconds|minutes|hours|days|weeks|months|years"
+ *    disabledDays="<i>Array; No default</i>"
+ *    disabledRanges="<i>Array; No default</i>"
+ *    displayLocalTime="<i>false</i>"
+ *    interval="<i>Number</i>"
+ *    labelUnits="milliseconds|seconds|minutes|hours|days|weeks|months|years"
+ *    maximum="<i>Date</i>"
+ *    minimum="<i>Date</i>"
+ *    minorTickInterval="<i>Number</i>"
+ *    minorTickUnits="milliseconds|seconds|minutes|hours|days|weeks|months|years"
+ *  /&gt;
+ *  </pre>
+ *
+ *  @includeExample examples/DateTimeAxisExample.mxml
+ *  
+ *  @langversion 3.0
+ *  @playerversion Flash 9
+ *  @playerversion AIR 1.1
+ *  @productversion Flex 3
+ */
+public class DateTimeAxis extends NumericAxis
+{
+//    include "../core/Version.as";
+
+    //--------------------------------------------------------------------------
+    //
+    //  Class constants
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  @private
+     */
+    private static const MILLISECONDS_IN_MINUTE:Number = 1000 * 60;
+    
+    /**
+     *  @private
+     */
+    private static const MILLISECONDS_IN_HOUR:Number = 1000 * 60 * 60;
+    
+    /**
+     *  @private
+     */
+    private static const MILLISECONDS_IN_DAY:Number = 1000 * 60 * 60 * 24;
+    
+    /**
+     *  @private
+     */
+    private static const MILLISECONDS_IN_WEEK:Number = 1000 * 60 * 60 * 24 * 7;
+    
+    /**
+     *  @private
+     */
+    private static const MILLISECONDS_IN_MONTH:Number = 1000 * 60 * 60 * 24 * 30;
+    
+    /**
+     *  @private
+     */
+    private static const MILLISECONDS_IN_YEAR:Number = 1000 * 60 * 60 * 24 * 365;
+    
+    /**
+     *  @private
+     */
+    private static const MINIMUM_LABEL_COUNT:Number = 2;
+    
+    /**
+     *  @private
+     */
+    private var UNIT_PROGRESSION:Object =
+    {
+        milliseconds: null,
+        seconds: "milliseconds",
+        minutes: "seconds",
+        hours: "minutes",
+        days: "hours",
+        weeks: "days",
+        months: "weeks",
+        years: "months"
+    };
+
+    //--------------------------------------------------------------------------
+    //
+    //  Constructor
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  Constructor.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function DateTimeAxis()
+    {
+        super();
+
+        baseAtZero = false;
+        autoAdjust = false;
+
+        updatePropertyAccessors();
+    }
+    
+    //--------------------------------------------------------------------------
+    //
+    //  Variables
+    //
+    //--------------------------------------------------------------------------
+    
+    /**
+     *  @private
+     */
+    private static var tmpDate:Date = new Date();
+    
+    /**
+     *  @private
+     */
+    private var millisecondsP:String;
+
+    /**
+     *  @private
+     */
+    private var secondsP:String;
+
+    /**
+     *  @private
+     */
+    private var minutesP:String;
+
+    /**
+     *  @private
+     */
+    private var hoursP:String;
+
+    /**
+     *  @private
+     */
+    private var dateP:String;
+
+    /**
+     *  @private
+     */
+    private var dayP:String;
+
+    /**
+     *  @private
+     */
+    private var monthP:String;
+
+    /**
+     *  @private
+     */
+    private var fullYearP:String;
+    
+    /**
+     * @private
+     */
+    private var dateRangeUtilities:DateRangeUtilities = new DateRangeUtilities(); 
+    //--------------------------------------------------------------------------
+    //
+    //  Overridden properties: NumericAxis
+    //
+    //--------------------------------------------------------------------------
+
+    //----------------------------------
+    //  parseFunction
+    //----------------------------------
+
+    [Inspectable(category="Other")]
+    
+    /** 
+     *  Specifies a method that customizes the value of the data points. 
+     *  With this property, you specify a method that accepts a value and 
+     *  returns a Date object. The Date object is then used in the DateTimeAxis 
+     *  object of the chart. This lets you provide customizable date input strings 
+     *  and convert them to Date objects, which Flex can then interpret for use in the DateTimeAxis.
+     *  
+     *  <p>Flex passes only one parameter to the parsing method. This parameter is the value of the 
+     *  data point you specified for the series. Typically, it is a String that represents some form 
+     *  of a date. You cannot override this parameter or add additional parameters.</p>
+     *  
+     *  <p>This Date object is immediately converted to a numeric value, 
+     *  so custom parseFunctions can reuse the same Date object
+     *  for performance reasons.
+     *  By default, the DateTimeAxis uses the string parsing functionality
+     *  in the ECMA standard <code>Date.parse()</code> method.</p>
+     *  
+     *  The following example uses a data provider that defines a data object in the format { yyyy, mm, dd }. 
+     *  The method specified by the <code>parseFunction</code> uses these values to create a Date object
+     *  that the axis can use.
+     *  
+     *  <pre>
+     *  &lt;mx:Script&gt;
+     *      import mx.collections.ArrayCollection;
+     *      [Bindable] 
+     *      public var aapl:ArrayCollection = new ArrayCollection([ 
+     *          {date: "2005, 8, 1", close: 42.71},
+     *          {date: "2005, 8, 2", close: 42.99},
+     *          {date: "2005, 8, 3", close: 44}
+     *      ]);
+     *      
+     *      public function myParseFunction(s:String):Date { 
+     *          // Get an array of Strings from the comma-separated String passed in.
+     *          var a:Array = s.split(",");
+     *  
+     *          // Create the new Date object. Note that the month argument is 0-based (with 0 being January).
+     *          var newDate:Date = new Date(a[0],a[1]-1,a[2]);
+     *          return newDate;
+     *      }
+     *  &lt;/mx:Script&gt;
+     *  &lt;mx:LineChart id="mychart" dataProvider="{aapl}" showDataTips="true"&gt;
+     *      &lt;mx:horizontalAxis&gt;
+     *          &lt;mx:DateTimeAxis dataUnits="days" parseFunction="myParseFunction"/&gt;
+     *      &lt;/mx:horizontalAxis&gt;
+     *      &lt;mx:series&gt;
+     *          &lt;mx:LineSeries yField="close" xField="date" displayName="AAPL"/&gt;
+     *      &lt;/mx:series&gt;
+     *  &lt;/mx:LineChart&gt;
+     *  </pre>
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function set parseFunction(value:Function):void
+    {
+        super.parseFunction = value;
+    }
+
+    //----------------------------------
+    //  requiredDescribedFields
+    //----------------------------------
+
+    /**
+     *  The fields of the DescribeData structure that this axis is interested in.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override protected function get requiredDescribedFields():uint
+    {
+        var fields:uint = DataDescription.REQUIRED_MIN_MAX |
+               DataDescription.REQUIRED_BOUNDED_VALUES;
+        
+        if (_userDataUnits == null)
+            fields |= DataDescription.REQUIRED_MIN_INTERVAL;
+            
+        return fields;
+    }
+
+    //----------------------------------
+    //  unitSize
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the unitSize property.
+     */
+    private var _unitSize:Number = MILLISECONDS_IN_DAY;
+    
+    /**
+     *  The width, in pixels, of a single data unit.
+     *  The type of a data unit is determined
+     *  by the value of the <code>dataUnits</code> property.
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    override public function get unitSize():Number
+    {
+        return _unitSize;
+    }
+
+    //--------------------------------------------------------------------------
+    //
+    //  Properties
+    //
+    //--------------------------------------------------------------------------
+    
+    //--------------------------------------
+    // alignLabelsToUnits
+    //--------------------------------------
+    
+    /**
+     *  @private
+     *  Storage for alignLabelsToUnits property
+     */
+    private var _alignLabelsToUnits:Boolean = true;
+
+    /**
+     *  Determines the placement of labels along the axis.
+     *  <p>When <code>false</code>, the chart always puts a label at the beginning of the axis. For example, 
+     *  if your labels are every month and your first datapoint is July 14th, your first label 
+     *  will be on July 14th. When <code>true</code>, Flex first calculates the label units, then labels 
+     *  the first whole interval of those units. For example, if your first data point was 
+     *  July 14th, and your label units was months (set explicitly or dynamically calculated), 
+     *  the first label will be on August 1st.</p>
+     *  
+     *  @default true
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get alignLabelsToUnits():Boolean
+    {
+        return _alignLabelsToUnits;
+    }
+    
+    /**
+     * @private
+     */ 
+    public function set alignLabelsToUnits(value:Boolean):void
+    {
+        if (value != _alignLabelsToUnits)
+        {
+            _alignLabelsToUnits = value;
+            invalidateCache();
+            dispatchEvent(new Event("mappingChange"));
+            dispatchEvent(new Event("axisChange"));                 
+        }
+    }
+    
+    //----------------------------------
+    //  dataInterval
+    //----------------------------------
+    
+    /**
+     *  @private
+     *  Storage for the dataInterval property.
+     */
+    private var _dataInterval:Number = 1;
+
+    /**
+     *  @private
+     */
+    private var _userDataInterval:Number;
+    
+    [Inspectable]
+
+    /**
+     *  Specifies the interval between data in your chart,
+     *  specified in <code>dataUnits</code>.
+     *  <p>If, for example, the <code>dataUnits</code> property
+     *  is set to <code>"hours"</code>,
+     *  and <code>dataInterval</code> property is set to 4,
+     *  the chart assumes your data occurs every four hours.
+     *  This affects how some series (such as ColumnSeries
+     *  and CandlestickSeries) render their data.
+     *  It also affects how labels are automatically chosen.</p>
+     *  
+     *  @see #dataUnits
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function set dataInterval(value:Number):void
+    {
+        if (isNaN(value))
+            value = 1;
+            
+        _dataInterval = _userDataInterval = value;
+
+        if (_userDataUnits != null)
+            _unitSize = toMilli(_dataInterval, _userDataUnits);
+        else
+            _unitSize = MILLISECONDS_IN_DAY;
+            
+        invalidateCache();
+
+        dispatchEvent(new Event("mappingChange"));
+        dispatchEvent(new Event("axisChange"));
+    }
+
+    //----------------------------------
+    //  dataUnits
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the dataUnits property.
+     */
+    private var _dataUnits:String = null;
+
+    /**
+     *  @private
+     */
+    private var _userDataUnits:String = null;
+    
+    [Inspectable(category="General", enumeration="milliseconds,seconds,minutes,hours,days,weeks,months,years", defaultValue="days")]
+
+    /**
+     *  Specifies the units that you expect the data in your chart to represent.
+     *  The value can be one of the following:
+     *  <ul>
+     *   <li><code>milliseconds</code></li>
+     *   <li><code>seconds</code></li>
+     *   <li><code>minutes</code></li>
+     *   <li><code>hours</code></li>
+     *   <li><code>days</code></li>
+     *   <li><code>weeks</code></li>
+     *   <li><code>months</code></li>
+     *   <li><code>years</code></li>
+     *  </ul>
+     *
+     *  <p>This value is used in two ways. 
+     *  First, when choosing appropriate label units,
+     *  a DateTimeAxis does not choose any unit smaller
+     *  than the units represented by the data.
+     *  If the value of the <code>dataUnits</code> property
+     *  is <code>days</code>, the chart would not render labels
+     *  for every hour, no matter what the minmium/maximum range is.</p>
+     *
+     *  <p>Secondly, the value of the <code>dataUnits</code> property
+     *  is used by some series to affect their rendering.
+     *  Specifically, most columnar series
+     *  (such as ColumnSeries, BarSeries, CandlestickSeries, and HLOCSeries)
+     *  use the value of the <code>dataUnits</code> property
+     *  to determine how wide to render their columns.</p>
+     *
+     *  <p>If, for example, your ColumnChart control's horizontal axis
+     *  had its <code>labelUnits</code> property set to <code>weeks</code>
+     *  and its <code>dataUnits</code> property set to <code>days</code>,
+     *  the ColumnChart renders each column at 1/7th the distance
+     *  between labels.</p>
+     *
+     *  <p>When the <code>dataUnits</code> property is set to <code>null</code>, columnar series render
+     *  their columns as days, but the DateTimeAxis chooses
+     *  an appropriate unit when it generates the labels.</p>
+     *
+     *  @default null
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get dataUnits():String
+    {
+        return _dataUnits;
+    }
+    
+    /**
+     *  @private
+     */
+    public function set dataUnits(value:String):void
+    {
+        _dataUnits = _userDataUnits = value;
+        
+        if (_dataUnits != null)
+            _unitSize = toMilli(_dataInterval, _dataUnits);
+        else
+            _unitSize = MILLISECONDS_IN_DAY;
+            
+        invalidateCache();
+
+        dispatchEvent(new Event("mappingChange"));
+        dispatchEvent(new Event("axisChange"));
+    }
+
+    //--------------------------------------
+    // disabledDays
+    //--------------------------------------
+    
+    /**
+     *  @private
+     *  Storage for the disabledDays property.
+     */
+    private var _disabledDays:Array /* of int */;
+
+    [Inspectable(arrayType = "int", category = "General", defaultValue = null)]
+
+    /**
+     *  The days to disable in a week.
+     *  All the dates in a month, for the specified day, are disabled.
+     *  The elements of this array can have values from 0 (Sunday) to
+     *  6 (Saturday).
+     *  For example, a value of <code>[ 0, 6 ]</code>
+     *  disables Sunday and Saturday.
+     *
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    
+    public function get disabledDays():Array /* of int */
+    {
+        return _disabledDays;           
+    }
+    
+    /**
+     * @private
+     */
+    public function set disabledDays(value:Array /* of int */):void
+    {
+        _disabledDays = value;
+        invalidateCache();
+        
+        dispatchEvent(new Event("mappingChange"));
+        dispatchEvent(new Event("axisChange"));
+    }
+    
+    
+    //----------------------------------
+    //  disabledRanges
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the disabledRanges property.
+     */
+    private var _disabledRanges:Array /* of Object */;
+    [Inspectable(arrayType = "Object", category = "General", defaultValue = null)]
+
+    /**
+     *  Disables single and multiple days.
+     *
+     *  <p>This property accepts an Array of objects as a parameter.
+     *  Each object in this array is a Date object, specifying a
+     *  single day to disable; or an object containing either or both
+     *  of the <code>rangeStart</code> and <code>rangeEnd</code> properties,
+     *  each of whose values is a Date object.
+     *  The value of these properties describes the boundaries
+     *  of the date range.
+     *  If either is omitted, the range is considered
+     *  unbounded in that direction.
+     *  If you specify only <code>rangeStart</code>,
+     *  all the dates after the specified date are disabled,
+     *  including the <code>rangeStart</code> date.
+     *  If you specify only <code>rangeEnd</code>,
+     *  all the dates before the specified date are disabled,
+     *  including the <code>rangeEnd</code> date.
+     *  To disable a single day, use a single Date object specifying a date
+     *  in the Array.</p>
+     *
+     *  <p>The following example, disables the following dates: January 11
+     *  2006, the range January 23 - February 10 2006, and March 1 2006
+     *  and all following dates.</p>
+     *
+     *  <p><code>disabledRanges="{[ new Date(2006,0,11), {rangeStart:
+     *  new Date(2006,0,23), rangeEnd: new Date(2006,1,10)},
+     *  {rangeStart: new Date(2006,2,1)} ]}"</code></p>
+     *
+     *  @default []
+     *  
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get disabledRanges():Array /* of Object */
+    {
+        return _disabledRanges;
+    }
+
+    /**
+     *  @private
+     */
+    public function set disabledRanges(value:Array /* of Object */):void
+    {
+        _disabledRanges = value;
+        invalidateCache();
+        
+        dispatchEvent(new Event("mappingChange"));
+        dispatchEvent(new Event("axisChange"));
+    }
+    
+    //----------------------------------
+    //  displayLocalTime
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the displayLocalTime property.
+     */
+    private var _displayLocalTime:Boolean = false;
+    
+    [Inspectable(category="General")]
+    
+    /** 
+     *  When set to <code>true</code>,
+     *  a DateTimeAxis considers all date values to be in the time zone
+     *  of the client machine running the application. 
+     *  If <code>false</code>, all values are in Universal Time
+     *  (Greenwich Mean Time).
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get displayLocalTime():Boolean
+    {
+        return _displayLocalTime;
+    }
+
+    /**
+     *  @private
+     */
+    public function set displayLocalTime(value:Boolean):void
+    {
+        _displayLocalTime = value;  
+        invalidateCache();
+
+        dispatchEvent(new Event("mappingChange"));
+        dispatchEvent(new Event("axisChange"));
+
+        updatePropertyAccessors();
+    }
+
+    //----------------------------------
+    //  interval
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the interval property.
+     */
+    private var _interval:Number;
+    
+    [Inspectable(category="General")]
+    
+    /**
+     *  Specifies the number of <code>labelUnits</code>
+     *  between label values along the axis. 
+     *  Flex calculates the interval if this property is set to <code>null</code>.
+     *
+     *  @default null
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get interval():Number
+    {
+        return _interval;
+    }
+    
+    /**
+     *  @private
+     */
+    public function set interval(value:Number):void
+    {
+        _interval = Math.max(1, value);
+        
+        invalidateCache();
+
+        dispatchEvent(new Event("mappingChange"));
+        dispatchEvent(new Event("axisChange"));
+    }
+
+    //----------------------------------
+    //  labelUnits
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the labelUnits property.
+     */
+    private var _labelUnits:String;
+    
+    /**
+     *  @private
+     */
+    private var _userLabelUnits:String = null;
+
+    [Inspectable(category="General", enumeration="milliseconds,seconds,minutes,hours,days,weeks,months,years")]
+
+    /**
+     *  The units that the axis uses to generate labels.
+     *  By default, a DateTimeAxis considers all valid units
+     *  (<code>milliseconds</code>, <code>seconds</code>, <code>minutes</code>, <code>hours</code>, <code>days</code>, 
+     *  <code>weeks</code>, <code>months</code>, or <code>years</code>).
+     *  
+     *  <p>If the <code>labelUnits</code> property is not set,
+     *  the chart does not use any unit smaller than the value
+     *  of the <code>dataUnits</code> property to render labels.</p>
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get labelUnits():String
+    {
+        return _labelUnits;
+    }
+
+    /**
+     *  @private
+     */
+    public function set labelUnits(value:String):void
+    {
+        _userLabelUnits = _labelUnits = value;
+        
+        invalidateCache();
+        dispatchEvent(new Event("mappingChange"));
+        dispatchEvent(new Event("axisChange"));
+    }
+    
+    //----------------------------------
+    //  maximum
+    //----------------------------------
+
+    [Inspectable(category="General", defaultValue="null")]
+    
+    /**
+     *  Specifies the maximum value for an axis label.
+     *  If <code>null</code>, Flex determines the minimum value
+     *  from the data in the chart.
+     *  
+     *  @default null
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get maximum():Date
+    {
+        return new Date(computedMaximum);
+    }
+    
+    /**
+     *  @private
+     */
+    public function set maximum(value:Date):void
+    {
+        if (value != null)
+            assignedMaximum = value.getTime();
+        else
+            assignedMaximum = NaN;
+        
+        invalidateCache();
+
+        dispatchEvent(new Event("mappingChange"));
+        dispatchEvent(new Event("axisChange"));
+    }
+
+    //----------------------------------
+    //  minimum
+    //----------------------------------
+
+    [Inspectable(category="General", defaultValue="null")]
+    
+    /**
+     *  Specifies the minimum value for an axis label.
+     *  If <code>null</code>, Flex determines the minimum value
+     *  from the data in the chart. 
+     *
+     *  @default null
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get minimum():Date
+    {
+        return new Date(computedMinimum);
+    }
+    
+    /**
+     *  @private
+     */
+    public function set minimum(value:Date):void
+    {
+        if (value != null)
+            assignedMinimum = value.getTime();
+        else
+            assignedMinimum = NaN;
+        invalidateCache();
+
+        dispatchEvent(new Event("mappingChange"));
+        dispatchEvent(new Event("axisChange"));
+    }
+
+    //----------------------------------
+    //  minorTickInterval
+    //----------------------------------
+
+    /**
+     *  @private
+     */
+    private var _minorTickInterval:Number;
+
+    /**
+     *  @private
+     */
+    private var _userMinorTickInterval:Number;
+
+    [Inspectable(category="General")]
+    
+    /** 
+     *  Specifies the number of <code>minorTickUnits</code>
+     *  between minor tick marks along the axis.
+     *  If this is set to <code>NaN</code>,
+     *  the DateTimeAxis calculates it automatically.
+     *  
+     *  <p>Normally the <code>minorTickInterval</code> property
+     *  is automatically set to 1.
+     *  If, however, the <code>minorTickUnits</code> property
+     *  is the same units as the <code>dataUnits</code> property
+     *  (either set explicitly or implicitly calculated),
+     *  then the <code>minorTickInterval</code> property
+     *  is the maximum of 1, or <code>dataInterval</code>.</p>
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get minorTickInterval():Number
+    {
+        return _userMinorTickInterval;
+    }
+    
+    /**
+     *  @private
+     */
+    public function set minorTickInterval(value:Number):void
+    {
+        _userMinorTickInterval = value;
+
+        invalidateCache();
+
+        dispatchEvent(new Event("mappingChange"));
+        dispatchEvent(new Event("axisChange"));
+    }
+
+    //----------------------------------
+    //  minorTickUnits
+    //----------------------------------
+
+    /**
+     *  @private
+     *  Storage for the minorTickUnits property.
+     */
+    private var _minorTickUnits:String;
+    
+    /**
+     *  @private
+     */
+    private var _userMinorTickUnits:String = null;  
+
+    [Inspectable(category="General", enumeration="milliseconds,seconds,minutes,hours,days,weeks,months,years")]
+
+    /**
+     *  The units that the Axis considers when generating minor tick marks.
+     *  By default, a DateTimeAxis considers all valid units 
+     *  (<code>milliseconds</code>, <code>seconds</code>, <code>minutes</code>, <code>hours</code>, <code>days</code>, 
+     *  <code>weeks</code>, <code>months</code>, or <code>years</code>).
+     *  
+     *  <p>If this property is not set, the chart determines the value
+     *  of the <code>minorTickUnits</code> property.
+     *  If the label interval is greater than 1,
+     *  the <code>minorTickUnits</code> property is set to the value
+     *  of the <code>labelUnits</code> property,
+     *  and the <code>minorTickInterval</code> property is set to 1.
+     *  If the label interval is 1, the <code>minorTickUnits</code> property is
+     *  set to the next smaller unit from the <code>labelUnits</code> property.
+     *  If set, the <code>minorTickUnits</code> property can never be smaller
+     *  than the value of the <code>dataUnits</code> property.</p>
+     *  
+     *  @langversion 3.0
+     *  @playerversion Flash 9
+     *  @playerversion AIR 1.1
+     *  @productversion Flex 3
+     */
+    public function get minorTickUnits():String
+    {
+        return _minorTickUnits;
+    }
+    
+    /**
+     *  @private
+     */
+    public function set minorTickUnits(value:String):void
+    {
+        _minorTickUnits = _userMinorTickUnits = value;
... 75088 lines suppressed ...


[royale-asjs] 04/10: Merge branch 'develop' into MXCharts

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

aharui pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git

commit efa5c4fee812f74bf14735f1cbbecd47e12840cf
Merge: 6e4390f e4a5551
Author: Alex Harui <ah...@apache.org>
AuthorDate: Thu Oct 25 20:11:55 2018 -0700

    Merge branch 'develop' into MXCharts

 examples/royale/JewelExample/.vscode/launch.json   | 26 +++++++++++++++++-----
 .../mx/messaging/channels/DirectHTTPChannel.as     |  2 +-
 .../main/royale/mx/rpc/http/HTTPMultiService.as    |  2 +-
 .../src/main/royale/mx/rpc/http/HTTPService.as     |  2 +-
 4 files changed, 23 insertions(+), 9 deletions(-)


[royale-asjs] 05/10: Merge branch 'develop' into MXCharts

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

aharui pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git

commit f165eeace4ef1ae081ffb4060fe8c86ea486a677
Merge: efa5c4f cf7cb3d
Author: Alex Harui <ah...@apache.org>
AuthorDate: Fri Oct 26 12:45:18 2018 -0700

    Merge branch 'develop' into MXCharts

 .../src/main/royale/App_Jewel.mxml                 |   2 +-
 .../JewelExample/src/main/royale/MainContent.mxml  |   2 +-
 .../src/main/royale/TextInputPlayGround.mxml       |  13 +
 .../Jewel/src/main/resources/jewel-manifest.xml    |   4 +-
 .../jewel/beads/controls/textinput/LowerCase.as    |  77 ++++
 .../jewel/beads/controls/textinput/UpperCase.as    |  77 ++++
 ...siveSizeMonitor.as => ResponsiveSizeMonitor.as} |   6 +-
 .../royale/org/apache/royale/utils/Language.as     |  57 +++
 .../src/main/royale/mx/core/Application.as         |  34 +-
 .../src/main/royale/mx/managers/SystemManager.as   |   9 +-
 .../src/main/royale/mx/utils/ObjectUtil.as         | 416 ++++++++++++++++++++-
 .../org/apache/royale/reflection/TypeDefinition.as |   1 +
 .../org/apache/royale/reflection/describeType.as   |   2 +-
 .../royale/reflection/getQualifiedClassName.as     |   2 +-
 .../src/main/royale/spark/components/TextInput.as  |  34 ++
 releasecandidate.xml                               |   2 +-
 16 files changed, 723 insertions(+), 15 deletions(-)


[royale-asjs] 02/10: Merge branch 'develop' into MXCharts

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

aharui pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git

commit a680f53c5c889ad16b7fc9d754f6d0e8bd0706a5
Merge: 13ca9f0 41c8a18
Author: Alex Harui <ah...@apache.org>
AuthorDate: Wed Oct 24 12:52:05 2018 -0700

    Merge branch 'develop' into MXCharts

 examples/amf/SampleAmfWebApp/.vscode/tasks.json    |   77 +-
 examples/amf/SampleAmfWebApp/pom.xml               |   12 +-
 examples/mxroyale/RemoteObjectAMFTest/pom.xml      |   17 +-
 .../src/main/royale/App_Jewel.mxml                 |  133 ++
 .../src/main/royale/FormsValidationPlayGround.mxml |    7 +
 .../main/royale/org/apache/royale/core/UIBase.as   |    6 +-
 .../src/main/royale/CollectionsClasses.as          |    1 +
 .../apache/royale/collections/CollectionUtils.as   |  140 ++
 .../projects/Jewel/src/main/resources/defaults.css |    6 +-
 .../Jewel/src/main/resources/jewel-manifest.xml    |    3 +-
 .../projects/Jewel/src/main/royale/JewelClasses.as |    3 +-
 .../jewel/beads/controllers/ComboBoxController.as  |   42 +-
 .../jewel/beads/controls/combobox/IComboBoxView.as |    4 +-
 .../jewel/beads/validators/CheckBoxValidator.as    |    7 +-
 .../{CheckBoxValidator.as => DateValidator.as}     |  188 ++-
 .../royale/jewel/beads/validators/FormValidator.as |    3 +-
 .../royale/jewel/beads/validators/Validator.as     |    2 +-
 .../royale/jewel/beads/views/ComboBoxPopUpView.as  |   83 +
 .../royale/jewel/beads/views/ComboBoxView.as       |   66 +-
 .../combobox/{ComboBoxList.as => ComboBoxPopUp.as} |   34 +-
 .../Jewel/src/main/sass/components/_combobox.sass  |    9 +-
 .../src/main/resources/mx-royale-manifest.xml      |    1 +
 .../MXRoyale/src/main/royale/MXRoyaleClasses.as    |   21 +-
 .../src/main/royale/mx/collections/SortField.as    |    2 +-
 .../src/main/royale/mx/controls/LinkBar.as         |  718 ++++++++
 .../MXRoyale/src/main/royale/mx/core/Container.as  |   18 +-
 .../src/main/royale/mx/events/MenuEvent.as         |   14 +
 .../{targets/TraceTarget.as => AbstractTarget.as}  |  279 ++--
 .../royale/mx/logging/errors/InvalidFilterError.as |   84 +
 .../mx/logging/targets/LineFormattedTarget.as      |  258 +++
 .../main/royale/mx/logging/targets/TraceTarget.as  |  245 +--
 .../mx/messaging/channels/DirectHTTPChannel.as     |  543 ++++++
 .../royale/mx/messaging/channels/URLVariables.as}  |   36 +-
 .../messaging/errors/MessageSerializationError.as  |   83 +
 .../mx/messaging/messages/HTTPRequestMessage.as    |  411 +++++
 .../royale/mx/printing/FlexPrintJobScaleType.as    |    1 +
 .../src/main/royale/mx/rpc/CallResponder.as        |  177 ++
 .../main/royale/mx/rpc/http/AbstractOperation.as   | 1215 ++++++++++++++
 .../main/royale/mx/rpc/http/HTTPMultiService.as    |  539 ++++++
 .../src/main/royale/mx/rpc/http/HTTPService.as     | 1245 +++++++++++---
 .../main/royale/mx/rpc/http/HTTPServiceWrapper.as} |   29 +-
 .../src/main/royale/mx/rpc/http/Operation.as       |  455 +++++
 .../main/royale/mx/rpc/http/SerializationFilter.as |  231 +++
 .../main/royale/mx/rpc/http/mxml/HTTPService.as    |    8 +-
 .../mx/rpc/remoting/CompressedRemoteObject.as      |   22 +-
 .../src/main/royale/mx/rpc/remoting/Operation.as   |   22 +-
 .../src/main/royale/mx/utils/ObjectUtil.as         |    2 +-
 .../src/main/resources/spark-royale-manifest.xml   |    7 +
 .../src/main/royale/SparkRoyaleClasses.as          |    1 +
 .../src/main/royale/spark/components/FormItem.as   |  541 ++++++
 .../royale/spark/components/RadioButtonGroup.as    |    2 +-
 .../royale/spark/components/SkinnableContainer.as  |   17 +
 .../src/main/royale/spark/components/TextArea.as   | 1481 +++++++++--------
 .../components/gridClasses/GridItemRenderer.as     | 1742 ++++++++++----------
 .../components/supportClasses/SkinnableTextBase.as |   18 +-
 55 files changed, 8823 insertions(+), 2488 deletions(-)

diff --cc frameworks/projects/MXRoyale/src/main/resources/mx-royale-manifest.xml
index 60fe196,d9f4412..223b738
--- a/frameworks/projects/MXRoyale/src/main/resources/mx-royale-manifest.xml
+++ b/frameworks/projects/MXRoyale/src/main/resources/mx-royale-manifest.xml
@@@ -125,7 -140,9 +125,8 @@@
  	<component id="GridRow" class="mx.containers.GridRow"/>
  	<component id="Parallel" class="mx.effects.Parallel"/>
  	<component id="AdvancedDataGridItemRenderer" class="mx.controls.advancedDataGridClasses.AdvancedDataGridItemRenderer" />
 -	<component id="LineSeries" class="mx.charts.series.LineSeries" />
  	<component id="Tree" class="mx.controls.Tree"/>
+ 	<component id="LinkBar" class="mx.controls.LinkBar"/>
      
  	<component id="AMFChannel" class="mx.messaging.channels.AMFChannel" />
  	<component id="ChannelSet" class="mx.messaging.ChannelSet" />


[royale-asjs] 10/10: Merge branch 'MXCharts' into develop

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

aharui pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git

commit eb8672ff50b02d8cc418fcb6a8eb552109857b89
Merge: 513a54e dd34351
Author: Alex Harui <ah...@apache.org>
AuthorDate: Mon Oct 29 10:32:31 2018 -0700

    Merge branch 'MXCharts' into develop

 .../mxroyale/tourdeflexmodules/src/explorer.xml    |    2 -
 .../html/beads/DataProviderItemsChangeNotifier.as  |    2 +-
 .../apache/royale/html/beads/SimpleAlertView.as    |   12 +-
 .../org/apache/royale/html/beads/SliderView.as     |   16 +-
 .../royale/html/supportClasses/HScrollViewport.as  |   80 -
 .../html/supportClasses/ScrollingViewport.as       |   24 +-
 .../royale/html/supportClasses/VScrollViewport.as  |   80 -
 .../org/apache/royale/events/KeyboardEvent.as      |   12 +-
 .../royale/org/apache/royale/events/MouseEvent.as  |   12 +-
 .../royale/org/apache/royale/graphics/IStroke.as   |    7 +-
 .../org/apache/royale/graphics/SolidColorStroke.as |    4 +-
 .../apache/royale/jewel/beads/views/ListView.as    |    3 +-
 .../apache/royale/jewel/beads/views/TableView.as   |    3 +-
 .../src/main/resources/mx-royale-manifest.xml      |   70 +-
 .../src/main/royale/mx/charts/AreaChart.as         |  557 +-
 .../src/main/royale/mx/charts/AxisLabel.as         |  135 +
 .../src/main/royale/mx/charts/AxisRenderer.as      | 3964 ++++++++++++
 .../MXRoyale/src/main/royale/mx/charts/BarChart.as |  916 ++-
 .../src/main/royale/mx/charts/BubbleChart.as       |  322 +
 .../src/main/royale/mx/charts/CandlestickChart.as  |  322 +
 .../src/main/royale/mx/charts/CategoryAxis.as      |  808 ++-
 .../src/main/royale/mx/charts/ChartItem.as         |  191 +-
 .../src/main/royale/mx/charts/ColumnChart.as       | 1263 +++-
 .../src/main/royale/mx/charts/DateTimeAxis.as      | 2541 ++++++++
 .../src/main/royale/mx/charts/GridLines.as         |  674 ++
 .../src/main/royale/mx/charts/HLOCChart.as         |  321 +
 .../MXRoyale/src/main/royale/mx/charts/HitData.as  |  444 +-
 .../MXRoyale/src/main/royale/mx/charts/Legend.as   | 6651 +++++++++++++++++++-
 .../src/main/royale/mx/charts/LegendItem.as        |  681 ++
 .../src/main/royale/mx/charts/LineChart.as         |  219 +-
 .../src/main/royale/mx/charts/LinearAxis.as        |  701 ++-
 .../MXRoyale/src/main/royale/mx/charts/LogAxis.as  |  606 ++
 .../MXRoyale/src/main/royale/mx/charts/PieChart.as |  275 +-
 .../src/main/royale/mx/charts/PlotChart.as         |  349 +-
 .../main/royale/mx/charts/chartClasses/AxisBase.as |  341 +
 .../AxisLabelSet.as}                               |   77 +-
 .../royale/mx/charts/chartClasses/BoundedValue.as  |  134 +
 .../mx/charts/chartClasses/CartesianCanvasValue.as |  126 +
 .../mx/charts/chartClasses/CartesianChart.as       | 2032 ++++++
 .../mx/charts/chartClasses/CartesianDataCanvas.as  | 2030 ++++++
 .../mx/charts/chartClasses/CartesianTransform.as   |  184 +-
 .../royale/mx/charts/chartClasses/ChartBase.as     | 5533 +++++++++++++++-
 .../royale/mx/charts/chartClasses/ChartElement.as  |  663 ++
 .../mx/charts/chartClasses/ChartItemDragProxy.as   |  129 +
 .../royale/mx/charts/chartClasses/ChartLabel.as    |  340 +
 .../royale/mx/charts/chartClasses/ChartState.as    |   97 +
 .../mx/charts/chartClasses/DataDescription.as      |  208 +
 .../main/royale/mx/charts/chartClasses/DataTip.as  |  678 +-
 .../royale/mx/charts/chartClasses/DataTransform.as |  247 +-
 .../mx/charts/chartClasses/DateRangeUtilities.as   |  575 ++
 .../mx/charts/chartClasses/DualStyleObject.as      |  284 +
 .../mx/charts/chartClasses/GraphicsUtilities.as    | 1286 ++--
 .../mx/charts/chartClasses/HLOCSeriesBase.as       | 1467 +++++
 .../main/royale/mx/charts/chartClasses/IAxis.as    |  797 ++-
 .../royale/mx/charts/chartClasses/IAxisRenderer.as |  266 +
 .../src/main/royale/mx/charts/chartClasses/IBar.as |  105 +
 .../royale/mx/charts/chartClasses/IChartElement.as |  257 +
 .../mx/charts/chartClasses/IChartElement2.as       |  107 +
 .../main/royale/mx/charts/chartClasses/IColumn.as  |  111 +
 .../royale/mx/charts/chartClasses/IDataCanvas.as   |  140 +
 .../royale/mx/charts/chartClasses/IStackable.as    |  115 +
 .../royale/mx/charts/chartClasses/IStackable2.as   |   78 +
 .../royale/mx/charts/chartClasses/InstanceCache.as |  541 ++
 .../royale/mx/charts/chartClasses/LegendData.as    |  137 +
 .../royale/mx/charts/chartClasses/NumericAxis.as   | 1423 +++++
 .../royale/mx/charts/chartClasses/PolarChart.as    |  650 ++
 .../mx/charts/chartClasses/PolarDataCanvas.as      | 1948 ++++++
 .../mx/charts/chartClasses/PolarTransform.as       |  253 +
 .../royale/mx/charts/chartClasses/RenderData.as    |  141 +-
 .../main/royale/mx/charts/chartClasses/Series.as   |  886 ++-
 .../royale/mx/charts/chartClasses/StackedSeries.as |  932 +++
 .../main/royale/mx/charts/effects/SeriesEffect.as  |  229 +
 .../SeriesInterpolate.as}                          |   66 +-
 .../main/royale/mx/charts/effects/SeriesSlide.as   |  134 +
 .../main/royale/mx/charts/effects/SeriesZoom.as    |  207 +
 .../effects/effectClasses/SeriesEffectInstance.as  |  435 ++
 .../effectClasses/SeriesInterpolateInstance.as     |  154 +
 .../effects/effectClasses/SeriesSlideInstance.as   |  339 +
 .../effects/effectClasses/SeriesZoomInstance.as    |  875 +++
 .../src/main/royale/mx/charts/events/ChartEvent.as |  154 +
 .../main/royale/mx/charts/events/ChartItemEvent.as |  164 +-
 .../royale/mx/charts/events/LegendMouseEvent.as    |  239 +
 .../royale/mx/charts/renderers/AreaRenderer.as     |  202 +
 .../royale/mx/charts/renderers/BoxItemRenderer.as  |  196 +
 .../mx/charts/renderers/CandlestickItemRenderer.as |  252 +
 .../mx/charts/renderers/CircleItemRenderer.as      |  207 +
 .../mx/charts/renderers/CrossItemRenderer.as       |  244 +
 .../mx/charts/renderers/DiamondItemRenderer.as     |  212 +
 .../royale/mx/charts/renderers/HLOCItemRenderer.as |  359 ++
 .../royale/mx/charts/renderers/LineRenderer.as     |  132 +
 .../mx/charts/renderers/ShadowBoxItemRenderer.as   |  224 +
 .../mx/charts/renderers/ShadowLineRenderer.as      |   95 +-
 .../mx/charts/renderers/TriangleItemRenderer.as    |  213 +
 .../mx/charts/renderers/WedgeItemRenderer.as       |  245 +
 .../src/main/royale/mx/charts/series/AreaSeries.as | 2085 +++++-
 .../src/main/royale/mx/charts/series/AreaSet.as    |  190 +
 .../src/main/royale/mx/charts/series/BarSeries.as  | 2512 +++++++-
 .../src/main/royale/mx/charts/series/BarSet.as     |  525 ++
 .../main/royale/mx/charts/series/BubbleSeries.as   | 1541 +++++
 .../royale/mx/charts/series/CandlestickSeries.as   |  556 ++
 .../main/royale/mx/charts/series/ColumnSeries.as   | 2568 +++++++-
 .../src/main/royale/mx/charts/series/ColumnSet.as  |  450 ++
 .../src/main/royale/mx/charts/series/HLOCSeries.as |  422 ++
 .../src/main/royale/mx/charts/series/LineSeries.as | 4352 +++++++------
 .../src/main/royale/mx/charts/series/PieSeries.as  | 4071 +++++++++---
 .../src/main/royale/mx/charts/series/PlotSeries.as | 1478 ++++-
 .../mx/charts/series/items/AreaSeriesItem.as       |  300 +
 .../royale/mx/charts/series/items/BarSeriesItem.as |  330 +
 .../mx/charts/series/items/BubbleSeriesItem.as     |  293 +
 .../mx/charts/series/items/ColumnSeriesItem.as     |  231 +-
 .../mx/charts/series/items/HLOCSeriesItem.as       |  422 ++
 .../mx/charts/series/items/LineSeriesItem.as       |  231 +
 .../mx/charts/series/items/LineSeriesSegment.as    |  191 +
 .../royale/mx/charts/series/items/PieSeriesItem.as |  623 +-
 .../mx/charts/series/items/PlotSeriesItem.as       |  247 +
 .../renderData/AreaSeriesRenderData.as}            |  310 +-
 .../series/renderData/BarSeriesRenderData.as       |  179 +
 .../renderData/BubbleSeriesRenderData.as}          |   63 +-
 .../series/renderData/ColumnSeriesRenderData.as    |  179 +
 .../series/renderData/HLOCSeriesRenderData.as      |  121 +
 .../series/renderData/LineSeriesRenderData.as      |  148 +
 .../series/renderData/PieSeriesRenderData.as       |  131 +
 .../series/renderData/PlotSeriesRenderData.as      |  101 +
 .../halo/SelectionSkin.as}                         |   73 +-
 .../main/royale/mx/charts/styles/HaloDefaults.as   |  251 +
 .../styles/metadata/FillStrokeStyles.as}           |   33 +-
 .../styles/metadata/GapStyles.as}                  |   33 +-
 .../charts/styles/metadata/ItemRendererStyles.as   |   43 +
 .../styles/metadata/LeadingStyle.as}               |   63 +-
 .../styles/metadata/MarginStyles.as}               |   33 +-
 .../royale/mx/charts/styles/metadata/TextStyles.as |  280 +
 .../src/main/royale/mx/containers/Panel.as         |  101 +-
 .../main/royale/mx/containers/beads/PanelView.as   |   25 +-
 .../mx/containers/beads/models/PanelModel.as       |    8 +-
 .../src/main/royale/mx/controls/LinkBar.as         |    2 +-
 .../src/main/royale/mx/core/Application.as         |   11 +-
 .../src/main/royale/mx/core/ClassFactory.as        |    2 +-
 .../IProgrammaticSkin.as}                          |   42 +-
 .../src/main/royale/mx/core/ITextFieldFactory.as   |   71 +
 .../src/main/royale/mx/core/IUIComponent.as        |    4 +
 .../src/main/royale/mx/core/IUITextField.as        |  168 +
 .../src/main/royale/mx/core/UIComponent.as         |  380 +-
 .../src/main/royale/mx/core/UITextField.as         |    4 +-
 .../src/main/royale/mx/core/UITextFormat.as        |  594 ++
 .../src/main/royale/mx/display/Graphics.as         |   38 +-
 .../MXRoyale/src/main/royale/mx/effects/Effect.as  |    4 +
 .../src/main/royale/mx/effects/EffectInstance.as   |   62 +-
 .../mx/effects/effectClasses/ParallelInstance.as   |  609 ++
 .../effects/effectClasses/TweenEffectInstance.as   |   11 +-
 .../src/main/royale/mx/events/FlexEvent.as         |    2 +-
 .../src/main/royale/mx/events/TweenEvent.as        |  230 +
 .../MXRoyale/src/main/royale/mx/graphics/IFill.as  |   41 +-
 .../src/main/royale/mx/graphics/IStroke.as         |   28 +-
 .../src/main/royale/mx/graphics/LinearGradient.as  |   37 +-
 .../src/main/royale/mx/graphics/SolidColor.as      |   40 +-
 .../main/royale/mx/graphics/SolidColorStroke.as    |   57 +-
 .../MXRoyale/src/main/royale/mx/graphics/Stroke.as |   36 +-
 .../src/main/royale/mx/managers/SystemManager.as   |    5 +-
 .../src/main/royale/mx/skins/ProgrammaticSkin.as   |   19 +-
 .../main/royale/mx/styles/CSSStyleDeclaration.as   |   74 +
 .../main/royale/mx/styles/ISimpleStyleClient.as    |    6 +-
 .../src/main/royale/mx/styles/IStyleManager.as     |  565 ++
 .../src/main/royale/mx/styles/IStyleManager2.as    |    2 +-
 .../MXRoyale/src/main/royale/mx/text/TextFormat.as |   66 +
 .../org/apache/royale/site/TitledAnchorList.as     |    2 +-
 .../src/main/royale/spark/collections/Sort.as      |    8 +
 .../src/main/royale/spark/collections/SortField.as |    9 +-
 .../src/main/royale/spark/components/Group.as      |    7 +-
 .../spark/components/supportClasses/TextBase.as    |    9 +-
 169 files changed, 75072 insertions(+), 7128 deletions(-)


[royale-asjs] 09/10: a few more places were private overwrites protected or public methods

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

aharui pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git

commit dd34351c4738e2a87acefadd0e1873f5895f8fc4
Author: Alex Harui <ah...@apache.org>
AuthorDate: Mon Oct 29 10:31:54 2018 -0700

    a few more places were private overwrites protected or public methods
---
 .../src/main/royale/org/apache/royale/jewel/beads/views/ListView.as    | 3 ++-
 .../src/main/royale/org/apache/royale/jewel/beads/views/TableView.as   | 3 ++-
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/views/ListView.as b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/views/ListView.as
index bc14ecc..a9bad6c 100644
--- a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/views/ListView.as
+++ b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/views/ListView.as
@@ -103,8 +103,9 @@ package org.apache.royale.jewel.beads.views
 		 * @private
 		 * Ensure the list selects the selectedItem if someone is set by the user at creation time
 		 */
-		private function itemsCreatedHandler(event:Event):void
+		override protected function itemsCreatedHandler(event:Event):void
 		{
+            super.itemsCreatedHandler(event);
 			if(listModel.selectedIndex != -1)
 				selectionChangeHandler(null);
 		}
diff --git a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/views/TableView.as b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/views/TableView.as
index b7030fd..0604bb0 100644
--- a/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/views/TableView.as
+++ b/frameworks/projects/Jewel/src/main/royale/org/apache/royale/jewel/beads/views/TableView.as
@@ -85,8 +85,9 @@ package org.apache.royale.jewel.beads.views
 		 * @private
 		 * Ensure the list selects the selectedItem if someone is set by the user at creation time
 		 */
-		private function itemsCreatedHandler(event:Event):void
+		override protected function itemsCreatedHandler(event:Event):void
 		{
+            super.itemsCreatedHandler(event);
 			if(listModel.selectedIndex != -1)
 				selectionChangeHandler(null);
 		}


[royale-asjs] 03/10: clean compile after merging develop branch

Posted by ah...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

aharui pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/royale-asjs.git

commit 6e4390f51febca105a7f4bd25147a5f35a147c88
Author: Alex Harui <ah...@apache.org>
AuthorDate: Wed Oct 24 13:16:37 2018 -0700

    clean compile after merging develop branch
---
 .../MXRoyale/src/main/royale/mx/controls/LinkBar.as         |  2 +-
 .../MXRoyale/src/main/royale/mx/graphics/LinearGradient.as  | 11 +++++++++++
 .../MXRoyale/src/main/royale/mx/graphics/SolidColor.as      | 13 ++++++++++++-
 .../src/main/royale/mx/graphics/SolidColorStroke.as         | 11 +++++++++++
 .../SparkRoyale/src/main/royale/spark/collections/Sort.as   |  8 ++++++++
 .../src/main/royale/spark/collections/SortField.as          |  9 ++++++++-
 .../main/royale/spark/components/supportClasses/TextBase.as |  9 +++------
 7 files changed, 54 insertions(+), 9 deletions(-)

diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/LinkBar.as b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/LinkBar.as
index 93513e3..7a1dee6 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/controls/LinkBar.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/controls/LinkBar.as
@@ -27,7 +27,7 @@ import mx.core.ClassFactory;
 import mx.core.EdgeMetrics;
 import mx.core.IFlexDisplayObject;
 import mx.core.mx_internal;
-import mx.events.ChildExistenceChangedEvent;
+//import mx.events.ChildExistenceChangedEvent;
 import mx.events.FlexEvent;
 import mx.events.ItemClickEvent;
 import mx.styles.ISimpleStyleClient;
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/graphics/LinearGradient.as b/frameworks/projects/MXRoyale/src/main/royale/mx/graphics/LinearGradient.as
index 9e6ca9b..f3ab501 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/graphics/LinearGradient.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/graphics/LinearGradient.as
@@ -40,6 +40,17 @@ public class LinearGradient implements IFill
     {
     }
 
+    private var _rotation:Number;
+    
+    public function get rotation():Number
+    {
+        return _rotation;
+    }
+    public function set rotation(value:Number):void
+    {
+        _rotation = value;
+    }
+    
     private var _entries:Array;
     
     public function get entries():Array
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/graphics/SolidColor.as b/frameworks/projects/MXRoyale/src/main/royale/mx/graphics/SolidColor.as
index fe5dce6..f8ba794 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/graphics/SolidColor.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/graphics/SolidColor.as
@@ -38,6 +38,17 @@ package mx.graphics
         {
         }
 
+        private var _alpha:Number;
+        
+        public function get alpha():Number
+        {
+            return _alpha;
+        }
+        public function set alpha(value:Number):void
+        {
+            _alpha = value;
+        }
+
         private var _color:Number;
         
         public function get color():Number
@@ -48,6 +59,6 @@ package mx.graphics
         {
             _color = value;
         }
-
+        
 	}
 }
diff --git a/frameworks/projects/MXRoyale/src/main/royale/mx/graphics/SolidColorStroke.as b/frameworks/projects/MXRoyale/src/main/royale/mx/graphics/SolidColorStroke.as
index 47a8510..29de512 100644
--- a/frameworks/projects/MXRoyale/src/main/royale/mx/graphics/SolidColorStroke.as
+++ b/frameworks/projects/MXRoyale/src/main/royale/mx/graphics/SolidColorStroke.as
@@ -59,6 +59,17 @@ package mx.graphics
         _color = value;
     }
 
+    private var _alpha:Number;
+        
+    public function get alpha():Number
+    {
+        return _alpha;
+    }
+    public function set alpha(value:Number):void
+    {
+        _alpha = value;
+    }
+
 	//----------------------------------
     //  caps
     //----------------------------------
diff --git a/frameworks/projects/SparkRoyale/src/main/royale/spark/collections/Sort.as b/frameworks/projects/SparkRoyale/src/main/royale/spark/collections/Sort.as
index e696a0f..e5a13fa 100644
--- a/frameworks/projects/SparkRoyale/src/main/royale/spark/collections/Sort.as
+++ b/frameworks/projects/SparkRoyale/src/main/royale/spark/collections/Sort.as
@@ -200,6 +200,14 @@ package spark.collections
 		// include "../core/Version.as";
 		// include "AdvancedStyleClientImplementation.as";
 		
+        public function get styleName():Object
+        {
+            return null;
+        }
+        public function set styleName(value:Object):void
+        {
+        }
+        
 		//--------------------------------------------------------------------------
 		//
 		//  Class constants
diff --git a/frameworks/projects/SparkRoyale/src/main/royale/spark/collections/SortField.as b/frameworks/projects/SparkRoyale/src/main/royale/spark/collections/SortField.as
index abd9b7a..e753585 100644
--- a/frameworks/projects/SparkRoyale/src/main/royale/spark/collections/SortField.as
+++ b/frameworks/projects/SparkRoyale/src/main/royale/spark/collections/SortField.as
@@ -166,7 +166,14 @@ package spark.collections
 	{
 		// include "../core/Version.as";
 		// include "AdvancedStyleClientImplementation.as";
-		
+        public function get styleName():Object
+        {
+            return null;
+        }
+        public function set styleName(value:Object):void
+        {
+        }
+
 		//--------------------------------------------------------------------------
 		//
 		//  Constructor
diff --git a/frameworks/projects/SparkRoyale/src/main/royale/spark/components/supportClasses/TextBase.as b/frameworks/projects/SparkRoyale/src/main/royale/spark/components/supportClasses/TextBase.as
index 54791e3..a938750 100644
--- a/frameworks/projects/SparkRoyale/src/main/royale/spark/components/supportClasses/TextBase.as
+++ b/frameworks/projects/SparkRoyale/src/main/royale/spark/components/supportClasses/TextBase.as
@@ -21,10 +21,6 @@ package spark.components.supportClasses
 {
 
 import org.apache.royale.geom.Rectangle;
-COMPILE::SWF
-{
-    import flash.display.DisplayObject;      
-}
 /*
 import flash.display.Graphics;
 import flash.display.Shape;
@@ -40,6 +36,7 @@ import spark.core.IDisplayText;
 import spark.utils.TextUtil;
 
 */
+import mx.core.IUIComponent;
 import mx.core.UIComponent;
 import mx.core.mx_internal;
 import mx.events.FlexEvent;
@@ -973,7 +970,7 @@ public class TextBase extends UIComponent
             // Add new TextLine accounting for our background Shape.
             COMPILE::SWF
             {
-                $addChildAt(textLine as DisplayObject, 1);
+                $addChildAt(textLine as IUIComponent, 1);
             }
             COMPILE::JS
             {
@@ -1003,7 +1000,7 @@ public class TextBase extends UIComponent
             {
                 COMPILE::SWF
                 {
-                    UIComponent(textLine.parent).$removeChild(textLine as DisplayObject);                        
+                    UIComponent(textLine.parent).$removeChild(textLine as IUIComponent);                        
                 }
                 COMPILE::JS
                 {