Class: Glimmer::LibUI::Arc

Inherits:
Shape
  • Object
show all
Defined in:
lib/glimmer/libui/arc.rb

Instance Attribute Summary

Attributes inherited from Shape

#args, #block, #keyword, #parent

Instance Method Summary collapse

Methods inherited from Shape

#area_proxy, #children, create, #destroy, exists?, #initialize, #method_missing, parameter_defaults, parameters, #path_proxy, #post_add_content, #post_initialize_child, #respond_to?, shape_class

Constructor Details

This class inherits a constructor from Glimmer::LibUI::Shape

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Glimmer::LibUI::Shape

Instance Method Details

#draw(area_draw_params) ⇒ Object



30
31
32
33
34
35
36
37
38
# File 'lib/glimmer/libui/arc.rb', line 30

def draw(area_draw_params)
  @args[5] ||= ControlProxy.boolean_to_integer(@args[5], allow_nil: false)
  if parent.is_a?(Figure) && parent.x.nil? && parent.y.nil?
    ::LibUI.draw_path_new_figure_with_arc(path_proxy.libui, *@args)
  else
    ::LibUI.draw_path_arc_to(path_proxy.libui, *@args)
  end
  super
end