2019-10-09 20:15:53 +08:00
|
|
|
%Import QtWidgets/QtWidgetsmod.sip
|
|
|
|
|
|
|
|
%If (Qt_5_0_0 -)
|
|
|
|
|
|
|
|
namespace ads
|
|
|
|
{
|
|
|
|
|
|
|
|
class CDockWidgetTab : QFrame
|
|
|
|
{
|
|
|
|
%TypeHeaderCode
|
|
|
|
#include <DockWidgetTab.h>
|
|
|
|
%End
|
|
|
|
|
|
|
|
protected:
|
|
|
|
virtual void mousePressEvent(QMouseEvent* ev);
|
|
|
|
virtual void mouseReleaseEvent(QMouseEvent* ev);
|
|
|
|
virtual void mouseMoveEvent(QMouseEvent* ev);
|
|
|
|
virtual void contextMenuEvent(QContextMenuEvent* ev);
|
|
|
|
virtual void mouseDoubleClickEvent(QMouseEvent *event);
|
|
|
|
|
|
|
|
public:
|
|
|
|
CDockWidgetTab(ads::CDockWidget* DockWidget /TransferThis/, QWidget* parent /TransferThis/ = 0);
|
|
|
|
virtual ~CDockWidgetTab();
|
|
|
|
bool isActiveTab() const;
|
|
|
|
void setActiveTab(bool active);
|
|
|
|
void setDockAreaWidget(ads::CDockAreaWidget* DockArea /Transfer/);
|
|
|
|
ads::CDockAreaWidget* dockAreaWidget() const;
|
2020-02-25 14:22:51 +08:00
|
|
|
ads::CDockWidget* dockWidget() const;
|
2019-10-09 20:15:53 +08:00
|
|
|
void setIcon(const QIcon& Icon);
|
|
|
|
const QIcon& icon() const;
|
|
|
|
QString text() const;
|
|
|
|
void setText(const QString& title);
|
2020-02-22 05:47:09 +08:00
|
|
|
bool isTitleElided() const;
|
2019-10-09 20:15:53 +08:00
|
|
|
bool isClosable() const;
|
|
|
|
virtual bool event(QEvent *e);
|
2020-05-13 22:05:00 +08:00
|
|
|
void setElideMode(Qt::TextElideMode mode);
|
2020-06-10 21:08:31 +08:00
|
|
|
void updateStyle();
|
2021-01-04 21:01:28 +08:00
|
|
|
QSize iconSize() const;
|
|
|
|
void setIconSize(const QSize& Size);
|
2019-10-09 20:15:53 +08:00
|
|
|
|
|
|
|
public slots:
|
|
|
|
virtual void setVisible(bool visible);
|
|
|
|
|
|
|
|
signals:
|
|
|
|
void activeTabChanged();
|
|
|
|
void clicked();
|
|
|
|
void closeRequested();
|
|
|
|
void closeOtherTabsRequested();
|
|
|
|
void moved(const QPoint& GlobalPos);
|
2020-02-22 05:47:09 +08:00
|
|
|
void elidedChanged(bool elided);
|
2019-10-09 20:15:53 +08:00
|
|
|
}; // class DockWidgetTab
|
|
|
|
};
|
|
|
|
// namespace ads
|
|
|
|
|
|
|
|
%End
|