Reference documentation
|
The VerticalTree implements a tree representation of item from the given model. More...
Public Member Functions | |
virtual void | paintConnectionsFor (QPainter &painter, const QModelIndex &index, const QPointF &offset) const |
Paints the connections between index and its children. | |
virtual void | positionsInTree () |
Defines the positions of the items in the tree. | |
virtual void | positionsInView () |
Defines the positions of the items in the view relative to their positions in the tree. More... | |
Public Member Functions inherited from AbstractTree | |
AbstractTree (QWidget *parent=0) | |
Initializes an AbstractTree object. More... | |
QPen | connectionPen () const |
Returns the QPen used to paint the connection between a parent and its children. | |
virtual QPainterPath | itemPath (const QModelIndex &index) const |
Defines the outer bounds of the item as a QPainterPath . More... | |
virtual QRectF | itemRect (const QModelIndex &index) const |
Defines the outer bounds of the item as a rectangle. More... | |
void | setConnectionPen (const QPen &pen) |
Sets the QPen used to paint the connection between a parent and its children. | |
void | setItemSpacing (int w, int h) |
Sets the spacing between two items. | |
Public Member Functions inherited from AbstractItemView | |
AbstractItemView (QWidget *parent=0) | |
Constructs an abstract item view with the given parent. | |
virtual QRectF | itemRect (int row, int column, const QModelIndex &parent=QModelIndex()) const |
This function overloads itemRect(). More... | |
Additional Inherited Members | |
Public Slots inherited from AbstractItemView | |
Protected Member Functions inherited from AbstractTree | |
virtual void | paintConnections (QPainter &painter, const QPointF &offset) const |
Paints the connections between the parents and its children. | |
virtual void | paintItems (QPainter &painter, const QPointF &offset) const |
Paints the items in the view using the results of the positionInView() method. | |
virtual void | setX (const QModelIndex &index, qreal x) |
Sets the X coordinates for the given index to x . | |
virtual void | setY (const QModelIndex &index, qreal y) |
Sets the Y coordinates for the given index to y . | |
virtual void | updateValues () |
Updates the items in the item view. More... | |
The VerticalTree implements a tree representation of item from the given model.
Contrary to QTreeView, a vertical tree is not a hierarchical list: the root is placed at the top and all children are placed on horizontal lines.
|
virtual |
Defines the positions of the items in the view relative to their positions in the tree.
This function uses the margins and the item size to calculate
Implements AbstractTree.
Reimplemented in HorizontalTree.