@gtkx/react / TextTagProps
Type Alias: TextTagProps
TextTagProps =
object
Defined in: packages/react/src/jsx.ts:197
Props for the TextTag virtual element.
Used to declaratively define and apply text formatting to content within a TextBuffer.
Example
<GtkTextView>
<x.TextBuffer>
Hello <x.TextTag id="bold" weight={Pango.Weight.BOLD}>bold</x.TextTag> world
</x.TextBuffer>
</GtkTextView>Properties
accumulativeMargin?
optionalaccumulativeMargin?:boolean
Defined in: packages/react/src/jsx.ts:267
Whether margins accumulate
allowBreaks?
optionalallowBreaks?:boolean
Defined in: packages/react/src/jsx.ts:261
Whether breaks are allowed
background?
optionalbackground?:string
Defined in: packages/react/src/jsx.ts:203
Background color as a string (e.g., "red", "#ff0000")
backgroundFullHeight?
optionalbackgroundFullHeight?:boolean
Defined in: packages/react/src/jsx.ts:205
Whether the background fills the entire line height
children?
optionalchildren?:ReactNode
Defined in: packages/react/src/jsx.ts:279
Text content and nested TextTag children
direction?
optionaldirection?:Gtk.TextDirection
Defined in: packages/react/src/jsx.ts:253
Text direction
editable?
optionaleditable?:boolean
Defined in: packages/react/src/jsx.ts:257
Whether the text can be modified
fallback?
optionalfallback?:boolean
Defined in: packages/react/src/jsx.ts:265
Whether font fallback is enabled
family?
optionalfamily?:string
Defined in: packages/react/src/jsx.ts:209
Font family name (e.g., "Sans", "Monospace")
font?
optionalfont?:string
Defined in: packages/react/src/jsx.ts:211
Font description string (e.g., "Sans Italic 12")
fontFeatures?
optionalfontFeatures?:string
Defined in: packages/react/src/jsx.ts:275
OpenType font features as a string
foreground?
optionalforeground?:string
Defined in: packages/react/src/jsx.ts:207
Foreground (text) color as a string
id
id:
string
Defined in: packages/react/src/jsx.ts:199
Unique identifier for this tag in the tag table
indent?
optionalindent?:number
Defined in: packages/react/src/jsx.ts:243
Paragraph indent in pixels (negative = hanging)
insertHyphens?
optionalinsertHyphens?:boolean
Defined in: packages/react/src/jsx.ts:263
Whether to insert hyphens at breaks
invisible?
optionalinvisible?:boolean
Defined in: packages/react/src/jsx.ts:259
Whether the text is invisible/hidden
justification?
optionaljustification?:Gtk.Justification
Defined in: packages/react/src/jsx.ts:251
Text justification
language?
optionallanguage?:string
Defined in: packages/react/src/jsx.ts:277
Language code (e.g., "en-US")
leftMargin?
optionalleftMargin?:number
Defined in: packages/react/src/jsx.ts:239
Left margin in pixels
letterSpacing?
optionalletterSpacing?:number
Defined in: packages/react/src/jsx.ts:235
Extra spacing between characters in Pango units
lineHeight?
optionallineHeight?:number
Defined in: packages/react/src/jsx.ts:237
Factor to scale line height by
overline?
optionaloverline?:Pango.Overline
Defined in: packages/react/src/jsx.ts:231
Overline style (use Pango.Overline constants)
paragraphBackground?
optionalparagraphBackground?:string
Defined in: packages/react/src/jsx.ts:269
Paragraph background color as a string
pixelsAboveLines?
optionalpixelsAboveLines?:number
Defined in: packages/react/src/jsx.ts:245
Pixels of blank space above paragraphs
pixelsBelowLines?
optionalpixelsBelowLines?:number
Defined in: packages/react/src/jsx.ts:247
Pixels of blank space below paragraphs
pixelsInsideWrap?
optionalpixelsInsideWrap?:number
Defined in: packages/react/src/jsx.ts:249
Pixels of blank space between wrapped lines
priority?
optionalpriority?:number
Defined in: packages/react/src/jsx.ts:201
Priority of this tag (higher wins when multiple tags affect same property)
rightMargin?
optionalrightMargin?:number
Defined in: packages/react/src/jsx.ts:241
Right margin in pixels
rise?
optionalrise?:number
Defined in: packages/react/src/jsx.ts:233
Offset of text above baseline in Pango units (negative = below)
scale?
optionalscale?:number
Defined in: packages/react/src/jsx.ts:217
Font size scale factor relative to default
showSpaces?
optionalshowSpaces?:Pango.ShowFlags
Defined in: packages/react/src/jsx.ts:271
How to render invisible characters
size?
optionalsize?:number
Defined in: packages/react/src/jsx.ts:215
Font size in Pango units
sizePoints?
optionalsizePoints?:number
Defined in: packages/react/src/jsx.ts:213
Font size in points
stretch?
optionalstretch?:Pango.Stretch
Defined in: packages/react/src/jsx.ts:223
Font stretch (use Pango.Stretch constants)
strikethrough?
optionalstrikethrough?:boolean
Defined in: packages/react/src/jsx.ts:227
Whether to strike through the text
style?
optionalstyle?:Pango.Style
Defined in: packages/react/src/jsx.ts:221
Font style (use Pango.Style constants)
textTransform?
optionaltextTransform?:Pango.TextTransform
Defined in: packages/react/src/jsx.ts:273
How to transform text for display
underline?
optionalunderline?:Pango.Underline
Defined in: packages/react/src/jsx.ts:229
Underline style (use Pango.Underline constants)
variant?
optionalvariant?:Pango.Variant
Defined in: packages/react/src/jsx.ts:225
Font variant (use Pango.Variant constants)
weight?
optionalweight?:Pango.Weight|number
Defined in: packages/react/src/jsx.ts:219
Font weight (use Pango.Weight constants)
wrapMode?
optionalwrapMode?:Gtk.WrapMode
Defined in: packages/react/src/jsx.ts:255
Wrap mode for line breaks