class Works::UI::ProgressBar

Defined in:

works/ui/progress_bar.cr

Constant Summary

BackgroundColor = LibAllegro.premul_rgba_f(0, 0, 0, 0.3)
Color = LibAllegro.map_rgb_f(1, 1, 1)
Margin = 3 * Screen.scale_factor
Padding = 3 * Screen.scale_factor

Constructors

Instance Method Summary

Instance methods inherited from class Works::UI::Base

draw(x, y) draw, height : Int32 height, height=(height : Int32) height=, inner_height inner_height, inner_width inner_width, margin : Int32 margin, margin=(margin : Int32) margin=, outer_height outer_height, outer_width outer_width, padding : Int32 padding, padding=(padding : Int32) padding=, width : Int32 width, width=(width : Int32) width=

Constructor methods inherited from class Works::UI::Base

new(width : Int32, height : Int32, margin : Int32 = 0, padding : Int32 = 0) new

Constructor Detail

def self.new(width, height, progress : Float64, color : LibAllegro::Color = Color) #

[View source]

Instance Method Detail

def color : LibAllegro::Color #

[View source]
def color=(color : LibAllegro::Color) #

[View source]
def draw(x, y) #

[View source]
def draw_background(x, y) #

[View source]
def draw_from_bottom(x, y) #

[View source]
def draw_progress_bar(x, y) #

[View source]
def progress : Float64 #

[View source]
def progress=(progress : Float64) #

[View source]