Version: 8.3.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Pages
SUIT_ItemDelegate Class Reference

An SUIT_DataObject-based item delegate class. More...

#include <SUIT_TreeModel.h>

Inheritance diagram for SUIT_ItemDelegate:
Inheritance graph

Public Member Functions

 SUIT_ItemDelegate (QObject *=0)
 Constructor. More...
 
virtual void paint (QPainter *, const QStyleOptionViewItem &, const QModelIndex &) const
 Render the item in the widget. More...
 
virtual QSize sizeHint (const QStyleOptionViewItem &option, const QModelIndex &index) const
 

Detailed Description

This class can be used to render the SUIT_DataObject-based item in the widgets like QTreeView and others. Refer to the Qt 4 documentation, model/view architecture section for more details).

Constructor & Destructor Documentation

SUIT_ItemDelegate::SUIT_ItemDelegate ( QObject parent = 0)
Parameters
parentparent object

Member Function Documentation

void SUIT_ItemDelegate::paint ( QPainter *  painter,
const QStyleOptionViewItem &  option,
const QModelIndex &  index 
) const
virtual

Customizes the item colors for the specific roles.

Parameters
painterpainter
optionpainting option
indexmodel index being rendered

References SUIT_TreeModel::BaseColorRole, SUIT_TreeModel::HighlightedTextRole, SUIT_TreeModel::HighlightRole, isValid(), and SUIT_TreeModel::TextColorRole.

QSize SUIT_ItemDelegate::sizeHint ( const QStyleOptionViewItem &  option,
const QModelIndex &  index 
) const
virtual

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