logplus/Workflow/WFWidget/include/PaiListItemDelegate.h
2026-01-17 12:55:45 +08:00

47 lines
936 B
C++

/**
* @file PaiListItemDelegate.h
* @brief PAI系统ListItem默认风格
* @date 2014-11-25
*/
#ifndef PAI_FRAME_WIDGET_PAILISTITEMDELEGATE_H
#define PAI_FRAME_WIDGET_PAILISTITEMDELEGATE_H
#include <QStyledItemDelegate>
#include <QPen>
class QListView;
namespace pai
{
namespace gui
{
/**
* @class PaiListItemDelegate
* @brief PAI风格 listItem delegate
*/
class PaiListItemDelegate: public QStyledItemDelegate
{
public:
/**
* @brief 构造函数
* @param[in] pParent 父亲
*/
PaiListItemDelegate(QObject *pParent = NULL);
protected:
/**
* @brief 重新实现重绘函数
* @param[in] pPainter 画笔
* @param[in] option 选项
* @param[in] index Model 索引
*/
void paint(QPainter *pPainter, const QStyleOptionViewItem & option, const QModelIndex & index) const;
private:
QPen m_GridPen; ///< 画笔
};
}
}
#endif ///< PAI_FRAME_WIDGET_PAILISTITEMDELEGATE_H