logplus/Workflow/WFWidget/include/PaiWidget.h

69 lines
1.6 KiB
C
Raw Normal View History

2026-01-17 12:55:45 +08:00
/**
* @file PaiWidget.h
* @brief widget
* @date 2013-1-29
*/
#ifndef PAI_FRAME_WIDGET_PAIWIDGET_H
#define PAI_FRAME_WIDGET_PAIWIDGET_H
#include <QWidget>
#include "Turtle.h"
namespace pai
{
namespace gui
{
/**
* @class PaiWidget
* @brief widget
*/
class PAI_WIDGET_EXPORT PaiWidget : public QWidget
{
Q_OBJECT
public:
/**
* @brief
* @param[in] pParent
* @param[in] flags Qt::WindowFlags
*/
PaiWidget(QWidget *pParent = NULL, Qt::WindowFlags flags = 0);
/**
* @brief
*/
virtual ~PaiWidget();
/**
* @brief
* @param[in] top
* @param[in] bottom
* @param[in] left
* @param[in] right
*/
void ShowBorder(bool top, bool bottom, bool left, bool right);
/**
* @brief
* @param[in] color
*/
void SetBackgroundColor(const QColor & color);
protected:
/**
* @brief
* @param[in] pEvent
*/
virtual void paintEvent(QPaintEvent *pEvent);
private:
bool m_ShowTopBorder; ///< 是否显示顶部边框
bool m_ShowBottomBorder; ///< 是否显示底部边框
bool m_ShowLeftBorder; ///< 是否显示左部边框
bool m_ShowRightBorder; ///< 是否显示右部边框
QColor m_BackgroundColor; ///< 背景颜色
};
}
}
#endif ///< PAI_FRAME_WIDGET_PAIWIDGET_H