You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
nmWATI/Include/iBase/Interface/IxPtyItem.h

62 lines
1.4 KiB
C++

#pragma once
#include <QVariant>
#include <QStringList>
#include "IxInterface.h"
class IxPtyPano;
// 属性项:虚接口
class IxPtyItem
: virtual public IxInterface
{
public:
// 载体
virtual IxPtyPano* getPtyPano() const = 0;
// 父级:属性项
virtual IxPtyItem* getParent() const = 0;
// 是否分组
virtual bool isGroup() const = 0;
// 取值范围
virtual void setLimit(int nMin, int nMax) = 0;
virtual void setLimit(double fMin, double fMax) = 0;
// 对于下拉类型的设定
virtual void setOptions(const QStringList& listName, const QList<QVariant>& listValue) = 0;
virtual void setOptions(const QStringList& listName, const QStringList& listValue) = 0;
virtual void setOptions(const QStringList& listName, const QList<int>& listValue) = 0;
// 当前值
virtual QVariant getValue() const = 0;
virtual void setValue(const QVariant& v, IxInterface* pSetBy = 0) = 0;
// 可见
virtual bool isVisible() const = 0;
virtual void setVisible(bool bVisible) = 0;
// 只读
virtual bool isReadOnly() const = 0;
virtual void setReadOnly(bool bReadOnly) = 0;
// 展开
virtual void setExpand(bool bExpand) = 0;
// 激活条目
virtual void activate() = 0;
// 高度
virtual void setHeight(int height) = 0;
virtual int getHeight() const = 0;
inline IxPtyItem* findPropertyItem(const QString& key);
};