diff options
author | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:56:07 +0000 |
---|---|---|
committer | tpearson <tpearson@283d02a7-25f6-0310-bc7c-ecb5cbfe19da> | 2010-07-31 19:56:07 +0000 |
commit | d6f8bbb45b267065a6907e71ff9c98bb6d161241 (patch) | |
tree | d109539636691d7b03036ca1c0ed29dbae6577cf /lib/widgets/propeditor/property.h | |
parent | 3331a47a9cad24795c7440ee8107143ce444ef34 (diff) | |
download | tdevelop-d6f8bbb45b267065a6907e71ff9c98bb6d161241.tar.gz tdevelop-d6f8bbb45b267065a6907e71ff9c98bb6d161241.zip |
Trinity Qt initial conversion
git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/kdevelop@1157658 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
Diffstat (limited to 'lib/widgets/propeditor/property.h')
-rw-r--r-- | lib/widgets/propeditor/property.h | 118 |
1 files changed, 59 insertions, 59 deletions
diff --git a/lib/widgets/propeditor/property.h b/lib/widgets/propeditor/property.h index 06f39c66..74fcb890 100644 --- a/lib/widgets/propeditor/property.h +++ b/lib/widgets/propeditor/property.h @@ -19,9 +19,9 @@ #ifndef PROPERTY_H #define PROPERTY_H -#include <qvariant.h> +#include <tqvariant.h> -#include <qmap.h> +#include <tqmap.h> class QWidget; class QString; @@ -36,14 +36,14 @@ namespace PropertyLib{ /** @short Property. -It includes support for QStringList properties, an i18n'ed label and stores an old value to allow undo. +It includes support for TQStringList properties, an i18n'ed label and stores an old value to allow undo. Contains name, type and value. -Type can be one of predefined types (including standard @ref QVariant types) by @ref PropertyLib::Property::PropertyType +Type can be one of predefined types (including standard @ref TQVariant types) by @ref PropertyLib::Property::PropertyType enum or custom user type. User defined types should have values more than 3000. -Value is a @ref QVariant. +Value is a @ref TQVariant. Property can optionally have a list of possible values. In that case use @ref ValueFromList type and valueList member. @@ -64,43 +64,43 @@ public: /** PropertyType. Integers that represent the type of the property. */ enum PropertyType { - //standard supported QVariant types - Invalid = QVariant::Invalid /**<invalid property type*/, - Map = QVariant::Map /**<QMap<QString, QVariant>*/, - List = QVariant::List /**<QValueList<QVariant>*/, - String = QVariant::String /**<string*/, - StringList = QVariant::StringList /**<string list*/, - Font = QVariant::Font /**<font*/, - Pixmap = QVariant::Pixmap /**<pixmap*/, - //@todo implement QVariant::Brush - Rect = QVariant::Rect /**<rectangle (x,y, width, height)*/, - Size = QVariant::Size /**<size (width, height)*/, - Color = QVariant::Color /**<color*/, - //@todo implement QVariant::Palette - //@todo implement QVariant::ColorGroup - //@todo implement QVariant::IconSet - Point = QVariant::Point /**<point (x,y)*/, - //@todo implement QVariant::Image - Integer = QVariant::Int /**<integer*/, - //@todo implement QVariant::UInt - Boolean = QVariant::Bool /**<boolean*/, - Double = QVariant::Double /**<double*/, - //@todo implement QVariant::CString - //@todo implement QVariant::PointArray - //@todo implement QVariant::Region - //@todo implement QVariant::Bitmap - Cursor = QVariant::Cursor /**<cursor*/, - SizePolicy = QVariant::SizePolicy /**<size policy (horizontal, vertical)*/, - Date = QVariant::Date /**<date*/, - //@todo implement QVariant::Time - DateTime = QVariant::DateTime /**<date and time*/, - //@todo implement QVariant::ByteArray - //@todo implement QVariant::BitArray - //@todo implement QVariant::KeySequence - //@todo implement QVariant::Pen - //@todo implement QVariant::Long - //@todo implement QVariant::LongLong - //@todo implement QVariant::ULongLong + //standard supported TQVariant types + Invalid = TQVariant::Invalid /**<invalid property type*/, + Map = TQVariant::Map /**<TQMap<TQString, TQVariant>*/, + List = TQVariant::List /**<TQValueList<TQVariant>*/, + String = TQVariant::String /**<string*/, + StringList = TQVariant::StringList /**<string list*/, + Font = TQVariant::Font /**<font*/, + Pixmap = TQVariant::Pixmap /**<pixmap*/, + //@todo implement TQVariant::Brush + Rect = TQVariant::Rect /**<rectangle (x,y, width, height)*/, + Size = TQVariant::Size /**<size (width, height)*/, + Color = TQVariant::Color /**<color*/, + //@todo implement TQVariant::Palette + //@todo implement TQVariant::ColorGroup + //@todo implement TQVariant::IconSet + Point = TQVariant::Point /**<point (x,y)*/, + //@todo implement TQVariant::Image + Integer = TQVariant::Int /**<integer*/, + //@todo implement TQVariant::UInt + Boolean = TQVariant::Bool /**<boolean*/, + Double = TQVariant::Double /**<double*/, + //@todo implement TQVariant::CString + //@todo implement TQVariant::PointArray + //@todo implement TQVariant::Region + //@todo implement TQVariant::Bitmap + Cursor = TQVariant::Cursor /**<cursor*/, + SizePolicy = TQVariant::SizePolicy /**<size policy (horizontal, vertical)*/, + Date = TQVariant::Date /**<date*/, + //@todo implement TQVariant::Time + DateTime = TQVariant::DateTime /**<date and time*/, + //@todo implement TQVariant::ByteArray + //@todo implement TQVariant::BitArray + //@todo implement TQVariant::KeySequence + //@todo implement TQVariant::Pen + //@todo implement TQVariant::Long + //@todo implement TQVariant::LongLong + //@todo implement TQVariant::ULongLong //predefined custom types @@ -117,36 +117,36 @@ public: /**Constructs empty property.*/ Property() {} /**Constructs property.*/ - Property(int type, const QString &name, const QString &description, - const QVariant &value = QVariant(), bool save = true, bool readOnly = false); + Property(int type, const TQString &name, const TQString &description, + const TQVariant &value = TQVariant(), bool save = true, bool readOnly = false); /**Constructs property with @ref ValueFromList type.*/ - Property(const QString &name, const QMap<QString, QVariant> &v_valueList, - const QString &description, const QVariant &value = QVariant(), bool save = true, bool readOnly = false); + Property(const TQString &name, const TQMap<TQString, TQVariant> &v_valueList, + const TQString &description, const TQVariant &value = TQVariant(), bool save = true, bool readOnly = false); virtual ~Property(); virtual bool operator<(const Property &prop) const; /**@return the name of the property.*/ - virtual QString name() const; + virtual TQString name() const; /**Sets the name of the property.*/ - virtual void setName(const QString &name); + virtual void setName(const TQString &name); /**@return the type of the property.*/ virtual int type() const; /**Sets the type of the property.*/ virtual void setType(int type); /**@return the value of the property.*/ - virtual QVariant value() const; + virtual TQVariant value() const; /**Sets the value of the property.*/ - virtual void setValue(const QVariant &value, bool rememberOldValue = true); + virtual void setValue(const TQVariant &value, bool rememberOldValue = true); /**@return the description of the property.*/ - virtual QString description() const; + virtual TQString description() const; /**Sets the description of the property.*/ - virtual void setDescription(const QString &description); + virtual void setDescription(const TQString &description); /**Sets the string-to-value correspondence list of the property. This is used to create comboboxes-like property editors.*/ - virtual void setValueList(const QMap<QString, QVariant> &list); + virtual void setValueList(const TQMap<TQString, TQVariant> &list); /**The string-to-value correspondence list of the property.*/ - QMap<QString, QVariant> valueList; + TQMap<TQString, TQVariant> valueList; /**Tells if the property can be saved to a stream, xml, etc. There is a possibility to use "GUI" properties that aren't @@ -160,17 +160,17 @@ public: virtual void setVisible(const bool visible); /**Gets the previous property value.*/ - virtual QVariant oldValue() const; + virtual TQVariant oldValue() const; private: // Property(Property &property) {}; // void operator=(Property &property) {}; int m_type; - QString m_name; - QString m_description; - QVariant m_value; - QVariant m_oldValue; + TQString m_name; + TQString m_description; + TQVariant m_value; + TQVariant m_oldValue; bool m_save; bool m_readOnly; bool m_visible; |