Class: XRC2Ruby::ObjectTypes::ToolBar
- Includes:
- Parent
- Defined in:
- lib/wx_sugar/xrc/xrc2ruby_types/toolbar.rb
Constant Summary
Constants inherited from Window
Instance Attribute Summary collapse
-
#dontattachtoframe ⇒ Object
Returns the value of attribute dontattachtoframe.
Attributes included from Parent
#children, #main_sizer, #sizer_items
Attributes inherited from Window
#bg, #enabled, #exstyle, #fg, #help, #hidden, #tooltip
Attributes inherited from Object
#centered, #name, #parent, #sub_class, #win_class
Instance Method Summary collapse
- #add_tool(tool) ⇒ Object
-
#initialize(*args) ⇒ ToolBar
constructor
A new instance of ToolBar.
- #setup ⇒ Object
Methods included from Parent
#add_child, #child_output, #named_windows, #output, #size_child
Methods inherited from Window
Methods included from InitArgs
#inherited, #init_arg, #init_args, #translatable_string_init_arg
Methods inherited from Object
#inspect, next_id, #output, #var_name
Constructor Details
#initialize(*args) ⇒ ToolBar
Returns a new instance of ToolBar.
5 6 7 8 |
# File 'lib/wx_sugar/xrc/xrc2ruby_types/toolbar.rb', line 5 def initialize(*args) super @tools = [] end |
Instance Attribute Details
#dontattachtoframe ⇒ Object
Returns the value of attribute dontattachtoframe.
4 5 6 |
# File 'lib/wx_sugar/xrc/xrc2ruby_types/toolbar.rb', line 4 def dontattachtoframe @dontattachtoframe end |
Instance Method Details
#add_tool(tool) ⇒ Object
10 11 12 |
# File 'lib/wx_sugar/xrc/xrc2ruby_types/toolbar.rb', line 10 def add_tool(tool) @tools << tool end |
#setup ⇒ Object
14 15 16 |
# File 'lib/wx_sugar/xrc/xrc2ruby_types/toolbar.rb', line 14 def setup @tools.inject('') { | str, tool | str + tool.output } end |