Class: AutoItX3::TabBook
Overview
A tab book or tab bar is a control that shows up most often at the top of a window and lets you choice between different contents within the same window.
Instance Method Summary collapse
-
#current ⇒ Object
Returns the currently shown tab.
-
#left ⇒ Object
Shows the tab left to the current one.
-
#right ⇒ Object
Shows the tab right to the current one.
Methods inherited from Control
#click, #disable, #enable, #enabled?, #focus, from_control, functions, functions=, #handle, #hide, #initialize, #move, #rect, #send_command_to_control, #send_keys, #show, #text, #text=, #visible?
Constructor Details
This class inherits a constructor from AutoItX3::Control
Instance Method Details
#current ⇒ Object
Returns the currently shown tab.
Return value
The number of the currently shown tab, starting with 1.
Raises
- Au3Error
-
Control or window not found.
Example
p tab.current #=> 2
591 592 593 |
# File 'lib/AutoItX3/control.rb', line 591 def current send_command_to_control("CurrentTab").to_i end |
#left ⇒ Object
Shows the tab left to the current one.
Return value
Returns the number of the now shown tab, starting with 1.
Raises
- Au3Error
-
Control or window not found.
Example
tab.left #| 1
614 615 616 617 |
# File 'lib/AutoItX3/control.rb', line 614 def left send_command_to_control("TabLeft") current end |
#right ⇒ Object
Shows the tab right to the current one.
Return value
Returns the number of the now shown tab, starting with 1.
Raises
- Au3Error
-
Control or window not found.
Example
tab.right #| 3
602 603 604 605 |
# File 'lib/AutoItX3/control.rb', line 602 def right send_command_to_control("TabRight") current end |