適用於 Adobe® Flash® Platform 的 ActionScript® 3.0 參考
首頁  |  隱藏套件和類別清單 |  套件  |  類別  |  新增內容  |  索引  |  附錄  |  為什麼顯示英文?
篩選: AIR 30.0 和更早版本, Flash Player 30.0 和更早版本, Flash Lite 4
Flex 4.6 和更早版本, Flash Pro CS6 和更早版本
隱藏篩選
flashx.textLayout.formats 

TextLayoutFormat  - AS3

套件x

最上層
adobe.utils
air.desktop
air.net
air.update
air.update.events
coldfusion.air
coldfusion.air.errors
coldfusion.air.events
coldfusion.service
coldfusion.service.events
coldfusion.service.mxml
com.adobe.acm.solutions.authoring.domain.extensions
com.adobe.acm.solutions.ccr.domain.extensions
com.adobe.consulting.pst.vo
com.adobe.dct.component
com.adobe.dct.component.datadictionary
com.adobe.dct.component.datadictionaryElement
com.adobe.dct.component.dataElementsPanel
com.adobe.dct.component.toolbars
com.adobe.dct.event
com.adobe.dct.exp
com.adobe.dct.model
com.adobe.dct.service
com.adobe.dct.service.provider
com.adobe.dct.transfer
com.adobe.dct.util
com.adobe.dct.view
com.adobe.ep.taskmanagement.domain
com.adobe.ep.taskmanagement.event
com.adobe.ep.taskmanagement.filter
com.adobe.ep.taskmanagement.services
com.adobe.ep.taskmanagement.util
com.adobe.ep.ux.attachmentlist.component
com.adobe.ep.ux.attachmentlist.domain
com.adobe.ep.ux.attachmentlist.domain.events
com.adobe.ep.ux.attachmentlist.domain.renderers
com.adobe.ep.ux.attachmentlist.skin
com.adobe.ep.ux.attachmentlist.skin.renderers
com.adobe.ep.ux.content.event
com.adobe.ep.ux.content.factory
com.adobe.ep.ux.content.handlers
com.adobe.ep.ux.content.managers
com.adobe.ep.ux.content.model.asset
com.adobe.ep.ux.content.model.preview
com.adobe.ep.ux.content.model.relation
com.adobe.ep.ux.content.model.search
com.adobe.ep.ux.content.model.toolbar
com.adobe.ep.ux.content.search
com.adobe.ep.ux.content.services
com.adobe.ep.ux.content.services.load
com.adobe.ep.ux.content.services.permissions
com.adobe.ep.ux.content.services.preview
com.adobe.ep.ux.content.services.providers
com.adobe.ep.ux.content.services.query
com.adobe.ep.ux.content.services.relationships
com.adobe.ep.ux.content.services.search.lccontent
com.adobe.ep.ux.content.services.version
com.adobe.ep.ux.content.view
com.adobe.ep.ux.content.view.components.activate
com.adobe.ep.ux.content.view.components.grid
com.adobe.ep.ux.content.view.components.grid.hover
com.adobe.ep.ux.content.view.components.grid.hover.component
com.adobe.ep.ux.content.view.components.grid.renderers
com.adobe.ep.ux.content.view.components.relationships
com.adobe.ep.ux.content.view.components.review
com.adobe.ep.ux.content.view.components.search.renderers
com.adobe.ep.ux.content.view.components.searchpod
com.adobe.ep.ux.content.view.components.toolbar
com.adobe.ep.ux.content.view.components.toolbar.controlRenderers
com.adobe.ep.ux.content.view.components.version
com.adobe.ep.ux.documentsubmit.component
com.adobe.ep.ux.documentsubmit.domain
com.adobe.ep.ux.documentsubmit.skin
com.adobe.ep.ux.taskaction.component
com.adobe.ep.ux.taskaction.domain
com.adobe.ep.ux.taskaction.domain.events
com.adobe.ep.ux.taskaction.skin
com.adobe.ep.ux.taskdetails.component
com.adobe.ep.ux.taskdetails.domain
com.adobe.ep.ux.taskdetails.skin
com.adobe.ep.ux.tasklist.component
com.adobe.ep.ux.tasklist.domain
com.adobe.ep.ux.tasklist.skin
com.adobe.ep.ux.webdocumentviewer.domain
com.adobe.exm.expression
com.adobe.exm.expression.error
com.adobe.exm.expression.event
com.adobe.exm.expression.impl
com.adobe.fiber.runtime.lib
com.adobe.fiber.services
com.adobe.fiber.services.wrapper
com.adobe.fiber.styles
com.adobe.fiber.util
com.adobe.fiber.valueobjects
com.adobe.gravity.binding
com.adobe.gravity.context
com.adobe.gravity.flex.bundleloader
com.adobe.gravity.flex.progress
com.adobe.gravity.flex.serviceloader
com.adobe.gravity.framework
com.adobe.gravity.init
com.adobe.gravity.service.bundleloader
com.adobe.gravity.service.logging
com.adobe.gravity.service.manifest
com.adobe.gravity.service.progress
com.adobe.gravity.tracker
com.adobe.gravity.ui
com.adobe.gravity.utility
com.adobe.gravity.utility.async
com.adobe.gravity.utility.error
com.adobe.gravity.utility.events
com.adobe.gravity.utility.factory
com.adobe.gravity.utility.flex.async
com.adobe.gravity.utility.logging
com.adobe.gravity.utility.message
com.adobe.gravity.utility.sequence
com.adobe.gravity.utility.url
com.adobe.guides.control
com.adobe.guides.domain
com.adobe.guides.i18n
com.adobe.guides.spark.components.skins
com.adobe.guides.spark.components.skins.mx
com.adobe.guides.spark.headers.components
com.adobe.guides.spark.headers.skins
com.adobe.guides.spark.layouts.components
com.adobe.guides.spark.layouts.skins
com.adobe.guides.spark.navigators.components
com.adobe.guides.spark.navigators.renderers
com.adobe.guides.spark.navigators.skins
com.adobe.guides.spark.util
com.adobe.guides.spark.wrappers.components
com.adobe.guides.spark.wrappers.skins
com.adobe.guides.submit
com.adobe.icc.dc.domain
com.adobe.icc.dc.domain.factory
com.adobe.icc.editors.events
com.adobe.icc.editors.handlers
com.adobe.icc.editors.managers
com.adobe.icc.editors.model
com.adobe.icc.editors.model.config
com.adobe.icc.editors.model.el
com.adobe.icc.editors.model.el.operands
com.adobe.icc.editors.model.el.operators
com.adobe.icc.enum
com.adobe.icc.external.dc
com.adobe.icc.obj
com.adobe.icc.services
com.adobe.icc.services.category
com.adobe.icc.services.config
com.adobe.icc.services.download
com.adobe.icc.services.export
com.adobe.icc.services.external
com.adobe.icc.services.formbridge
com.adobe.icc.services.fragmentlayout
com.adobe.icc.services.layout
com.adobe.icc.services.letter
com.adobe.icc.services.locator
com.adobe.icc.services.module
com.adobe.icc.services.render
com.adobe.icc.services.submit
com.adobe.icc.services.user
com.adobe.icc.token
com.adobe.icc.vo
com.adobe.icc.vo.render
com.adobe.icomm.assetplacement.controller
com.adobe.icomm.assetplacement.controller.utils
com.adobe.icomm.assetplacement.data
com.adobe.icomm.assetplacement.model
com.adobe.livecycle.assetmanager.client
com.adobe.livecycle.assetmanager.client.event
com.adobe.livecycle.assetmanager.client.handler
com.adobe.livecycle.assetmanager.client.managers
com.adobe.livecycle.assetmanager.client.model
com.adobe.livecycle.assetmanager.client.model.cms
com.adobe.livecycle.assetmanager.client.service
com.adobe.livecycle.assetmanager.client.service.search
com.adobe.livecycle.assetmanager.client.service.search.cms
com.adobe.livecycle.assetmanager.client.utils
com.adobe.livecycle.content
com.adobe.livecycle.rca.model
com.adobe.livecycle.rca.model.constant
com.adobe.livecycle.rca.model.document
com.adobe.livecycle.rca.model.participant
com.adobe.livecycle.rca.model.reminder
com.adobe.livecycle.rca.model.stage
com.adobe.livecycle.rca.service
com.adobe.livecycle.rca.service.core
com.adobe.livecycle.rca.service.core.delegate
com.adobe.livecycle.rca.service.process
com.adobe.livecycle.rca.service.process.delegate
com.adobe.livecycle.rca.token
com.adobe.livecycle.ria.security.api
com.adobe.livecycle.ria.security.service
com.adobe.mosaic.layouts
com.adobe.mosaic.layouts.dragAndDrop
com.adobe.mosaic.layouts.interfaces
com.adobe.mosaic.mxml
com.adobe.mosaic.om.constants
com.adobe.mosaic.om.events
com.adobe.mosaic.om.impl
com.adobe.mosaic.om.interfaces
com.adobe.mosaic.skinning
com.adobe.mosaic.sparklib.editors
com.adobe.mosaic.sparklib.optionMenu
com.adobe.mosaic.sparklib.scrollableMenu
com.adobe.mosaic.sparklib.scrollableMenu.skins
com.adobe.mosaic.sparklib.tabLayout
com.adobe.mosaic.sparklib.tabLayout.events
com.adobe.mosaic.sparklib.tabLayout.layouts
com.adobe.mosaic.sparklib.tabLayout.skins
com.adobe.mosaic.sparklib.text
com.adobe.mosaic.sparklib.util
com.adobe.solutions.acm.authoring.presentation
com.adobe.solutions.acm.authoring.presentation.actionbar
com.adobe.solutions.acm.authoring.presentation.common
com.adobe.solutions.acm.authoring.presentation.events
com.adobe.solutions.acm.authoring.presentation.fragment
com.adobe.solutions.acm.authoring.presentation.letter
com.adobe.solutions.acm.authoring.presentation.letter.data
com.adobe.solutions.acm.authoring.presentation.preview
com.adobe.solutions.acm.authoring.presentation.rte
com.adobe.solutions.acm.ccr.presentation
com.adobe.solutions.acm.ccr.presentation.contentcapture
com.adobe.solutions.acm.ccr.presentation.contentcapture.events
com.adobe.solutions.acm.ccr.presentation.contentcapture.preview
com.adobe.solutions.acm.ccr.presentation.datacapture
com.adobe.solutions.acm.ccr.presentation.datacapture.renderers
com.adobe.solutions.acm.ccr.presentation.pdf
com.adobe.solutions.exm
com.adobe.solutions.exm.authoring
com.adobe.solutions.exm.authoring.components.controls
com.adobe.solutions.exm.authoring.components.toolbars
com.adobe.solutions.exm.authoring.domain
com.adobe.solutions.exm.authoring.domain.expression
com.adobe.solutions.exm.authoring.domain.impl
com.adobe.solutions.exm.authoring.domain.method
com.adobe.solutions.exm.authoring.domain.variable
com.adobe.solutions.exm.authoring.enum
com.adobe.solutions.exm.authoring.events
com.adobe.solutions.exm.authoring.model
com.adobe.solutions.exm.authoring.renderer
com.adobe.solutions.exm.authoring.view
com.adobe.solutions.exm.expression
com.adobe.solutions.exm.impl
com.adobe.solutions.exm.impl.method
com.adobe.solutions.exm.method
com.adobe.solutions.exm.mock
com.adobe.solutions.exm.mock.method
com.adobe.solutions.exm.runtime
com.adobe.solutions.exm.runtime.impl
com.adobe.solutions.exm.variable
com.adobe.solutions.prm.constant
com.adobe.solutions.prm.domain
com.adobe.solutions.prm.domain.factory
com.adobe.solutions.prm.domain.impl
com.adobe.solutions.prm.domain.manager
com.adobe.solutions.prm.presentation.asset
com.adobe.solutions.prm.presentation.constant
com.adobe.solutions.prm.presentation.document
com.adobe.solutions.prm.presentation.event
com.adobe.solutions.prm.presentation.file
com.adobe.solutions.prm.presentation.project
com.adobe.solutions.prm.presentation.team
com.adobe.solutions.prm.presentation.util
com.adobe.solutions.prm.service
com.adobe.solutions.prm.services.impl
com.adobe.solutions.prm.vo
com.adobe.solutions.rca.constant
com.adobe.solutions.rca.domain
com.adobe.solutions.rca.domain.common
com.adobe.solutions.rca.domain.factory
com.adobe.solutions.rca.domain.impl
com.adobe.solutions.rca.domain.impl.manager
com.adobe.solutions.rca.domain.manager
com.adobe.solutions.rca.presentation
com.adobe.solutions.rca.presentation.comment
com.adobe.solutions.rca.presentation.constant
com.adobe.solutions.rca.presentation.event
com.adobe.solutions.rca.presentation.gantt
com.adobe.solutions.rca.presentation.gantt.ruler
com.adobe.solutions.rca.presentation.template
com.adobe.solutions.rca.presentation.template.audit
com.adobe.solutions.rca.presentation.template.definition
com.adobe.solutions.rca.presentation.template.documents
com.adobe.solutions.rca.presentation.template.stages
com.adobe.solutions.rca.presentation.util
com.adobe.solutions.rca.service
com.adobe.solutions.rca.services.impl
com.adobe.solutions.rca.vo
com.adobe.solutions.rca.vo.um
com.adobe.viewsource
fl.accessibility
fl.containers
fl.controls
fl.controls.dataGridClasses
fl.controls.listClasses
fl.controls.progressBarClasses
fl.core
fl.data
fl.display
fl.events
fl.ik
fl.lang
fl.livepreview
fl.managers
fl.motion
fl.motion.easing
fl.rsl
fl.text
fl.transitions
fl.transitions.easing
fl.video
flash.accessibility
flash.concurrent
flash.crypto
flash.data
flash.desktop
flash.display
flash.display3D
flash.display3D.textures
flash.errors
flash.events
flash.external
flash.filesystem
flash.filters
flash.geom
flash.globalization
flash.html
flash.media
flash.net
flash.net.dns
flash.net.drm
flash.notifications
flash.permissions
flash.printing
flash.profiler
flash.sampler
flash.security
flash.sensors
flash.system
flash.text
flash.text.engine
flash.text.ime
flash.ui
flash.utils
flash.xml
flashx.textLayout
flashx.textLayout.compose
flashx.textLayout.container
flashx.textLayout.conversion
flashx.textLayout.edit
flashx.textLayout.elements
flashx.textLayout.events
flashx.textLayout.factory
flashx.textLayout.formats
flashx.textLayout.operations
flashx.textLayout.utils
flashx.undo
ga.controls
ga.layouts
ga.model
ga.uiComponents
ga.util
ga.views
ga.wrappers
lc.foundation
lc.foundation.domain
lc.foundation.events
lc.foundation.ui
lc.foundation.util
lc.preloader
lc.procmgmt
lc.procmgmt.commands
lc.procmgmt.domain
lc.procmgmt.events
lc.procmgmt.formbridge
lc.procmgmt.impl
lc.procmgmt.ui.attachments
lc.procmgmt.ui.controls
lc.procmgmt.ui.controls.card
lc.procmgmt.ui.controls.renderer
lc.procmgmt.ui.help
lc.procmgmt.ui.layout
lc.procmgmt.ui.presentationmodel
lc.procmgmt.ui.process
lc.procmgmt.ui.search
lc.procmgmt.ui.startpoint
lc.procmgmt.ui.task
lc.procmgmt.ui.task.form
lc.procmgmt.ui.task.form.commands
lc.procmgmt.ui.tracking
mx.accessibility
mx.automation
mx.automation.air
mx.automation.delegates
mx.automation.delegates.advancedDataGrid
mx.automation.delegates.charts
mx.automation.delegates.containers
mx.automation.delegates.controls
mx.automation.delegates.controls.dataGridClasses
mx.automation.delegates.controls.fileSystemClasses
mx.automation.delegates.core
mx.automation.delegates.flashflexkit
mx.automation.events
mx.binding
mx.binding.utils
mx.charts
mx.charts.chartClasses
mx.charts.effects
mx.charts.effects.effectClasses
mx.charts.events
mx.charts.renderers
mx.charts.series
mx.charts.series.items
mx.charts.series.renderData
mx.charts.styles
mx.collections
mx.collections.errors
mx.containers
mx.containers.accordionClasses
mx.containers.dividedBoxClasses
mx.containers.errors
mx.containers.utilityClasses
mx.controls
mx.controls.advancedDataGridClasses
mx.controls.dataGridClasses
mx.controls.listClasses
mx.controls.menuClasses
mx.controls.olapDataGridClasses
mx.controls.scrollClasses
mx.controls.sliderClasses
mx.controls.textClasses
mx.controls.treeClasses
mx.controls.videoClasses
mx.core
mx.core.windowClasses
mx.data
mx.data.crypto
mx.data.errors
mx.data.events
mx.data.messages
mx.data.mxml
mx.data.offline.errors
mx.data.utils
mx.effects
mx.effects.easing
mx.effects.effectClasses
mx.events
mx.filters
mx.flash
mx.formatters
mx.geom
mx.graphics
mx.graphics.codec
mx.graphics.shaderClasses
mx.logging
mx.logging.errors
mx.logging.targets
mx.managers
mx.messaging
mx.messaging.channels
mx.messaging.config
mx.messaging.errors
mx.messaging.events
mx.messaging.management
mx.messaging.messages
mx.modules
mx.netmon
mx.olap
mx.olap.aggregators
mx.preloaders
mx.printing
mx.resources
mx.rpc
mx.rpc.events
mx.rpc.http
mx.rpc.http.mxml
mx.rpc.livecycle
mx.rpc.mxml
mx.rpc.remoting
mx.rpc.remoting.mxml
mx.rpc.soap
mx.rpc.soap.mxml
mx.rpc.wsdl
mx.rpc.xml
mx.skins
mx.skins.halo
mx.skins.spark
mx.skins.wireframe
mx.skins.wireframe.windowChrome
mx.states
mx.styles
mx.utils
mx.validators
org.osmf.containers
org.osmf.display
org.osmf.elements
org.osmf.events
org.osmf.layout
org.osmf.logging
org.osmf.media
org.osmf.metadata
org.osmf.net
org.osmf.net.dvr
org.osmf.net.httpstreaming
org.osmf.net.metrics
org.osmf.net.qos
org.osmf.net.rtmpstreaming
org.osmf.net.rules
org.osmf.traits
org.osmf.utils
spark.accessibility
spark.automation.delegates
spark.automation.delegates.components
spark.automation.delegates.components.gridClasses
spark.automation.delegates.components.mediaClasses
spark.automation.delegates.components.supportClasses
spark.automation.delegates.skins.spark
spark.automation.events
spark.collections
spark.components
spark.components.calendarClasses
spark.components.gridClasses
spark.components.mediaClasses
spark.components.supportClasses
spark.components.windowClasses
spark.core
spark.effects
spark.effects.animation
spark.effects.easing
spark.effects.interpolation
spark.effects.supportClasses
spark.events
spark.filters
spark.formatters
spark.formatters.supportClasses
spark.globalization
spark.globalization.supportClasses
spark.layouts
spark.layouts.supportClasses
spark.managers
spark.modules
spark.preloaders
spark.primitives
spark.primitives.supportClasses
spark.skins
spark.skins.mobile
spark.skins.mobile.supportClasses
spark.skins.spark
spark.skins.spark.mediaClasses.fullScreen
spark.skins.spark.mediaClasses.normal
spark.skins.spark.windowChrome
spark.skins.wireframe
spark.skins.wireframe.mediaClasses
spark.skins.wireframe.mediaClasses.fullScreen
spark.transitions
spark.utils
spark.validators
spark.validators.supportClasses
xd.core.axm.enterprise.view.components
xd.core.axm.enterprise.view.skins
xd.core.axm.view.components
xd.core.axm.view.components.support

語言元素

全域常數
全域函數
運算子
陳述式、關鍵字和指令
特殊類型

附錄

新增內容
編譯器錯誤
編譯器警告
執行階段錯誤
移轉至 ActionScript 3
支援的字元集
僅限 MXML 標籤
移動 XML 元素
Timed Text 標籤
不建議元素清單
AccessibilityImplementation 常數
如何使用 ActionScript 範例
法律聲明
套件flashx.textLayout.formats
類別public class TextLayoutFormat
繼承TextLayoutFormat Inheritance Object
實作 ITextLayoutFormat
子類別 ListMarkerFormat

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

TextLayoutFormat 類別保留所有文字版面屬性。這些屬性會影響容器層級、段落層級以及文字層級的文字流排的格式和樣式。ContainerController 類別和 FlowElement 基底類別都具有 format 屬性,讓您可將 TextLayoutFormat 實體指定給這兩項類別。將 TextLayoutFormat 物件指定給容器,以改變所有容器內容的格式。將 TextLayoutFormat 物件指定給 FlowElement 子系,以指定該特定元素的格式:TextFlow、ParagraphElement、DivElement、SpanElement、InlineGraphicElement、LinkElement 以及 TCYElement。除了 format 屬性之外,這些類別也定義每一個個別的 TextLayoutFormat 屬性,所以如有需要,您可以覆寫該元素的特定樣式屬性設定。

因為您可以在多重層級設定指定樣式,這可能會發生衝突。例如,在 TextFlow 層級的文字顏色可能設定為黑色,而 SpanElement 物件卻將它設定為藍色。一般原則是文字流排樹狀結構中最低層級的設定為最優先。因此,如果設定了 TextFlow 實體的連字層級,而且也設定 DivElement 的連字層級,則 DivElement 設定為優先。

重疊顯示樣式是指如果在較低層級中未定義樣式值,則採用文字流排中較高層級樣式的程序。當即將顯示元素中未定義的樣式時,會使用其預設值,或使用從父元素所重疊顯示或繼承的值。例如,如果 SpanElement 物件上文字的透明度 (textAlpha 屬性) 未定義,但 TextFlow 中已設定,則 TexFlow.textAlpha 屬性的值會重疊顯示到 SpanElement 物件,並套用到該範圍的文字。重疊顯示的結果,或是套用至元素的樣式總和,將儲存在元素的 computedFormat 屬性。

您可以利用相同的方式,使用 ContainerController 和 FlowElement 類別的 userStyles 屬性套用使用者樣式。此屬性允許您讀取或寫入使用者樣式字典,並將其設定套用到容器或文字流排元素。使用者樣式字典是由成對 stylename-value 組成的物件。userStyles 屬性指定的樣式具有高於其他屬性的優先權。

大部分未定義的樣式,會在重疊顯示期間繼承其直屬父輩的值。少部分樣式則不會繼承其父值,而是使用自身的預設值。

未定義時採用自身預設值的樣式屬性包括: backgroundAlphabackgroundColorcolumnCountcolumnGapcolumnWidthlineBreakpaddingBottompaddingLeftpaddingRightpaddingTopverticalAlign

檢視範例

更多範例

相關 API 元素



公用屬性
 屬性定義自
  alignmentBaseline : *
指定主基線對齊的基線。
TextLayoutFormat
  backgroundAlpha : *
背景的 Alpha (透明度) 值 (如果重疊顯示時未定義,則採用預設值)。
TextLayoutFormat
  backgroundColor : *
文字的背景色彩 (如果重疊顯示時未定義,則採用預設值)。
TextLayoutFormat
  baselineShift : *
從 dominantBaseline 值位移基線的量。
TextLayoutFormat
  blockProgression : *
指定行位置為垂直或水平走向。
TextLayoutFormat
  breakOpportunity : *
將文字分為多行時,控制換行的位置。
TextLayoutFormat
  cffHinting : *
用於此文字的 CFF 提示類型。
TextLayoutFormat
  clearFloats : *
控制文字圍繞浮動圖的方式。
TextLayoutFormat
  color : *
文字的色彩。
TextLayoutFormat
  columnCount : *
文字欄的數目 (如果在重疊顯示時未定義,則採用預設值)。
TextLayoutFormat
  columnGap : *
指定欄與欄之間的間距大小 (以像素為單位),如果重疊顯示時未定義,則採用預設值。
TextLayoutFormat
  columnWidth : *
以像素為單位的欄寬 (如果重疊顯示時未定義,則採用預設值)。
TextLayoutFormat
 Inheritedconstructor : Object
類別物件的參照或是特定物件實體的建構函數。
Object
  coreStyles : Object
[唯讀] 傳回此 TextLayoutFormat 的 coreStyles。
TextLayoutFormat
  defaultFormat : flashx.textLayout.formats:ITextLayoutFormat
[靜態] [唯讀] 傳回具有預設設定的 TextLayoutFormat 物件。
TextLayoutFormat
  digitCase : *
用於此文字的數字大小寫類型。
TextLayoutFormat
  digitWidth : *
用於此文字的數字寬度類型。
TextLayoutFormat
  direction : *
指定文字區塊內之文字的預設雙向內嵌層級。
TextLayoutFormat
  dominantBaseline : *
指定貼齊 alignmentBaseline 的元素基線,以決定行上元素的垂直位置。
TextLayoutFormat
  firstBaselineOffset : *
指定容器中第一行的基線位置。
TextLayoutFormat
  fontFamily : *
要使用的字體名稱,或是以逗號分隔的字體名稱清單。
TextLayoutFormat
  fontLookup : *
要使用的字體查詢。
TextLayoutFormat
  fontSize : *
以像素為單位的文字大小。
TextLayoutFormat
  fontStyle : *
文字的樣式。
TextLayoutFormat
  fontWeight : *
文字的粗細。
TextLayoutFormat
  justificationRule : *
對齊段落中文字所使用的規則。
TextLayoutFormat
  justificationStyle : *
段落對齊所用的樣式。
TextLayoutFormat
  kerning : *
字距微調會調整某些字元組之間的像素,以改善可讀性。
TextLayoutFormat
  leadingModel : *
指定行距模型,它結合了行距基礎及行距方向。
TextLayoutFormat
  ligatureLevel : *
控制字體中定義的哪些連字可用於文字。
TextLayoutFormat
  lineBreak : *
控制容器內的文字換行 (如果重疊顯示時未定義,則採用預設值)。
TextLayoutFormat
  lineHeight : *
文字的行距控制。
TextLayoutFormat
  lineThrough : *
若為 true,將套用刪除線,亦即通過文字中間的線。
TextLayoutFormat
  linkActiveFormat : *
定義正常狀態下的連結格式屬性。
TextLayoutFormat
  linkHoverFormat : *
當滑鼠在連結的邊緣之內 (或上方) 時,定義用於懸浮狀態下的連結格式屬性。
TextLayoutFormat
  linkNormalFormat : *
定義正常狀態下的連結格式屬性。
TextLayoutFormat
  listAutoPadding : *
當該邊上的清單邊框距離值為 auto 時,指定清單的開頭邊緣自動縮排。
TextLayoutFormat
  listMarkerFormat : *
定義格式屬性清單標記。
TextLayoutFormat
  listStylePosition : *
有效值為 ListStylePosition.INSIDE、ListStylePosition.OUTSIDE、FormatValue.INHERIT。若未定義預設值,則表示未設定。如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。
TextLayoutFormat
  listStyleType : *
有效值為 ListStyleType.UPPER_ALPHA、ListStyleType.LOWER_ALPHA、ListStyleType.UPPER_ROMAN、ListStyleType.LOWER_ROMAN、ListStyleType.NONE、ListStyleType.DISC、ListStyleType.CIRCLE、ListStyleType.SQUARE、ListStyleType.BOX、ListStyleType.CHECK、ListStyleType.DIAMOND、ListStyleType.HYPHEN、ListStyleType.ARABIC_INDIC、ListStyleType.BENGALI、ListStyleType.DECIMAL、ListStyleType.DECIMAL_LEADING_ZERO、ListStyleType.DEVANAGARI、ListStyleType.GUJARATI、ListStyleType.GURMUKHI、ListStyleType.KANNADA、ListStyleType.PERSIAN、ListStyleType.THAI、ListStyleType.URDU、ListStyleType.CJK_EARTHLY_BRANCH、ListStyleType.CJK_HEAVENLY_STEM、ListStyleType.HANGUL、ListStyleType.HANGUL_CONSTANT、ListStyleType.HIRAGANA、ListStyleType.HIRAGANA_IROHA、ListStyleType.KATAKANA、ListStyleType.KATAKANA_IROHA、ListStyleType.LOWER_ALPHA、ListStyleType.LOWER_GREEK、ListStyleType.LOWER_LATIN、ListStyleType.UPPER_ALPHA、ListStyleType.UPPER_GREEK、ListStyleType.UPPER_LATIN、FormatValue.INHERIT。若未定義預設值,則表示未設定。如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。
TextLayoutFormat
  locale : *
文字的地區。
TextLayoutFormat
  paddingBottom : *
下方內移距 (以像素為單位)。
TextLayoutFormat
  paddingLeft : *
左方內移距 (以像素為單位)。
TextLayoutFormat
  paddingRight : *
右方內移距 (以像素為單位)。
TextLayoutFormat
  paddingTop : *
上方內移距 (以像素為單位)。
TextLayoutFormat
  paragraphEndIndent : *
指定段落結尾邊緣縮排量的數字 (以像素為單位)。
TextLayoutFormat
  paragraphSpaceAfter : *
指定段落之後保留的間距大小的數字 (以像素為單位)。
TextLayoutFormat
  paragraphSpaceBefore : *
指定段落之前保留的間距大小的數字 (以像素為單位)。
TextLayoutFormat
  paragraphStartIndent : *
指定段落開頭邊緣縮排量的數字 (以像素為單位)。
TextLayoutFormat
  renderingMode : *
用於此文字的顯示模式。
TextLayoutFormat
  styleName : *
指定元素的識別類別,如此只要參照此 styleName就可以設定元素的樣式。
TextLayoutFormat
  styles : Object
[唯讀] 傳回此 TextLayoutFormat 的 styles。
TextLayoutFormat
  tabStops : *
指定段落關聯的定位停駐點。
TextLayoutFormat
  textAlign : *
段落中各行相對於容器的對齊方式。
TextLayoutFormat
  textAlignLast : *
段落中最後 (或唯一的) 一行相對於齊行文字中之容器的對齊方式。
TextLayoutFormat
  textAlpha : *
文字的 Alpha (透明) 值。
TextLayoutFormat
  textDecoration : *
文字上的裝飾。
TextLayoutFormat
  textIndent : *
以像素為單位,指定段落中第一行縮排量的數字。
TextLayoutFormat
  textJustify : *
指定對齊文字的選項。
TextLayoutFormat
  textRotation : *
決定此文字要旋轉的度數。
TextLayoutFormat
  trackingLeft : *
以像素為單位代表要套用至每個字元左側字距調整 (手動字距微調) 量的數字 (或 fontSize 的百分比,例如,120%)。
TextLayoutFormat
  trackingRight : *
以像素為單位代表要套用至每個字元右側字距調整 (手動字距微調) 量的數字 (或 fontSize 的百分比,例如,120%)。
TextLayoutFormat
  typographicCase : *
用於此文字的印刷大小寫類型。
TextLayoutFormat
  userStyles : Object
[唯讀] 傳回此 TextLayoutFormat 的 userStyles。
TextLayoutFormat
  verticalAlign : *
垂直對齊或齊行 (如果重疊顯示時未定義,則採用預設值)。
TextLayoutFormat
  whiteSpaceCollapse : *
將文字匯入 TextFlow 時捨去或保留空格。
TextLayoutFormat
  wordSpacing : *
指定對齊時要使用之文字間的最佳、最小和最大間距 (標準間距的倍數)。
TextLayoutFormat
公用方法
 方法定義自
  
建立新的 TextLayoutFormat 物件。
TextLayoutFormat
  
以傳入的 ITextLayoutFormat 實體中設定的屬性值取代此 TextLayoutFormat 物件中的屬性值。
TextLayoutFormat
  
以此 TextLayoutFormat 物件的值連接傳入的 ITextLayoutFormat 實體中的屬性值。
TextLayoutFormat
  
以此 TextLayoutFormat 物件的值連接傳入的 ITextLayoutFormat 實體中的屬性值。
TextLayoutFormat
  
從 ITextLayoutFormat 實體值複製 TextLayoutFormat 設定到此 TextLayoutFormat 物件。
TextLayoutFormat
  
[靜態] 建立新的 TextLayoutFormat 物件。
TextLayoutFormat
  
getStyle(styleProp:String):*
傳回由指定樣式名稱之 styleProp 參數所指定的樣式值。
TextLayoutFormat
 Inherited
指出物件是否有已定義的指定屬性。
Object
  
[靜態] 比較 ITextLayoutFormat 實體 p1 中的屬性以及 ITextLayoutFormat 實體 p2 中的屬性,如果所有屬性相符,則傳回 true。
TextLayoutFormat
 Inherited
指出 Object 類別的實體是否位於指定為參數的物件原型鏈中。
Object
 Inherited
指出指定的屬性是否存在,以及是否可列舉。
Object
  
如果此 TextLayoutFormat 物件中的屬性與傳入的 ITextLayoutFormat 實體中的屬性不相符,則將此 TextLayoutFormat 物件中的屬性設定為未定義。
TextLayoutFormat
  
如果此 TextLayoutFormat 物件中的屬性與傳入的 ITextLayoutFormat 實體中的屬性相符,則將此 TextLayoutFormat 物件中的屬性設定為未定義。
TextLayoutFormat
 Inherited
為迴圈作業設定動態屬性的可用性。
Object
  
setStyle(styleProp:String, newValue:*):void
將 styleProp 參數所指定的樣式設為 newValue 參數所指定的值。
TextLayoutFormat
 Inherited
傳回代表此物件的字串,根據地區特定慣例進行格式化。
Object
 Inherited
會傳回指定之物件的字串形式。
Object
 Inherited
會傳回指定之物件的基本值。
Object
屬性詳細資訊

alignmentBaseline

屬性
alignmentBaseline:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定主基線對齊的基線。例如,如果設定 dominantBaseline 為 ASCENT,設定 alignmentBaseline 為 DESCENT 會使得文字上方對齊 DESCENT 基線,或在基線之下。通常是由字行中的最大元素決定基線。

baselines

有效值是 TextBaseline.ROMAN、TextBaseline.ASCENT、TextBaseline.DESCENT、TextBaseline.IDEOGRAPHIC_TOP、TextBaseline.IDEOGRAPHIC_CENTER、TextBaseline.IDEOGRAPHIC_BOTTOM、TextBaseline.USE_DOMINANT_BASELINE、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 TextBaseline.USE_DOMINANT_BASELINE。



實作
    public function get alignmentBaseline():*
    public function set alignmentBaseline(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素


範例  ( 如何使用本範例 )
此範例會將 alignmentBaseline 設為三個不同的值 - USE_DOMINANT_BASELINE、DESCENT 以及 IDEOGRAPHIC_CENTER - 表示在 dominantBaseline 設為 ASCENT 的段落三種範圍。
package flashx.textLayout.formats.examples {
    import flash.display.Sprite;
    import flash.text.engine.TextBaseline;
    import flashx.textLayout.container.ContainerController;
    import flashx.textLayout.elements.ParagraphElement;
    import flashx.textLayout.elements.SpanElement;
    import flashx.textLayout.elements.TextFlow;
    import flashx.textLayout.formats.TextAlign;

    public class TextLayoutFormat_alignmentBaselineExample extends Sprite
    {
        public function TextLayoutFormat_alignmentBaselineExample()
        {
            // create text flow with dominantBaseline of ASCENT and 3 spans
            var textFlow:TextFlow = new TextFlow();
            var paragraph:ParagraphElement = new ParagraphElement();
            paragraph.fontFamily = "Helvetica";
            paragraph.fontSize = 20;
            paragraph.dominantBaseline = TextBaseline.ASCENT    
            var spanOne:SpanElement = new SpanElement();
            var spanTwo:SpanElement = new SpanElement();
            var spanThree:SpanElement = new SpanElement();
            spanOne.text = "Hello, World  ";
            spanTwo.text = "Hello, World  ";
            spanThree.text = "Hello, World";
            
            // add spans to paragraph and specify alignment baseline for each
            paragraph.addChild(spanOne);
            spanOne.alignmentBaseline = TextBaseline.USE_DOMINANT_BASELINE;    
            paragraph.addChild(spanTwo);
            spanTwo.alignmentBaseline = TextBaseline.DESCENT;
            paragraph.addChild(spanThree);
            spanThree.alignmentBaseline = TextBaseline.IDEOGRAPHIC_CENTER;
            
            // add paragraph to TextFlow and set container position
            textFlow.addChild(paragraph);
            this.x = 50;
            this.y = 100;
            
            // update controller to display on stage
            textFlow.flowComposer.addController(new ContainerController(this,400,300));
            textFlow.flowComposer.updateAllControllers();    
        }
    }
}

backgroundAlpha

屬性 
backgroundAlpha:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

背景的 Alpha (透明度) 值 (如果重疊顯示時未定義,則採用預設值)。值為 0 時表示完全透明,值為 1 時表示完全不透明。alpha 設為 0 的顯示物件都是作用中的狀態,即使看不見它們亦然。

有效值是從 0 到 1 的數字以及 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義,則此屬性的值就會是 1。



實作
    public function get backgroundAlpha():*
    public function set backgroundAlpha(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

backgroundColor

屬性 
backgroundColor:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

文字的背景色彩 (如果重疊顯示時未定義,則採用預設值)。可以是常數值 BackgroundColor.TRANSPARENT,或指定 3 個 8 位元 RGB (紅色、綠色、藍色) 值的 16 進位值;例如,0xFF0000 是紅色,而 0x00FF00 是綠色。

有效字串值為 BackgroundColor.TRANSPARENT、FormatValue.INHERIT 以及從 0x0 到 0xffffffff 的單位。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義,則此屬性的值就會是 BackgroundColor.TRANSPARENT。



實作
    public function get backgroundColor():*
    public function set backgroundColor(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

baselineShift

屬性 
baselineShift:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

dominantBaseline 值位移基線的量。單位為像素,或 fontSize 的百分比 (在此情況下,請輸入字串值,如 140%)。正值會將水平文字上移 (垂直文字則右移),負值則會將水平文字下移 (垂直文字則左移)。

有效值是 BaselineShift.SUPERSCRIPT、BaselineShift.SUBSCRIPT、FormatValue.INHERIT。

有效值是從 -1000 到 1000 之間的數字。

有效值是從 -1000 到 1000 之間數字的百分比。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 0.0。



實作
    public function get baselineShift():*
    public function set baselineShift(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

blockProgression

屬性 
blockProgression:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定行位置為垂直或水平走向。行由上到下 (BlockProgression.TB,用於水平文字) 排列,或由右向左 (BlockProgression.RL,用於垂直文字) 排列。

有效值是 BlockProgression.RL、BlockProgression.TB、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 BlockProgression.TB。



實作
    public function get blockProgression():*
    public function set blockProgression(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

breakOpportunity

屬性 
breakOpportunity:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

將文字分為多行時,控制換行的位置。設定為 BreakOpportunity.AUTO 以一般方式斷行。設定為 BreakOpportunity.NONE 則文字不斷行,除非文字超過度量且沒有其他空間可斷行。。設定為 BreakOpportunity.ANY 可在任意位置斷行,而非只限於在單字之間斷行。設定為 BreakOpportunity.ALL 使每個印刷群集放置於個別行 (對路徑上的文字很實用)。

有效值為 BreakOpportunity.ALL、BreakOpportunity.ANY、BreakOpportunity.AUTO、BreakOpportunity.NONE、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 BreakOpportunity.AUTO。



實作
    public function get breakOpportunity():*
    public function set breakOpportunity(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

cffHinting

屬性 
cffHinting:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

用於此文字的 CFF 提示類型。CFF 提示會決定 Flash 執行階段是否強制強式水平詞幹以符合子像素格線。只有當 renderingMode 屬性設定為 RenderingMode.CFF,且字體為內嵌時 (fontLookup 屬性設定為 FontLookup.EMBEDDED_CFF),才會套用此屬性。在小型螢幕上,提示會為讀者產生清晰、易辨識的文字。

有效值為 CFFHinting.NONE、CFFHinting.HORIZONTAL_STEM、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 CFFHinting.HORIZONTAL_STEM。



實作
    public function get cffHinting():*
    public function set cffHinting(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

clearFloats

屬性 
clearFloats:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

控制文字圍繞浮動圖的方式。「none」值允許文字以極貼近的方式圍繞浮動圖。「left」值會使文字略過含有左邊浮動圖之容器的任何部分。「right」值會使文字略過含有右邊浮動圖之容器的任何部分。「both」值會使文字略過任何浮動圖。

有效值為 ClearFloats.STARTClearFloats.ENDClearFloats.LEFTClearFloats.RIGHTClearFloats.BOTHClearFloats.NONEFormatValue.INHERIT

若未定義預設值,則表示未設定。

如果在重疊顯示時未定義,則此屬性的值就會是 ClearFloats.NONE



實作
    public function get clearFloats():*
    public function set clearFloats(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內。

相關 API 元素

color

屬性 
color:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

文字的色彩。指定 3 個 8 位元 RGB (紅色、綠色、藍色) 值的 16 進位數字;例如 0xFF0000 為紅色,而 0x00FF00 為綠色。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 0。



實作
    public function get color():*
    public function set color(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

columnCount

屬性 
columnCount:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

文字欄的數目 (如果在重疊顯示時未定義,則採用預設值)。欄的數目會覆寫其他的欄設定。值為整數,如果未指定值,則為 FormatValue.AUTO。如果未指定 columnCount,則會使用 columnWidth 建立容器內可容納的最大欄位數目。

有效字串值為 FormatValue.AUTO、FormatValue.INHERIT 以及從 1 至 50 的整數。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義,則此屬性的值就會是 FormatValue.AUTO。



實作
    public function get columnCount():*
    public function set columnCount(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

columnGap

屬性 
columnGap:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定欄與欄之間的間距大小 (以像素為單位),如果重疊顯示時未定義,則採用預設值。值為數字

有效值是從 0 到 1000 的數字以及 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義,則此屬性的值就會是 20。



實作
    public function get columnGap():*
    public function set columnGap(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

columnWidth

屬性 
columnWidth:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

以像素為單位的欄寬 (如果重疊顯示時未定義,則採用預設值)。如果您指定欄的寬度,而非數目,則在具有容器寬度和 columnGap 設定的情況下,TextLayout 會儘可能建立符合該寬度的最大欄數。在最後一欄之後,任何剩餘的空格都是靠左對齊。值為數字。

有效字串值為 FormatValue.AUTO、FormatValue.INHERIT 以及從 0 到 8000 的數字。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義,則此屬性的值就會是 FormatValue.AUTO。



實作
    public function get columnWidth():*
    public function set columnWidth(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

coreStyles

屬性 
coreStyles:Object  [唯讀]

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

傳回此 TextLayoutFormat 的 coreStyles。coreStyles 物件包含 TextLayoutFormat 所定義且位於 TextLayoutFormat.description 中的格式。傳回的 coreStyles 物件包含一個 stylename-value 組的陣列。



實作
    public function get coreStyles():Object

相關 API 元素

defaultFormat

屬性 
defaultFormat:flashx.textLayout.formats:ITextLayoutFormat  [唯讀]

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

傳回具有預設設定的 TextLayoutFormat 物件。此方法永遠會傳回相同物件。



實作
    public static function get defaultFormat():flashx.textLayout.formats:ITextLayoutFormat

digitCase

屬性 
digitCase:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

用於此文字的數字大小寫類型。設定值為 DigitCase.OLD_STYLE 會使用不同的字母上緣和字母下緣模擬小寫字體。數字是等比例的間距。只有在選取的字樣中可使用此樣式,大部分是在補充或專業字體中。DigitCase.LINING 設定具有全部大寫字高度,而且通常在圖表中以固定間距排列。

digitCase

有效值為 DigitCase.DEFAULT、DigitCase.LINING、DigitCase.OLD_STYLE、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 DigitCase.DEFAULT。



實作
    public function get digitCase():*
    public function set digitCase(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

digitWidth

屬性 
digitWidth:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

用於此文字的數字寬度類型。這可以是 DigitWidth.PROPORTIONAL (對於個別數字的顯示效果最佳) 或 DigitWidth.TABULAR (最適用於表格、圖表及垂直行中的數字)。

digitWidth

有效值為 DigitWidth.DEFAULT、DigitWidth.PROPORTIONAL、DigitWidth.TABULAR、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 DigitWidth.DEFAULT。



實作
    public function get digitWidth():*
    public function set digitWidth(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

direction

屬性 
direction:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定文字區塊內之文字的預設雙向內嵌層級。由左向右的讀取順序,如同拉丁文樣式手寫體,或由右向左的讀取順序,如同阿拉伯文或希伯來文。在容器層級套用此屬性時,它也會影響欄方向。就像文字一樣,欄可以由左向右或由右向左。下面是一些範例:

direction

有效值為 Direction.LTR、Direction.RTL、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 Direction.LTR。



實作
    public function get direction():*
    public function set direction(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

dominantBaseline

屬性 
dominantBaseline:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定貼齊 alignmentBaseline 的元素基線,以決定行上元素的垂直位置。TextBaseline.AUTO 的值根據父段落的 locale 屬性選取主基線。針對日文與中文,選取的基線值為 TextBaseline.IDEOGRAPHIC_CENTER;其他則為 TextBaseline.ROMAN。這些基線的選擇是由字體及字體大小的選擇所決定。

baselines

有效值為 FormatValue.AUTO、TextBaseline.ROMAN、TextBaseline.ASCENT、TextBaseline.DESCENT、TextBaseline.IDEOGRAPHIC_TOP、TextBaseline.IDEOGRAPHIC_CENTER、TextBaseline.IDEOGRAPHIC_BOTTOM、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 FormatValue.AUTO。



實作
    public function get dominantBaseline():*
    public function set dominantBaseline(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

firstBaselineOffset

屬性 
firstBaselineOffset:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定容器中第一行的基線位置。此屬性參照的基線,是依據容器層級地區而定。對於日文和中文,它會是 TextBaseline.IDEOGRAPHIC_BOTTOM;而對於所有其他語言,則為 TextBaseline.ROMAN。從容器的上方內移距 (或如果 blockProgression 是 RL,則為右方內移距) 到首行基線的偏移量,可以是 BaselineOffset.ASCENT (相當於字行上緣)、BaselineOffset.LINE_HEIGHT (相當於首行高度),或任何固定值數字,以指定絕對距離。BaselineOffset.AUTO 對齊字行上緣與容器上方內移距。

firstBaselineOffset1firstBaselineOffset2firstBaselineOffset3firstBaselineOffset4

有效字串值為 BaselineOffset.AUTO、BaselineOffset.ASCENT、BaselineOffset.LINE_HEIGHT、FormatValue.INHERIT 以及從 0 到 1000 的數字。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 BaselineOffset.AUTO。



實作
    public function get firstBaselineOffset():*
    public function set firstBaselineOffset(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

fontFamily

屬性 
fontFamily:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

要使用的字體名稱,或是以逗號分隔的字體名稱清單。Flash 執行階段會以清單中的第一個可用字體來顯示元素。例如,Arial, Helvetica, _sans 會讓 Player 先搜尋 Arial,如果找不到 Arial 則搜尋 Helvetica,如果這兩項都找不到,則搜尋 _sans。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 Arial。



實作
    public function get fontFamily():*
    public function set fontFamily(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

fontLookup

屬性 
fontLookup:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

要使用的字體查詢。指定 FontLookup.DEVICE 使用執行 SWF 檔案之系統上所安裝的字體。裝置字體會導致影片大小變得較小,但文字在不同系統及平台間的顯示不盡相同。指定 FontLookup.EMBEDDED_CFF 使用內嵌於已發佈的 SWF 檔案的字體外框。內嵌的字體會增加 SWF 檔案的大小 (有時差距極大),但文字會一律以所選的字體顯示。

有效值為 FontLookup.DEVICE、FontLookup.EMBEDDED_CFF、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 FontLookup.DEVICE。



實作
    public function get fontLookup():*
    public function set fontLookup(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

fontSize

屬性 
fontSize:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

以像素為單位的文字大小。

有效值是從 1 到 720 的數字以及 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 12。



實作
    public function get fontSize():*
    public function set fontSize(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

fontStyle

屬性 
fontStyle:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

文字的樣式。可以是 FontPosture.NORMAL (用於純文字) 或 FontPosture.ITALIC (用於斜體字)。此屬性只套用到裝置字體 (fontLookup 屬性設定為 flash.text.engine.FontLookup.DEVICE)。

有效值是 FontPosture.NORMAL、FontPosture.ITALIC、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 FontPosture.NORMAL。



實作
    public function get fontStyle():*
    public function set fontStyle(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

fontWeight

屬性 
fontWeight:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

文字的粗細。可以是 FontWeight.NORMAL (用於純文字) 或 FontWeight.BOLD。只套用到裝置字體 (fontLookup 屬性設定為 flash.text.engine.FontLookup.DEVICE)。

有效值為 FontWeight.NORMAL、FontWeight.BOLD、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 FontWeight.NORMAL。



實作
    public function get fontWeight():*
    public function set fontWeight(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

justificationRule

屬性 
justificationRule:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

對齊段落中文字所使用的規則。預設值為 FormatValue.AUTO,可根據段落的 locale 屬性來對齊文字。除了日文與中文之外的所有語言,FormatValue.AUTO 會成為 JustificationRule.SPACE,可為空白字元增加額外的空間。針對日文與中文,FormatValue.AUTO 會成為 JustficationRule.EAST_ASIAN。對齊在某種程度上會變更標點符號的間距。在羅馬文字中,逗號與日文句號佔用完整的字元寬度,但是在東亞文字中,則只有一半的字元寬度。此外,在東亞文字中,連續標點符號之間的間距會變得較小,以遵循傳統東亞印刷慣例。請注意,下列範例中,行距會套用至段落的第二行。在東亞版本中,最後兩行向左推送。在羅馬版本中,第二行以及接續的字行向左推送。

justificationRule

有效值為 JustificationRule.EAST_ASIAN、JustificationRule.SPACE、FormatValue.AUTO、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 FormatValue.AUTO。



實作
    public function get justificationRule():*
    public function set justificationRule(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

justificationStyle

屬性 
justificationStyle:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

段落對齊所用的樣式。只能與 JustificationRule.EAST_ASIANjustificationRule 設定一起使用。FormatValue.AUTO 的預設值針對所有地區設定解析為 JustificationStyle.PUSH_IN_KINSOKU。JustificationStyle 類別定義的常數指定處理避頭尾字元 (不能在字行開頭或結尾出現的日文字元) 的選項。如果您要加寬文字,請指定 JustificationStyle.PUSH-OUT-ONLY。如果您想要讓行為的效果類似使用 JustificationRule.SPACEjustificationRule 的效果,請使用 JustificationStyle.PRIORITIZE-LEAST-ADJUSTMENT

有效值為 JustificationStyle.PRIORITIZE_LEAST_ADJUSTMENT、JustificationStyle.PUSH_IN_KINSOKU、JustificationStyle.PUSH_OUT_ONLY、FormatValue.AUTO、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 FormatValue.AUTO。



實作
    public function get justificationStyle():*
    public function set justificationStyle(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

kerning

屬性 
kerning:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

字距微調會調整某些字元組之間的像素,以改善可讀性。具有特殊字距表的所有字體都支援特殊字距。

有效值為 Kerning.ON、Kerning.OFF、Kerning.AUTO、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 Kerning.AUTO。



實作
    public function get kerning():*
    public function set kerning(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

leadingModel

屬性 
leadingModel:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定行距模型,它結合了行距基礎及行距方向。行距基礎是 lineHeight 屬性參照的基線。行矩方向決定 lineHeight 屬性參照的是某線條基線與其前線條之間的距離,或是與其後線條之間的距離。FormatValue.AUTO 的預設值乃是根據段落的 locale 屬性來解析。對於日文和中文,它會是 LeadingModel.IDEOGRAPHIC_TOP_DOWN,而對於所有其他語言,則是 LeadingModel.ROMAN_UP

行距基礎:

leadingBasis1 leadingBasis2 leadingBasis3

行距方向:

leadingDirection1 leadingDirection2 leadingDirection3

有效值為 LeadingModel.ROMAN_UP、LeadingModel.IDEOGRAPHIC_TOP_UP、LeadingModel.IDEOGRAPHIC_CENTER_UP、LeadingModel.IDEOGRAPHIC_TOP_DOWN、LeadingModel.IDEOGRAPHIC_CENTER_DOWN、LeadingModel.APPROXIMATE_TEXT_FIELD、LeadingModel.ASCENT_DESCENT_UP、LeadingModel.BOX、LeadingModel.AUTO、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 LeadingModel.AUTO。



實作
    public function get leadingModel():*
    public function set leadingModel(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

ligatureLevel

屬性 
ligatureLevel:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

控制字體中定義的哪些連字可用於文字。這些設定的每一個所顯示的連字與字體有相依性。當兩個以上的字母形式接合為單一字符時,會發生連字。連字通常會取代共享相同組件的連續字元,如字母組「fi」、「fl」或「ae」。連字可用於拉丁文和非拉丁文字元集。由於 LigatureLevel 類別的值 - MINIMUMCOMMONUNCOMMONEXOTIC 所啟用的連字具有累增效果。每個值啟用一組新的連字,但也包括先前類型。

注意:使用阿拉伯文或斯拉夫文字體時,ligatureLevel 必須設為 MINIMUM 或更大值。

ligatureLevel

有效值為 LigatureLevel.MINIMUM、LigatureLevel.COMMON、LigatureLevel.UNCOMMON、LigatureLevel.EXOTIC、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 LigatureLevel.COMMON。



實作
    public function get ligatureLevel():*
    public function set ligatureLevel(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

lineBreak

屬性 
lineBreak:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

控制容器內的文字換行 (如果重疊顯示時未定義,則採用預設值)。容器中的文字可設定為符合容器寬度 (LineBreak.TO_FIT),或者可設定為只在明確的歸位字元或換行字元 (LineBreak.EXPLICIT) 時斷行。

有效值是 LineBreak.EXPLICIT、LineBreak.TO_FIT、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義,則此屬性的值就會是 LineBreak.TO_FIT。



實作
    public function get lineBreak():*
    public function set lineBreak(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

lineHeight

屬性 
lineHeight:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

文字的行距控制。上一行或下一行基線 (根據 LeadingModel) 到目前字行基線的距離等於字行中任一字元所套用的最大行距。這可以是數字或百分比。如果指定百分比,請輸入字串值,如 140%。

lineHeight1lineHeight2

有效值是從 -720 到 720 之間的數字。

有效值是從 -1000% 到 1000% 之間數字的百分比。

有效值包括 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 120%。



實作
    public function get lineHeight():*
    public function set lineHeight(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

lineThrough

屬性 
lineThrough:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

若為 true,將套用刪除線,亦即通過文字中間的線。

有效值為 true、false 與 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 false。



實作
    public function get lineThrough():*
    public function set lineThrough(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

linkActiveFormat

屬性 
linkActiveFormat:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

定義正常狀態下的連結格式屬性。這個值會貫穿整個階層而且會套用至任何為後代的連結。接受 inheritITextLayoutFormat 或將具有索引鍵及值做為成員的物件陣列轉換為 TextLayoutFormat。

有效值包括 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 null。



實作
    public function get linkActiveFormat():*
    public function set linkActiveFormat(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內。

linkHoverFormat

屬性 
linkHoverFormat:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

當滑鼠在連結的邊緣之內 (或上方) 時,定義用於懸浮狀態下的連結格式屬性。這個值會貫穿整個階層而且會套用至任何為後代的連結。接受 inheritITextLayoutFormat 或將具有索引鍵及值做為成員的物件陣列轉換為 TextLayoutFormat。

有效值包括 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 null。



實作
    public function get linkHoverFormat():*
    public function set linkHoverFormat(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內。

linkNormalFormat

屬性 
linkNormalFormat:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

定義正常狀態下的連結格式屬性。這個值會貫穿整個階層而且會套用至任何為後代的連結。接受 inheritITextLayoutFormat 或將具有索引鍵及值做為成員的物件陣列轉換為 TextLayoutFormat。

有效值包括 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 null。



實作
    public function get linkNormalFormat():*
    public function set linkNormalFormat(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內。

listAutoPadding

屬性 
listAutoPadding:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

當該邊上的清單邊框距離值為 auto 時,指定清單的開頭邊緣自動縮排。

有效值是從 -1000 到 1000 的數字以及 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 40。



實作
    public function get listAutoPadding():*
    public function set listAutoPadding(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

listMarkerFormat

屬性 
listMarkerFormat:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

定義格式屬性清單標記。這個值會貫穿整個階層而且會套用至任何為後代的連結。接受 inheritIListMarkerFormat 或將具有索引鍵及值做為成員的物件陣列轉換為 ListMarkerFormat。

有效值包括 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 null。



實作
    public function get listMarkerFormat():*
    public function set listMarkerFormat(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內。

listStylePosition

屬性 
listStylePosition:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

有效值為 ListStylePosition.INSIDE、ListStylePosition.OUTSIDE、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 ListStylePosition.OUTSIDE。



實作
    public function get listStylePosition():*
    public function set listStylePosition(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

listStyleType

屬性 
listStyleType:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

有效值為 ListStyleType.UPPER_ALPHA、ListStyleType.LOWER_ALPHA、ListStyleType.UPPER_ROMAN、ListStyleType.LOWER_ROMAN、ListStyleType.NONE、ListStyleType.DISC、ListStyleType.CIRCLE、ListStyleType.SQUARE、ListStyleType.BOX、ListStyleType.CHECK、ListStyleType.DIAMOND、ListStyleType.HYPHEN、ListStyleType.ARABIC_INDIC、ListStyleType.BENGALI、ListStyleType.DECIMAL、ListStyleType.DECIMAL_LEADING_ZERO、ListStyleType.DEVANAGARI、ListStyleType.GUJARATI、ListStyleType.GURMUKHI、ListStyleType.KANNADA、ListStyleType.PERSIAN、ListStyleType.THAI、ListStyleType.URDU、ListStyleType.CJK_EARTHLY_BRANCH、ListStyleType.CJK_HEAVENLY_STEM、ListStyleType.HANGUL、ListStyleType.HANGUL_CONSTANT、ListStyleType.HIRAGANA、ListStyleType.HIRAGANA_IROHA、ListStyleType.KATAKANA、ListStyleType.KATAKANA_IROHA、ListStyleType.LOWER_ALPHA、ListStyleType.LOWER_GREEK、ListStyleType.LOWER_LATIN、ListStyleType.UPPER_ALPHA、ListStyleType.UPPER_GREEK、ListStyleType.UPPER_LATIN、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 ListStyleType.DISC。



實作
    public function get listStyleType():*
    public function set listStyleType(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

locale

屬性 
locale:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

文字的地區。控制大小寫轉換和形狀。使用 Unicode Technical Standard #35 中描述的標準地區識別名稱。例如 en、en_US 以及 en-US 都是英文,ja 則是日文。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 en。



實作
    public function get locale():*
    public function set locale(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

paddingBottom

屬性 
paddingBottom:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

下方內移距 (以像素為單位)。除了開端邊框距離為 45 的清單以外,auto 的預設值均為零 (如果重疊顯示時未定義,則採用預設值)。容器下方邊緣與文字之間的間距。值為 Number 或 auto。

使用水平文字時,在具有多欄的可捲動容器中,第一欄及接續各欄會在容器結尾以空格顯示邊框距離,但在最後一欄,如果文字無法完全填入,則必須捲動才能看到邊框距離。

有效字串值為 FormatValue.AUTO、FormatValue.INHERIT 以及從 -8000 到 8000 的數字。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義,則此屬性的值就會是 FormatValue.AUTO。



實作
    public function get paddingBottom():*
    public function set paddingBottom(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

paddingLeft

屬性 
paddingLeft:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

左方內移距 (以像素為單位)。除了開端邊框距離為 45 的清單以外,auto 的預設值均為零 (如果重疊顯示時未定義,則採用預設值)。容器左方邊緣與文字之間的間距。值為 Number 或 auto。

使用垂直文字時,在具有多欄的可捲動容器中,第一欄及接續各欄會在容器結尾以空格顯示邊框距離,但在最後一欄,如果文字無法完全填入,則必須捲動才能看到邊框距離。

有效字串值為 FormatValue.AUTO、FormatValue.INHERIT 以及從 -8000 到 8000 的數字。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義,則此屬性的值就會是 FormatValue.AUTO。



實作
    public function get paddingLeft():*
    public function set paddingLeft(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

paddingRight

屬性 
paddingRight:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

右方內移距 (以像素為單位)。除了開端邊框距離為 45 的清單以外,auto 的預設值均為零 (如果重疊顯示時未定義,則採用預設值)。容器右方邊緣與文字之間的間距。值為 Number 或 auto。

有效字串值為 FormatValue.AUTO、FormatValue.INHERIT 以及從 -8000 到 8000 的數字。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義,則此屬性的值就會是 FormatValue.AUTO。



實作
    public function get paddingRight():*
    public function set paddingRight(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

paddingTop

屬性 
paddingTop:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

上方內移距 (以像素為單位)。除了開端邊框距離為 45 的清單以外,auto 的預設值均為零 (如果重疊顯示時未定義,則採用預設值)。容器上方邊緣與文字之間的間距。值為 Number 或 auto。

有效字串值為 FormatValue.AUTO、FormatValue.INHERIT 以及從 -8000 到 8000 的數字。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義,則此屬性的值就會是 FormatValue.AUTO。



實作
    public function get paddingTop():*
    public function set paddingTop(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

paragraphEndIndent

屬性 
paragraphEndIndent:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定段落結尾邊緣縮排量的數字 (以像素為單位)。參考由左至右文字的右邊,與由右至左文字的左邊。

有效值是從 0 到 8000 的數字以及 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 0。



實作
    public function get paragraphEndIndent():*
    public function set paragraphEndIndent(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

paragraphSpaceAfter

屬性 
paragraphSpaceAfter:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定段落之後保留的間距大小的數字 (以像素為單位)。使用 paragraphSpaceBefore 在前後收合。

有效值是從 0 到 8000 的數字以及 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 0。



實作
    public function get paragraphSpaceAfter():*
    public function set paragraphSpaceAfter(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

paragraphSpaceBefore

屬性 
paragraphSpaceBefore:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定段落之前保留的間距大小的數字 (以像素為單位)。使用 paragraphSpaceAfter 在前後收合。

有效值是從 0 到 8000 的數字以及 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 0。



實作
    public function get paragraphSpaceBefore():*
    public function set paragraphSpaceBefore(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

paragraphStartIndent

屬性 
paragraphStartIndent:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定段落開頭邊緣縮排量的數字 (以像素為單位)。參考由左至右文字的左邊,與由右至左文字的右邊。

有效值是從 0 到 8000 的數字以及 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 0。



實作
    public function get paragraphStartIndent():*
    public function set paragraphStartIndent(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

renderingMode

屬性 
renderingMode:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

用於此文字的顯示模式。只套用到內嵌字體 (fontLookup 屬性設定為 FontLookup.EMBEDDED_CFF)。

有效值是 RenderingMode.NORMAL、RenderingMode.CFF、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 RenderingMode.CFF。



實作
    public function get renderingMode():*
    public function set renderingMode(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

styleName

屬性 
styleName:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定元素的識別類別,如此只要參照此 styleName 就可以設定元素的樣式。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義,則此屬性的值就會是 null。



實作
    public function get styleName():*
    public function set styleName(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內。

styles

屬性 
styles:Object  [唯讀]

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

傳回此 TextLayoutFormat 的 styles。注意:getter 會複製樣式字典。coreStyles 物件封裝格式屬性中設定的所有樣式,包括核心及使用者樣式。傳回的物件包含一個 stylename-value 組的陣列。



實作
    public function get styles():Object

相關 API 元素

tabStops

屬性 
tabStops:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定段落關聯的定位停駐點。Setter 可以使用 TabStopFormat 的陣列、壓縮字串表示法、未定義或 FormatValue.INHERIT。壓縮字串表示法一律轉換為 TabStopFormat 的陣列。

字串基礎格式是一份定位停駐點清單,其中使用一或多個空格分隔每個定位停駐點。

定位停駐點會採用下列格式:<alignment type><alignment position>|<alignment token>。

對齊類型是單一字元,可以是 S、E、C 或 D (或對等的小寫字母)。S 或 s 表示開頭 (start),E 或 e 表示結尾 (end),C 或 c 表示中間 (center),D 或 d 表示小數 (decimal)。對齊類型是選擇性項目,如果未指定,則預設為 S。

對齊位置是一個數字,並根據數字 (小數或科學標記法) 的 FXG 規格指定。需要有對齊位置。

垂直分隔列用於分隔對齊位置與對齊字符,並應只在對齊字符存在時才出現。

如果對齊類型是 D,則對齊字符為選擇性,而且如果對齊類型不是 D,就不應出現。對齊字符可以是由任何結束定位停駐點的空格所終止的字元順序 (對於最後一個定位停駐點而言,終止間距是選擇性的;對齊字符的結尾是隱含的)。如果使用反斜線 (\) 跳開,則空格可做為對齊字符的一部分。如果使用另一個反斜線 (\\) 跳開,則反斜線可做為對齊字符的一部分。如果對齊方式類型為 D,且未指定對齊字符,則會採用 null 預設值。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 null。



實作
    public function get tabStops():*
    public function set tabStops(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

textAlign

屬性 
textAlign:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

段落中各行相對於容器的對齊方式。TextAlign.LEFT 沿著容器左方邊緣對齊字行。TextAlign.RIGHT 對齊右方邊緣。TextAlign.CENTER 讓字行的左方及右方邊緣等距。TextAlign.JUSTIFY 會延展行以填滿空間。TextAlign.START 等同於設定由左向右文字的靠左對齊,或由右向左文字的靠右對齊。TextAlign.END 等同於設定由左向右文字的靠右對齊,或由右向左文字的靠左對齊。

有效值為 TextAlign.LEFT、TextAlign.RIGHT、TextAlign.CENTER、TextAlign.JUSTIFY、TextAlign.START、TextAlign.END、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 TextAlign.START。



實作
    public function get textAlign():*
    public function set textAlign(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

textAlignLast

屬性 
textAlignLast:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

段落中最後 (或唯一的) 一行相對於齊行文字中之容器的對齊方式。如果 textAlign 設定為 TextAlign.JUSTIFYtextAlignLast 會指定最後一行 (或唯一的一行,如果這是一個單行區塊時) 的對齊方式。值類似於 textAlign

有效值為 TextAlign.LEFT、TextAlign.RIGHT、TextAlign.CENTER、TextAlign.JUSTIFY、TextAlign.START、TextAlign.END、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 TextAlign.START。



實作
    public function get textAlignLast():*
    public function set textAlignLast(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

textAlpha

屬性 
textAlpha:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

文字的 Alpha (透明) 值。值為 0 時表示完全透明,值為 1 時表示完全不透明。textAlpha 設為 0 的顯示物件都是作用中狀態,即便看不見亦是如此。

有效值是從 0 到 1 的數字以及 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 1。



實作
    public function get textAlpha():*
    public function set textAlpha(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

textDecoration

屬性 
textDecoration:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

文字上的裝飾。用於套用底線;預設為 none。

有效值為 TextDecoration.NONE、TextDecoration.UNDERLINE、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 TextDecoration.NONE。



實作
    public function get textDecoration():*
    public function set textDecoration(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

textIndent

屬性 
textIndent:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

以像素為單位,指定段落中第一行縮排量的數字。負值縮排會將行推向邊界,因而可能超出容器。

有效值是從 -8000 到 8000 的數字以及 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 0。



實作
    public function get textIndent():*
    public function set textIndent(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

textJustify

屬性 
textJustify:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定對齊文字的選項。預設值為 TextJustify.INTER_WORD,表示將額外空間增加到空白字元。TextJustify.DISTRIBUTE 將額外空間增加到空白字元以及個別字母之間。僅與 JustificationRule.SPACEjustificationRule 值一併使用。

有效值為 TextJustify.INTER_WORD、TextJustify.DISTRIBUTE、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 TextJustify.INTER_WORD。



實作
    public function get textJustify():*
    public function set textJustify(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

textRotation

屬性 
textRotation:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

決定此文字要旋轉的度數。

有效值為 TextRotation.ROTATE_0、TextRotation.ROTATE_180、TextRotation.ROTATE_270、TextRotation.ROTATE_90、TextRotation.AUTO、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 TextRotation.AUTO。



實作
    public function get textRotation():*
    public function set textRotation(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

trackingLeft

屬性 
trackingLeft:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

以像素為單位代表要套用至每個字元左側字距調整 (手動字距微調) 量的數字 (或 fontSize 的百分比,例如,120%)。如果已啟用特殊字距,trackingLeft 值就會加入到該字體之特殊字距表中的值。如果已停用特殊字距,trackingLeft 值會當做手動特殊字距值來使用。同時支援正值與負值。

有效值是從 -1000 到 1000 之間的數字。

有效值是從 -1000% 到 1000% 之間數字的百分比。

有效值包括 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 0。



實作
    public function get trackingLeft():*
    public function set trackingLeft(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

trackingRight

屬性 
trackingRight:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

以像素為單位代表要套用至每個字元右側字距調整 (手動字距微調) 量的數字 (或 fontSize 的百分比,例如,120%)。如果已啟用特殊字距,trackingRight 值就會加入到該字體之特殊字距表中的值。如果已停用特殊字距,trackingRight 值會當做手動特殊字距值來使用。同時支援正值與負值。

有效值是從 -1000 到 1000 之間的數字。

有效值是從 -1000% 到 1000% 之間數字的百分比。

有效值包括 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 0。



實作
    public function get trackingRight():*
    public function set trackingRight(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

typographicCase

屬性 
typographicCase:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

用於此文字的印刷大小寫類型。下面是一些範例:

typographicCase

有效值是 TLFTypographicCase.DEFAULT、TLFTypographicCase.CAPS_TO_SMALL_CAPS、TLFTypographicCase.UPPERCASE、TLFTypographicCase.LOWERCASE、TLFTypographicCase.LOWERCASE_TO_SMALL_CAPS、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 TLFTypographicCase.DEFAULT。



實作
    public function get typographicCase():*
    public function set typographicCase(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

userStyles

屬性 
userStyles:Object  [唯讀]

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

傳回此 TextLayoutFormat 的 userStyles。userStyles 物件包含 TextLayoutFormat 所定義但不在 TextLayoutFormat.description 中的格式。傳回的 userStyles 物件包含一個 stylename-value 組的陣列。



實作
    public function get userStyles():Object

相關 API 元素

verticalAlign

屬性 
verticalAlign:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

垂直對齊或齊行 (如果重疊顯示時未定義,則採用預設值)。決定容器內 TextFlow 元素的對齊方式。

有效值是 VerticalAlign.TOP、VerticalAlign.MIDDLE、VerticalAlign.BOTTOM、VerticalAlign.JUSTIFY、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義,則此屬性的值就會是 VerticalAlign.TOP。



實作
    public function get verticalAlign():*
    public function set verticalAlign(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

whiteSpaceCollapse

屬性 
whiteSpaceCollapse:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

將文字匯入 TextFlow 時捨去或保留空格。WhiteSpaceCollapse.PRESERVE 保留所有空白字元。WhiteSpaceCollapse.COLLAPSE 移除匯入文字區塊內的換行、定位點以及開頭和結尾空白。斷行標籤 () 和 Unicode 字行分隔符號字元都將保留。

有效值為 WhiteSpaceCollapse.PRESERVE、WhiteSpaceCollapse.COLLAPSE、FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性將繼承祖系的值。如果沒有祖系設定此屬性,則值將為 WhiteSpaceCollapse.COLLAPSE。



實作
    public function get whiteSpaceCollapse():*
    public function set whiteSpaceCollapse(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內

相關 API 元素

wordSpacing

屬性 
wordSpacing:*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

指定對齊時要使用之文字間的最佳、最小和最大間距 (標準間距的倍數)。最佳間距可用來指定所需的間距大小,以作為字體中定義之值的分數。textJustify 為均分時會使用最小和最大值,以決定文字之間的間距寬窄,然後才使用字元間距來對齊行。

有效值是從 -1000% 到 1000% 之間數字的百分比。

有效值包括 FormatValue.INHERIT。

若未定義預設值,則表示未設定。

如果重疊顯示時未定義此屬性,則此屬性會繼承祖系的值。如果沒有祖系設定此屬性,則值將為 100%、50%、150%。



實作
    public function get wordSpacing():*
    public function set wordSpacing(value:any):void

擲回值
RangeError — 設定時值不在此屬性的範圍內
建構函式詳細資料

TextLayoutFormat

()建構函式
public function TextLayoutFormat(initialValues:flashx.textLayout.formats:ITextLayoutFormat = null)

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

建立新的 TextLayoutFormat 物件。所有設定為空白,或者可以選擇從提供的 initialValues 物件初始化。

參數
initialValues:flashx.textLayout.formats:ITextLayoutFormat (default = null) — 要複製其初始值的選擇性實體。

相關 API 元素

方法詳細資訊

apply

()方法
public function apply(incoming:flashx.textLayout.formats:ITextLayoutFormat):void

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

incoming ITextLayoutFormat 實體中設定的屬性值取代此 TextLayoutFormat 物件中屬性的值。incoming ITextLayoutFormat 實體中 undefined 的屬性並未在此物件中變更。

參數

incoming:flashx.textLayout.formats:ITextLayoutFormat — 此 TextLayoutFormat 物件套用其屬性值的實體。


範例  ( 如何使用本範例 )

此範例將一個 TextLayoutFormat 物件的設定套用到第二個物件 (textFormatLayout),並使用接收的物件將文字格式化。
package flashx.textLayout.formats.examples {
    import flash.display.Sprite;
    import flashx.textLayout.container.ContainerController;
    import flashx.textLayout.elements.ParagraphElement;
    import flashx.textLayout.elements.SpanElement;
    import flashx.textLayout.elements.TextFlow;
    import flashx.textLayout.formats.TextLayoutFormat;
    
    public class TextLayoutFormat_applyExample extends Sprite
    {
        public function TextLayoutFormat_applyExample()
        {
            // create a container and add it to the stage
            var container:Sprite = new Sprite();
            this.stage.addChild(container);
            // create TextFlow, ParagraphElement, and SpanElement objects
            var textFlow:TextFlow = new TextFlow();
            var p:ParagraphElement = new ParagraphElement();
            var span:SpanElement = new SpanElement();
            // create two TextLayoutFormat objects
            var textLayoutFormat:TextLayoutFormat = new TextLayoutFormat();
            var textLayoutFormat2:TextLayoutFormat = new TextLayoutFormat();
            // set format attributes in the first one
            textLayoutFormat.textIndent = 8;
            textLayoutFormat.color = 0x336633;
            textLayoutFormat.fontFamily = "Arial, Helvetica, _sans";
            textLayoutFormat.fontSize = 24;
            // set some of the same attributes on the second one
            textLayoutFormat2.color = 0x0000CC;
            textLayoutFormat2.fontSize = 12;
            textLayoutFormat2.textIndent = 24;
            // add text to the span, the span to the paragraph, and the paragraph to the text flow.
            span.text = "Notice that fontFamily is unchanged because it was undefined in textLayoutFormat2.";
            p.addChild( span);
            textFlow.addChild(p);
            // use apply() to apply textLayoutFormat2 format settings; assign format to the text flow
            textLayoutFormat.apply(textLayoutFormat2);  
            textFlow.hostFormat = textLayoutFormat;  
            // add paragraph to textFlow and update controller to display it
            textFlow.addChild(p);
            var controller:ContainerController = new ContainerController(container, 200, 200 );
            textFlow.flowComposer.addController(controller);
            textFlow.flowComposer.updateAllControllers();  
        }
    }
}

concat

()方法 
public function concat(incoming:flashx.textLayout.formats:ITextLayoutFormat):void

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

以此 TextLayoutFormat 物件的值連接 incoming ITextLayoutFormat 實體中的屬性值。在此 (接收) TextLayoutFormat 物件中,值為 FormatValue.INHERIT 的屬性,以及值為 undefined的繼承屬性,將從 incoming 物件取得新值。值為 undefined 的非繼承屬性將取得其預設值。所有其他屬性將維持不變。

參數

incoming:flashx.textLayout.formats:ITextLayoutFormat — 值開始連接的實體。

相關 API 元素


範例  ( 如何使用本範例 )

此範例將一個 TextLayoutFormat 物件中設定的值增加到第二個物件 (textFormatLayout) 中未定義之相對屬性的值,並使用接收的物件將文字格式化。
package flashx.textLayout.formats.examples {
    import flash.display.Sprite;
    import flashx.textLayout.container.ContainerController;
    import flashx.textLayout.elements.ParagraphElement;
    import flashx.textLayout.elements.SpanElement;
    import flashx.textLayout.elements.TextFlow;
    import flashx.textLayout.formats.TextLayoutFormat;
    
    public class TextLayoutFormat_concatExample extends Sprite
    {
        public function TextLayoutFormat_concatExample()
        {
            // create a container and add it to the stage
            var container:Sprite = new Sprite();
            this.stage.addChild(container);
            // create TextFlow, ParagraphElement, and SpanElement objects
            var textFlow:TextFlow = new TextFlow();
            var p:ParagraphElement = new ParagraphElement();
            var span:SpanElement = new SpanElement();
            // create two TextLayoutFormat objects
            var textLayoutFormat:TextLayoutFormat = new TextLayoutFormat();
            var textLayoutFormat2:TextLayoutFormat = new TextLayoutFormat();
            // set format attributes in the first one
            textLayoutFormat.textIndent = 8;
            textLayoutFormat.color = 0x336633;
            textLayoutFormat.fontSize = 18;
            // set some of the same attributes on the second one
            textLayoutFormat2.textIndent = 24;
            textLayoutFormat2.color = 0x0000CC;
            textLayoutFormat2.fontSize = 12;
            textLayoutFormat2.fontFamily = "Arial, Helvetica, _sans";
            // concat textLayoutFormat2 settings; assign format to the text flow
            textLayoutFormat.concat(textLayoutFormat2);    
            textFlow.hostFormat = textLayoutFormat; 
            // add text to the span, the span to the paragraph, and the paragraph to the text flow.
            span.text = "Notice that fontFamily value has been added from textLayout2 to textLayout but " +
                "the other values have not been changed.";     
            p.addChild( span);
            textFlow.addChild(p);
            // update controller to display it
            var controller:ContainerController = new ContainerController(container, 200, 200 );
            textFlow.flowComposer.addController(controller);
            textFlow.flowComposer.updateAllControllers(); 
        }
    }
}

concatInheritOnly

()方法 
public function concatInheritOnly(incoming:flashx.textLayout.formats:ITextLayoutFormat):void

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

以此 TextLayoutFormat 物件的值連接 incoming ITextLayoutFormat 實體中的屬性值。在此 (接收) TextLayoutFormat 物件中,值為 FormatValue.INHERIT 的屬性,以及值為 undefined的繼承屬性,將從 incoming 物件取得新值。所有其他屬性將維持不變。

參數

incoming:flashx.textLayout.formats:ITextLayoutFormat — 值開始連接的實體。

相關 API 元素


範例  ( 如何使用本範例 )

此範例將一個 TextLayoutFormat 物件中的值增加到第二個 TextLayoutFormat 物件中未定義之相對屬性的值,但僅適用於屬性可以繼承的狀況下。這個範例會使用自主接收 TextLayoutFormat 物件中的結果來設定文字的格式。
package flashx.textLayout.formats.examples {
    import flash.display.Sprite;
    import flashx.textLayout.container.ContainerController;
    import flashx.textLayout.elements.ParagraphElement;
    import flashx.textLayout.elements.SpanElement;
    import flashx.textLayout.elements.TextFlow;
    import flashx.textLayout.formats.TextLayoutFormat;
    
    public class TextLayoutFormat_concatInheritOnlyExample extends Sprite
    {
        public function TextLayoutFormat_concatInheritOnlyExample()
        {
            // create a container and add it to the stage
            var container:Sprite = new Sprite();
            this.stage.addChild(container);
            // create TextFlow, ParagraphElement, and SpanElement objects
            var textFlow:TextFlow = new TextFlow();
            var p:ParagraphElement = new ParagraphElement();
            var span:SpanElement = new SpanElement();
            // create two TextLayoutFormat objects
            var textLayoutFormat:TextLayoutFormat = new TextLayoutFormat();
            var textLayoutFormat2:TextLayoutFormat = new TextLayoutFormat();
            // set format attributes in the first one
            textLayoutFormat.color = 0xFF0000;
            textLayoutFormat.fontSize = undefined;            
            // set attributes on the second one (fontSize set here, too)
            textLayoutFormat2.color = 0x00FF00;
            textLayoutFormat2.backgroundColor = 0x00CCCC;
            textLayoutFormat2.fontSize = 16;
            textLayoutFormat2.fontFamily = "Times Roman";
            // concat textLayoutFormat2 settings; assign format to the text flow
            textLayoutFormat.concatInheritOnly(textLayoutFormat2);    
            textFlow.hostFormat = textLayoutFormat; 
            // add text to the span, the span to the paragraph, and the paragraph to the text flow.
            span.text = "Notice that the value of backgroundColor is "
            span.text += textLayoutFormat.backgroundColor;
            span.text += ", even though it is set in textLayoutFormat2. This is because " +
                "this property does not inherit. Also notice that font color does not change " +
                "because it is not undefined."
            p.addChild( span);
            textFlow.addChild(p);
            // update controller to display it
            var controller:ContainerController = new ContainerController(container, 200, 200 );
            textFlow.flowComposer.addController(controller);
            textFlow.flowComposer.updateAllControllers();  
        }
    }
}

copy

()方法 
public function copy(incoming:flashx.textLayout.formats:ITextLayoutFormat):void

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

從 ITextLayoutFormat 實體的 values 複製 TextLayoutFormat 設定到此 TextLayoutFormat 物件。如果 valuesnull,則此 TextLayoutFormat 物件的所有屬性會初始化為未定義值。

參數

incoming:flashx.textLayout.formats:ITextLayoutFormat — 要複製其值的選擇性實體。


範例  ( 如何使用本範例 )

這個範例會使用 copy(),將 TextLayoutFormat 物件中的預設格式設定置換成已設定部分格式屬性的 TextLayoutFormat 物件。
package flashx.textLayout.formats.examples {
    import flash.display.Sprite;
    import flashx.textLayout.container.ContainerController;
    import flashx.textLayout.elements.ParagraphElement;
    import flashx.textLayout.elements.SpanElement;
    import flashx.textLayout.elements.TextFlow;
    import flashx.textLayout.formats.TextLayoutFormat;
    
    public class TextLayoutFormat_copyExample extends Sprite
    {
        public function TextLayoutFormat_copyExample()
        {
            // create a container and add it to the stage
            var container:Sprite = new Sprite();
            this.stage.addChild(container);
            // create TextFlow, ParagraphElement, and SpanElement objects
            var textFlow:TextFlow = new TextFlow();
            var p:ParagraphElement = new ParagraphElement();
            var span:SpanElement = new SpanElement();
            // create two TextLayoutFormat objects
            var textLayoutFormat:TextLayoutFormat = new TextLayoutFormat();
            var textLayoutFormat2:TextLayoutFormat = new TextLayoutFormat();
            // set format attributes in the second one
            textLayoutFormat2.textIndent = 8;
            textLayoutFormat2.color = 0x336633;
            textLayoutFormat2.fontFamily = "Times Roman";
            textLayoutFormat2.fontSize = 18;
            // add text to the span, the span to the paragraph, and the paragraph to the text flow.
            span.text = "Notice that formatting values set in textLayoutFormat2 override " +
                "the default values in textLayoutFormat."; 
            p.addChild(span);
            textFlow.addChild(p);
            // copy format settings of textLayoutFormat2; assign format to the text flow
            textLayoutFormat.copy(textLayoutFormat2);
            textFlow.hostFormat = textLayoutFormat;  
            // add paragraph to textFlow and update controller to display it
            textFlow.addChild(p);
            var controller:ContainerController = new ContainerController(container, 200, 200 );
            textFlow.flowComposer.addController(controller);
            textFlow.flowComposer.updateAllControllers();      
        }
    }
}

createTextLayoutFormat

()方法 
public static function createTextLayoutFormat(initialValues:Object):flashx.textLayout.formats:TextLayoutFormat

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

建立新的 TextLayoutFormat 物件。所有設定為空白,或者可以選擇從提供的 initialValues 物件初始化。

參數

initialValues:Object — 如果複製 ITextLayoutFormat 物件的值,則為要複製其初始值的選擇性實體 ()。否則,此參數會被視為 Dictionary 或 Object 並重複執行。

傳回值
flashx.textLayout.formats:TextLayoutFormat

getStyle

()方法 
public function getStyle(styleProp:String):*

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

傳回由指定樣式名稱之 styleProp 參數所指定的樣式值。

參數

styleProp:String — 要擷取其值的樣式名稱。

傳回值
* — 指定樣式的值。類型則會視存取的樣式類型而不同。如果未設定樣式,則傳回 undefined

isEqual

()方法 
public static function isEqual(p1:flashx.textLayout.formats:ITextLayoutFormat, p2:flashx.textLayout.formats:ITextLayoutFormat):Boolean

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

比較 ITextLayoutFormat 實體 p1 中的屬性以及 ITextLayoutFormat 實體 p2 中的屬性,如果所有屬性相符,則傳回 true

參數

p1:flashx.textLayout.formats:ITextLayoutFormat — 與 p2 比較的實體。
 
p2:flashx.textLayout.formats:ITextLayoutFormat — 與 p1 比較的實體。

傳回值
Boolean — 如果所有屬性相符則為 true,否則為 false。

removeClashing

()方法 
public function removeClashing(incoming:flashx.textLayout.formats:ITextLayoutFormat):void

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

如果此 TextLayoutFormat 物件中的屬性與 incoming ITextLayoutFormat 實體中的屬性不相符,則將此 TextLayoutFormat 物件中的屬性設定為 undefined

參數

incoming:flashx.textLayout.formats:ITextLayoutFormat — 與此 TextLayoutFormat 物件的屬性值比較的實體。


範例  ( 如何使用本範例 )

此範例會呼叫 removeClashing(),從 textLayoutFormat2 移除任何與 textLayoutFormat 之格式化值不同的格式化值。它會將不同的值設定為 undefined,取消已套用的值。
package flashx.textLayout.formats.examples {
    import flash.display.Sprite;
    import flashx.textLayout.container.ContainerController;
    import flashx.textLayout.elements.ParagraphElement;
    import flashx.textLayout.elements.SpanElement;
    import flashx.textLayout.elements.TextFlow;
    import flashx.textLayout.formats.TextLayoutFormat;
    
    public class TextLayoutFormat_removeClashingExample extends Sprite
    {
        public function TextLayoutFormat_removeClashingExample()
        {
            // create a container and add it to the stage
            var container:Sprite = new Sprite();
            this.stage.addChild(container);
            // create TextFlow, ParagraphElement, and SpanElement objects
            var textFlow:TextFlow = new TextFlow();
            var p:ParagraphElement = new ParagraphElement();
            var span:SpanElement = new SpanElement();
            // create two TextLayoutFormat objects
            var textLayoutFormat:TextLayoutFormat = new TextLayoutFormat();
            var textLayoutFormat2:TextLayoutFormat = new TextLayoutFormat();
            // set format attributes for textLayoutFormat2
            textLayoutFormat.textIndent = 8;
            textLayoutFormat.color = 0x336633;
            textLayoutFormat.fontFamily = "Arial, Helvetica, _sans";
            textLayoutFormat.fontSize = 24;
            // set fontFamily to same value for textLayoutFormat2            
            textLayoutFormat2.fontFamily = "Arial, Helvetica, _sans";
            // add text to the span, the span to the paragraph, and the paragraph to the text flow.
            span.text = "Notice that fontFamily (Arial, Helvetica, _sans) is applied." 
            p.addChild( span);
            textFlow.addChild(p);    
            // call removeClashing(), cancelling any values that clash with textLayoutFormat; 
            // assign it to the text flow
            textLayoutFormat.removeClashing(textLayoutFormat2);  
            textFlow.hostFormat = textLayoutFormat;  
            // add paragraph to textFlow and update controller to display it
            textFlow.addChild(p);
            var controller:ContainerController = new ContainerController(container, 200, 200 );
            textFlow.flowComposer.addController(controller);
            textFlow.flowComposer.updateAllControllers();  
        }
    }
}

removeMatching

()方法 
public function removeMatching(incoming:flashx.textLayout.formats:ITextLayoutFormat):void

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

如果此 TextLayoutFormat 物件中的屬性與 incoming ITextLayoutFormat 實體中的屬性相符,則將此 TextLayoutFormat 物件中的屬性設定為 undefined

參數

incoming:flashx.textLayout.formats:ITextLayoutFormat — 與此 TextLayoutFormat 物件的屬性值比較的實體。


範例  ( 如何使用本範例 )

此範例會呼叫 removeMatching(),以便從 textLayoutFormat 移除任何與 textLayoutFormat2 之格式值相符的格式值。
package flashx.textLayout.formats.examples {
    import flash.display.Sprite;
    import flashx.textLayout.container.ContainerController;
    import flashx.textLayout.elements.ParagraphElement;
    import flashx.textLayout.elements.SpanElement;
    import flashx.textLayout.elements.TextFlow;
    import flashx.textLayout.formats.TextLayoutFormat;
    
    public class TextLayoutFormat_removeMatchingExample extends Sprite
    {
        public function TextLayoutFormat_removeMatchingExample()
        {
            // create a container and add it to the stage
            var container:Sprite = new Sprite();
            this.stage.addChild(container);
            // create TextFlow, ParagraphElement, and SpanElement objects
            var textFlow:TextFlow = new TextFlow();
            var p:ParagraphElement = new ParagraphElement();
            var span:SpanElement = new SpanElement();
            // create two TextLayoutFormat objects
            var textLayoutFormat:TextLayoutFormat = new TextLayoutFormat();
            var textLayoutFormat2:TextLayoutFormat = new TextLayoutFormat();
            // set format attributes for textLayoutFormat
            textLayoutFormat.textIndent = 8;
            textLayoutFormat.color = 0x336633;
            textLayoutFormat.fontFamily = "Arial, Helvetica, _sans";
            textLayoutFormat.fontSize = 24;
            // add text to the span, the span to the paragraph, and the paragraph to the text flow
            span.text = "Notice that fontFamily (Arial, Helvetica, _sans) is not applied." 
            p.addChild( span);
            textFlow.addChild(p);
            // set fontFamily to same value for textLayoutFormat2            
            textLayoutFormat2.fontFamily = "Arial, Helvetica, _sans";        
            // call removeMatching() to remove any values that match textLayoutFormat2; 
            // assign textLayoutFormat to the text flow
            textLayoutFormat.removeMatching(textLayoutFormat2);
            textFlow.hostFormat = textLayoutFormat;  
            // add paragraph to textFlow and update controller to display it
            textFlow.addChild(p);
            var controller:ContainerController = new ContainerController(container, 200, 200 );
            textFlow.flowComposer.addController(controller);
            textFlow.flowComposer.updateAllControllers();  
        }
    }
}

setStyle

()方法 
public function setStyle(styleProp:String, newValue:*):void

語言版本: ActionScript 3.0
執行階段版本: Flash Player 10, AIR 1.5

styleProp 參數所指定的樣式設為 newValue 參數所指定的值。

參數

styleProp:String — 要設定的樣式名稱。
 
newValue:* — 要設定樣式的目標值。

TextLayoutFormatExample.as

範例將段落格式設定為邊界 15 像素、首行縮排 20 像素,以及在 40 像素的向左對齊定位停駐點。它使用細明體字體 (使用替代的裝置字體)、將大小設定為 14 像素、顏色為綠色、開啟特殊字距,並將行距 (lineHeight) 設定為 140%。
package flashx.textLayout.formats.examples
{
    import flash.display.Sprite;
    import flashx.textLayout.container.ContainerController;
    import flashx.textLayout.elements.ParagraphElement;
    import flashx.textLayout.elements.SpanElement;
    import flashx.textLayout.elements.TextFlow;
    import flashx.textLayout.formats.TabStopFormat;
    import flashx.textLayout.formats.TextLayoutFormat;
    import flash.text.engine.TabAlignment;
    
    public class TextLayoutFormatExample extends Sprite
    {
        public function TextLayoutFormatExample()
        {
            var textFlow:TextFlow = new TextFlow();
            var textLayoutFormat:TextLayoutFormat = new TextLayoutFormat();
            textLayoutFormat.paragraphStartIndent = 15;
            textLayoutFormat.paragraphSpaceBefore = 15;
            textLayoutFormat.paragraphEndIndent = 15;
            textLayoutFormat.paragraphSpaceAfter = 15;
            textLayoutFormat.textIndent = 20;
            textLayoutFormat.color = 0x336633;
            textLayoutFormat.fontFamily = "Arial, Helvetica, _sans";
            textLayoutFormat.fontSize = 14;
            textLayoutFormat.kerning = flash.text.engine.Kerning.ON;
            textLayoutFormat.lineHeight = "140%";

            var tabStop1:TabStopFormat = new TabStopFormat();
            tabStop1.alignment = flash.text.engine.TabAlignment.START;
            tabStop1.position = 40;
            textLayoutFormat.tabStops = new Array(tabStop1);
            textFlow.hostFormat = textLayoutFormat;

            var p:ParagraphElement = new ParagraphElement();
            var span:SpanElement = new SpanElement();
            span.text = "This example formats a paragraph with 15 pixel margins, a 20 pixel first " +
                 "line indent, and a left-aligned tab stop at 40 pixels (last line). It uses the " +
                 "Arial font (with alternate device fonts), sets the size to 14 pixels, the color to green, " +
                 " turns on kerning, \n \t and sets leading (lineHeight) to 140%.";
            p.addChildAt(0, span);
            textFlow.addChildAt(0, p);

            textFlow.flowComposer.addController(new ContainerController(this,310,200));
            textFlow.flowComposer.updateAllControllers();
        }
    }
}
TextLayoutFormatExample2.as

這個範例會將 Unicode 中的日文字元字串轉換成文字方向以及設定 TextLayoutFormat 屬性,由右向左垂直顯示文字方向。
package flashx.textLayout.formats.examples
{
    import flash.display.Sprite;
    import flash.system.Capabilities;
    
    import flashx.textLayout.container.ContainerController;
    import flashx.textLayout.conversion.TextConverter;
    import flashx.textLayout.elements.TextFlow;
    import flashx.textLayout.formats.BlockProgression;
    import flashx.textLayout.formats.JustificationRule;
    import flashx.textLayout.formats.TextLayoutFormat;
    import flashx.textLayout.formats.VerticalAlign;
    
    public class TextLayoutFormatExample2 extends Sprite
    {
        public function TextLayoutFormatExample2()
        {
            // create TextFlow object
            var textFlow:TextFlow = new TextFlow();   
            // create TextLayoutFormat object
            var textLayoutFormat:TextLayoutFormat = new TextLayoutFormat();
            // define Japanese text in a string of Unicode characters
            var jaText:String = String.fromCharCode(
                0x30AF, 0x30ED, 0x30B9, 0x30D7, 0x30E9, 0x30C3, 0x30C8, 0x30D5, 
                0x30A9, 0x30FC, 0x30E0, 0x4E0A, 0x3067, 0x518D, 0x751F, 0x53EF, 
                0x80FD, 0x306A
            ) + 
            "Flash Video" +
            String.fromCharCode(
                0x3092, 0x914D, 0x4FE1, 0x3001, 0x653F, 0x5E9C, 0x6700, 0x65B0, 
                0x60C5, 0x5831, 0x3092, 0x3088, 0x308A, 0x591A, 0x304F, 0x306E, 
                0x56FD, 0x6C11, 0x306B, 0x9AD8, 0x54C1, 0x8CEA, 0x306A, 0x753B, 
                0x50CF, 0x3067, 0x7C21, 0x5358, 0x304B, 0x3064, 0x30EA, 0x30A2, 
                0x30EB, 0x30BF, 0x30A4, 0x30E0, 0x306B, 0x63D0, 0x4F9B, 0x3059, 
                0x308B, 0x3053, 0x3068, 0x304C, 0x53EF, 0x80FD, 0x306B, 0x306A, 
                0x308A, 0x307e, 0x3057, 0x305F, 0x3002);
            // convert the text into a TextFlow object
            textFlow = TextConverter.importToFlow(jaText, TextConverter.PLAIN_TEXT_FORMAT);
            // set the locale and fontFamily
            textLayoutFormat.locale = "ja";
            if (Capabilities.os.search("Mac OS") > -1) 
                textLayoutFormat.fontFamily = String.fromCharCode(0x5C0F, 0x585A, 0x660E, 0x671D) + " Pro R"; // "Kozuka Mincho Pro R"                    koFont.fontName = "Adobe " + String.fromCharCode(0xBA85, 0xC870) + " Std M"; // "Adobe Myungjo Std M"
            else 
                textLayoutFormat.fontFamily = "Kozuka Mincho Pro R";
            // specify right-to-left block progression, east Asian justification, and top vertical alignment
            textLayoutFormat.blockProgression = BlockProgression.RL;
            textLayoutFormat.justificationRule = JustificationRule.EAST_ASIAN;
            textLayoutFormat.verticalAlign = VerticalAlign.TOP;
            textFlow.hostFormat = textLayoutFormat;
            // add controller and update to display text
            textFlow.flowComposer.addController(new ContainerController(this, 300, 200));
            textFlow.flowComposer.updateAllControllers();
        }
    }
}




[ X ]為什麼顯示英文?
「ActionScript 3.0 參考」的內容是以英文顯示

並非所有「ActionScript 3.0 參考」的內容都翻譯為所有語言。當語言元素未翻譯時,就會以英文顯示。例如,ga.controls.HelpBox 類別並沒有翻譯為任何語言。因此在參考的繁體中文版本中,ga.controls.HelpBox 類別就會以英文顯示。