class

Opal::UI::LoadingIndicator

Inherits Opal::UI::Element < Opal::UI::Themable < Reference < Object

Animated loading spinner indicator inspired by Python Textual's LoadingIndicator. Supports multiple animation styles (:dots, :pulse, :bars, :orbit), customizable labels, and theme colors.

Constants

SPINNERS = { dots: ["⠋", "⠙", "⠹", "⠸", "⠼", "⠴", "⠦", "⠧", "⠇", "⠏"], pulse: ["░", "▒", "▓", "█", "▓", "▒"], bars: [" ", "▃", "▄", "▅", "▆", "▇", "█", "▇", "▆", "▅", "▄", "▃"], orbit: ["◐", "◓", "◑", "◒"], }

Constructors

new(label : String | Nil = nil, style : Symbol = :dots, fg : Color | Symbol | String | Nil = nil, label_fg : Color | Symbol | String | Nil = nil)
Source

Instance methods

fg=(fg : Color | Nil)
Source
frame
Source
frame=(frame : UInt64)
Source
label
Source
label=(label : String | Nil)
Source
label_fg
Source
label_fg=(label_fg : Color | Nil)
Source
preferred_size(available_w : Int32, available_h : Int32) : Tuple(Int32, Int32)
Source
render(buffer : Buffer, x : Int32, y : Int32, width : Int32, height : Int32) : Nil
Source
style
Source
style=(style : Symbol)
Source
tick

Advances the animation frame

Source