Class: Wee::Brush::TableRowTag
Instance Attribute Summary
Attributes inherited from Wee::Brush
#canvas, #parent
Instance Method Summary
collapse
#__action_callback, #__actionurl_callback, #__actionurl_named_callback, #__input_callback, #css_class, #css_class_for, #method_missing, #onclick_callback, #onclick_update, #with
Methods inherited from Wee::Brush
#close, #with
Constructor Details
Returns a new instance of TableRowTag.
232
233
234
|
# File 'lib/wee/renderer/html/brushes.rb', line 232
def initialize
super('tr')
end
|
Instance Method Details
#align_top ⇒ Object
236
237
238
|
# File 'lib/wee/renderer/html/brushes.rb', line 236
def align_top
html_attr('align', 'top')
end
|
#columns(*cols, &block) ⇒ Object
240
241
242
243
244
245
246
247
248
249
250
251
252
|
# File 'lib/wee/renderer/html/brushes.rb', line 240
def columns(*cols, &block)
with {
cols.each {|col|
@canvas.table_data.with {
if block
block.call(col)
else
@canvas.text(col)
end
}
}
}
end
|
#headings(*headers, &block) ⇒ Object
254
255
256
257
258
259
260
261
262
263
264
265
266
|
# File 'lib/wee/renderer/html/brushes.rb', line 254
def headings(*, &block)
with {
.each {||
@canvas..with {
if block
block.call()
else
@canvas.text()
end
}
}
}
end
|
274
275
276
277
278
|
# File 'lib/wee/renderer/html/brushes.rb', line 274
def spacer
with {
@canvas.table_data { @canvas.space }
}
end
|
#spanning_column(str, colspan) ⇒ Object
268
269
270
271
272
|
# File 'lib/wee/renderer/html/brushes.rb', line 268
def spanning_column(str, colspan)
with {
@canvas.table_data.col_span(colspan).with(str)
}
end
|