diff options
Diffstat (limited to 'kexi/formeditor/widgetpropertyset.cpp')
-rw-r--r-- | kexi/formeditor/widgetpropertyset.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/kexi/formeditor/widgetpropertyset.cpp b/kexi/formeditor/widgetpropertyset.cpp index 5ed8f96d..8d7d7daf 100644 --- a/kexi/formeditor/widgetpropertyset.cpp +++ b/kexi/formeditor/widgetpropertyset.cpp @@ -253,7 +253,7 @@ WidgetPropertySet::addWidget(TQWidget *w) //second widget, update metainfo d->set["this:className"].setValue("special:multiple"); d->set["this:classString"].setValue( - i18n("Multiple Widgets") + TQString(" (%1)").tqarg(d->widgets.count()) ); + i18n("Multiple Widgets") + TQString(" (%1)").arg(d->widgets.count()) ); d->set["this:iconName"].setValue("multiple_obj"); //name doesn't make sense for now d->set["name"].setValue(""); @@ -328,7 +328,7 @@ WidgetPropertySet::createPropertiesForWidget(TQWidget *w) const bool oldValueExists = modifiedPropertiesIt!=modifiedProperties->constEnd(); if(meta->isEnumType()) { - if(qstrcmp(propertyName, "tqalignment") == 0) { + if(qstrcmp(propertyName, "alignment") == 0) { createAlignProperty(meta, w, subwidget); continue; } @@ -678,7 +678,7 @@ WidgetPropertySet::isNameValid(const TQString &name) KMessageBox::sorry(KFormDesigner::FormManager::self()->activeForm()->widget(), i18n("Could not rename widget \"%1\" to \"%2\" because " "\"%3\" is not a valid name (identifier) for a widget.\n") - .tqarg(w->name()).tqarg(name).tqarg(name)); + .arg(w->name()).arg(name).arg(name)); d->slotPropertyChangedEnabled = false; d->set["name"].resetValue(); d->slotPropertyChangedEnabled = true; @@ -689,7 +689,7 @@ WidgetPropertySet::isNameValid(const TQString &name) KMessageBox::sorry( KFormDesigner::FormManager::self()->activeForm()->widget(), i18n("Could not rename widget \"%1\" to \"%2\" " "because a widget with the name \"%3\" already exists.\n") - .tqarg(w->name()).tqarg(name).tqarg(name)); + .arg(w->name()).arg(name).arg(name)); d->slotPropertyChangedEnabled = false; d->set["name"].resetValue(); d->slotPropertyChangedEnabled = true; @@ -740,7 +740,7 @@ WidgetPropertySet::eventFilter(TQObject *o, TQEvent *ev) if(d->set["geometry"].value() == o->property("geometry")) // to avoid infinite recursion return false; - d->set["geometry"] = TQT_TQWIDGET(o)->tqgeometry(); + d->set["geometry"] = TQT_TQWIDGET(o)->geometry(); } } else if(d->widgets.count() > 1 && ev->type() == TQEvent::Move) // the widget is being moved, we update the property @@ -775,8 +775,8 @@ WidgetPropertySet::createAlignProperty(const TQMetaProperty *meta, TQWidget *wid TQStringList list; TQString value; - const int tqalignment = subwidget->property("tqalignment").toInt(); - const TQStringList keys( TQStringList::fromStrList( meta->valueToKeys(tqalignment) ) ); + const int alignment = subwidget->property("alignment").toInt(); + const TQStringList keys( TQStringList::fromStrList( meta->valueToKeys(alignment) ) ); TQStrList *enumKeys = new TQStrList(meta->enumKeys()); const TQStringList possibleValues( TQStringList::fromStrList(*enumKeys) ); @@ -786,7 +786,7 @@ WidgetPropertySet::createAlignProperty(const TQMetaProperty *meta, TQWidget *wid bool isTopLevel = KFormDesigner::FormManager::self()->isTopLevel(widget); if(possibleValues.find("AlignHCenter")!=possibleValues.constEnd()) { - // Create the horizontal tqalignment property + // Create the horizontal alignment property if(keys.find("AlignHCenter")!=keys.constEnd() || keys.find("AlignCenter")!=keys.constEnd()) value = "AlignHCenter"; else if(keys.find("AlignRight")!=keys.constEnd()) @@ -812,7 +812,7 @@ WidgetPropertySet::createAlignProperty(const TQMetaProperty *meta, TQWidget *wid if(possibleValues.find("AlignTop")!=possibleValues.constEnd()) { - // Create the ver tqalignment property + // Create the ver alignment property if(keys.find("AlignTop")!=keys.constEnd()) value = "AlignTop"; else if(keys.find("AlignBottom")!=keys.constEnd()) @@ -837,7 +837,7 @@ WidgetPropertySet::createAlignProperty(const TQMetaProperty *meta, TQWidget *wid ) { // Create the wordbreak property KoProperty::Property *p = new KoProperty::Property("wordbreak", - TQVariant(tqalignment & TQt::WordBreak, 3), i18n("Word Break"), i18n("Word Break") ); + TQVariant(alignment & TQt::WordBreak, 3), i18n("Word Break"), i18n("Word Break") ); d->set.addProperty(p); updatePropertyValue(tree, "wordbreak"); if (!KFormDesigner::FormManager::self()->activeForm()->library()->isPropertyVisible( @@ -865,9 +865,9 @@ WidgetPropertySet::saveAlignProperty(const TQString &property) WidgetWithSubpropertiesInterface* subpropIface = dynamic_cast<WidgetWithSubpropertiesInterface*>( (TQWidget*)d->widgets.first() ); TQWidget *subwidget = (subpropIface && subpropIface->subwidget()) ? subpropIface->subwidget() : (TQWidget*)d->widgets.first(); - int count = subwidget->metaObject()->findProperty("tqalignment", true); + int count = subwidget->metaObject()->findProperty("alignment", true); const TQMetaProperty *meta = subwidget->metaObject()->property(count, true); - subwidget->setProperty("tqalignment", meta->keysToValue(list)); + subwidget->setProperty("alignment", meta->keysToValue(list)); ObjectTreeItem *tree = KFormDesigner::FormManager::self()->activeForm()->objectTree()->lookup( d->widgets.first()->name() ); @@ -877,11 +877,11 @@ WidgetPropertySet::saveAlignProperty(const TQString &property) if(d->isUndoing) return; - if(d->lastCommand && d->lastCommand->property() == "tqalignment") + if(d->lastCommand && d->lastCommand->property() == "alignment") d->lastCommand->setValue(meta->keysToValue(list)); else { d->lastCommand = new PropertyCommand(this, d->widgets.first()->name(), - subwidget->property("tqalignment"), meta->keysToValue(list), "tqalignment"); + subwidget->property("alignment"), meta->keysToValue(list), "alignment"); KFormDesigner::FormManager::self()->activeForm()->addCommand(d->lastCommand, false); } } |