Skip to content

ITextStyle

Unofficial

Text style interface.

Import:

import type { ITextStyle } from '@obsidian-typings/obsidian-public-latest';

Signature:

export interface ITextStyle

Properties

PropertyTypeDescription
alignTextStyleAlignText alignment.
breakWordsbooleanWhether to break words.
dropShadowbooleanWhether to show a drop shadow.
dropShadowAlphanumberDrop shadow alpha.
dropShadowAnglenumberDrop shadow angle in radians.
dropShadowBlurnumberDrop shadow blur radius.
dropShadowColornumber | stringDrop shadow color.
dropShadowDistancenumberDrop shadow distance.
fillTextStyleFillFill style for the text.
fillGradientStopsnumber[]Fill gradient stops.
fillGradientTypeTEXT_GRADIENTFill gradient type.
fontFamilystring | string[]Font family.
fontSizenumber | stringFont size.
fontStyleTextStyleFontStyleFont style.
fontVariantTextStyleFontVariantFont variant.
fontWeightTextStyleFontWeightFont weight.
leadingnumberLeading between lines.
letterSpacingnumberLetter spacing.
lineHeightnumberLine height.
lineJoinTextStyleLineJoinLine join style.
miterLimitnumberMiter limit.
paddingnumberPadding around the text.
strokenumber | stringStroke color.
strokeThicknessnumberStroke thickness.
textBaselineTextStyleTextBaselineText baseline.
trimbooleanWhether to trim whitespace.
whiteSpaceTextStyleWhiteSpaceWhite space handling.
wordWrapbooleanWhether to word wrap.
wordWrapWidthnumberWord wrap width.