umbrello: SeqLineWidget Class Reference

umbrello 2.38.1 Umbrello UML Modeller is a Unified Modelling Language (UML) diagram program based on KDE Technology

- Main Page
- Related Pages
- Modules
- Namespaces
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Classes | Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes | List of all members
SeqLineWidget Class Reference

Widget class for graphical representation of sequence lines. More...

`#include <seqlinewidget.h>`

Inheritance diagram for SeqLineWidget:

## Classes
struct | DestructionBox

## Public Member Functions
| SeqLineWidget (UMLScene *scene, ObjectWidget *pObject)
virtual | ~SeqLineWidget ()
bool | onWidget (const QPointF &p)
bool | onDestructionBox (const QPointF &p)
void | cleanup ()
void | setupDestructionBox ()
void | setStartPoint (int startX, int startY)
int | getLineLength () const
ObjectWidget * | getObjectWidget ()
void | setEndOfLine (int yPosition)
void | setLineColorCmd (const QColor &color)

## Protected Member Functions
void | cleanupDestructionBox ()
void | moveDestructionBox ()
void | contextMenuEvent (QGraphicsSceneContextMenuEvent *event)

## Protected Attributes
ObjectWidget * | m_pObject
| ObjectWidget associated with this sequence line.
UMLScene * | m_scene
| scene displayed on
struct SeqLineWidget::DestructionBox | m_DestructionBox
| the destruction box
int | m_nLengthY
| the length of the line

## Static Protected Attributes
static int const | m_nMouseDownEpsilonX = 20
| margin used for mouse clicks

## Detailed Description

Widget class for graphical representation of sequence lines.

A sequence lifeline consists of the object widget at the top and a vertical line starting at the bottom edge of the object widget at half its width. The line grows downward when sequence messages are added such that the line always extends far enough to act as the background for all messages. This class represents only the line part of the lifeline.

Author
  Paul Hensgen Bugs and comments to umbre.nosp@m.llo-.nosp@m.devel.nosp@m.@kde.nosp@m..org or https://bugs.kde.org

## Constructor & Destructor Documentation

## ◆ SeqLineWidget()

SeqLineWidget::SeqLineWidget | ( | UMLScene * | scene,
|  | ObjectWidget * | pObject
| ) |  |

Constructor.

## ◆ ~SeqLineWidget()

SeqLineWidget::~SeqLineWidget | ( |  | ) |
| virtual

Destructor.

## Member Function Documentation

## ◆ cleanup()

void SeqLineWidget::cleanup | ( |  | ) |

Clean up anything before deletion.

## ◆ cleanupDestructionBox()

void SeqLineWidget::cleanupDestructionBox | ( |  | ) |
| protected

Clean up destruction box.

## ◆ contextMenuEvent()

void SeqLineWidget::contextMenuEvent | ( | QGraphicsSceneContextMenuEvent * | event | ) |
| protected

## ◆ getLineLength()

int SeqLineWidget::getLineLength | ( |  | ) | const
| inline

Gets the length of the line.

Returns
  Length of the line.

## ◆ getObjectWidget()

ObjectWidget * SeqLineWidget::getObjectWidget | ( |  | ) |
| inline

Returns the ObjectWidget associated with this sequence line.

Returns
  Pointer to the associated ObjectWidget.

## ◆ moveDestructionBox()

void SeqLineWidget::moveDestructionBox | ( |  | ) |
| protected

Move destruction box.

## ◆ onDestructionBox()

bool SeqLineWidget::onDestructionBox | ( | const QPointF & | p | ) |

Return whether point is on the destruction box.

Parameters

  p | The point to investigate.

Returns
  True if point is on the destruction box of this sequence line.

## ◆ onWidget()

bool SeqLineWidget::onWidget | ( | const QPointF & | p | ) |

Return whether point is on sequence line. Takes into account destruction box if shown.

Parameters

  p | The point to investigate.

Returns
  True if point is on this sequence line.

## ◆ setEndOfLine()

void SeqLineWidget::setEndOfLine | ( | int | yPosition | ) |

Sets the y position of the bottom of the vertical line.

Parameters

  yPosition | The y coordinate for the bottom of the line.

## ◆ setLineColorCmd()

void SeqLineWidget::setLineColorCmd | ( | const QColor & | color | ) |

## ◆ setStartPoint()

void SeqLineWidget::setStartPoint | ( | int | startX,
|  | int | startY
| ) |  |

Set the start point of the line.

Parameters

  startX | X coordinate of the start point.
  startY | Y coordinate of the start point.

## ◆ setupDestructionBox()

void SeqLineWidget::setupDestructionBox | ( |  | ) |

Set up destruction box.

## Member Data Documentation

## ◆ m_DestructionBox

struct SeqLineWidget::DestructionBox SeqLineWidget::m_DestructionBox
| protected

the destruction box

## ◆ m_nLengthY

int SeqLineWidget::m_nLengthY
| protected

the length of the line

## ◆ m_nMouseDownEpsilonX

int const SeqLineWidget::m_nMouseDownEpsilonX = 20
| staticprotected

margin used for mouse clicks

## ◆ m_pObject

ObjectWidget* SeqLineWidget::m_pObject
| protected

ObjectWidget associated with this sequence line.

## ◆ m_scene

UMLScene* SeqLineWidget::m_scene
| protected

scene displayed on

The documentation for this class was generated from the following files:

- umbrello/umlwidgets/seqlinewidget.h
- umbrello/umlwidgets/seqlinewidget.cpp