summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorThomas Hartmann <Thomas.Hartmann@digia.com>2012-11-21 16:42:09 +0100
committerThomas Hartmann <Thomas.Hartmann@digia.com>2012-11-21 17:51:37 +0100
commit4080f940f9080b46dfebe3746c8ad224b14b69e0 (patch)
tree15d03bd6247f4bdeda01680e524c68a55c2ad194
parent8629043061f09d3bb2b95b2a075d271b6d36ba7f (diff)
downloadqt-creator-4080f940f9080b46dfebe3746c8ad224b14b69e0.tar.gz
QmlDesigner.ItemLibrary: replace XML item data with QML
Since we provide a tool for QML we should also use QML instead of XML. This is also more consistent in regard to .qmltype files. Change-Id: I61c5a2354acac5d3fe41da5f1d92ae3bd8505bc5 Reviewed-by: Marco Bubke <marco.bubke@digia.com>
-rw-r--r--src/plugins/qmldesigner/designercore/include/metainfoparser.h71
-rw-r--r--src/plugins/qmldesigner/designercore/metainfo/metainfo.cpp18
-rw-r--r--src/plugins/qmldesigner/designercore/metainfo/metainfoparser.cpp361
-rw-r--r--src/plugins/qmldesigner/desktopplugin/desktop.metainfo522
-rw-r--r--src/plugins/qmldesigner/qtquickplugin/quick.metainfo654
5 files changed, 1123 insertions, 503 deletions
diff --git a/src/plugins/qmldesigner/designercore/include/metainfoparser.h b/src/plugins/qmldesigner/designercore/include/metainfoparser.h
index 2a7141175b..beb8e23adb 100644
--- a/src/plugins/qmldesigner/designercore/include/metainfoparser.h
+++ b/src/plugins/qmldesigner/designercore/include/metainfoparser.h
@@ -31,10 +31,13 @@
#define METAINFOPARSER_H
#include "qmldesignercorelib_global.h"
-#include <QXmlStreamReader>
+#include <metainfo.h>
+
+#include <qmljs/qmljssimplereader.h>
+
#include <QString>
#include <QFile>
-#include <metainfo.h>
+
namespace QmlDesigner {
@@ -43,25 +46,69 @@ class ItemLibraryEntry;
namespace Internal {
-class QMLDESIGNERCORE_EXPORT MetaInfoParser
+class MetaInfoParser : protected QmlJS::SimpleAbstractStreamReader
{
+ Q_DECLARE_TR_FUNCTIONS(QmlDesigner::Internal::MetaInfoParser)
+
public:
MetaInfoParser(const MetaInfo &metaInfo);
- void parseFile(const QString &path);
+ void readMetaInfoFile(const QString &path);
+
+
+ QStringList errors();
protected:
- void errorHandling(QXmlStreamReader &reader, QFile &file);
- void tokenHandler(QXmlStreamReader &reader);
- void metaInfoHandler(QXmlStreamReader &reader);
- void handleMetaInfoElement(QXmlStreamReader &reader);
- void handleNodeElement(QXmlStreamReader &reader);
- void handleNodeItemLibraryEntryElement(QXmlStreamReader &reader, const QString &className, const QIcon &icon);
- void handleItemLibraryEntryPropertyElement(QXmlStreamReader &reader, ItemLibraryEntry &itemLibraryEntry);
- void handleItemLibraryEntryQmlElement(QXmlStreamReader &reader, ItemLibraryEntry &itemLibraryEntry);
+ virtual void elementStart(const QString &name);
+ virtual void elementEnd();
+ virtual void propertyDefinition(const QString &name, const QVariant &value);
private:
+ enum ParserSate { Error,
+ Finished,
+ Undefined,
+ ParsingDocument,
+ ParsingMetaInfo,
+ ParsingType,
+ ParsingItemLibrary,
+ ParsingProperty,
+ ParsingQmlSource
+ };
+
+ ParserSate readDocument(const QString &name);
+
+ ParserSate readMetaInfoRootElement(const QString &name);
+ ParserSate readTypeElement(const QString &name);
+ ParserSate readItemLibraryEntryElement(const QString &name);
+ ParserSate readPropertyElement(const QString &name);
+ ParserSate readQmlSourceElement(const QString &name);
+
+ void readTypeProperty(const QString &name, const QVariant &value);
+ void readItemLibraryEntryProperty(const QString &name, const QVariant &value);
+ void readPropertyProperty(const QString &name, const QVariant &value);
+ void readQmlSourceProperty(const QString &name, const QVariant &value);
+
+ void setVersion(const QString &versionNumber);
+
+ ParserSate parserState() const;
+ void setParserState(ParserSate newParserState);
+
+ void insertItemLibraryEntry();
+ void insertProperty();
+
+ void addErrorInvalidType(const QString &typeName);
+
+ ParserSate m_parserState;
MetaInfo m_metaInfo;
+
+ QString m_currentClassName;
+ QString m_currentIcon;
+ QString m_currentSource;
+ ItemLibraryEntry m_currentEntry;
+
+ QString m_currentPropertyName;
+ QString m_currentPropertyType;
+ QVariant m_currentPropertyValue;
};
}
diff --git a/src/plugins/qmldesigner/designercore/metainfo/metainfo.cpp b/src/plugins/qmldesigner/designercore/metainfo/metainfo.cpp
index a40d5747ff..5949dcba21 100644
--- a/src/plugins/qmldesigner/designercore/metainfo/metainfo.cpp
+++ b/src/plugins/qmldesigner/designercore/metainfo/metainfo.cpp
@@ -38,7 +38,9 @@
#include "pluginmanager/widgetpluginmanager.h"
+
#include <QDebug>
+#include <QMessageBox>
#include <QPair>
#include <QtAlgorithms>
@@ -62,7 +64,7 @@ public:
void initialize();
- void parseXmlFiles();
+ void parseItemLibraryDescriptions();
QScopedPointer<ItemLibraryInfo> m_itemLibraryInfo;
@@ -87,7 +89,7 @@ void MetaInfoPrivate::clear()
void MetaInfoPrivate::initialize()
{
- parseXmlFiles();
+ parseItemLibraryDescriptions();
m_isInitialized = true;
}
@@ -107,7 +109,7 @@ static inline bool isDepricatedQtType(const QString &typeName)
return typeName.contains("Qt.");
}
-void MetaInfoPrivate::parseXmlFiles()
+void MetaInfoPrivate::parseItemLibraryDescriptions()
{
Internal::WidgetPluginManager pluginManager;
foreach (const QString &pluginDir, m_q->s_pluginDirs)
@@ -115,7 +117,15 @@ void MetaInfoPrivate::parseXmlFiles()
QList<IWidgetPlugin *> widgetPluginList = pluginManager.instances();
foreach (IWidgetPlugin *plugin, widgetPluginList) {
Internal::MetaInfoParser parser(*m_q);
- parser.parseFile(plugin->metaInfo());
+ try {
+ parser.readMetaInfoFile(plugin->metaInfo());
+ } catch (InvalidMetaInfoException &e) {
+ qWarning() << e.description();
+ const QString errorMessage = plugin->metaInfo() + QLatin1Char('\n') + QLatin1Char('\n') + parser.errors().join(QLatin1String("\n"));
+ QMessageBox::critical(0,
+ QCoreApplication::translate("QmlDesigner::Internal::MetaInfoPrivate", "Invalid meta info"),
+ errorMessage);
+ }
}
}
diff --git a/src/plugins/qmldesigner/designercore/metainfo/metainfoparser.cpp b/src/plugins/qmldesigner/designercore/metainfo/metainfoparser.cpp
index ab6eb6e35c..bedee850c7 100644
--- a/src/plugins/qmldesigner/designercore/metainfo/metainfoparser.cpp
+++ b/src/plugins/qmldesigner/designercore/metainfo/metainfoparser.cpp
@@ -40,206 +40,275 @@
namespace QmlDesigner {
namespace Internal {
+enum {
+ debug = false
+};
+
+const char rootElementName[] = "MetaInfo";
+const char typeElementName[] = "Type";
+const char ItemLibraryEntryElementName[] = "ItemLibraryEntry";
+const char QmlSourceElementName[] = "QmlSource";
+const char PropertyElementName[] = "Property";
MetaInfoParser::MetaInfoParser(const MetaInfo &metaInfo)
- : m_metaInfo(metaInfo)
+ : m_parserState(Undefined),
+ m_metaInfo(metaInfo)
{
}
-void MetaInfoParser::parseFile(const QString &path)
+void MetaInfoParser::readMetaInfoFile(const QString &path)
{
- QFile file;
- file.setFileName(path);
- if (!file.open(QIODevice::ReadOnly))
- throw new InvalidMetaInfoException(__LINE__, __FUNCTION__, __FILE__);
-
- QXmlStreamReader reader;
- reader.setDevice(&file);
+ m_parserState = ParsingDocument;
+ if (!SimpleAbstractStreamReader::readFile(path)) {
+ qWarning() << "readMetaInfoFile()" << path;
+ qWarning() << errors();
+ m_parserState = Error;
+ throw InvalidMetaInfoException(__LINE__, __FUNCTION__, __FILE__);
+ }
- while (!reader.atEnd()) {
- reader.readNext();
- tokenHandler(reader);
+ if (!errors().isEmpty()) {
+ qWarning() << "readMetaInfoFile()" << path;
+ qWarning() << errors();
+ m_parserState = Error;
+ throw InvalidMetaInfoException(__LINE__, __FUNCTION__, __FILE__);
}
- errorHandling(reader, file);
}
-void MetaInfoParser::tokenHandler(QXmlStreamReader &reader)
+QStringList MetaInfoParser::errors()
{
- if (reader.isStartElement() && reader.name() == "metainfo")
- handleMetaInfoElement(reader);
+ return QmlJS::SimpleAbstractStreamReader::errors();
}
-void MetaInfoParser::handleMetaInfoElement(QXmlStreamReader &reader)
+void MetaInfoParser::elementStart(const QString &name)
{
- while (!reader.atEnd() && !(reader.isEndElement() && reader.name() == "metainfo")) {
- reader.readNext();
- metaInfoHandler(reader);
+ switch (parserState()) {
+ case ParsingDocument: setParserState(readDocument(name)); break;
+ case ParsingMetaInfo: setParserState(readMetaInfoRootElement(name)); break;
+ case ParsingType: setParserState(readTypeElement(name)); break;
+ case ParsingItemLibrary: setParserState(readItemLibraryEntryElement(name)); break;
+ case ParsingProperty: setParserState(readPropertyElement(name)); break;
+ case ParsingQmlSource: setParserState(readQmlSourceElement(name)); break;
+ case Finished: setParserState(Error);
+ case Undefined: setParserState(Error);
+ addError(tr("Illegal state while parsing"), currentSourceLocation());
+ case Error:
+ default: return;
}
}
-void MetaInfoParser::metaInfoHandler(QXmlStreamReader &reader)
+void MetaInfoParser::elementEnd()
{
- if (reader.isStartElement())
- {
- if (reader.name() == "node")
- handleNodeElement(reader);
+ switch (parserState()) {
+ case ParsingMetaInfo: setParserState(ParsingDocument); break;
+ case ParsingType: setParserState(ParsingMetaInfo); break;
+ case ParsingItemLibrary: insertItemLibraryEntry(); setParserState((ParsingType)); break;
+ case ParsingProperty: insertProperty(); setParserState(ParsingItemLibrary); break;
+ case ParsingQmlSource: setParserState(ParsingItemLibrary); break;
+ case ParsingDocument: setParserState(Finished);
+ case Finished: setParserState(Error);
+ case Undefined: setParserState(Error);
+ addError(tr("Illegal state while parsing"), currentSourceLocation());
+ case Error:
+ default: return;
}
}
-void MetaInfoParser::handleNodeElement(QXmlStreamReader &reader)
+void MetaInfoParser::propertyDefinition(const QString &name, const QVariant &value)
{
- const QXmlStreamAttributes attributes = reader.attributes();
-
- const QString className = attributes.value("name").toString();
- const QIcon icon = QIcon(attributes.value("icon").toString());
-
- if (className.isEmpty()) {
- reader.raiseError("Invalid element 'node' - mandatory attribute 'name' is missing");
- return;
+ switch (parserState()) {
+ case ParsingType: readTypeProperty(name, value); break;
+ case ParsingItemLibrary: readItemLibraryEntryProperty(name, value); break;
+ case ParsingProperty: readPropertyProperty(name, value); break;
+ case ParsingQmlSource: readQmlSourceProperty(name, value); break;
+ case ParsingMetaInfo: addError(tr("No property definition allowed"), currentSourceLocation()); break;
+ case ParsingDocument:
+ case Finished:
+ case Undefined: setParserState(Error);
+ addError(tr("Illegal state while parsing"), currentSourceLocation());
+ case Error:
+ default: return;
}
+}
- while (!reader.atEnd() && !(reader.isEndElement() && reader.name() == "node")) {
- reader.readNext();
-
- handleNodeItemLibraryEntryElement(reader, className, icon);
+MetaInfoParser::ParserSate MetaInfoParser::readDocument(const QString &name)
+{
+ if (name == QLatin1String(rootElementName)) {
+ m_currentClassName = QString();
+ m_currentIcon = QString();
+ return ParsingMetaInfo;
+ } else {
+ addErrorInvalidType(name);
+ return Error;
}
}
-void MetaInfoParser::handleNodeItemLibraryEntryElement(QXmlStreamReader &reader, const QString &className, const QIcon &icon)
+MetaInfoParser::ParserSate MetaInfoParser::readMetaInfoRootElement(const QString &name)
{
- if (reader.isStartElement() && reader.name() == "itemlibraryentry")
- {
- const QString versionNumber = reader.attributes().value("version").toString();
-
- int major = 1;
- int minor = 0;
-
- if (!versionNumber.isEmpty()) {
- int val;
- bool ok;
- if (versionNumber.contains('.')) {
- val = versionNumber.split('.').first().toInt(&ok);
- major = ok ? val : major;
- val = versionNumber.split('.').last().toInt(&ok);
- minor = ok ? val : minor;
- } else {
- val = versionNumber.toInt(&ok);
- major = ok ? val : major;
- }
- }
-
- const QString name = reader.attributes().value("name").toString();
-
- ItemLibraryEntry entry;
- entry.setType(className, major, minor);
- entry.setName(name);
- entry.setIcon(icon);
-
- QString iconPath = reader.attributes().value("libraryIcon").toString();
- if (!iconPath.isEmpty())
- entry.setIconPath(iconPath);
+ if (name == QLatin1String(typeElementName)) {
+ m_currentClassName = QString();
+ m_currentIcon = QString();
+ return ParsingType;
+ } else {
+ addErrorInvalidType(name);
+ return Error;
+ }
+}
- QString category = reader.attributes().value("category").toString();
- if (!category.isEmpty())
- entry.setCategory(category);
+MetaInfoParser::ParserSate MetaInfoParser::readTypeElement(const QString &name)
+{
+ if (name == QLatin1String(ItemLibraryEntryElementName)) {
+ m_currentEntry = ItemLibraryEntry();
+ m_currentEntry.setForceImport(false);
+ m_currentEntry.setType(m_currentClassName, -1, -1);
+ m_currentEntry.setIcon(QIcon(m_currentIcon));
+ return ParsingItemLibrary;
+ } else {
+ addErrorInvalidType(name);
+ return Error;
+ }
+}
- QString requiredImport = reader.attributes().value("requiredImport").toString();
- if (!requiredImport.isEmpty())
- entry.setRequiredImport(requiredImport);
+MetaInfoParser::ParserSate MetaInfoParser::readItemLibraryEntryElement(const QString &name)
+{
+ if (name == QmlSourceElementName) {
+ return ParsingQmlSource;
+ } else if (name == PropertyElementName) {
+ m_currentPropertyName = QString();
+ m_currentPropertyType = QString();
+ m_currentPropertyValue = QVariant();
+ return ParsingProperty;
+ } else {
+ addError(tr("Invalid type %1").arg(name), currentSourceLocation());
+ return Error;
+ }
+}
- if (reader.attributes().hasAttribute("forceImport")) {
- QString forceImport = reader.attributes().value("forceImport").toString();
- if (forceImport == QLatin1String("true") || forceImport == QLatin1String("True"))
- entry.setForceImport(true);
- else
- entry.setForceImport(false);
- } else {
- entry.setForceImport(false);
- }
+MetaInfoParser::ParserSate MetaInfoParser::readPropertyElement(const QString &name)
+{
+ addError(tr("Invalid type %1").arg(name), currentSourceLocation());
+ return Error;
+}
- while (!reader.atEnd() && !(reader.isEndElement() && reader.name() == "itemlibraryentry")) {
- reader.readNext();
- handleItemLibraryEntryPropertyElement(reader, entry);
- handleItemLibraryEntryQmlElement(reader, entry);
- }
+MetaInfoParser::ParserSate MetaInfoParser::readQmlSourceElement(const QString &name)
+{
+ addError(tr("Invalid type %1").arg(name), currentSourceLocation());
+ return Error;
+}
- m_metaInfo.itemLibraryInfo()->addEntry(entry);
+void MetaInfoParser::readTypeProperty(const QString &name, const QVariant &value)
+{
+ if (name == QLatin1String("name")) {
+ m_currentClassName = value.toString();
+ } else if (name == QLatin1String("icon")) {
+ m_currentIcon = value.toString();
+ } else {
+ addError(tr("Unknown property for Type %1").arg(name), currentSourceLocation());
+ setParserState(Error);
}
}
-void MetaInfoParser::handleItemLibraryEntryPropertyElement(QXmlStreamReader &reader, ItemLibraryEntry &itemLibraryEntry)
+void MetaInfoParser::readItemLibraryEntryProperty(const QString &name, const QVariant &value)
{
- if (reader.isStartElement() && reader.name() == "property")
- {
- QXmlStreamAttributes attributes(reader.attributes());
- QString name = attributes.value("name").toString();
- QString type = attributes.value("type").toString();
- QString value = attributes.value("value").toString();
- itemLibraryEntry.addProperty(name, type, value);
-
- reader.readNext();
+ if (name == QLatin1String("name")) {
+ m_currentEntry.setName(value.toString());
+ } else if (name == QLatin1String("category")) {
+ m_currentEntry.setCategory(value.toString());
+ } else if (name == QLatin1String("libraryIcon")) {
+ m_currentEntry.setIconPath(value.toString());
+ } else if (name == QLatin1String("version")) {
+ setVersion(value.toString());
+ } else if (name == QLatin1String("requiredImport")) {
+ m_currentEntry.setRequiredImport(value.toString());
+ } else if (name == QLatin1String("forceImport")) {
+ m_currentEntry.setForceImport(value.toBool());
+ } else {
+ addError(tr("Unknown property for ItemLibraryEntry %1").arg(name), currentSourceLocation());
+ setParserState(Error);
}
}
-void MetaInfoParser::handleItemLibraryEntryQmlElement(QXmlStreamReader &reader, ItemLibraryEntry &itemLibraryEntry)
+void MetaInfoParser::readPropertyProperty(const QString &name, const QVariant &value)
{
- if (reader.isStartElement() && reader.name() == "qml")
- {
- QXmlStreamAttributes attributes(reader.attributes());
- QString source = attributes.value("source").toString();
- itemLibraryEntry.setQml(source);
+ if (name == QLatin1String("name")) {
+ m_currentPropertyName = value.toString();
+ } else if (name == QLatin1String("type")) {
+ m_currentPropertyType = value.toString();
+ } else if (name == QLatin1String("value")) {
+ m_currentPropertyValue = value;
+ } else {
+ addError(tr("Unknown property for Property %1").arg(name), currentSourceLocation());
+ setParserState(Error);
+ }
+}
- reader.readNext();
+void MetaInfoParser::readQmlSourceProperty(const QString &name, const QVariant &value)
+{
+ if (name == QLatin1String("source")) {
+ m_currentEntry.setQml(value.toString());
+ } else {
+ addError(tr("Unknown property for QmlSource %1").arg(name), currentSourceLocation());
+ setParserState(Error);
}
}
-void MetaInfoParser::errorHandling(QXmlStreamReader &reader, QFile &file)
+void MetaInfoParser::setVersion(const QString &versionNumber)
{
- if (!reader.hasError())
- return;
+ const QString typeName = m_currentEntry.typeName();
+ int major = 1;
+ int minor = 0;
+
+ if (!versionNumber.isEmpty()) {
+ int val;
+ bool ok;
+ if (versionNumber.contains('.')) {
+ val = versionNumber.split('.').first().toInt(&ok);
+ major = ok ? val : major;
+ val = versionNumber.split('.').last().toInt(&ok);
+ minor = ok ? val : minor;
+ } else {
+ val = versionNumber.toInt(&ok);
+ major = ok ? val : major;
+ }
+ }
+ m_currentEntry.setType(typeName, major, minor);
+}
- qDebug() << QString("Error at %1, %2:%3: %4")
- .arg(file.fileName())
- .arg(reader.lineNumber())
- .arg(reader.columnNumber())
- .arg(reader.errorString());
+MetaInfoParser::ParserSate MetaInfoParser::parserState() const
+{
+ return m_parserState;
+}
- file.reset();
+void MetaInfoParser::setParserState(ParserSate newParserState)
+{
+ if (debug && newParserState == Error)
+ qDebug() << "Error";
- QString fileString = file.readAll();
- QString snippetString;
- int lineCount = 0;
- int position = reader.characterOffset();
- while (position >= 0)
- {
- if (fileString[position] == '\n') {
- if (lineCount > 3)
- break;
- lineCount++;
- }
+ m_parserState = newParserState;
+}
- snippetString.prepend(fileString[position]);
- position--;
+void MetaInfoParser::insertItemLibraryEntry()
+{
+ if (debug) {
+ qDebug() << "insertItemLibraryEntry()";
+ qDebug() << m_currentEntry;
}
- lineCount = 0;
- position = reader.characterOffset();
- while (position >= 0)
- {
- position++;
- if (fileString[position] == '\n') {
- if (lineCount > 1)
- break;
- lineCount++;
- }
-
- snippetString.append(fileString[position]);
+ try {
+ m_metaInfo.itemLibraryInfo()->addEntry(m_currentEntry);
+ } catch (InvalidMetaInfoException &) {
+ addError(tr("Invalid or duplicate item library entry %1").arg(m_currentEntry.name()), currentSourceLocation());
}
-
- qDebug() << snippetString;
-
}
-
+void MetaInfoParser::insertProperty()
+{
+ m_currentEntry.addProperty(m_currentPropertyName, m_currentPropertyType, m_currentPropertyValue);
}
+
+void MetaInfoParser::addErrorInvalidType(const QString &typeName)
+{
+ addError(tr("Invalid type %1").arg(typeName), currentSourceLocation());
}
+
+} //Internal
+} //QmlDesigner
diff --git a/src/plugins/qmldesigner/desktopplugin/desktop.metainfo b/src/plugins/qmldesigner/desktopplugin/desktop.metainfo
index 07f4a5aed0..da774b58f0 100644
--- a/src/plugins/qmldesigner/desktopplugin/desktop.metainfo
+++ b/src/plugins/qmldesigner/desktopplugin/desktop.metainfo
@@ -1,139 +1,383 @@
-<metainfo>
- <node name="QtDesktop.Button" icon=":/desktopplugin/images/button16.png">
- <itemlibraryentry name="Button" category="Components Desktop" libraryIcon=":/desktopplugin/images/button.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="100"/>
- <property name="text" type="QString" value="Button"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.ComboBox" icon=":/desktopplugin/images/button16.png">
- <itemlibraryentry name="ComboBox" category="Components Desktop" libraryIcon=":/desktopplugin/images/button.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="100"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.ToolButton" icon=":/desktopplugin/images/button16.png">
- <itemlibraryentry name="ToolButton" category="Components Desktop" libraryIcon=":/desktopplugin/images/button.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="100"/>
- <property name="text" type="QString" value="Button"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.CheckBox" icon=":/desktopplugin/images/checkbox16.png">
- <itemlibraryentry name="CheckBox" category="Components Desktop" libraryIcon=":/desktopplugin/images/checkbox.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="180"/>
- <property name="text" type="QString" value="CheckBox"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.ChoiceList" icon=":/desktopplugin/images/choicelist16.png">
- <itemlibraryentry name="ChoiceList" category="Components Desktop" libraryIcon=":/desktopplugin/images/choicelist.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="180"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.ProgressBar" icon=":/desktopplugin/images/progressbar16.png">
- <itemlibraryentry name="ProgressBar" category="Components Desktop" libraryIcon=":/desktopplugin/images/progressbar.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="100"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.SpinBox">
- <itemlibraryentry name="SpinBox" category="Components Desktop" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="100"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.Dial">
- <itemlibraryentry name="Dial" category="Components Desktop" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="100"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.SplitterRow">
- <itemlibraryentry name="SplitterRow" category="Components Desktop" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="200"/>
- <property name="height" type="int" value="200"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.RadioButton" icon=":/desktopplugin/images/radiobutton16.png">
- <itemlibraryentry name="RadioButton" category="Components Desktop" libraryIcon=":/desktopplugin/images/radiobutton.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="180"/>
- <property name="text" type="QString" value="RadioButton"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.TextArea" icon=":/desktopplugin/images/textarea16.png">
- <itemlibraryentry name="TextArea" category="Components Desktop" libraryIcon=":/desktopplugin/images/textarea.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="180"/>
- <property name="height" type="int" value="180"/>
- <property name="text" type="QString" value="TextArea"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.ButtonRow" icon=":/desktopplugin/images/buttonrow16.png">
- <itemlibraryentry name="ButtonRow" category="Components Desktop" libraryIcon=":/desktopplugin/images/buttonrow.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="120"/>
- <property name="height" type="int" value="20"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.TabBar" icon=":/desktopplugin/images/tabbar16.png">
- <itemlibraryentry name="TabBar" category="Components Desktop" libraryIcon=":/desktopplugin/images/tabbar.png" version="0.1" requiredImport="QtDesktop">
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.Slider" icon=":/desktopplugin/images/slider16.png">
- <itemlibraryentry name="Slider (horizontal)" category="Components Desktop" libraryIcon=":/desktopplugin/images/slider.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="180"/>
- <property name="orientation" type="int" value="1"/>
- </itemlibraryentry>
- <itemlibraryentry name="Slider (vertical)" category="Components Desktop" libraryIcon=":/desktopplugin/images/sliderh.png" version="0.1" requiredImport="QtDesktop">
- <property name="height" type="int" value="180"/>
- <property name="orientation" type="int" value="2"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.ScrollBar">
- <itemlibraryentry name="ScrollBar (horizontal)" category="Components Desktop" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="180"/>
- <property name="orientation" type="int" value="1"/>
- </itemlibraryentry>
- <itemlibraryentry name="ScrollBar (vertical)" category="Components Desktop" version="0.1" requiredImport="QtDesktop">
- <property name="height" type="int" value="180"/>
- <property name="orientation" type="int" value="2"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.TabFrame" icon=":/desktopplugin//images/window16.png">
- <itemlibraryentry name="TabGroup" category="Components Desktop" libraryIcon=":/desktopplugin/images/window.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="360"/>
- <property name="height" type="int" value="40"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.ScrollArea">
- <itemlibraryentry name="ScrollArea" category="Components Desktop" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="300"/>
- <property name="height" type="int" value="300"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.GroupBox">
- <itemlibraryentry name="GroupBox" category="Components Desktop" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="300"/>
- <property name="height" type="int" value="300"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.Frame">
- <itemlibraryentry name="Frame" category="Components Desktop" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="300"/>
- <property name="height" type="int" value="300"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.ToolBar" icon=":/desktopplugin/images/toolbar16.png">
- <itemlibraryentry name="ToolBar" category="Components Desktop" libraryIcon=":/desktopplugin/images/toolbar.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="300"/>
- <property name="height" type="int" value="50"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.Switch" icon=":/desktopplugin/images/switchbutton16.png">
- <itemlibraryentry name="Switch" category="Components Desktop" libraryIcon=":/desktopplugin/images/switchbutton.png" version="0.1" requiredImport="QtDesktop">
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.TextField" icon=":/desktopplugin/images/textfield16.png">
- <itemlibraryentry name="TextField" category="Components Desktop" libraryIcon=":/desktopplugin/images/textfield.png" version="0.1" requiredImport="QtDesktop">
- <property name="width" type="int" value="180"/>
- <property name="text" type="QString" value="TextField"/>
- </itemlibraryentry>
- </node>
- <node name="QtDesktop.Label" icon=":/desktopplugin/images/window16.png.png">
- <itemlibraryentry name="Label" category="Components Desktop" libraryIcon=":/desktopplugin/images/window.png" version="0.1" requiredImport="QtDesktop">
- <property name="text" type="QString" value="Label"/>
- </itemlibraryentry>
- </node>
-</metainfo>
+MetaInfo {
+
+ Type {
+ name: "QtDesktop.Button"
+ icon: ":/desktopplugin/images/button16.png"
+
+ ItemLibraryEntry {
+ name: "Button"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/button.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ Property { name: "text"; type: "QString"; value: "Button"; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.ComboBox"
+ icon: ":/desktopplugin/images/button16.png"
+
+ ItemLibraryEntry {
+ name: "ComboBox"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/button.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.ToolButton"
+ icon: ":/desktopplugin/images/button16.png"
+
+ ItemLibraryEntry {
+ name: "Tool Button"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/button.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ Property { name: "text"; type: "QString"; value: "Tool Button"; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.CheckBox"
+ icon: ":/desktopplugin/images/button16.png"
+
+ ItemLibraryEntry {
+ name: "Check Box"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/button.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ Property { name: "text"; type: "QString"; value: "CheckBox"; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.ChoiceList"
+ icon: ":/desktopplugin/images/choicelist16.png"
+
+ ItemLibraryEntry {
+ name: "Choice List"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/choicelist.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 180; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.ProgressBar"
+ icon: ":/desktopplugin/images/progressbar16.png"
+
+ ItemLibraryEntry {
+ name: "Progress Bar"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/progressbar.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.SpinBox"
+ icon: ":/desktopplugin/images/progressbar16.png"
+
+ ItemLibraryEntry {
+ name: "Spin Box"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/progressbar.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.Dial"
+ //icon: ":/desktopplugin/images/progressbar16.png"
+
+ ItemLibraryEntry {
+ name: "Dial"
+ category: "Components Desktop"
+ //libraryIcon: ":/desktopplugin/images/progressbar.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.RadioButton"
+ icon: ":/desktopplugin/images/radiobutton16.png"
+
+ ItemLibraryEntry {
+ name: "Radio Button"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/radiobutton.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 180; }
+ Property { name: "text"; type: "QString"; value: "Radio Button"; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.TextArea"
+ icon: ":/desktopplugin/images/textarea16.png"
+
+ ItemLibraryEntry {
+ name: "Text Area"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/textarea.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 180; }
+ Property { name: "height"; type: "int"; value: 180; }
+ Property { name: "text"; type: "QString"; value: "Text Area"; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.ButtonRow"
+ icon: ":/desktopplugin/images/buttonrow16.png"
+
+ ItemLibraryEntry {
+ name: "Button Row"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/buttonrow.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 120; }
+ Property { name: "height"; type: "int"; value: 120; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.SplitterRow"
+ icon: ":/desktopplugin/images/buttonrow16.png"
+
+ ItemLibraryEntry {
+ name: "Splitter Row"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/buttonrow.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 200; }
+ Property { name: "height"; type: "int"; value: 020; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.TabBar"
+ icon: ":/desktopplugin/images/tabbar16.png"
+
+ ItemLibraryEntry {
+ name: "Tab Bar"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/tabbar.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+ }
+ }
+
+ Type {
+ name: "QtDesktop.Slider"
+ icon: ":/desktopplugin/images/slider16.png"
+
+ ItemLibraryEntry {
+ name: "Slider (horizontal)"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/slider.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 180; }
+ Property { name: "orientation"; type: "int"; value: "1"; }
+
+ }
+
+ ItemLibraryEntry {
+ name: "Slider (vertical)"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/sliderh.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "height"; type: "int"; value: 180; }
+ Property { name: "orientation"; type: "int"; value: "2"; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.ScrollBar"
+ icon: ":/desktopplugin/images/slider16.png"
+
+ ItemLibraryEntry {
+ name: "ScrollBar (horizontal)"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/slider.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 180; }
+ Property { name: "orientation"; type: "int"; value: "1"; }
+
+ }
+
+ ItemLibraryEntry {
+ name: "ScrollBar (vertical)"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/sliderh.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "height"; type: "int"; value: 180; }
+ Property { name: "orientation"; type: "int"; value: "2"; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.TabFrame"
+ icon: ":/desktopplugin//images/window16.png"
+
+ ItemLibraryEntry {
+ name: "Tab Frame"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/window.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 360; }
+ Property { name: "height"; type: "int"; value: 200; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.ScrollArea"
+ icon: ":/desktopplugin//images/window16.png"
+
+ ItemLibraryEntry {
+ name: "Scroll Area"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/window.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 360; }
+ Property { name: "height"; type: "int"; value: 300; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.GroupBox"
+ icon: ":/desktopplugin//images/window16.png"
+
+ ItemLibraryEntry {
+ name: "Group Box"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/window.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 360; }
+ Property { name: "height"; type: "int"; value: 300; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.Frame"
+ icon: ":/desktopplugin//images/window16.png"
+
+ ItemLibraryEntry {
+ name: "Frame"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/window.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 360; }
+ Property { name: "height"; type: "int"; value: 300; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.ToolBar"
+ icon: ":/desktopplugin/images/toolbar16.png"
+
+ ItemLibraryEntry {
+ name: "Tool Bar"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/toolbar.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 360; }
+ Property { name: "height"; type: "int"; value: 50; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.Switch"
+ icon: ":/desktopplugin/images/switchbutton16.png"
+
+ ItemLibraryEntry {
+ name: "Switch"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/switchbutton.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+ }
+ }
+
+ Type {
+ name: "QtDesktop.TextField"
+ icon: ":/desktopplugin/images/textfield16.png"
+
+ ItemLibraryEntry {
+ name: "Text Field"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/textfield.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "width"; type: "int"; value: 180; }
+ Property { name: "text"; type: "QString"; value: "Text Field"; }
+ }
+ }
+
+ Type {
+ name: "QtDesktop.Label"
+ icon: ":/desktopplugin/images/window16.png.png"
+
+ ItemLibraryEntry {
+ name: "Label"
+ category: "Components Desktop"
+ libraryIcon: ":/desktopplugin/images/window.png"
+ version: "0.1"
+ requiredImport: "QtDesktop"
+
+ Property { name: "text"; type: "QString"; value: "Text Field"; }
+ }
+ }
+}
diff --git a/src/plugins/qmldesigner/qtquickplugin/quick.metainfo b/src/plugins/qmldesigner/qtquickplugin/quick.metainfo
index cd48606ce4..0729b47a38 100644
--- a/src/plugins/qmldesigner/qtquickplugin/quick.metainfo
+++ b/src/plugins/qmldesigner/qtquickplugin/quick.metainfo
@@ -1,202 +1,452 @@
-<metainfo>
- <node name="QtQuick.Item" icon=":/qtquickplugin/images/item-icon16.png">
- <itemlibraryentry name="Item" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/item-icon.png" version="1.0">
- <property name="width" type="int" value="200"/>
- <property name="height" type="int" value="200"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Rectangle" icon=":/qtquickplugin/images/rect-icon16.png">
- <itemlibraryentry name="Rectangle" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/rect-icon.png" version="1.0">
- <property name="color" type="QColor" value="#ffffff"/>
- <property name="width" type="int" value="200"/>
- <property name="height" type="int" value="200"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Rectangle" icon=":/qtquickplugin/images/rect-icon16.png">
- <itemlibraryentry name="Rectangle" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/rect-icon.png" version="2.0">
- <property name="color" type="QColor" value="#ffffff"/>
- <property name="width" type="int" value="200"/>
- <property name="height" type="int" value="200"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Text" icon=":/qtquickplugin/images/text-icon16.png">
- <itemlibraryentry name="Text" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/text-icon.png" version="1.0">
- <qml source=":/qtquickplugin/source/text.qml"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Text" icon=":/qtquickplugin/images/text-icon16.png">
- <itemlibraryentry name="Text" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/text-icon.png" version="2.0">
- <qml source=":/qtquickplugin/source/textv2.qml"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.TextEdit" icon=":/qtquickplugin/images/text-edit-icon16.png">
- <itemlibraryentry name="Text Edit" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/text-edit-icon.png" version="1.0">
- <qml source=":/qtquickplugin/source/texteditv2.qml"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.TextEdit" icon=":/qtquickplugin/images/text-edit-icon16.png">
- <itemlibraryentry name="Text Edit" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/text-edit-icon.png" version="2.0">
- <qml source=":/qtquickplugin/source/texteditv2.qml"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.TextInput" icon=":/qtquickplugin/images/text-input-icon16.png">
- <itemlibraryentry name="Text Input" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/text-input-icon.png" version="1.0">
- <qml source=":/qtquickplugin/source/textinput.qml"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.TextInput" icon=":/qtquickplugin/images/text-input-icon16.png">
- <itemlibraryentry name="Text Input" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/text-input-icon.png" version="2.0">
- <qml source=":/qtquickplugin/source/textinputv2.qml"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.MouseArea" icon=":/qtquickplugin/images/mouse-area-icon16.png">
- <itemlibraryentry name="Mouse Area" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/mouse-area-icon.png" version="1.0">
- <property name="width" type="int" value="100"/>
- <property name="height" type="int" value="100"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.MouseArea" icon=":/qtquickplugin/images/mouse-area-icon16.png">
- <itemlibraryentry name="Mouse Area" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/mouse-area-icon.png" version="2.0">
- <property name="width" type="int" value="100"/>
- <property name="height" type="int" value="100"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Image" icon=":/qtquickplugin/images/image-icon16.png">
- <itemlibraryentry name="Image" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/image-icon.png" version="1.0">
- <property name="width" type="int" value="100"/>
- <property name="height" type="int" value="100"/>
- <property name="source" type="QUrl" value="qrc:/qtquickplugin/images/template_image.png"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Image" icon=":/qtquickplugin/images/image-icon16.png">
- <itemlibraryentry name="Image" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/image-icon.png" version="2.0">
- <property name="width" type="int" value="100"/>
- <property name="height" type="int" value="100"/>
- <property name="source" type="QUrl" value="qrc:/qtquickplugin/images/template_image.png"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.BorderImage" icon=":/qtquickplugin/images/border-image-icon16.png">
- <itemlibraryentry name="Border Image" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/border-image-icon.png" version="1.0">
- <property name="width" type="int" value="100"/>
- <property name="height" type="int" value="100"/>
- <property name="source" type="QUrl" value="qrc:/qtquickplugin/images/template_image.png"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.BorderImage" icon=":/qtquickplugin/images/border-image-icon16.png">
- <itemlibraryentry name="Border Image" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/border-image-icon.png" version="2.0">
- <property name="width" type="int" value="100"/>
- <property name="height" type="int" value="100"/>
- <property name="source" type="QUrl" value="qrc:/qtquickplugin/images/template_image.png"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Flickable" icon=":/qtquickplugin/images/flickable-icon16.png">
- <itemlibraryentry name="Flickable" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/flickable-icon.png" version="1.0">
- <property name="width" type="int" value="300"/>
- <property name="height" type="int" value="300"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Flipable" icon=":/qtquickplugin/images/flipable-icon16.png">
- <itemlibraryentry name="Flipable" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/flipable-icon.png" version="2.0">
- <property name="width" type="int" value="300"/>
- <property name="height" type="int" value="300"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.GridView" icon=":/qtquickplugin/images/gridview-icon16.png">
- <itemlibraryentry name="Grid View" category="Qt Quick - Views" libraryIcon=":/qtquickplugin/images/gridview-icon.png" version="1.0">
- <qml source=":/qtquickplugin/source/gridview.qml"/>
- </itemlibraryentry>
- </node>
-
- <node name="QtQuick.GridView" icon=":/qtquickplugin/images/gridview-icon16.png">
- <itemlibraryentry name="Grid View" category="Qt Quick - Views" libraryIcon=":/qtquickplugin/images/gridview-icon.png" version="2.0">
- <qml source=":/qtquickplugin/source/gridviewv2.qml"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.ListView" icon=":/qtquickplugin/images/listview-icon16.png">
- <itemlibraryentry name="List View" category="Qt Quick - Views" libraryIcon=":/qtquickplugin/images/listview-icon.png" version="1.0">
- <qml source=":/qtquickplugin/source/listview.qml"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.ListView" icon=":/qtquickplugin/images/listview-icon16.png">
- <itemlibraryentry name="List View" category="Qt Quick - Views" libraryIcon=":/qtquickplugin/images/listview-icon.png" version="2.0">
- <qml source=":/qtquickplugin/source/listviewv2.qml"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.PathView" icon=":/qtquickplugin/images/pathview-icon16.png">
- <itemlibraryentry name="Path View" category="Qt Quick - Views" libraryIcon=":/qtquickplugin/images/pathview-icon.png" version="1.0">
- <qml source=":/qtquickplugin/source/pathview.qml"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.PathView" icon=":/qtquickplugin/images/pathview-icon16.png">
- <itemlibraryentry name="Path View" category="Qt Quick - Views" libraryIcon=":/qtquickplugin/images/pathview-icon.png" version="2.0">
- <qml source=":/qtquickplugin/source/pathviewv2.qml"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.FocusScope" icon=":/qtquickplugin/images/focusscope-icon16.png">
- <itemlibraryentry name="Focus Scope" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/focusscope-icon.png" version="1.0">
- <property name="width" type="int" value="100"/>
- <property name="height" type="int" value="100"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.FocusScope" icon=":/qtquickplugin/images/focusscope-icon16.png">
- <itemlibraryentry name="Focus Scope" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/focusscope-icon.png" version="2.0">
- <property name="width" type="int" value="100"/>
- <property name="height" type="int" value="100"/>
- </itemlibraryentry>
- </node>
- <node name="QtWebKit.WebView" icon=":/qtquickplugin/images/webview-icon16.png">
- <itemlibraryentry name="Web View" category="Qt Quick - Basic" libraryIcon=":/qtquickplugin/images/webview-icon.png" version="1.0" requiredImport="QtWebKit" forceImport="true">
- <property name="width" type="int" value="300"/>
- <property name="height" type="int" value="300"/>
- <property name="url" type="QString" value="qrc:/qtquickplugin/html/welcome.html"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Row" icon=":/qtquickplugin/images/item-icon16.png">
- <itemlibraryentry name="Row" category="Qt Quick - Positioner" libraryIcon=":/qtquickplugin/images/item-icon.png" version="1.0">
- <property name="width" type="int" value="400"/>
- <property name="height" type="int" value="200"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Row" icon=":/qtquickplugin/images/item-icon16.png">
- <itemlibraryentry name="Row" category="Qt Quick - Positioner" libraryIcon=":/qtquickplugin/images/item-icon.png" version="2.0">
- <property name="width" type="int" value="400"/>
- <property name="height" type="int" value="200"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Column" icon=":/qtquickplugin/images/item-icon16.png">
- <itemlibraryentry name="Column" category="Qt Quick - Positioner" libraryIcon=":/qtquickplugin/images/item-icon.png" version="1.0">
- <property name="width" type="int" value="200"/>
- <property name="height" type="int" value="400"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Column" icon=":/qtquickplugin/images/item-icon16.png">
- <itemlibraryentry name="Column" category="Qt Quick - Positioner" libraryIcon=":/qtquickplugin/images/item-icon.png" version="2.0">
- <property name="width" type="int" value="200"/>
- <property name="height" type="int" value="400"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Grid" icon=":/qtquickplugin/images/item-icon16.png">
- <itemlibraryentry name="Grid" category="Qt Quick - Positioner" libraryIcon=":/qtquickplugin/images/item-icon.png" version="1.0">
- <property name="width" type="int" value="400"/>
- <property name="height" type="int" value="400"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Grid" icon=":/qtquickplugin/images/item-icon16.png">
- <itemlibraryentry name="Grid" category="Qt Quick - Positioner" libraryIcon=":/qtquickplugin/images/item-icon.png" version="2.0">
- <property name="width" type="int" value="400"/>
- <property name="height" type="int" value="400"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Flow" icon=":/qtquickplugin/images/item-icon16.png">
- <itemlibraryentry name="Flow" category="Qt Quick - Positioner" libraryIcon=":/qtquickplugin/images/item-icon.png" version="1.0">
- <property name="width" type="int" value="400"/>
- <property name="height" type="int" value="400"/>
- </itemlibraryentry>
- </node>
- <node name="QtQuick.Flow" icon=":/qtquickplugin/images/item-icon16.png">
- <itemlibraryentry name="Flow" category="Qt Quick - Positioner" libraryIcon=":/qtquickplugin/images/item-icon.png" version="2.0">
- <property name="width" type="int" value="400"/>
- <property name="height" type="int" value="400"/>
- </itemlibraryentry>
- </node>
- </metainfo>
+MetaInfo {
+
+ Type {
+ name: "QtQuick.Item"
+ icon: ":/qtquickplugin/images/item-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Item"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/item-icon.png"
+ version: "1.0"
+
+ Property { name: "width"; type: "int"; value: 200; }
+ Property { name: "height"; type: "int"; value: 200; }
+ }
+
+ ItemLibraryEntry {
+ name: "Item"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/item-icon.png"
+ version: "2.0"
+
+ Property { name: "width"; type: "int"; value: 200; }
+ Property { name: "height"; type: "int"; value: 200; }
+ }
+ }
+
+ Type {
+ name: "QtQuick.Rectangle"
+ icon: ":/qtquickplugin/images/rect-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Rectangle"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/rect-icon.png"
+ version: "1.0"
+
+ Property { name: "width"; type: "int"; value: 200; }
+ Property { name: "height"; type: "int"; value: 200; }
+ Property { name: "color"; type: "QColor"; value: "#ffffff"; }
+
+ }
+
+ ItemLibraryEntry {
+ name: "Rectangle"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/rect-icon.png"
+ version: "2.0"
+
+ Property { name: "width"; type: "int"; value: 200; }
+ Property { name: "height"; type: "int"; value: 200; }
+ Property { name: "color"; type: "QColor"; value: "#ffffff"; }
+ }
+ }
+
+ Type {
+ name: "QtQuick.Text"
+ icon: ":/qtquickplugin/images/text-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Text"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/text-icon.png"
+ version: "1.0"
+
+ QmlSource { source: ":/qtquickplugin/source/text.qml" }
+ }
+
+ ItemLibraryEntry {
+ name: "Text"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/text-icon.png"
+ version: "2.0"
+
+ QmlSource { source: ":/qtquickplugin/source/textv2.qml" }
+ }
+ }
+
+ Type {
+ name: "QtQuick.TextEdit"
+ icon: ":/qtquickplugin/images/text-edit-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Text Edit"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/text-edit-icon.png"
+ version: "1.0"
+
+ QmlSource { source: ":/qtquickplugin/source/textedit.qml" }
+ }
+
+ ItemLibraryEntry {
+ name: "Text Edit"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/text-edit-icon.png"
+ version: "2.0"
+
+ QmlSource { source: ":/qtquickplugin/source/texteditv2.qml" }
+ }
+ }
+
+ Type {
+ name: "QtQuick.TextInput"
+ icon: ":/qtquickplugin/images/text-input-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Text Input"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/text-edit-icon.png"
+ version: "1.0"
+
+ QmlSource { source: ":/qtquickplugin/source/textinput.qml" }
+ }
+
+ ItemLibraryEntry {
+ name: "Text Input"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/text-input-icon.png"
+ version: "2.0"
+
+ QmlSource { source: ":/qtquickplugin/source/textinput.qml" }
+ }
+ }
+
+ Type {
+ name: "QtQuick.MouseArea"
+ icon: ":/qtquickplugin/images/mouse-area-icon16.png"
+
+ ItemLibraryEntry {
+ name: "MouseArea"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/mouse-area-icon.png"
+ version: "1.0"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ Property { name: "height"; type: "int"; value: 100; }
+
+ }
+
+ ItemLibraryEntry {
+ name: "MouseArea"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/mouse-area-icon.png"
+ version: "2.0"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ Property { name: "height"; type: "int"; value: 100; }
+ }
+ }
+
+ Type {
+ name: "QtQuick.Image"
+ icon: ":/qtquickplugin/images/image-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Image"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/image-icon.png"
+ version: "1.0"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ Property { name: "height"; type: "int"; value: 100; }
+ Property { name: "source"; type: "QUrl"; value:"qrc:/qtquickplugin/images/template_image.png"; }
+ }
+
+ ItemLibraryEntry {
+ name: "Image"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/image-icon.png"
+ version: "2.0"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ Property { name: "height"; type: "int"; value: 100; }
+ Property { name: "source"; type: "QUrl"; value:"qrc:/qtquickplugin/images/template_image.png"; }
+ }
+ }
+
+ Type {
+ name: "QtQuick.BorderImage"
+ icon: ":/qtquickplugin/images/border-image-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Border Image"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/border-image-icon.png"
+ version: "1.0"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ Property { name: "height"; type: "int"; value: 100; }
+ Property { name: "source"; type: "QUrl"; value:"qrc:/qtquickplugin/images/template_image.png"; }
+ }
+
+ ItemLibraryEntry {
+ name: "Border Image"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/border-image-icon.png"
+ version: "2.0"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ Property { name: "height"; type: "int"; value: 100; }
+ Property { name: "source"; type: "QUrl"; value:"qrc:/qtquickplugin/images/template_image.png"; }
+ }
+ }
+
+ Type {
+ name: "QtQuick.Flickable"
+ icon: ":/qtquickplugin/images/flickable-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Flickable"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/flickable-icon.png"
+ version: "1.0"
+
+ Property { name: "width"; type: "int"; value: 300; }
+ Property { name: "height"; type: "int"; value: 300; }
+ }
+
+ ItemLibraryEntry {
+ name: "Flickable"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/flickable-icon.png"
+ version: "2.0"
+
+ Property { name: "width"; type: "int"; value: 300; }
+ Property { name: "height"; type: "int"; value: 300; }
+ }
+ }
+
+ Type {
+ name: "QtQuick.Flipable"
+ icon: ":/qtquickplugin/images/flipable-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Flipable"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/flipable-icon.png"
+ version: "1.0"
+
+ Property { name: "width"; type: "int"; value: 200; }
+ Property { name: "height"; type: "int"; value: 200; }
+ }
+
+ ItemLibraryEntry {
+ name: "Flipable"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/flipable-icon.png"
+ version: "2.0"
+
+ Property { name: "width"; type: "int"; value: 200; }
+ Property { name: "height"; type: "int"; value: 200; }
+ }
+ }
+
+ Type {
+ name: "QtQuick.GridView"
+ icon: ":/qtquickplugin/images/gridview-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Grid View"
+ category: "Qt Quick - Views"
+ libraryIcon: ":/qtquickplugin/gridview-icon.png"
+ version: "1.0"
+
+ QmlSource { source: ":/qtquickplugin/source/gridview.qml" }
+ }
+
+ ItemLibraryEntry {
+ name: "Grid View"
+ category: "Qt Quick - Views"
+ libraryIcon: ":/qtquickplugin/images/gridview-icon.png"
+ version: "2.0"
+
+ QmlSource { source: ":/qtquickplugin/source/gridviewv2.qml" }
+ }
+ }
+
+ Type {
+ name: "QtQuick.ListView"
+ icon: ":/qtquickplugin/images/listview-icon16.png"
+
+ ItemLibraryEntry {
+ name: "List View"
+ category: "Qt Quick - Views"
+ libraryIcon: ":/qtquickplugin/listview-icon.png"
+ version: "1.0"
+
+ QmlSource { source: ":/qtquickplugin/source/listview.qml" }
+ }
+
+ ItemLibraryEntry {
+ name: "List View"
+ category: "Qt Quick - Views"
+ libraryIcon: ":/qtquickplugin/images/listview-icon.png"
+ version: "2.0"
+
+ QmlSource { source: ":/qtquickplugin/source/listviewv2.qml" }
+ }
+ }
+
+ Type {
+ name: "QtQuick.PathView"
+ icon: ":/qtquickplugin/images/pathview-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Path View"
+ category: "Qt Quick - Views"
+ libraryIcon: ":/qtquickplugin/pathview-icon.png"
+ version: "1.0"
+
+ QmlSource { source: ":/qtquickplugin/source/pathview.qml" }
+ }
+
+ ItemLibraryEntry {
+ name: "Path View"
+ category: "Qt Quick - Views"
+ libraryIcon: ":/qtquickplugin/images/pathview-icon.png"
+ version: "2.0"
+
+ QmlSource { source: ":/qtquickplugin/source/pathviewv2.qml" }
+ }
+ }
+
+ Type {
+ name: "QtQuick.FocusScope"
+ icon: ":/qtquickplugin/images/focusscope-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Focus Scope"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/focusscope-icon.png"
+ version: "1.0"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ Property { name: "height"; type: "int"; value: 100; }
+ }
+
+ ItemLibraryEntry {
+ name: "Focus Scope"
+ category: "Qt Quick - Basic"
+ libraryIcon: ":/qtquickplugin/images/focusscope-icon.png"
+ version: "2.0"
+
+ Property { name: "width"; type: "int"; value: 100; }
+ Property { name: "height"; type: "int"; value: 100; }
+ }
+ }
+
+ Type {
+ name: "QtWebKit.WebView"
+ icon: ":/qtquickplugin/images/webview-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Web View"
+ category: "Qt Quick - Positioner"
+ libraryIcon: ":/qtquickplugin/webview-icon.png"
+ version: "1.0"
+ requiredImport: "QtWebKit"
+ forceImport: "true"
+
+ Property { name: "width"; type: "int"; value: 300; }
+ Property { name: "height"; type: "int"; value: 300; }
+ Property { name: "url"; type: "QString"; value: "qrc:/qtquickplugin/html/welcome.html" }
+ }
+
+ ItemLibraryEntry {
+ name: "Web View"
+ category: "Qt Quick - Positioner"
+ libraryIcon: ":/qtquickplugin/images/webview-icon.png"
+ version: "2.0"
+
+ Property { name: "width"; type: "int"; value: 300; }
+ Property { name: "height"; type: "int"; value: 300; }
+ Property { name: "url"; type: "QString"; value: "qrc:/qtquickplugin/html/welcome.html" }
+ }
+ }
+
+ Type {
+ name: "QtQuick.Column"
+ icon: ":/qtquickplugin/images/item-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Column"
+ category: "Qt Quick - Positioner"
+ libraryIcon: ":/qtquickplugin/item-icon.png"
+ version: "1.0"
+
+ Property { name: "width"; type: "int"; value: 200; }
+ Property { name: "height"; type: "int"; value: 400; }
+ }
+
+ ItemLibraryEntry {
+ name: "Column"
+ category: "Qt Quick - Positioner"
+ libraryIcon: ":/qtquickplugin/images/item-icon.png"
+ version: "2.0"
+
+ Property { name: "width"; type: "int"; value: 200; }
+ Property { name: "height"; type: "int"; value: 400; }
+ }
+ }
+
+ Type {
+ name: "QtQuick.Grid"
+ icon: ":/qtquickplugin/images/item-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Grid"
+ category: "Qt Quick - Positioner"
+ libraryIcon: ":/qtquickplugin/item-icon.png"
+ version: "1.0"
+
+ Property { name: "width"; type: "int"; value: 400; }
+ Property { name: "height"; type: "int"; value: 400; }
+ }
+
+ ItemLibraryEntry {
+ name: "Grid"
+ category: "Qt Quick - Positioner"
+ libraryIcon: ":/qtquickplugin/images/item-icon.png"
+ version: "2.0"
+
+ Property { name: "width"; type: "int"; value: 400; }
+ Property { name: "height"; type: "int"; value: 400; }
+ }
+ }
+
+ Type {
+ name: "QtQuick.Flow"
+ icon: ":/qtquickplugin/images/item-icon16.png"
+
+ ItemLibraryEntry {
+ name: "Flow"
+ category: "Qt Quick - Positioner"
+ libraryIcon: ":/qtquickplugin/item-icon.png"
+ version: "1.0"
+
+ Property { name: "width"; type: "int"; value: 400; }
+ Property { name: "height"; type: "int"; value: 400; }
+ }
+
+ ItemLibraryEntry {
+ name: "Flow"
+ category: "Qt Quick - Positioner"
+ libraryIcon: ":/qtquickplugin/images/item-icon.png"
+ version: "2.0"
+
+ Property { name: "width"; type: "int"; value: 400; }
+ Property { name: "height"; type: "int"; value: 400; }
+ }
+ }
+}