summaryrefslogtreecommitdiffstats
path: root/tools/designer/src
diff options
context:
space:
mode:
Diffstat (limited to 'tools/designer/src')
-rw-r--r--tools/designer/src/components/formeditor/brushmanagerproxy.h2
-rw-r--r--tools/designer/src/components/formeditor/qdesigner_resource.cpp6
-rw-r--r--tools/designer/src/components/formeditor/qtbrushmanager.h2
-rw-r--r--tools/designer/src/components/propertyeditor/designerpropertymanager.cpp7
-rw-r--r--tools/designer/src/components/signalsloteditor/connectdialog.ui8
-rw-r--r--tools/designer/src/designer/Info_mac.plist2
-rw-r--r--tools/designer/src/designer/designer.pro3
-rw-r--r--tools/designer/src/designer/designer.rc30
-rw-r--r--tools/designer/src/designer/mainwindow.cpp2
-rw-r--r--tools/designer/src/designer/qdesigner_workbench.cpp13
-rw-r--r--tools/designer/src/designer/uifile.icnsbin0 -> 123696 bytes
-rw-r--r--tools/designer/src/lib/sdk/abstractformwindow.cpp14
-rw-r--r--tools/designer/src/lib/sdk/script.cpp6
-rw-r--r--tools/designer/src/lib/shared/iconselector_p.h4
-rw-r--r--tools/designer/src/lib/shared/qdesigner_propertysheet.cpp28
-rw-r--r--tools/designer/src/lib/shared/qtresourceeditordialog_p.h2
-rw-r--r--tools/designer/src/lib/shared/qtresourcemodel_p.h4
-rw-r--r--tools/designer/src/lib/shared/qtresourceview_p.h4
-rw-r--r--tools/designer/src/lib/shared/widgetfactory.cpp6
-rw-r--r--tools/designer/src/lib/uilib/abstractformbuilder.cpp14
-rw-r--r--tools/designer/src/lib/uilib/formbuilder.cpp4
-rw-r--r--tools/designer/src/plugins/activeqt/qaxwidgettaskmenu.cpp2
-rw-r--r--tools/designer/src/uitools/quiloader.cpp8
-rw-r--r--tools/designer/src/uitools/quiloader.h2
24 files changed, 116 insertions, 57 deletions
diff --git a/tools/designer/src/components/formeditor/brushmanagerproxy.h b/tools/designer/src/components/formeditor/brushmanagerproxy.h
index 9314120..bfd95e5 100644
--- a/tools/designer/src/components/formeditor/brushmanagerproxy.h
+++ b/tools/designer/src/components/formeditor/brushmanagerproxy.h
@@ -64,7 +64,7 @@ public:
private:
QScopedPointer<BrushManagerProxyPrivate> d_ptr;
- Q_DECLARE_SCOPED_PRIVATE(BrushManagerProxy)
+ Q_DECLARE_PRIVATE(BrushManagerProxy)
Q_DISABLE_COPY(BrushManagerProxy)
Q_PRIVATE_SLOT(d_func(), void brushAdded(const QString &, const QBrush &))
Q_PRIVATE_SLOT(d_func(), void brushRemoved(const QString &name))
diff --git a/tools/designer/src/components/formeditor/qdesigner_resource.cpp b/tools/designer/src/components/formeditor/qdesigner_resource.cpp
index de4b57b..ac03909 100644
--- a/tools/designer/src/components/formeditor/qdesigner_resource.cpp
+++ b/tools/designer/src/components/formeditor/qdesigner_resource.cpp
@@ -631,13 +631,13 @@ static bool readUiAttributes(QIODevice *dev, QString *errorMessage,
*language = attributes.value(languageAttribute).toString();
return true;
} else {
- *errorMessage = QCoreApplication::translate("Designer", "Invalid ui file: The root element <ui> is missing.");
+ *errorMessage = QCoreApplication::translate("Designer", "Invalid UI file: The root element <ui> is missing.");
return false;
}
}
}
- *errorMessage = QCoreApplication::translate("Designer", "An error has occurred while reading the ui file at line %1, column %2: %3")
+ *errorMessage = QCoreApplication::translate("Designer", "An error has occurred while reading the UI file at line %1, column %2: %3")
.arg(reader.lineNumber()).arg(reader.columnNumber()).arg(reader.errorString());
return false;
}
@@ -756,7 +756,7 @@ void QDesignerResource::setSaveRelative(bool relative)
QWidget *QDesignerResource::create(DomUI *ui, QWidget *parentWidget)
{
// Load extra info extension. This is used by Jambi for preventing
- // C++ ui files from being loaded
+ // C++ UI files from being loaded
if (QDesignerExtraInfoExtension *extra = qt_extension<QDesignerExtraInfoExtension*>(core()->extensionManager(), core())) {
if (!extra->loadUiExtraInfo(ui)) {
const QString errorMessage = QApplication::translate("Designer", "This file cannot be read because the extra info extension failed to load.");
diff --git a/tools/designer/src/components/formeditor/qtbrushmanager.h b/tools/designer/src/components/formeditor/qtbrushmanager.h
index e6ced60..4884c577 100644
--- a/tools/designer/src/components/formeditor/qtbrushmanager.h
+++ b/tools/designer/src/components/formeditor/qtbrushmanager.h
@@ -78,7 +78,7 @@ signals:
private:
QScopedPointer<QtBrushManagerPrivate> d_ptr;
- Q_DECLARE_SCOPED_PRIVATE(QtBrushManager)
+ Q_DECLARE_PRIVATE(QtBrushManager)
Q_DISABLE_COPY(QtBrushManager)
};
diff --git a/tools/designer/src/components/propertyeditor/designerpropertymanager.cpp b/tools/designer/src/components/propertyeditor/designerpropertymanager.cpp
index fb1a5bb..ca55b15 100644
--- a/tools/designer/src/components/propertyeditor/designerpropertymanager.cpp
+++ b/tools/designer/src/components/propertyeditor/designerpropertymanager.cpp
@@ -254,8 +254,11 @@ void TextEditor::resourceActionActivated()
{
QString oldPath = m_editor->text();
if (oldPath.startsWith(QLatin1String("qrc:")))
- oldPath = oldPath.mid(4);
- const QString newPath = IconSelector::choosePixmapResource(m_core, m_core->resourceModel(), oldPath, this);
+ oldPath.remove(0, 4);
+ // returns ':/file'
+ QString newPath = IconSelector::choosePixmapResource(m_core, m_core->resourceModel(), oldPath, this);
+ if (newPath.startsWith(QLatin1Char(':')))
+ newPath.remove(0, 1);
if (newPath.isEmpty() || newPath == oldPath)
return;
const QString newText = QLatin1String("qrc:") + newPath;
diff --git a/tools/designer/src/components/signalsloteditor/connectdialog.ui b/tools/designer/src/components/signalsloteditor/connectdialog.ui
index bd062eb..568516a 100644
--- a/tools/designer/src/components/signalsloteditor/connectdialog.ui
+++ b/tools/designer/src/components/signalsloteditor/connectdialog.ui
@@ -13,7 +13,7 @@
<string>Configure Connection</string>
</property>
<layout class="QGridLayout" >
- <item row="0" column="0" colspan="2" >
+ <item row="0" column="0" >
<widget class="QGroupBox" name="signalGroupBox" >
<property name="title" >
<string>GroupBox</string>
@@ -53,7 +53,7 @@
</layout>
</widget>
</item>
- <item row="0" column="2" >
+ <item row="0" column="1" >
<widget class="QGroupBox" name="slotGroupBox" >
<property name="title" >
<string>GroupBox</string>
@@ -93,14 +93,14 @@
</layout>
</widget>
</item>
- <item row="1" column="0" >
+ <item row="1" column="0" colspan="2" >
<widget class="QCheckBox" name="showAllCheckBox" >
<property name="text" >
<string>Show signals and slots inherited from QWidget</string>
</property>
</widget>
</item>
- <item row="2" column="1" colspan="2" >
+ <item row="2" column="0" colspan="2" >
<widget class="QDialogButtonBox" name="buttonBox" >
<property name="orientation" >
<enum>Qt::Horizontal</enum>
diff --git a/tools/designer/src/designer/Info_mac.plist b/tools/designer/src/designer/Info_mac.plist
index 8632a6d..f19176f 100644
--- a/tools/designer/src/designer/Info_mac.plist
+++ b/tools/designer/src/designer/Info_mac.plist
@@ -22,7 +22,7 @@
<string>ui</string>
</array>
<key>CFBundleTypeIconFile</key>
- <string>@ICON@</string>
+ <string>uifile.icns</string>
<key>CFBundleTypeRole</key>
<string>Editor</string>
<key>LSIsAppleDefaultForType</key>
diff --git a/tools/designer/src/designer/designer.pro b/tools/designer/src/designer/designer.pro
index e7fa038..aa6850c 100644
--- a/tools/designer/src/designer/designer.pro
+++ b/tools/designer/src/designer/designer.pro
@@ -78,6 +78,9 @@ mac {
ICON = designer.icns
QMAKE_INFO_PLIST = Info_mac.plist
TARGET = Designer
+ FILETYPES.files = uifile.icns
+ FILETYPES.path = Contents/Resources
+ QMAKE_BUNDLE_DATA += FILETYPES
}
target.path=$$[QT_INSTALL_BINS]
diff --git a/tools/designer/src/designer/designer.rc b/tools/designer/src/designer/designer.rc
index 4b6324b..1f8bc0a 100644
--- a/tools/designer/src/designer/designer.rc
+++ b/tools/designer/src/designer/designer.rc
@@ -1,2 +1,32 @@
+#include "winver.h"
+
IDI_ICON1 ICON DISCARDABLE "designer.ico"
+VS_VERSION_INFO VERSIONINFO
+ FILEVERSION 1,0,0,0
+ PRODUCTVERSION 1,0,0,0
+ FILEFLAGS 0x0L
+ FILEFLAGSMASK 0x3fL
+ FILEOS 0x00040004L
+ FILETYPE 0x1L
+ FILESUBTYPE 0x0L
+BEGIN
+ BLOCK "StringFileInfo"
+ BEGIN
+ BLOCK "000004b0"
+ BEGIN
+ VALUE "CompanyName", "Nokia Corporation and/or its subsidiary(-ies)"
+ VALUE "FileDescription", "Qt Designer"
+ VALUE "FileVersion", "1.0.0.0"
+ VALUE "LegalCopyright", "Copyright (C) 2009 Nokia Corporation and/or its subsidiary(-ies)."
+ VALUE "InternalName", "designer"
+ VALUE "OriginalFilename", "designer.exe"
+ VALUE "ProductName", "Qt Designer"
+ VALUE "ProductVersion", "1.0.0.0"
+ END
+ END
+ BLOCK "VarFileInfo"
+ BEGIN
+ VALUE "Translation", 0x0, 1200
+ END
+END
diff --git a/tools/designer/src/designer/mainwindow.cpp b/tools/designer/src/designer/mainwindow.cpp
index b72a790..a3ca234 100644
--- a/tools/designer/src/designer/mainwindow.cpp
+++ b/tools/designer/src/designer/mainwindow.cpp
@@ -155,7 +155,7 @@ DockedMdiArea::DockedMdiArea(const QString &extension, QWidget *parent) :
QStringList DockedMdiArea::uiFiles(const QMimeData *d) const
{
- // Extract dropped ui files from Mime data.
+ // Extract dropped UI files from Mime data.
QStringList rc;
if (!d->hasFormat(QLatin1String(uriListMimeFormatC)))
return rc;
diff --git a/tools/designer/src/designer/qdesigner_workbench.cpp b/tools/designer/src/designer/qdesigner_workbench.cpp
index 923687a2..2ac9e1f 100644
--- a/tools/designer/src/designer/qdesigner_workbench.cpp
+++ b/tools/designer/src/designer/qdesigner_workbench.cpp
@@ -410,6 +410,12 @@ void QDesignerWorkbench::switchToDockedMode()
switchToNeutralMode();
+#ifndef Q_WS_MAC
+ QDesignerToolWindow *widgetBoxWrapper = widgetBoxToolWindow();
+ widgetBoxWrapper->action()->setVisible(true);
+ widgetBoxWrapper->setWindowTitle(tr("Widget Box"));
+#endif
+
m_mode = DockedMode;
const QDesignerSettings settings(m_core);
m_dockedMainWindow = new DockedMainWindow(this, m_toolbarMenu, m_toolWindows);
@@ -462,8 +468,6 @@ void QDesignerWorkbench::switchToTopLevelMode()
// make sure that the widgetbox is visible if it is different from neutral.
QDesignerToolWindow *widgetBoxWrapper = widgetBoxToolWindow();
Q_ASSERT(widgetBoxWrapper);
- if (!widgetBoxWrapper->action()->isChecked())
- widgetBoxWrapper->action()->trigger();
switchToNeutralMode();
const QPoint desktopOffset = desktopGeometry().topLeft();
@@ -502,9 +506,6 @@ void QDesignerWorkbench::switchToTopLevelMode()
found_visible_window |= tw->isVisible();
}
- if (!widgetBoxWrapper->action()->isChecked())
- widgetBoxWrapper->action()->trigger();
-
if (!m_toolWindows.isEmpty() && !found_visible_window)
m_toolWindows.first()->show();
@@ -960,7 +961,7 @@ QDesignerFormWindow * QDesignerWorkbench::loadForm(const QString &fileName,
removeFormWindow(formWindow);
formWindowManager->removeFormWindow(editor);
m_core->metaDataBase()->remove(editor);
- *errorMessage = tr("The file <b>%1</b> is not a valid Designer ui file.").arg(file.fileName());
+ *errorMessage = tr("The file <b>%1</b> is not a valid Designer UI file.").arg(file.fileName());
return 0;
}
*uic3Converted = editor->fileName().isEmpty();
diff --git a/tools/designer/src/designer/uifile.icns b/tools/designer/src/designer/uifile.icns
new file mode 100644
index 0000000..2473ea4
--- /dev/null
+++ b/tools/designer/src/designer/uifile.icns
Binary files differ
diff --git a/tools/designer/src/lib/sdk/abstractformwindow.cpp b/tools/designer/src/lib/sdk/abstractformwindow.cpp
index 89c1015..313b324 100644
--- a/tools/designer/src/lib/sdk/abstractformwindow.cpp
+++ b/tools/designer/src/lib/sdk/abstractformwindow.cpp
@@ -247,7 +247,7 @@ QDesignerFormWindowInterface *QDesignerFormWindowInterface::findFormWindow(QObje
/*!
\fn virtual QString QDesignerFormWindowInterface::fileName() const
- Returns the file name of the .ui file that describes the form
+ Returns the file name of the UI file that describes the form
currently being shown.
\sa setFileName()
@@ -399,11 +399,11 @@ QDesignerFormWindowInterface *QDesignerFormWindowInterface::findFormWindow(QObje
\fn virtual QStringList QDesignerFormWindowInterface::includeHints() const
Returns a list of the header files that will be included in the
- form window's associated \c .ui file.
+ form window's associated UI file.
Header files may be local, i.e. relative to the project's
- directory,\c "mywidget.h", or global, i.e. part of Qt or the
- compilers standard libraries:\c <QtGui/QWidget>.
+ directory, \c "mywidget.h", or global, i.e. part of Qt or the
+ compilers standard libraries: \c <QtGui/QWidget>.
\sa setIncludeHints()
*/
@@ -412,11 +412,11 @@ QDesignerFormWindowInterface *QDesignerFormWindowInterface::findFormWindow(QObje
\fn virtual void QDesignerFormWindowInterface::setIncludeHints(const QStringList &includeHints)
Sets the header files that will be included in the form window's
- associated \c .ui file to the specified \a includeHints.
+ associated UI file to the specified \a includeHints.
Header files may be local, i.e. relative to the project's
- directory,\c "mywidget.h", or global, i.e. part of Qt or the
- compilers standard libraries:\c <QtGui/QWidget>.
+ directory, \c "mywidget.h", or global, i.e. part of Qt or the
+ compilers standard libraries: \c <QtGui/QWidget>.
\sa includeHints()
*/
diff --git a/tools/designer/src/lib/sdk/script.cpp b/tools/designer/src/lib/sdk/script.cpp
index 90b4c73..2eda3d1 100644
--- a/tools/designer/src/lib/sdk/script.cpp
+++ b/tools/designer/src/lib/sdk/script.cpp
@@ -54,7 +54,7 @@ QT_BEGIN_NAMESPACE
\since 4.3
On saving the form, the extension is queried for a script snippet
- to be associated with the widget while saving the \c .ui file.
+ to be associated with the widget while saving the UI file.
This script is then run after creating the widget by \l uic or
QUiLoader.
@@ -66,7 +66,7 @@ QT_BEGIN_NAMESPACE
for which an editor is provided by the QDesignerTaskMenuExtension.
While saving the form, the state is serialized as a QVariantMap of
- \QD-supported properties, which is stored in the \c .ui file. This is
+ \QD-supported properties, which is stored in the UI file. This is
handled by data() and setData().
For item view contents, there might be for example a key that determines
@@ -97,7 +97,7 @@ QDesignerScriptExtension::~QDesignerScriptExtension()
\fn virtual QVariantMap QDesignerScriptExtension::data() const
Returns a map of variants describing the internal state to be
- stored in the \c .ui file.
+ stored in the UI file.
*/
/*!
diff --git a/tools/designer/src/lib/shared/iconselector_p.h b/tools/designer/src/lib/shared/iconselector_p.h
index e91a21e..9190d54 100644
--- a/tools/designer/src/lib/shared/iconselector_p.h
+++ b/tools/designer/src/lib/shared/iconselector_p.h
@@ -88,7 +88,7 @@ public:
private:
QScopedPointer<class LanguageResourceDialogPrivate> d_ptr;
- Q_DECLARE_SCOPED_PRIVATE(LanguageResourceDialog)
+ Q_DECLARE_PRIVATE(LanguageResourceDialog)
Q_DISABLE_COPY(LanguageResourceDialog)
Q_PRIVATE_SLOT(d_func(), void slotAccepted())
Q_PRIVATE_SLOT(d_func(), void slotPathChanged(QString))
@@ -121,7 +121,7 @@ signals:
void iconChanged(const PropertySheetIconValue &icon);
private:
QScopedPointer<class IconSelectorPrivate> d_ptr;
- Q_DECLARE_SCOPED_PRIVATE(IconSelector)
+ Q_DECLARE_PRIVATE(IconSelector)
Q_DISABLE_COPY(IconSelector)
Q_PRIVATE_SLOT(d_func(), void slotStateActivated())
diff --git a/tools/designer/src/lib/shared/qdesigner_propertysheet.cpp b/tools/designer/src/lib/shared/qdesigner_propertysheet.cpp
index f43b527..5b22a86 100644
--- a/tools/designer/src/lib/shared/qdesigner_propertysheet.cpp
+++ b/tools/designer/src/lib/shared/qdesigner_propertysheet.cpp
@@ -1381,6 +1381,24 @@ bool QDesignerPropertySheet::isFakeLayoutProperty(int index) const
return false;
}
+// Determine the "designable" state of a property. Properties, which have
+// a per-object boolean test function that returns false are shown in
+// disabled state ("checked" depending on "checkable", etc.)
+// Properties, which are generally not designable independent
+// of the object are not shown at all.
+enum DesignableState { PropertyIsDesignable,
+ // Object has a Designable test function that returns false.
+ PropertyOfObjectNotDesignable,
+ PropertyNotDesignable };
+
+static inline DesignableState designableState(const QDesignerMetaPropertyInterface *p, const QObject *object)
+{
+ if (p->attributes(object) & QDesignerMetaPropertyInterface::DesignableAttribute)
+ return PropertyIsDesignable;
+ return (p->attributes() & QDesignerMetaPropertyInterface::DesignableAttribute) ?
+ PropertyOfObjectNotDesignable : PropertyNotDesignable;
+}
+
bool QDesignerPropertySheet::isVisible(int index) const
{
if (d->invalidIndex(Q_FUNC_INFO, index))
@@ -1450,9 +1468,8 @@ bool QDesignerPropertySheet::isVisible(int index) const
if (!(p->accessFlags() & QDesignerMetaPropertyInterface::WriteAccess))
return false;
- // Enabled handling
- return (p->attributes(d->m_object) & QDesignerMetaPropertyInterface::DesignableAttribute) ||
- (p->attributes() & QDesignerMetaPropertyInterface::DesignableAttribute);
+ // Enabled handling: Hide only statically not designable properties
+ return designableState(p, d->m_object) != PropertyNotDesignable;
}
void QDesignerPropertySheet::setVisible(int index, bool visible)
@@ -1482,9 +1499,12 @@ bool QDesignerPropertySheet::isEnabled(int index) const
if (d->m_info.value(index).visible == true) // Sun CC 5.5 oddity, wants true
return true;
+ // Enable setting of properties for statically non-designable properties
+ // as this might be done via TaskMenu/Cursor::setProperty. Note that those
+ // properties are not visible.
const QDesignerMetaPropertyInterface *p = d->m_meta->property(index);
return (p->accessFlags() & QDesignerMetaPropertyInterface::WriteAccess) &&
- (p->attributes(d->m_object) & QDesignerMetaPropertyInterface::DesignableAttribute);
+ designableState(p, d->m_object) != PropertyOfObjectNotDesignable;
}
bool QDesignerPropertySheet::isAttribute(int index) const
diff --git a/tools/designer/src/lib/shared/qtresourceeditordialog_p.h b/tools/designer/src/lib/shared/qtresourceeditordialog_p.h
index 59c5ca6..6eac2b8 100644
--- a/tools/designer/src/lib/shared/qtresourceeditordialog_p.h
+++ b/tools/designer/src/lib/shared/qtresourceeditordialog_p.h
@@ -85,7 +85,7 @@ private:
~QtResourceEditorDialog();
QScopedPointer<class QtResourceEditorDialogPrivate> d_ptr;
- Q_DECLARE_SCOPED_PRIVATE(QtResourceEditorDialog)
+ Q_DECLARE_PRIVATE(QtResourceEditorDialog)
Q_DISABLE_COPY(QtResourceEditorDialog)
Q_PRIVATE_SLOT(d_func(), void slotQrcFileInserted(QtQrcFile *))
diff --git a/tools/designer/src/lib/shared/qtresourcemodel_p.h b/tools/designer/src/lib/shared/qtresourcemodel_p.h
index 22e98bb..e9f1c93 100644
--- a/tools/designer/src/lib/shared/qtresourcemodel_p.h
+++ b/tools/designer/src/lib/shared/qtresourcemodel_p.h
@@ -89,7 +89,7 @@ private:
friend class QtResourceModel;
QScopedPointer<class QtResourceSetPrivate> d_ptr;
- Q_DECLARE_SCOPED_PRIVATE(QtResourceSet)
+ Q_DECLARE_PRIVATE(QtResourceSet)
Q_DISABLE_COPY(QtResourceSet)
};
@@ -134,7 +134,7 @@ private:
friend class QtResourceSet;
QScopedPointer<class QtResourceModelPrivate> d_ptr;
- Q_DECLARE_SCOPED_PRIVATE(QtResourceModel)
+ Q_DECLARE_PRIVATE(QtResourceModel)
Q_DISABLE_COPY(QtResourceModel)
Q_PRIVATE_SLOT(d_func(), void slotFileChanged(const QString &))
diff --git a/tools/designer/src/lib/shared/qtresourceview_p.h b/tools/designer/src/lib/shared/qtresourceview_p.h
index 82bb8d8..0484686 100644
--- a/tools/designer/src/lib/shared/qtresourceview_p.h
+++ b/tools/designer/src/lib/shared/qtresourceview_p.h
@@ -103,7 +103,7 @@ protected:
private:
QScopedPointer<class QtResourceViewPrivate> d_ptr;
- Q_DECLARE_SCOPED_PRIVATE(QtResourceView)
+ Q_DECLARE_PRIVATE(QtResourceView)
Q_DISABLE_COPY(QtResourceView)
Q_PRIVATE_SLOT(d_func(), void slotResourceSetActivated(QtResourceSet *))
Q_PRIVATE_SLOT(d_func(), void slotCurrentPathChanged(QTreeWidgetItem *))
@@ -131,7 +131,7 @@ public:
private:
QScopedPointer<class QtResourceViewDialogPrivate> d_ptr;
- Q_DECLARE_SCOPED_PRIVATE(QtResourceViewDialog)
+ Q_DECLARE_PRIVATE(QtResourceViewDialog)
Q_DISABLE_COPY(QtResourceViewDialog)
Q_PRIVATE_SLOT(d_func(), void slotResourceSelected(const QString &))
};
diff --git a/tools/designer/src/lib/shared/widgetfactory.cpp b/tools/designer/src/lib/shared/widgetfactory.cpp
index 6c45daf..7080ed3 100644
--- a/tools/designer/src/lib/shared/widgetfactory.cpp
+++ b/tools/designer/src/lib/shared/widgetfactory.cpp
@@ -834,9 +834,11 @@ bool WidgetFactory::isPassiveInteractor(QWidget *widget)
if (isTabBarInteractor(tabBar))
m_lastWasAPassiveInteractor = true;
return m_lastWasAPassiveInteractor;
- } else if (qobject_cast<QSizeGrip*>(widget))
+#ifndef QT_NO_SIZEGRIP
+ } else if (qobject_cast<QSizeGrip*>(widget)) {
return (m_lastWasAPassiveInteractor = true);
- else if (qobject_cast<QMdiSubWindow*>(widget))
+#endif
+ } else if (qobject_cast<QMdiSubWindow*>(widget))
return (m_lastWasAPassiveInteractor = true);
else if (qobject_cast<QAbstractButton*>(widget) && (qobject_cast<QTabBar*>(widget->parent()) || qobject_cast<QToolBox*>(widget->parent())))
return (m_lastWasAPassiveInteractor = true);
diff --git a/tools/designer/src/lib/uilib/abstractformbuilder.cpp b/tools/designer/src/lib/uilib/abstractformbuilder.cpp
index 5a6e1f5..1711d43 100644
--- a/tools/designer/src/lib/uilib/abstractformbuilder.cpp
+++ b/tools/designer/src/lib/uilib/abstractformbuilder.cpp
@@ -135,7 +135,7 @@ public:
QAbstractFormBuilder provides a standard interface and a default
implementation for constructing forms from user interface
files. It is not intended to be instantiated directly. Use the
- QFormBuilder class to create user interfaces from \c{.ui} files at
+ QFormBuilder class to create user interfaces from UI files at
run-time. For example:
\snippet doc/src/snippets/code/tools_designer_src_lib_uilib_abstractformbuilder.cpp 0
@@ -145,10 +145,10 @@ public:
functions:
\list
- \o load() handles reading of \c{.ui} format files from arbitrary
+ \o load() handles reading of UI format files from arbitrary
QIODevices, and construction of widgets from the XML data
that they contain.
- \o save() handles saving of widget details in \c{.ui} format to
+ \o save() handles saving of widget details in UI format to
arbitrary QIODevices.
\o workingDirectory() and setWorkingDirectory() control the
directory in which forms are held. The form builder looks for
@@ -208,13 +208,13 @@ QWidget *QAbstractFormBuilder::load(QIODevice *dev, QWidget *parentWidget)
}
}
if (reader.hasError()) {
- uiLibWarning(QCoreApplication::translate("QAbstractFormBuilder", "An error has occurred while reading the ui file at line %1, column %2: %3")
+ uiLibWarning(QCoreApplication::translate("QAbstractFormBuilder", "An error has occurred while reading the UI file at line %1, column %2: %3")
.arg(reader.lineNumber()).arg(reader.columnNumber())
.arg(reader.errorString()));
return 0;
}
if (!initialized) {
- uiLibWarning(QCoreApplication::translate("QAbstractFormBuilder", "Invalid ui file: The root element <ui> is missing."));
+ uiLibWarning(QCoreApplication::translate("QAbstractFormBuilder", "Invalid UI file: The root element <ui> is missing."));
return 0;
}
@@ -657,7 +657,7 @@ void QAbstractFormBuilder::layoutInfo(DomLayout *ui_layout, QObject *parent, int
spac = p->elementNumber();
#ifdef Q_OS_MAC
- // here we recognize ui file < 4.3 (no we don't store margin property)
+ // here we recognize UI file < 4.3 (no we don't store margin property)
if (mar != INT_MIN) {
const int defaultMargin = parent->inherits("QLayoutWidget") ? 0 : 9;
if (mar == defaultMargin)
@@ -1202,7 +1202,7 @@ QActionGroup *QAbstractFormBuilder::createActionGroup(QObject *parent, const QSt
\fn void QAbstractFormBuilder::save(QIODevice *device, QWidget *widget)
Saves an XML representation of the given \a widget to the
- specified \a device in the standard \c{.ui} file format.
+ specified \a device in the standard UI file format.
\sa load()*/
void QAbstractFormBuilder::save(QIODevice *dev, QWidget *widget)
diff --git a/tools/designer/src/lib/uilib/formbuilder.cpp b/tools/designer/src/lib/uilib/formbuilder.cpp
index 043991e..f737311 100644
--- a/tools/designer/src/lib/uilib/formbuilder.cpp
+++ b/tools/designer/src/lib/uilib/formbuilder.cpp
@@ -57,12 +57,12 @@ namespace QFormInternal {
\class QFormBuilder
\brief The QFormBuilder class is used to dynamically construct
- user interfaces from .ui files at run-time.
+ user interfaces from UI files at run-time.
\inmodule QtDesigner
The QFormBuilder class provides a mechanism for dynamically
- creating user interfaces at run-time, based on \c{.ui} files
+ creating user interfaces at run-time, based on UI files
created with \QD. For example:
\snippet doc/src/snippets/code/tools_designer_src_lib_uilib_formbuilder.cpp 0
diff --git a/tools/designer/src/plugins/activeqt/qaxwidgettaskmenu.cpp b/tools/designer/src/plugins/activeqt/qaxwidgettaskmenu.cpp
index 1158e35..1cbf1c1 100644
--- a/tools/designer/src/plugins/activeqt/qaxwidgettaskmenu.cpp
+++ b/tools/designer/src/plugins/activeqt/qaxwidgettaskmenu.cpp
@@ -162,7 +162,7 @@ void QAxWidgetTaskMenu::setActiveXControl()
tr("The control requires a design-time license"));
clsid = QUuid();
} else {
- key = QString::fromUtf16((ushort *)bKey);
+ key = QString::fromWCharArray(bKey);
}
cf2->Release();
diff --git a/tools/designer/src/uitools/quiloader.cpp b/tools/designer/src/uitools/quiloader.cpp
index 83d3089..260e9bd 100644
--- a/tools/designer/src/uitools/quiloader.cpp
+++ b/tools/designer/src/uitools/quiloader.cpp
@@ -574,20 +574,20 @@ void QUiLoaderPrivate::setupWidgetMap() const
\brief The QUiLoader class enables standalone applications to
dynamically create user interfaces at run-time using the
- information stored in .ui files or specified in plugin paths.
+ information stored in UI files or specified in plugin paths.
In addition, you can customize or create your own user interface by
deriving your own loader class.
If you have a custom component or an application that embeds \QD, you can
also use the QFormBuilder class provided by the QtDesigner module to create
- user interfaces from \c{.ui} files.
+ user interfaces from UI files.
The QUiLoader class provides a collection of functions allowing you to
- create widgets based on the information stored in \c .ui files (created
+ create widgets based on the information stored in UI files (created
with \QD) or available in the specified plugin paths. The specified plugin
paths can be retrieved using the pluginPaths() function. Similarly, the
- contents of a \c{.ui} file can be retrieved using the load() function. For
+ contents of a UI file can be retrieved using the load() function. For
example:
\snippet doc/src/snippets/quiloader/mywidget.cpp 0
diff --git a/tools/designer/src/uitools/quiloader.h b/tools/designer/src/uitools/quiloader.h
index 7f718a6..40b5010 100644
--- a/tools/designer/src/uitools/quiloader.h
+++ b/tools/designer/src/uitools/quiloader.h
@@ -92,7 +92,7 @@ public:
private:
QScopedPointer<QUiLoaderPrivate> d_ptr;
- Q_DECLARE_SCOPED_PRIVATE(QUiLoader)
+ Q_DECLARE_PRIVATE(QUiLoader)
Q_DISABLE_COPY(QUiLoader)
};