Class: Aurita::GUI::Text_Field
- Inherits:
-
Input_Field
- Object
- Element
- Form_Field
- Input_Field
- Aurita::GUI::Text_Field
- Defined in:
- lib/aurita-gui/form/text_field.rb
Overview
Wrapper for Input_Field, sets type to :text.
Usage:
i = Text_Field.new(:name => :description,
:label => 'Description',
:value => 'Lorem ipsum dolor')
Instance Attribute Summary
Attributes inherited from Form_Field
#form, #hidden, #label, #required, #type, #value
Attributes inherited from Element
#attrib, #content, #parent, #tag, #type
Instance Method Summary collapse
-
#initialize(params, &block) ⇒ Text_Field
constructor
A new instance of Text_Field.
Methods inherited from Input_Field
Methods inherited from Form_Field
#disable!, #disabled=, #editable!, #element, #enable!, #hidden?, #hide!, #optional!, #readonly!, #readonly=, #readonly?, #readonly_element, #required!, #required?, #show!, #to_hidden_field, #to_s
Methods inherited from Element
#+, #[], #[]=, #clear_floating, #dom_id, #dom_id=, #each, #empty?, #id, #id=, #length, #method_missing, #string, #to_ary
Constructor Details
#initialize(params, &block) ⇒ Text_Field
Returns a new instance of Text_Field.
16 17 18 19 |
# File 'lib/aurita-gui/form/text_field.rb', line 16 def initialize(params, &block) params[:type] = :text unless params[:type] super(params) end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Aurita::GUI::Element