class
Opal::UI::Text
- Opal::UI::Text
- Opal::UI::Element
- Reference
- Object
Overview
Renders styled text with optional wrapping or clipping.
Defined in:
opal/ui/components/text.crConstructors
Instance Method Summary
- #bg : Color
- #bg=(bg : Color)
- #bold=(bold : Bool)
- #bold? : Bool
- #content : String
- #content=(content : String)
- #dim=(dim : Bool)
- #dim? : Bool
- #fg : Color
- #fg=(fg : Color)
- #italic=(italic : Bool)
- #italic? : Bool
- #preferred_size(available_w : Int32, available_h : Int32) : Tuple(Int32, Int32)
- #render(buffer : Buffer, x : Int32, y : Int32, width : Int32, height : Int32) : Nil
- #underline=(underline : Bool)
- #underline? : Bool
- #wrap=(wrap : Bool)
- #wrap? : Bool
Instance methods inherited from class Opal::UI::Element
preferred_size(available_w : Int32, available_h : Int32) : Tuple(Int32, Int32)
preferred_size,
render(buffer : Buffer, x : Int32, y : Int32, width : Int32, height : Int32) : Nil
render
Constructor Detail
def self.new(content : String, fg : Color | Symbol | String = Color.none, bg : Color | Symbol | String = Color.none, bold : Bool = false, dim : Bool = false, italic : Bool = false, underline : Bool = false, wrap : Bool = false)
#