class

UIng::Area::Attribute

Inherits UIng::BlockConstructor < Reference < Object

Attribute represents text styling properties for AttributedString.

IMPORTANT: Ownership rules

  • When passed to AttributedString#set_attribute, ownership transfers to libui.
  • After ownership transfer, the Attribute MUST NOT be reused or freed manually.
  • Each set_attribute call requires a NEW Attribute instance.

Constructors

new(*args, &)
Source
new(*args, **kwargs, &)
Source
new(ref_ptr : Pointer(LibUI::Attribute))
Source
new_background(r : Float64, g : Float64, b : Float64, a : Float64) : Attribute
Source
new_color(r : Float64, g : Float64, b : Float64, a : Float64) : Attribute
Source
new_family(family : String) : Attribute
Source
new_features(open_type_features : OpenTypeFeatures) : Attribute
Source
new_italic(italic : TextItalic) : Attribute
Source
new_size(size : Float64) : Attribute
Source
new_stretch(stretch : TextStretch) : Attribute
Source
new_underline(underline : Underline) : Attribute
Source
new_underline_color(underline_color : UnderlineColor, r : Float64, g : Float64, b : Float64, a : Float64) : Attribute
Source
new_weight(weight : TextWeight) : Attribute
Source

Instance methods

color
Source
family
Source
features
Source
finalize
Source
free
Source
italic
Source
released=(released : Bool)
Source
released?
Source
size
Source
stretch
Source
to_unsafe
Source
type
Source
underline
Source
underline_color
Source
weight
Source

Nested types