|
|
#ifndef PYTHONQTWRAPPER_QTREEWIDGETITEM_H
|
|
|
#define PYTHONQTWRAPPER_QTREEWIDGETITEM_H
|
|
|
|
|
|
#include <qtreewidget.h>
|
|
|
#include <QObject>
|
|
|
|
|
|
#include <QVariant>
|
|
|
#include <qbrush.h>
|
|
|
#include <qdatastream.h>
|
|
|
#include <qfont.h>
|
|
|
#include <qicon.h>
|
|
|
#include <qlist.h>
|
|
|
#include <qsize.h>
|
|
|
#include <qstringlist.h>
|
|
|
#include <qtreewidget.h>
|
|
|
|
|
|
class PythonQtWrapper_QTreeWidgetItem : public QObject
|
|
|
{ Q_OBJECT
|
|
|
public:
|
|
|
Q_ENUMS(ItemType ChildIndicatorPolicy )
|
|
|
enum ItemType{
|
|
|
Type = QTreeWidgetItem::Type, UserType = QTreeWidgetItem::UserType};
|
|
|
enum ChildIndicatorPolicy{
|
|
|
ShowIndicator = QTreeWidgetItem::ShowIndicator, DontShowIndicator = QTreeWidgetItem::DontShowIndicator, DontShowIndicatorWhenChildless = QTreeWidgetItem::DontShowIndicatorWhenChildless};
|
|
|
public slots:
|
|
|
bool hasOwner(QTreeWidgetItem* theWrappedObject) { return theWrappedObject->treeWidget()!=NULL || theWrappedObject->parent()!=NULL; }
|
|
|
|
|
|
QTreeWidgetItem* new_QTreeWidgetItem(QTreeWidget* view, QTreeWidgetItem* after, int type = Type);
|
|
|
QTreeWidgetItem* new_QTreeWidgetItem(QTreeWidget* view, const QStringList& strings, int type = Type);
|
|
|
QTreeWidgetItem* new_QTreeWidgetItem(QTreeWidget* view, int type = Type);
|
|
|
QTreeWidgetItem* new_QTreeWidgetItem(QTreeWidgetItem* parent, QTreeWidgetItem* after, int type = Type);
|
|
|
QTreeWidgetItem* new_QTreeWidgetItem(QTreeWidgetItem* parent, const QStringList& strings, int type = Type);
|
|
|
QTreeWidgetItem* new_QTreeWidgetItem(QTreeWidgetItem* parent, int type = Type);
|
|
|
QTreeWidgetItem* new_QTreeWidgetItem(const QStringList& strings, int type = Type);
|
|
|
QTreeWidgetItem* new_QTreeWidgetItem(int type = Type);
|
|
|
void delete_QTreeWidgetItem(QTreeWidgetItem* obj) { delete obj; }
|
|
|
void addChild(QTreeWidgetItem* theWrappedObject, QTreeWidgetItem* child);
|
|
|
void addChildren(QTreeWidgetItem* theWrappedObject, const QList<QTreeWidgetItem* >& children);
|
|
|
QBrush background(QTreeWidgetItem* theWrappedObject, int column) const;
|
|
|
Qt::CheckState checkState(QTreeWidgetItem* theWrappedObject, int column) const;
|
|
|
QTreeWidgetItem* child(QTreeWidgetItem* theWrappedObject, int index) const;
|
|
|
int childCount(QTreeWidgetItem* theWrappedObject) const;
|
|
|
QTreeWidgetItem::ChildIndicatorPolicy childIndicatorPolicy(QTreeWidgetItem* theWrappedObject) const;
|
|
|
QTreeWidgetItem* clone(QTreeWidgetItem* theWrappedObject) const;
|
|
|
int columnCount(QTreeWidgetItem* theWrappedObject) const;
|
|
|
QVariant data(QTreeWidgetItem* theWrappedObject, int column, int role) const;
|
|
|
Qt::ItemFlags flags(QTreeWidgetItem* theWrappedObject) const;
|
|
|
QFont font(QTreeWidgetItem* theWrappedObject, int column) const;
|
|
|
QBrush foreground(QTreeWidgetItem* theWrappedObject, int column) const;
|
|
|
QIcon icon(QTreeWidgetItem* theWrappedObject, int column) const;
|
|
|
int indexOfChild(QTreeWidgetItem* theWrappedObject, QTreeWidgetItem* child) const;
|
|
|
void insertChild(QTreeWidgetItem* theWrappedObject, int index, QTreeWidgetItem* child);
|
|
|
void insertChildren(QTreeWidgetItem* theWrappedObject, int index, const QList<QTreeWidgetItem* >& children);
|
|
|
bool isDisabled(QTreeWidgetItem* theWrappedObject) const;
|
|
|
bool isExpanded(QTreeWidgetItem* theWrappedObject) const;
|
|
|
bool isFirstColumnSpanned(QTreeWidgetItem* theWrappedObject) const;
|
|
|
bool isHidden(QTreeWidgetItem* theWrappedObject) const;
|
|
|
bool isSelected(QTreeWidgetItem* theWrappedObject) const;
|
|
|
void writeTo(QTreeWidgetItem* theWrappedObject, QDataStream& out);
|
|
|
void readFrom(QTreeWidgetItem* theWrappedObject, QDataStream& in);
|
|
|
QTreeWidgetItem* parent(QTreeWidgetItem* theWrappedObject) const;
|
|
|
void removeChild(QTreeWidgetItem* theWrappedObject, QTreeWidgetItem* child);
|
|
|
void setBackground(QTreeWidgetItem* theWrappedObject, int column, const QBrush& brush);
|
|
|
void setCheckState(QTreeWidgetItem* theWrappedObject, int column, Qt::CheckState state);
|
|
|
void setChildIndicatorPolicy(QTreeWidgetItem* theWrappedObject, QTreeWidgetItem::ChildIndicatorPolicy policy);
|
|
|
void setData(QTreeWidgetItem* theWrappedObject, int column, int role, const QVariant& value);
|
|
|
void setDisabled(QTreeWidgetItem* theWrappedObject, bool disabled);
|
|
|
void setExpanded(QTreeWidgetItem* theWrappedObject, bool expand);
|
|
|
void setFirstColumnSpanned(QTreeWidgetItem* theWrappedObject, bool span);
|
|
|
void setFlags(QTreeWidgetItem* theWrappedObject, Qt::ItemFlags flags);
|
|
|
void setFont(QTreeWidgetItem* theWrappedObject, int column, const QFont& font);
|
|
|
void setForeground(QTreeWidgetItem* theWrappedObject, int column, const QBrush& brush);
|
|
|
void setHidden(QTreeWidgetItem* theWrappedObject, bool hide);
|
|
|
void setIcon(QTreeWidgetItem* theWrappedObject, int column, const QIcon& icon);
|
|
|
void setSelected(QTreeWidgetItem* theWrappedObject, bool select);
|
|
|
void setSizeHint(QTreeWidgetItem* theWrappedObject, int column, const QSize& size);
|
|
|
void setStatusTip(QTreeWidgetItem* theWrappedObject, int column, const QString& statusTip);
|
|
|
void setText(QTreeWidgetItem* theWrappedObject, int column, const QString& text);
|
|
|
void setTextAlignment(QTreeWidgetItem* theWrappedObject, int column, int alignment);
|
|
|
void setToolTip(QTreeWidgetItem* theWrappedObject, int column, const QString& toolTip);
|
|
|
void setWhatsThis(QTreeWidgetItem* theWrappedObject, int column, const QString& whatsThis);
|
|
|
QSize sizeHint(QTreeWidgetItem* theWrappedObject, int column) const;
|
|
|
void sortChildren(QTreeWidgetItem* theWrappedObject, int column, Qt::SortOrder order);
|
|
|
QString statusTip(QTreeWidgetItem* theWrappedObject, int column) const;
|
|
|
QTreeWidgetItem* takeChild(QTreeWidgetItem* theWrappedObject, int index);
|
|
|
QList<QTreeWidgetItem* > takeChildren(QTreeWidgetItem* theWrappedObject);
|
|
|
QString text(QTreeWidgetItem* theWrappedObject, int column) const;
|
|
|
int textAlignment(QTreeWidgetItem* theWrappedObject, int column) const;
|
|
|
QString toolTip(QTreeWidgetItem* theWrappedObject, int column) const;
|
|
|
QTreeWidget* treeWidget(QTreeWidgetItem* theWrappedObject) const;
|
|
|
int type(QTreeWidgetItem* theWrappedObject) const;
|
|
|
QString whatsThis(QTreeWidgetItem* theWrappedObject, int column) const;
|
|
|
};
|
|
|
|
|
|
#endif // PYTHONQTWRAPPER_QTREEWIDGETITEM_H
|
|
|
|