Module: Roby::GUI::RelationsCanvasPlan
- Included in:
- Plan
- Defined in:
- lib/roby/gui/relations_view/relations_canvas.rb
Constant Summary collapse
- PLAN_STROKE_WIDTH =
5
Instance Attribute Summary collapse
-
#depth ⇒ Object
readonly
The plan depth, i.e.
-
#max_depth ⇒ Object
readonly
The max depth of the plan tree in this branch.
Instance Method Summary collapse
- #display(display, item) ⇒ Object
- #display_create(display) ⇒ Object
- #display_name(display) ⇒ Object
- #display_parent ⇒ Object
Instance Attribute Details
#depth ⇒ Object (readonly)
The plan depth, i.e. its distance from the root plan
327 328 329 |
# File 'lib/roby/gui/relations_view/relations_canvas.rb', line 327 def depth @depth end |
#max_depth ⇒ Object (readonly)
The max depth of the plan tree in this branch
329 330 331 |
# File 'lib/roby/gui/relations_view/relations_canvas.rb', line 329 def max_depth @max_depth end |
Instance Method Details
#display(display, item) ⇒ Object
346 |
# File 'lib/roby/gui/relations_view/relations_canvas.rb', line 346 def display(display, item); end |
#display_create(display) ⇒ Object
331 332 333 334 335 336 337 338 339 |
# File 'lib/roby/gui/relations_view/relations_canvas.rb', line 331 def display_create(display) scene = display.scene pen = Qt::Pen.new pen.width = PLAN_STROKE_WIDTH pen.style = Qt::SolidLine pen.cap_style = Qt::SquareCap pen.join_style = Qt::RoundJoin scene.add_rect Qt::RectF.new(0, 0, 0, 0), pen end |
#display_name(display) ⇒ Object
348 349 350 |
# File 'lib/roby/gui/relations_view/relations_canvas.rb', line 348 def display_name(display) "" end |
#display_parent ⇒ Object
341 342 343 344 |
# File 'lib/roby/gui/relations_view/relations_canvas.rb', line 341 def display_parent if respond_to?(:plan) then plan end end |