Class: Wee::Brush::TextAreaTag

Inherits:
GenericTagBrush show all
Defined in:
lib/wee/renderer/html/brushes.rb

Instance Attribute Summary

Attributes inherited from Wee::Brush

#canvas, #parent

Instance Method Summary collapse

Methods inherited from GenericTagBrush

#__action_callback, #__actionurl_callback, #__actionurl_named_callback, #__input_callback, #css_class, #css_class_for, #method_missing, #onclick_callback, #onclick_update

Methods inherited from Wee::Brush

#close

Constructor Details

#initializeTextAreaTag

Returns a new instance of TextAreaTag.



295
296
297
# File 'lib/wee/renderer/html/brushes.rb', line 295

def initialize
  super('textarea')
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method in the class Wee::Brush::GenericTagBrush

Instance Method Details

#value(val) ⇒ Object



304
305
306
307
# File 'lib/wee/renderer/html/brushes.rb', line 304

def value(val)
  @value = val
  self
end

#with(*args, &block) ⇒ Object



309
310
311
312
313
314
315
316
317
318
319
# File 'lib/wee/renderer/html/brushes.rb', line 309

def with(*args, &block)
  if @value
    if block or !args.empty?
      raise "please use either method 'value' or 'with'"
    else
      super(@value)
    end
  else
    super
  end
end