Class: OutputItemView

Inherits:
Shirka::Qt::TreeItemView show all
Defined in:
lib/troshka/output_item/view.rb

Instance Attribute Summary

Attributes inherited from Shirka::View

#controller, #data, #label

Instance Method Summary collapse

Methods inherited from Shirka::Qt::TreeItemView

#build, #id, #on_view_adding, #widget_class

Methods inherited from Shirka::View

#build, #initialize, #on_component_added, #on_view_added, #on_view_adding, #widget, #widget_class

Methods included from Shirka::Eventalk

#add_watcher, #fire, #forward, #watch, #watchers

Constructor Details

This class inherits a constructor from Shirka::View

Instance Method Details

#init(data) ⇒ Object



2
3
4
# File 'lib/troshka/output_item/view.rb', line 2

def init(data)
  @data = "Time elapsed: %.3f ms" % data
end

#style(widget) ⇒ Object



6
7
8
# File 'lib/troshka/output_item/view.rb', line 6

def style(widget)
  widget.setForeground 0, Qt::Brush.new(Qt::Color.new 100, 100, 100)
end