Skip navigation
Currently Being Moderated

[svn:fx-trunk] 7967: PARB changes to TextGraphicElement/SimpleText/ RichText and to text styles in general.

Jun 18, 2009 1:04 PM

Revision: 7967

Author:   gosmith@adobe.com

Date:     2009-06-18 12:44:16 -0700 (Thu, 18 Jun 2009)

 

Log Message:

***********

PARB changes to TextGraphicElement/SimpleText/RichText and to text styles in general.

 

TextGraphicElement:

 

The 'truncation' property has been renamed to 'maxDisplayedLines'.

 

The isTruncated() method has become an 'isTruncated' read-only property.

 

RichText:

 

Since a TextFlow object is the fundamental representation for rich test in TLF, the RichText component now has a public textFlow:TextFlow property which you can get or set. To turn TLF markup -- in either String or XML form -- into a TextFlow, use the static importFromString() and importFromXML() methods in the TextFlowUtil class. These are bindable methods so that if the markup parameter changes they will re-evaluate. To turn the TextFlow back into markup, use TextFLowUtil.export(...) to produce XML.

 

The 'content' property is now intended only for use by the MXML compiler. It is set-only and only supports being set to what MXML markup produces: a String (which will be treated as the text of an implicit span in an implicit paragraph), a FlowElement, or an Array of Strings and FlowElements.

 

The 'text', 'textFlow', and 'content' properties are interacting properties. For example, you can set 'textFlow' and then get the 'text', and vice versa. In fact, you can now do this immediately, without waiting for the component to undergo a LayoutManager pass. Of these three properties, the last one set in ActionScript wins; if more than one is set in MXML the results are undefined since MXML does not guarantee the order in which properties are set. Setting any of them to null is equivalent to setting the 'text' to the empty String, which is the initial state of the component.

 

Styles:

 

The 'lineBreak' style is now non-inheriting, since in TLF it doesn't inherit from FlowElement to FlowElement.

 

The text styles are now divided into five buckets:

 

BasicInheritingTextStyles.as

BasicNonInheritingTextStyles.as

AdvancedInheritingTextStyles.as

AdvancedNonInheritingTextStyles.as

SelectionFormatTextStyles.as

 

Skinnable components like TextInput and TextArea no longer declare any on the noninheriting text styles, because the RichTextElement in the skin doesn't inherit them. You must set them directly on the RichTextElement in the component's skin, either with ActionScript or by reskinning.

 

The styleInitialized() method has been added to the IAdvancedStyleClient interface.

 

QE Notes: None

Doc Notes: None

Bugs: None

Reviewer: Carol

 

Modified Paths:

**************

    flex/sdk/trunk/frameworks/projects/airframework/src/spark/skins/spark /SparkChromeWindowedApplicationSkin.mxml

    flex/sdk/trunk/frameworks/projects/airframework/src/spark/skins/spark /WindowedApplicationSkin.mxml

    flex/sdk/trunk/frameworks/projects/airframework/src/spark/skins/spark /windowChrome/MacTitleBarSkin.mxml

    flex/sdk/trunk/frameworks/projects/airframework/src/spark/skins/spark /windowChrome/TitleBarSkin.mxml

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/Numeric Stepper.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/Scrolle r.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/Skinnab leContainer.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/Skinnab leDataContainer.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/VideoPl ayer.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/support Classes/ButtonBase.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/support Classes/GroupBase.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/support Classes/SkinnableTextBase.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/components/support Classes/Slider.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/primitives/RichEdi tableText.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/primitives/RichTex t.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/primitives/SimpleT ext.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/primitives/support Classes/TextGraphicElement.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/skins/spark/Button BarFirstButtonSkin.mxml

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/skins/spark/Button BarLastButtonSkin.mxml

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/skins/spark/Button BarMiddleButtonSkin.mxml

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/skins/spark/Button Skin.mxml

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/skins/spark/CheckB oxSkin.mxml

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/skins/spark/Defaul tButtonSkin.mxml

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/skins/spark/RadioB uttonSkin.mxml

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/skins/spark/Toggle ButtonSkin.mxml

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/utils/TextFlowUtil .as

    flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/IAdvancedS tyleClient.as

    flex/sdk/trunk/frameworks/projects/framework/src/mx/styles/StyleProxy .as

    flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wirefram e/ButtonBarFirstButtonSkin.mxml

    flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wirefram e/ButtonBarLastButtonSkin.mxml

    flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wirefram e/ButtonBarMiddleButtonSkin.mxml

    flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wirefram e/ButtonSkin.mxml

    flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wirefram e/CheckBoxSkin.mxml

    flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wirefram e/DefaultButtonSkin.mxml

    flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wirefram e/RadioButtonSkin.mxml

    flex/sdk/trunk/frameworks/projects/wireframe/src/spark/skins/wirefram e/ToggleButtonSkin.mxml

 

Added Paths:

***********

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/styles/metadata/Ad vancedInheritingTextStyles.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/styles/metadata/Ad vancedNonInheritingTextStyles.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/styles/metadata/Ba sicInheritingTextStyles.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/styles/metadata/Ba sicNonInheritingTextStyles.as

 

Removed Paths:

*************

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/styles/metadata/Ad vancedTextLayoutFormatStyles.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/styles/metadata/Ba sicTextLayoutFormatStyles.as

    flex/sdk/trunk/frameworks/projects/flex4/src/spark/styles/metadata/No nInheritingTextLayoutFormatStyles.as

 

More Like This

  • Retrieving data ...

Bookmarked By (0)