Class: Tgui::TabContainer::Tabs

Inherits:
Tgui::Tabs show all
Defined in:
lib/white_gold/dsl/tab_container.rb

Constant Summary

Constants included from ApiChild

ApiChild::API_CHILD_PREFIX

Instance Attribute Summary

Attributes inherited from Widget

#page

Attributes inherited from ExternObject

#pointer

Instance Method Summary collapse

Methods inherited from Tgui::Tabs

#[], #_abi_add, #_abi_change_text, #_abi_deselect, #_abi_get_auto_size, #_abi_get_maximum_tab_width, #_abi_get_minimum_tab_width, #_abi_get_selected, #_abi_get_selected_index, #_abi_get_tab_enabled, #_abi_get_tab_visible, #_abi_get_tabs_count, #_abi_get_text, #_abi_insert, #_abi_on_tab_select, #_abi_remove, #_abi_remove_all, #_abi_remove_by_index, #_abi_select, #_abi_select_by_index, #_abi_set_auto_size, #_abi_set_maximum_tab_width, #_abi_set_minimum_tab_width, #_abi_set_tab_enabled, #_abi_set_tab_height, #_abi_set_tab_visible, #items, #remove, #remove_all, #selected, #selected=

Methods inherited from Widget

#_abi_ask_tool_tip, #_abi_can_gain_focus, _abi_finalizer, #_abi_finish_all_animations, #_abi_get_absolute_position, #_abi_get_boolean_renderer_property, #_abi_get_color_renderer_property, #_abi_get_float_renderer_property, #_abi_get_font_renderer_property, #_abi_get_full_size, #_abi_get_mouse_cursor, #_abi_get_name, #_abi_get_outline_renderer_property, #_abi_get_position, #_abi_get_size, #_abi_get_string_renderer_property, #_abi_get_text_size, #_abi_get_text_styles_renderer_property, #_abi_get_texture_renderer_property, #_abi_get_tool_tip, _abi_get_type, _abi_get_unshared, #_abi_get_widget_name, #_abi_hide_with_effect, #_abi_is_animation_playing, #_abi_is_container, #_abi_is_enabled, #_abi_is_focusable, #_abi_is_focused, #_abi_is_mouse_down, #_abi_is_visible, #_abi_key_pressed, #_abi_left_mouse_pressed, #_abi_left_mouse_released, #_abi_mouse_moved, #_abi_move_to_back, #_abi_move_to_front, #_abi_move_with_animation, #_abi_on_animation_finish, #_abi_on_focus, #_abi_on_mouse_enter, #_abi_on_mouse_leave, #_abi_on_position_change, #_abi_on_show_effect_finish, #_abi_on_size_change, #_abi_on_unfocus, #_abi_resize_with_animation, #_abi_right_mouse_pressed, #_abi_right_mouse_released, #_abi_scrolled, #_abi_set_boolean_renderer_property, #_abi_set_color_renderer_property, #_abi_set_enabled, #_abi_set_float_renderer_property, #_abi_set_focusable, #_abi_set_focused, #_abi_set_font_renderer_property, #_abi_set_height, #_abi_set_mouse_cursor, #_abi_set_outline_renderer_property, #_abi_set_position, #_abi_set_renderer, #_abi_set_size, #_abi_set_string_renderer_property, #_abi_set_text_size, #_abi_set_text_styles_renderer_property, #_abi_set_texture_renderer_property, #_abi_set_tool_tip, #_abi_set_visible, #_abi_set_widget_name, #_abi_set_width, #_abi_show_with_effect, #_abi_text_entered, api_attr, finalizer, #flags=, #height, #hide, #method_missing, #pack_animation_time, #renderer=, #respond_to?, #self_cast_up, self_renderer, #show, #theme_comp, #visible=, #width, #window

Methods included from ApiChild

#api_child

Methods included from BangDef

#def!

Methods included from BangNestedCaller

#bang_method_missing, #bang_object_stack, #bang_respond_to?, #self!, #upon!

Methods inherited from ExternObject

abi_attr, abi_bit_enum, abi_def, abi_enum, #abi_pack, abi_signal, abi_static, #abi_unpack, callback_storage, callback_storage=, data_storage=, finalizer, global_callback_storage, global_callback_storage=, #initialized, self_abi_def, self_abi_def_setter

Methods included from Packer

#abi_pack, #abi_packer, #abi_packer_method_name

Methods included from Unpacker

#abi_unpack, #abi_unpacker, #abi_unpacker_method_name

Constructor Details

#initialize(tabs_container, pointer) ⇒ Tabs

Returns a new instance of Tabs.



8
9
10
11
# File 'lib/white_gold/dsl/tab_container.rb', line 8

def initialize tabs_container, pointer
  super(pointer:)
  @tabs_container = tabs_container
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Tgui::Widget

Instance Method Details

#alignmentObject



20
21
22
# File 'lib/white_gold/dsl/tab_container.rb', line 20

def alignment
  @tabs_container.abi_unpack(TabAlign, @tabs_container._abi_get_tab_alignment)
end

#alignment=(alignment) ⇒ Object



16
17
18
# File 'lib/white_gold/dsl/tab_container.rb', line 16

def alignment=(alignment)
  @tabs_container._abi_set_tab_alignment @tabs_container.abi_pack(TabAlign, alignment)
end

#fixed_sizeObject



28
29
30
# File 'lib/white_gold/dsl/tab_container.rb', line 28

def fixed_size
  @tabs_container.abi_unpack_float(@tabs_container._abi_get_fixed_size)
end

#fixed_size=(size) ⇒ Object



24
25
26
# File 'lib/white_gold/dsl/tab_container.rb', line 24

def fixed_size=(size)
  @tabs_container._abi_set_fixed_size @tabs_container.abi_pack_float(size)
end

#height=(height) ⇒ Object



32
33
34
# File 'lib/white_gold/dsl/tab_container.rb', line 32

def height=(height)
  @tabs_container._abi_set_tabs_height @tabs_container.abi_pack("Layout", h)
end