TextCharacterStyle

A character style.

Instance Properties

Name Description Access
appliedFont The font applied to the CharacterStyle, specified as either a font object or the name of font family. Can return: Font, String or NothingEnum enumerator. read-write
appliedLanguage The language of the text. Can return: LanguageWithVendors, Language or NothingEnum enumerator. Can also accept: String. read-write
basedOn The style that this style is based on. Can return: CharacterStyle or String. read-write
baselineShift The baseline shift applied to the text. Can return: Unit or NothingEnum enumerator. read-write
capitalization The capitalization scheme. Can return: Capitalization enumerator or NothingEnum enumerator. read-write
characterAlignment The alignment of small characters to the largest character in the line. Can return: CharacterAlignment enumerator or NothingEnum enumerator. read-write
characterDirection The direction of the character. Can return: CharacterDirectionOptions enumerator or NothingEnum enumerator. read-write
characterRotation The rotation angle (in degrees) of individual characters. Note: The rotation is counterclockwise. Can return: Real or NothingEnum enumerator. read-write
cjkGridTracking If true, uses grid tracking to track non-Roman characters in CJK grids. Can return: Boolean or NothingEnum enumerator. read-write
diacriticPosition Position of diacriticical characters. Can return: DiacriticPositionOptions enumerator or NothingEnum enumerator. read-write
digitsType The digits type. Can return: DigitsTypeOptions enumerator or NothingEnum enumerator. read-write
emitCss Emit CSS. Can return: Boolean or NothingEnum enumerator. read-write
endJoin The stroke join type applied to the characters of the text. Can return: OutlineJoin enumerator or NothingEnum enumerator. read-write
eventListeners EventListeners A collection of event listeners. read-only
events Events A collection of events. read-only
fillColor The swatch (color, gradient, tint, or mixed ink) applied to the fill of the CharacterStyle. . Can return: Swatch or NothingEnum enumerator. Can also accept: String. read-write
fillTint The tint (as a percentage) of the fill color of the CharacterStyle. (To specify a tint percentage, use a number in the range of 0 to 100; to use the inherited or overridden value, use -1.). Can return: Real or NothingEnum enumerator. read-write
fontStyle The name of the font style. Can return: String or NothingEnum enumerator. read-write
glyphForm The glyph variant to substitute for standard glyphs. Can return: AlternateGlyphForms enumerator or NothingEnum enumerator. read-write
gradientFillAngle The angle of a linear gradient applied to the fill of the text. (Range: -180 to 180). Can return: Real or NothingEnum enumerator. read-write
gradientFillLength The length (for a linear gradient) or radius (for a radial gradient) applied to the fill of the text. Can return: Real or NothingEnum enumerator. read-write
gradientFillStart The starting point (in page coordinates) of a gradient applied to the fill of the text, in the format [x, y]. Can return: Array of 2 Units or NothingEnum enumerator. read-write
gradientStrokeAngle The angle of a linear gradient applied to the stroke of the text. (Range: -180 to 180). Can return: Real or NothingEnum enumerator. read-write
gradientStrokeLength The length (for a linear gradient) or radius (for a radial gradient) applied to the stroke of the text. Can return: Real or NothingEnum enumerator. read-write
gradientStrokeStart The starting point (in page coordinates) of a gradient applied to the stroke of the text, in the format [x, y]. Can return: Array of 2 Units or NothingEnum enumerator. read-write
horizontalScale The horizontal scaling applied to the CharacterStyle. Can return: Real or NothingEnum enumerator. read-write
id number The unique ID of the CharacterStyle. read-only
imported If true, the style was imported from another document. Can return: Boolean or NothingEnum enumerator. read-only
includeClass If true, class attribute will be generated for the style. Can return: Boolean or NothingEnum enumerator. read-write
index number The index of the CharacterStyle within its containing object. read-only
isValid bool Returns true if the object specifier resolves to valid objects. read-only
jidori The number of grid squares in which to arrange the text. . Can return: Short Integer or NothingEnum enumerator. read-write
kashidas Use of Kashidas for justification. Can return: KashidasOptions enumerator or NothingEnum enumerator. read-write
kentenAlignment The alignment of kenten characters relative to the parent characters. . Can return: KentenAlignment enumerator or NothingEnum enumerator. read-write
kentenCharacterSet The character set used for the custom kenten character. Note: Valid only when kenten kind is custom. . Can return: KentenCharacterSet enumerator or NothingEnum enumerator. read-write
kentenCustomCharacter The character used for kenten. Note: Valid only when kenten kind is custom. Can return: String or NothingEnum enumerator. read-write
kentenFillColor The swatch (color, gradient, tint, or mixed ink) applied to the fill of kenten characters. Can return: Swatch, String or NothingEnum enumerator. read-write
kentenFont The font to use for kenten characters. Can return: Font, String or NothingEnum enumerator. read-write
kentenFontSize The size (in points) of kenten characters. Can return: Real or NothingEnum enumerator. read-write
kentenFontStyle The font style of kenten characters. Can return: String or NothingEnum enumerator. read-write
kentenKind The style of kenten characters. Can return: KentenCharacter enumerator or NothingEnum enumerator. read-write
kentenOverprintFill The method of overprinting the kenten fill. Can return: AdornmentOverprint enumerator or NothingEnum enumerator. read-write
kentenOverprintStroke The method of overprinting the kenten stroke. Can return: AdornmentOverprint enumerator or NothingEnum enumerator. read-write
kentenPlacement The distance between kenten characters and their parent characters. Can return: Real or NothingEnum enumerator. read-write
kentenPosition The kenten position relative to the parent character. Can return: RubyKentenPosition enumerator or NothingEnum enumerator. read-write
kentenStrokeColor The swatch (color, gradient, tint, or mixed ink) applied to the stroke of kenten characters. Can return: Swatch, String or NothingEnum enumerator. read-write
kentenStrokeTint The stroke tint (as a percentage) of kenten characters. (Range: 0 to 100). Can return: Real or NothingEnum enumerator. read-write
kentenTint The fill tint (as a percentage) of kenten characters. (Range: 0 to 100). Can return: Real or NothingEnum enumerator. read-write
kentenWeight The stroke weight (in points) of kenten characters. Can return: Real or NothingEnum enumerator. read-write
kentenXScale The horizontal size of kenten characters as a percent of the original size. Can return: Real or NothingEnum enumerator. read-write
kentenYScale The vertical size of kenten charachers as a percent of the original size. . Can return: Real or NothingEnum enumerator. read-write
kerningMethod The type of pair kerning. Can return: String or NothingEnum enumerator. read-write
keyboardDirection The keyboard direction of the character. Can return: CharacterDirectionOptions enumerator or NothingEnum enumerator. read-write
label string A property that can be set to any string. read-write
leading The leading applied to the text. Can return: Unit, Leading enumerator or NothingEnum enumerator. read-write
leadingAki The amount of space before each character. Can return: Real or NothingEnum enumerator. read-write
ligatures If true, replaces specific character combinations (e.g., fl, fi) with ligature characters. Can return: Boolean or NothingEnum enumerator. read-write
miterLimit = 4 The limit of the ratio of stroke width to miter length before a miter (pointed) join becomes a bevel (squared-off) join. Can return: Real (0 - 1000) or NothingEnum enumerator. read-write
name string The name of the style. read-write
noBreak If true, keeps the text on the same line. . Can return: Boolean or NothingEnum enumerator. read-write
otfContextualAlternate If true, uses contextual alternate forms in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfDiscretionaryLigature If true, uses discretionary ligatures in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfFigureStyle The figure style in OpenType fonts. Can return: OTFFigureStyle enumerator or NothingEnum enumerator. read-write
otfFraction If true, uses fractions in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfHVKana If true, switches hiragana fonts, which have different glyphs for horizontal and vertical. . Can return: Boolean or NothingEnum enumerator. read-write
otfHistorical If true, use historical forms in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfJustificationAlternate If true, use alternate justification forms in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfLocale If true, uses localized forms in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfMark If true, uses mark positioning in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfOrdinal If true, uses ordinals in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfOverlapSwash If true, use overlapping swash forms in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfProportionalMetrics If true, kerns according to proportional CJK metrics in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfRomanItalics If true, applies italics to half-width alphanumerics. . Can return: Boolean or NothingEnum enumerator. read-write
otfSlashedZero If true, use a slashed zeroes in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfStretchedAlternate If true, use stretched alternate forms in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfStylisticAlternate If true, use stylistic alternate forms in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfStylisticSets The stylistic sets to use in OpenType fonts. Can return: Long Integer or NothingEnum enumerator. read-write
otfSwash If true, uses swash forms in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
otfTitling If true, uses titling forms in OpenType fonts. Can return: Boolean or NothingEnum enumerator. read-write
overprintFill If true, the fill color of the characters will overprint. Can return: Boolean or NothingEnum enumerator. read-write
overprintStroke If true, the stroke of the characters will overprint. Can return: Boolean or NothingEnum enumerator. read-write
parent The parent of the CharacterStyle (a Document, Application or CharacterStyleGroup). read-only
pointSize The text size. Can return: Unit or NothingEnum enumerator. read-write
position The text position relative to the baseline. Can return: Position enumerator or NothingEnum enumerator. read-write
positionalForm The OpenType positional form. Can return: PositionalForms enumerator or NothingEnum enumerator. read-write
previewColor The color to use for preview, specified either as an array of three doubles, each in the range 0 to 255 and representing R, G, and B values, or as a UI color. Can return: Array of 3 Reals (0 - 255) or UIColors enumerator or NothingEnum enumerator. read-write
properties Object A property that allows setting of several properties at the same time. read-write
rubyAlignment The ruby alignment. Can return: RubyAlignments enumerator or NothingEnum enumerator. read-write
rubyAutoAlign If true, auto aligns ruby. Can return: Boolean or NothingEnum enumerator. read-write
rubyAutoScaling If true, automatically scales ruby to the specified percent of parent text size. For information on specifying a percent, see ruby parent scaling percent. . Can return: Boolean or NothingEnum enumerator. read-write
rubyAutoTcyAutoScale If true, automatically scales glyphs in auto tcy (tate-chuu-yoko) in ruby to fit one em. Can return: Boolean or NothingEnum enumerator. read-write
rubyAutoTcyDigits The number of digits included in auto tcy (tate-chuu-yoko) in ruby. Can return: Short Integer or NothingEnum enumerator. read-write
rubyAutoTcyIncludeRoman If true, includes Roman characters in auto tcy (tate-chuu-yoko) in ruby. Can return: Boolean or NothingEnum enumerator. read-write
rubyFill The swatch (color, gradient, tint, or mixed ink) applied to the fill of ruby characters. Can return: Swatch, String or NothingEnum enumerator. read-write
rubyFont The font applied to ruby characters. Can return: Font, String or NothingEnum enumerator. read-write
rubyFontSize The size (in points) of ruby characters. Can return: Real or NothingEnum enumerator. read-write
rubyFontStyle The font style of ruby characters. Can return: String or NothingEnum enumerator. read-write
rubyOpenTypePro If true, uses OpenType Pro fonts for ruby. Can return: Boolean or NothingEnum enumerator. read-write
rubyOverhang If true, constrains ruby overhang to the specified amount. For information on specifying an amount, see ruby parent overhang amount. . Can return: Boolean or NothingEnum enumerator. read-write
rubyOverprintFill The method of overprinting the ruby fill. Can return: AdornmentOverprint enumerator or NothingEnum enumerator. read-write
rubyOverprintStroke The method of overprinting the ruby stroke. Can return: AdornmentOverprint enumerator or NothingEnum enumerator. read-write
rubyParentOverhangAmount The amount by which ruby characters can overhang the parent text. Can return: RubyOverhang enumerator or NothingEnum enumerator. read-write
rubyParentScalingPercent The amount (as a percentage) to scale the parent text size to determine the ruby text size. Can return: Real or NothingEnum enumerator. read-write
rubyParentSpacing The ruby spacing relative to the parent text. . Can return: RubyParentSpacing enumerator or NothingEnum enumerator. read-write
rubyPosition The position of ruby characters relative to the parent text. Can return: RubyKentenPosition enumerator or NothingEnum enumerator. read-write
rubyStroke The swatch (color, gradient, tint, or mixed ink) applied to the stroke of ruby characters. Can return: Swatch, String or NothingEnum enumerator. read-write
rubyStrokeTint The stroke tint (as a percentage) of ruby characters. Can return: Real or NothingEnum enumerator. read-write
rubyTint The tint (as a percentage) of the ruby fill color. (Range: 0 to 100). Can return: Real or NothingEnum enumerator. read-write
rubyType The ruby type. Can return: RubyTypes enumerator or NothingEnum enumerator. read-write
rubyWeight The stroke weight (in points) of ruby characters. Can return: Real or NothingEnum enumerator. read-write
rubyXOffset The amount of horizontal space between ruby and parent characters. Can return: Real or NothingEnum enumerator. read-write
rubyXScale The horizontal size of ruby characters, specified as a percent of the original size. Can return: Real or NothingEnum enumerator. read-write
rubyYOffset The amount of vertical space between ruby and parent characters. Can return: Real or NothingEnum enumerator. read-write
rubyYScale The vertical size of ruby characters, specified as a percent of the original size. Can return: Real or NothingEnum enumerator. read-write
scaleAffectsLineHeight If true, the line changes size when characters are scaled. . Can return: Boolean or NothingEnum enumerator. read-write
shataiAdjustRotation If true, applies shatai rotation. Can return: Boolean or NothingEnum enumerator. read-write
shataiAdjustTsume If true, adjusts shatai tsume. Can return: Boolean or NothingEnum enumerator. read-write
shataiDegreeAngle The shatai lens angle (in degrees). Can return: Real or NothingEnum enumerator. read-write
shataiMagnification The amount (as a percentage) of shatai obliquing to apply. Can return: Real or NothingEnum enumerator. read-write
skew The skew angle of the CharacterStyle. Can return: Real or NothingEnum enumerator. read-write
splitDocument Split Document (EPUB only). Can return: Boolean or NothingEnum enumerator. read-write
strikeThroughColor The swatch (color, gradient, tint, or mixed ink) applied to the strikethrough stroke. Can return: Swatch, String or NothingEnum enumerator. read-write
strikeThroughGapColor The swatch (color, gradient, tint, or mixed ink) applied to the gap of the strikethrough stroke. Can return: Swatch, String or NothingEnum enumerator. read-write
strikeThroughGapOverprint If true, the gap color of the strikethrough stroke will overprint. Note: Valid when strike through type is not solid. Can return: Boolean or NothingEnum enumerator. read-write
strikeThroughGapTint The tint (as a percentage) of the strikethrough stroke gap color. (Range: 0 to 100) Note: Valid when strike through type is not solid. Can return: Real or NothingEnum enumerator. read-write
strikeThroughOffset The amount by which to offset the strikethrough stroke from the text baseline. Can return: Unit or NothingEnum enumerator. read-write
strikeThroughOverprint If true, the strikethrough stroke will overprint. Can return: Boolean or NothingEnum enumerator. read-write
strikeThroughTint The tint (as a percentage) of the strikethrough stroke. (Range: 0 to 100). Can return: Real or NothingEnum enumerator. read-write
strikeThroughType The stroke type of the strikethrough stroke. Can return: StrokeStyle, String or NothingEnum enumerator. read-write
strikeThroughWeight The stroke weight of the strikethrough stroke. Can return: Unit or NothingEnum enumerator. read-write
strikeThru If true, draws a strikethrough line through the text. Can return: Boolean or NothingEnum enumerator. read-write
strokeAlignment The stroke alignment applied to the text. Can return: TextStrokeAlign enumerator or NothingEnum enumerator. read-write
strokeColor The swatch (color, gradient, tint, or mixed ink) applied to the stroke of the CharacterStyle. Can return: Swatch or NothingEnum enumerator. Can also accept: String. read-write
strokeTint The tint (as a percentage) of the stroke color of the CharacterStyle. (To specify a tint percentage, use a number in the range of 0 to 100; to use the inherited or overridden value, use -1.). Can return: Real or NothingEnum enumerator. read-write
strokeWeight The stroke weight applied to the characters of the text. Can return: Unit or NothingEnum enumerator. read-write
styleExportTagMaps StyleExportTagMaps A collection of style export tag maps. read-only
styleUniqueId A unique id that can be assigned to a style. This can be used to differentiate between the styles. Internal use only. Can return: String or NothingEnum enumerator. read-write
tatechuyoko If true, makes the character horizontal in vertical text. Can return: Boolean or NothingEnum enumerator. read-write
tatechuyokoXOffset The horizontal offset for horizontal characters in vertical text. Can return: Real or NothingEnum enumerator. read-write
tatechuyokoYOffset The vertical offset for horizontal characters in vertical text. Can return: Real or NothingEnum enumerator. read-write
tracking The amount by which to loosen or tighten a block of text, specified in thousands of an em. Can return: Real or NothingEnum enumerator. read-write
trailingAki The amount of space after each character. Can return: Real or NothingEnum enumerator. read-write
tsume The amount of horizontal character compression. Can return: Real or NothingEnum enumerator. read-write
underline If true, underlines the text. Can return: Boolean or NothingEnum enumerator. read-write
underlineColor The swatch (color, gradient, tint, or mixed ink) applied to the underline stroke. . Can return: Swatch, String or NothingEnum enumerator. read-write
underlineGapColor The swatch (color, gradient, tint, or mixed ink) applied to the gap of the underline stroke. Note: Valid when underline type is not solid. Can return: Swatch, String or NothingEnum enumerator. read-write
underlineGapOverprint If true, the gap color of the underline stroke will overprint. Can return: Boolean or NothingEnum enumerator. read-write
underlineGapTint The tint (as a percentage) of the gap color of the underline stroke. (Range: 0 to 100) Note: Valid when underline type is not solid. Can return: Real or NothingEnum enumerator. read-write
underlineOffset The amount by which to offset the underline from the text baseline. Can return: Unit or NothingEnum enumerator. read-write
underlineOverprint If true, the underline stroke color will overprint. Can return: Boolean or NothingEnum enumerator. read-write
underlineTint The underline stroke tint (as a percentage). (Range: 0 to 100). Can return: Real or NothingEnum enumerator. read-write
underlineType The stroke type of the underline stroke. Can return: StrokeStyle, String or NothingEnum enumerator. read-write
underlineWeight The stroke weight of the underline stroke. Can return: Unit or NothingEnum enumerator. read-write
verticalScale The vertical scaling applied to the CharacterStyle. Can return: Real or NothingEnum enumerator. read-write
warichu If true, turns on warichu. Can return: Boolean or NothingEnum enumerator. read-write
warichuAlignment The warichu alignment. Can return: WarichuAlignment enumerator or NothingEnum enumerator. read-write
warichuCharsAfterBreak The minimum number of characters allowed after a line break. . Can return: Short Integer or NothingEnum enumerator. read-write
warichuCharsBeforeBreak The minimum number of characters allowed before a line break. Can return: Short Integer or NothingEnum enumerator. read-write
warichuLineSpacing The gap between lines of warichu characters. Can return: Real or NothingEnum enumerator. read-write
warichuLines The number of lines of warichu within a single normal line. Can return: Short Integer or NothingEnum enumerator. read-write
warichuSize The amount (as a percentage) to scale parent text size to determine warichu size. Can return: Real or NothingEnum enumerator. read-write
xOffsetDiacritic The x (horizontal) offset for diacritic adjustment. Can return: Real or NothingEnum enumerator. read-write
yOffsetDiacritic The y (vertical) offset for diacritic adjustment. Can return: Real or NothingEnum enumerator. read-write

Methods

addEventListener(
eventType, handler ​[, captures])
 → EventListener
createThumbnailWithProperties(
previewText, pointSize, space, colorValue, to)
 → bool
extractLabel(
key)
 → string
insertLabel(
key, value)
move(
to, reference)
 → CharacterStyle
remove(
[replacingWith])
removeEventListener(
eventType, handler ​[, captures])
 → bool
toSource(
)
 → string
toSpecifier(
)
 → string
addEventListener(
eventType, handler ​[, captures=false])
 → EventListener
Adds an event listener.
eventType string The event type.
handler The event handler. Can accept: File or JavaScript Function.
captures bool This parameter is obsolete. (Optional)
createThumbnailWithProperties(
previewText, pointSize, space, colorValue, to)
 → bool
Create thumbnail for selected text with the given properties.
previewText string Text to use as sample
pointSize number Text font size (in points)
space ColorSpace Color space RGB, CMYK or LAB
colorValue Array<number> Color values
to File The path to the export file.
duplicate(
)
 → CharacterStyle
Duplicates the CharacterStyle.
extractLabel(
key)
 → string
Gets the label value associated with the specified key.
key string The key.
getElements(
)
 → CharacterStyle
Resolves the object specifier, creating an array of object references.
insertLabel(
key, value)
Sets the label to the value associated with the specified key.
key string The key.
value string The value.
move(
to, reference)
 → CharacterStyle
Moves the style to the specified location.
to LocationOptions The location relative to the reference object or within the containing object.
reference The reference object. Note: Required when the to parameter specifies before or after. Can accept: ParagraphStyle, ParagraphStyleGroup, CharacterStyle, CharacterStyleGroup, CellStyle, CellStyleGroup, TableStyle, TableStyleGroup, Document or Application. (Optional)
remove(
[replacingWith])
Deletes the style.
replacingWith CharacterStyle The style to apply in place of the deleted style. (Optional)
removeEventListener(
eventType, handler ​[, captures=false])
 → bool
Removes the event listener.
eventType string The registered event type.
handler The registered event handler. Can accept: File or JavaScript Function.
captures bool This parameter is obsolete. (Optional)
toSource(
)
 → string
Generates a string which, if executed, will return the CharacterStyle.
toSpecifier(
)
 → string
Retrieves the object specifier.