Class: TT::GUI::Textbox

Inherits:
Control show all
Defined in:
TT_Lib2/gui.rb

Overview

Events

  • :change

  • :keydown

  • :keypress

  • :keyup

  • :focus

  • :blur

Since:

  • 2.4.0

Instance Attribute Summary collapse

Attributes inherited from Control

#bottom, #font_bold, #font_italic, #font_name, #font_size, #height, #left, #name, #parent, #right, #tooltip, #top, #ui_id, #width, #window

Instance Method Summary collapse

Methods inherited from Control

#add_event_handler, #call_event, #disabled=, #disabled?, #enabled=, #enabled?, events, has_event?, #inspect, #move, #position, #positioned?, #properties, #release!, #size

Methods included from ControlEvents

included

Constructor Details

#initialize(value) ⇒ Textbox

Returns a new instance of Textbox

Parameters:

  • value (String)

Since:

  • 2.4.0



779
780
781
782
# File 'TT_Lib2/gui.rb', line 779

def initialize( value )
  super
  @value = value
end

Instance Attribute Details

#multilineObject Also known as: multiline?

Since:

  • 2.4.0



766
767
768
# File 'TT_Lib2/gui.rb', line 766

def multiline
  @multiline
end

#valueString

Returns:

  • (String)

Since:

  • 2.6.0



766
767
768
# File 'TT_Lib2/gui.rb', line 766

def value
  @value
end

Instance Method Details

#custom_propertiesTT::JSON

Returns:

Since:

  • 2.6.0



802
803
804
805
806
807
# File 'TT_Lib2/gui.rb', line 802

def custom_properties
  prop = TT::JSON.new
  prop['value'] = @value
  prop['multiline'] = @multiline
  prop
end