Class: RUI::GuiBuilder::Label
- Includes:
- RUI::GuiBuilder
- Defined in:
- lib/rui/toolkits/qtbase/gui_builder.rb
Overview
A label.
The label text is specified by the text
attribute.
A buddy
attribute can also be specified as a widget id. The widget with the given id will be set as the buddy of this label as GUI construction time.
Instance Method Summary collapse
Methods included from RUI::GuiBuilder
build, #build, #builder, #setup_widget
Instance Method Details
#create_element(window, parent, desc) ⇒ Object
229 230 231 232 233 234 235 236 |
# File 'lib/rui/toolkits/qtbase/gui_builder.rb', line 229 def create_element(window, parent, desc) label = Qt::Label.new(desc.opts[:text].to_s, window) (label, window, parent, desc) if desc.opts[:buddy] window.buddies[label] = desc.opts[:buddy] end label end |