summaryrefslogtreecommitdiffstats
path: root/kexi/formeditor/objecttree.h
diff options
context:
space:
mode:
Diffstat (limited to 'kexi/formeditor/objecttree.h')
-rw-r--r--kexi/formeditor/objecttree.h110
1 files changed, 55 insertions, 55 deletions
diff --git a/kexi/formeditor/objecttree.h b/kexi/formeditor/objecttree.h
index 252ee54c..ca301f4d 100644
--- a/kexi/formeditor/objecttree.h
+++ b/kexi/formeditor/objecttree.h
@@ -22,15 +22,15 @@
#ifndef KFORMDESIGNEROBJECTTREE_H
#define KFORMDESIGNEROBJECTTREE_H
-#include <qptrlist.h>
-#include <qmap.h>
-#include <qdict.h>
-#include <qvariant.h>
-#include <qstring.h>
-#include <qguardedptr.h>
+#include <tqptrlist.h>
+#include <tqmap.h>
+#include <tqdict.h>
+#include <tqvariant.h>
+#include <tqstring.h>
+#include <tqguardedptr.h>
-class QWidget;
-class QDomElement;
+class TQWidget;
+class TQDomElement;
namespace KFormDesigner {
@@ -39,53 +39,53 @@ class Container;
class EventEater;
//! @short An list of ObjectTreeItem pointers.
-typedef QPtrList<ObjectTreeItem> ObjectTreeList;
+typedef TQPtrList<ObjectTreeItem> ObjectTreeList;
//! @short An iterator for ObjectTreeList.
-typedef QPtrListIterator<ObjectTreeItem> ObjectTreeListIterator;
+typedef TQPtrListIterator<ObjectTreeItem> ObjectTreeListIterator;
-//! @short A QString-based disctionary of ObjectTreeItem pointers.
-typedef QDict<ObjectTreeItem> ObjectTreeDict;
+//! @short A TQString-based disctionary of ObjectTreeItem pointers.
+typedef TQDict<ObjectTreeItem> ObjectTreeDict;
//! @short An iterator for ObjectTreeDict.
-typedef QDictIterator<ObjectTreeItem> ObjectTreeDictIterator;
+typedef TQDictIterator<ObjectTreeItem> ObjectTreeDictIterator;
-//! @short A QString -> QVarinat map.
-typedef QMap<QString, QVariant> QVariantMap;
+//! @short A TQString -> TQVarinat map.
+typedef TQMap<TQString, TQVariant> TQVariantMap;
-//! @short A const iterator for QVariantMap.
-typedef QMapConstIterator<QString, QVariant> QVariantMapConstIterator;
+//! @short A const iterator for TQVariantMap.
+typedef TQMapConstIterator<TQString, TQVariant> TQVariantMapConstIterator;
/*!
@short An item representing a widget
- Holds the properties of a widget (classname, name, parent, children ..).
+ Holds the properties of a widget (classname, name, tqparent, tqchildren ..).
@author Lucijan Busch <[email protected]>
*/
class KFORMEDITOR_EXPORT ObjectTreeItem
{
public:
- ObjectTreeItem(const QString &className, const QString &name, QWidget *widget, Container *parentContainer, Container *container=0);
+ ObjectTreeItem(const TQString &className, const TQString &name, TQWidget *widget, Container *tqparentContainer, Container *container=0);
virtual ~ObjectTreeItem();
- QString name() const { return m_name; }
- QString className() const { return m_className; }
- QWidget* widget() const { return m_widget; }
+ TQString name() const { return m_name; }
+ TQString className() const { return m_className; }
+ TQWidget* widget() const { return m_widget; }
EventEater* eventEater() const { return m_eater; }
- ObjectTreeItem* parent() const { return m_parent; }
- ObjectTreeList* children() { return &m_children; }
+ ObjectTreeItem* tqparent() const { return m_parent; }
+ ObjectTreeList* tqchildren() { return &m_tqchildren; }
- /*! \return a QMap<QString, QVariant> of all modified properties for this widget.
- The QVariant is the old value (ie first value) of the property whose name is the QString. */
- const QVariantMap* modifiedProperties() const { return &m_props;}
+ /*! \return a TQMap<TQString, TQVariant> of all modified properties for this widget.
+ The TQVariant is the old value (ie first value) of the property whose name is the TQString. */
+ const TQVariantMap* modifiedProperties() const { return &m_props;}
//! \return the widget's Container, or 0 if the widget is not a Container.
Container* container() const { return m_container;}
- void setWidget(QWidget *w) { m_widget = w; }
- void setParent(ObjectTreeItem *parent) { m_parent = parent;}
+ void setWidget(TQWidget *w) { m_widget = w; }
+ void setParent(ObjectTreeItem *tqparent) { m_parent = tqparent;}
void debug(int ident);
- void rename(const QString &name);
+ void rename(const TQString &name);
void addChild(ObjectTreeItem *it);
void removeChild(ObjectTreeItem *it);
@@ -93,20 +93,20 @@ class KFORMEDITOR_EXPORT ObjectTreeItem
/*! Adds \a property in the list of the modified properties for this object.
These modified properties are written in the .ui files when saving the form.
*/
- void addModifiedProperty(const QCString &property, const QVariant &oldValue);
- void storeUnknownProperty(QDomElement &el);
+ void addModifiedProperty(const TQCString &property, const TQVariant &oldValue);
+ void storeUnknownProperty(TQDomElement &el);
/*! Adds subproperty \a property value \a value (a property of subwidget).
Remembering it for delayed setting is needed because on loading
the subwidget could be not created yet (true e.g. for KexiDBAutoField). */
- void addSubproperty(const QCString &property, const QVariant& value);
+ void addSubproperty(const TQCString &property, const TQVariant& value);
/*! \return subproperties for this item, added by addSubproperty()
or 0 is there are no subproperties. */
- QMap<QString, QVariant>* subproperties() const { return m_subprops; }
+ TQMap<TQString, TQVariant>* subproperties() const { return m_subprops; }
- void setPixmapName(const QCString &property, const QString &name);
- QString pixmapName(const QCString &property);
+ void setPixmapName(const TQCString &property, const TQString &name);
+ TQString pixmapName(const TQCString &property);
void setEnabled(bool enabled) { m_enabled = enabled; }
bool isEnabled() const { return m_enabled; }
@@ -119,17 +119,17 @@ class KFORMEDITOR_EXPORT ObjectTreeItem
void setGridPos(int row, int col, int rowspan, int colspan);
protected:
- QString m_className;
- QString m_name;
- ObjectTreeList m_children;
- QGuardedPtr<Container> m_container;
- QMap<QString, QVariant> m_props;
- QMap<QString, QVariant> *m_subprops;
- QString m_unknownProps;
- QMap<QCString, QString> m_pixmapNames;
+ TQString m_className;
+ TQString m_name;
+ ObjectTreeList m_tqchildren;
+ TQGuardedPtr<Container> m_container;
+ TQMap<TQString, TQVariant> m_props;
+ TQMap<TQString, TQVariant> *m_subprops;
+ TQString m_unknownProps;
+ TQMap<TQCString, TQString> m_pixmapNames;
ObjectTreeItem* m_parent;
- QGuardedPtr<QWidget> m_widget;
- QGuardedPtr<EventEater> m_eater;
+ TQGuardedPtr<TQWidget> m_widget;
+ TQGuardedPtr<EventEater> m_eater;
bool m_enabled;
@@ -145,25 +145,25 @@ class KFORMEDITOR_EXPORT ObjectTreeItem
class KFORMEDITOR_EXPORT ObjectTree : public ObjectTreeItem
{
public:
- ObjectTree(const QString &className=QString::null, const QString &name=QString::null,
- QWidget *widget=0, Container *container=0);
+ ObjectTree(const TQString &className=TQString(), const TQString &name=TQString(),
+ TQWidget *widget=0, Container *container=0);
virtual ~ObjectTree();
/*! Renames the item named \a oldname to \a newname. \return false if widget named \a newname
already exists and renaming failed. */
- bool rename(const QString &oldname, const QString &newname );
- /*! Sets \a newparent as new parent for the item whose name is \a name. */
- bool reparent(const QString &name, const QString &newparent);
+ bool rename(const TQString &oldname, const TQString &newname );
+ /*! Sets \a newtqparent as new tqparent for the item whose name is \a name. */
+ bool reparent(const TQString &name, const TQString &newtqparent);
/*! \return the ObjectTreeItem named \a name, or 0 if doesn't exist. */
- ObjectTreeItem* lookup(const QString &name);
+ ObjectTreeItem* lookup(const TQString &name);
/*! \return a dict containing all ObjectTreeItem in this ObjectTree. If you want to iterate on
this dict, use ObjectTreeDictIterator. */
ObjectTreeDict* dict() { return &m_treeDict; }
- void addItem(ObjectTreeItem *parent, ObjectTreeItem *c);
- void removeItem(const QString &name);
+ void addItem(ObjectTreeItem *tqparent, ObjectTreeItem *c);
+ void removeItem(const TQString &name);
void removeItem(ObjectTreeItem *c);
/*! Generates a new, unique name for a new widget using prefix \a prefix
@@ -173,7 +173,7 @@ class KFORMEDITOR_EXPORT ObjectTree : public ObjectTreeItem
If \a numberSuffixRequired is false and there's a widget prefix \a prefix,
then \a prefix is returned (e.g. if \a prefix is "lineEdit", and "lineEdit" doesn't exist yet,
"lineEdit" is returned). */
- QCString generateUniqueName(const QCString &prefix, bool numberSuffixRequired = true);
+ TQCString generateUniqueName(const TQCString &prefix, bool numberSuffixRequired = true);
private:
ObjectTreeDict m_treeDict;