Class: Shoes::Rect
- Inherits:
-
Common::ArtElement
- Object
- Common::UIElement
- Common::ArtElement
- Shoes::Rect
- Defined in:
- shoes-core/lib/shoes/rect.rb
Constant Summary collapse
Constants inherited from Common::ArtElement
Common::ArtElement::REDRAW_OFFSET_FACTOR, Common::ArtElement::REDRAW_SIZING_FACTOR
Constants included from Common::Style
Common::Style::DEFAULT_STYLES, Common::Style::STYLE_GROUPS
Instance Attribute Summary
Attributes included from Common::Clickable
Attributes inherited from Common::UIElement
#app, #dimensions, #gui, #parent
Instance Method Summary collapse
Methods inherited from Common::ArtElement
#painted?, #redraw_height, #redraw_left, #redraw_top, #redraw_width
Methods included from Common::Translate
#clear_translate, #translate_left, #translate_top
Methods included from Common::Stroke
Methods included from Common::Rotate
Methods included from Common::Fill
Methods included from Common::Clickable
#click, #pass_coordinates?, #register_click, #release
Methods inherited from Common::UIElement
#add_to_parent, #after_initialize, #before_initialize, #create_backend, #handle_block, #initialize, #needs_rotate?, #painted?, #redraw_height, #redraw_left, #redraw_top, #redraw_width, #update_fill, #update_stroke
Methods included from Common::Style
#applicable_app_styles, #create_style_hash, included, #style, #style_init
Methods included from Common::SafelyEvaluate
Methods included from Common::Remove
Methods included from Common::Positioning
Methods included from Common::Visibility
#hidden?, #hidden_from_view?, #hide, #outside_parent_view?, #show, #toggle, #visible?
Methods included from Common::Inspect
Methods included from Common::Attachable
Constructor Details
This class inherits a constructor from Shoes::Common::UIElement
Instance Method Details
#create_dimensions(left, top, width, height) ⇒ Object
8 9 10 11 12 13 14 15 |
# File 'shoes-core/lib/shoes/rect.rb', line 8 def create_dimensions(left, top, width, height) left ||= @style[:left] || 0 top ||= @style[:top] || 0 width ||= @style[:width] || 0 height ||= @style[:height] || width @dimensions = AbsoluteDimensions.new left, top, width, height, @style end |