From c19590f72012168f4e6ea1a3f7e55cb080919a34 Mon Sep 17 00:00:00 2001 From: Robin Burchell Date: Fri, 11 Mar 2016 09:45:26 +0100 Subject: Move qmltime out of benchmarks directory. This is a tool, not a benchmark. Change-Id: Ie6b4452a1235923e1663a8a525ddad8408d21545 Reviewed-by: Simon Hausmann --- tools/qmltime/example.qml | 47 ++++ tools/qmltime/linelaidout.qml | 54 ++++ tools/qmltime/qmltime.cpp | 277 +++++++++++++++++++++ tools/qmltime/qmltime.pro | 10 + tools/qmltime/tests/anchors/empty.qml | 67 +++++ tools/qmltime/tests/anchors/fill.qml | 74 ++++++ tools/qmltime/tests/anchors/null.qml | 60 +++++ tools/qmltime/tests/animation/large.qml | 74 ++++++ tools/qmltime/tests/animation/largeNoProps.qml | 74 ++++++ tools/qmltime/tests/item_creation/children.qml | 67 +++++ tools/qmltime/tests/item_creation/data.qml | 67 +++++ tools/qmltime/tests/item_creation/no_creation.qml | 45 ++++ tools/qmltime/tests/item_creation/resources.qml | 67 +++++ tools/qmltime/tests/loader/Loaded.qml | 40 +++ tools/qmltime/tests/loader/component_loader.qml | 49 ++++ tools/qmltime/tests/loader/empty_loader.qml | 48 ++++ tools/qmltime/tests/loader/no_loader.qml | 47 ++++ tools/qmltime/tests/loader/source_loader.qml | 49 ++++ .../tests/positioner_creation/no_positioner.qml | 70 ++++++ .../tests/positioner_creation/null_positioner.qml | 67 +++++ .../tests/positioner_creation/positioner.qml | 70 ++++++ tools/qmltime/tests/vmemetaobject/null.qml | 46 ++++ tools/qmltime/tests/vmemetaobject/property.qml | 51 ++++ tools/qmltime/textingrid.qml | 65 +++++ 24 files changed, 1585 insertions(+) create mode 100644 tools/qmltime/example.qml create mode 100644 tools/qmltime/linelaidout.qml create mode 100644 tools/qmltime/qmltime.cpp create mode 100644 tools/qmltime/qmltime.pro create mode 100644 tools/qmltime/tests/anchors/empty.qml create mode 100644 tools/qmltime/tests/anchors/fill.qml create mode 100644 tools/qmltime/tests/anchors/null.qml create mode 100644 tools/qmltime/tests/animation/large.qml create mode 100644 tools/qmltime/tests/animation/largeNoProps.qml create mode 100644 tools/qmltime/tests/item_creation/children.qml create mode 100644 tools/qmltime/tests/item_creation/data.qml create mode 100644 tools/qmltime/tests/item_creation/no_creation.qml create mode 100644 tools/qmltime/tests/item_creation/resources.qml create mode 100644 tools/qmltime/tests/loader/Loaded.qml create mode 100644 tools/qmltime/tests/loader/component_loader.qml create mode 100644 tools/qmltime/tests/loader/empty_loader.qml create mode 100644 tools/qmltime/tests/loader/no_loader.qml create mode 100644 tools/qmltime/tests/loader/source_loader.qml create mode 100644 tools/qmltime/tests/positioner_creation/no_positioner.qml create mode 100644 tools/qmltime/tests/positioner_creation/null_positioner.qml create mode 100644 tools/qmltime/tests/positioner_creation/positioner.qml create mode 100644 tools/qmltime/tests/vmemetaobject/null.qml create mode 100644 tools/qmltime/tests/vmemetaobject/property.qml create mode 100644 tools/qmltime/textingrid.qml (limited to 'tools/qmltime') diff --git a/tools/qmltime/example.qml b/tools/qmltime/example.qml new file mode 100644 index 0000000000..3ef15d7567 --- /dev/null +++ b/tools/qmltime/example.qml @@ -0,0 +1,47 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + property string name: "Bob Smith" + + QmlTime.Timer { + component: Item { + Text { text: name } + } + } +} + diff --git a/tools/qmltime/linelaidout.qml b/tools/qmltime/linelaidout.qml new file mode 100644 index 0000000000..90b7d14253 --- /dev/null +++ b/tools/qmltime/linelaidout.qml @@ -0,0 +1,54 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Text { + width: 480 + height: width + text: "1\n2\n3\n4\n5\n6\n7\n8\n9\n10\n11\n12\n13\n14\n15\n16\n17\n18\n19\n20\n21\n22\n23\n24\n25\n26\n27\n28\n29\n30\n31\n32\n33\n34\n35\n36\n37\n38\n39\n40\n41\n42" + color: "blue" + font.pixelSize: 15 + font.bold: true + + onLineLaidOut: { + line.x = (line.number % 7) * 70 + line.y = Math.floor(line.number / 7.0) * 70 + } + } + } +} diff --git a/tools/qmltime/qmltime.cpp b/tools/qmltime/qmltime.cpp new file mode 100644 index 0000000000..2abe71fb4c --- /dev/null +++ b/tools/qmltime/qmltime.cpp @@ -0,0 +1,277 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the test suite of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ +#include +#include +#include +#include +#include +#include +#include +#include + +#include + +class Timer : public QObject +{ + Q_OBJECT + Q_PROPERTY(QQmlComponent *component READ component WRITE setComponent) + +public: + Timer(); + + QQmlComponent *component() const; + void setComponent(QQmlComponent *); + + static Timer *timerInstance(); + + void run(uint); + + bool willParent() const; + void setWillParent(bool p); + +private: + void runTest(QQmlContext *, uint); + + QQmlComponent *m_component; + static Timer *m_timer; + + bool m_willparent; + QQuickView m_view; + QQuickItem *m_item; +}; +QML_DECLARE_TYPE(Timer); + +Timer *Timer::m_timer = 0; + +Timer::Timer() + : m_component(0) + , m_willparent(false) + , m_item(new QQuickItem) +{ + if (m_timer) + qWarning("Timer: Timer already registered"); + QQuickViewPrivate::get(&m_view)->setRootObject(m_item); + m_timer = this; +} + +QQmlComponent *Timer::component() const +{ + return m_component; +} + +void Timer::setComponent(QQmlComponent *c) +{ + m_component = c; +} + +Timer *Timer::timerInstance() +{ + return m_timer; +} + +void Timer::run(uint iterations) +{ + QQmlContext context(qmlContext(this)); + + QObject *o = m_component->create(&context); + QQuickItem *i = qobject_cast(o); + if (m_willparent && i) + i->setParentItem(m_item); + delete o; + + runTest(&context, iterations); +} + +bool Timer::willParent() const +{ + return m_willparent; +} + +void Timer::setWillParent(bool p) +{ + m_willparent = p; +} + +void Timer::runTest(QQmlContext *context, uint iterations) +{ + QTime t; + t.start(); + for (uint ii = 0; ii < iterations; ++ii) { + QObject *o = m_component->create(context); + QQuickItem *i = qobject_cast(o); + if (m_willparent && i) + i->setParentItem(m_item); + delete o; + } + + int e = t.elapsed(); + + qWarning() << "Total:" << e << "ms, Per iteration:" << qreal(e) / qreal(iterations) << "ms"; + +} + +void usage(const char *name) +{ + qWarning("Usage: %s [-iterations ] [-parent] \n", name); + + qWarning("qmltime is a tool for benchmarking the runtime cost of instantiating\n" + "a QML component. It is typically run as follows:\n" + "\n" + "%s path/to/benchmark.qml\n" + "\n" + "If the -parent option is specified, the component being measured will also\n" + "be parented to an item already in the scene.\n" + "\n" + "If the -iterations option is specified, the benchmark will run the specified\n" + "number of iterations. If -iterations is not specified, 1024 iterations\n" + "are performed.\n" + "\n" + "qmltime expects the file to be benchmarked to contain a certain structure.\n" + "Specifically, it requires the presence of a QmlTime.Timer element. For example,\n" + "say we wanted to benchmark the following list delegate:\n" + "\n" + "Rectangle {\n" + " color: \"green\"\n" + " width: 400; height: 100\n" + " Text {\n" + " anchors.centerIn: parent\n" + " text: name\n" + " }\n" + "}\n" + "\n" + "we would create a benchmark file that looks like this:\n" + "\n" + "import QtQuick 2.0\n" + "import QmlTime 1.0 as QmlTime\n" + "\n" + "Item {\n" + "\n" + " property string name: \"Bob Smith\"\n" + "\n" + " QmlTime.Timer {\n" + " component: Rectangle {\n" + " color: \"green\"\n" + " width: 400; height: 100\n" + " Text {\n" + " anchors.centerIn: parent\n" + " text: name\n" + " }\n" + " }\n" + " }\n" + "}\n" + "\n" + "The outer Item functions as a dummy data provider for any additional\n" + "data required by the bindings in the component being benchmarked (in the\n" + "example above we provide a \"name\" property).\n" + "\n" + "When started, the component is instantiated once before running\n" + "the benchmark, which means that the reported time does not include\n" + "compile time (as the results of compilation are cached internally).\n" + "In this sense the times reported by qmltime best correspond to the\n" + "costs associated with delegate creation in the view classes, where the\n" + "same delegate is instantiated over and over. Conversely, it is not a\n" + "good approximation for e.g. Loader, which typically only instantiates\n" + "an element once (and so for Loader the compile time is very relevant\n" + "to the overall cost).", name); + + exit(-1); +} + +int main(int argc, char ** argv) +{ + QGuiApplication app(argc, argv); + + qmlRegisterType("QmlTime", 1, 0, "Timer"); + + uint iterations = 1024; + QString filename; + bool willParent = false; + + for (int ii = 1; ii < argc; ++ii) { + QByteArray arg(argv[ii]); + + if (arg == "-iterations") { + if (ii + 1 < argc) { + ++ii; + QByteArray its(argv[ii]); + bool ok = false; + iterations = its.toUInt(&ok); + if (!ok) + usage(argv[0]); + } else { + usage(argv[0]); + } + } else if (arg == "-parent") { + willParent = true; + } else if (arg == "-help") { + usage(argv[0]); + } else { + filename = QLatin1String(argv[ii]); + } + } + + if (filename.isEmpty()) + usage(argv[0]); + + QQmlEngine engine; + QQmlComponent component(&engine, filename); + if (component.isError()) { + qWarning() << component.errors(); + return -1; + } + + QObject *obj = component.create(); + if (!obj) { + qWarning() << component.errors(); + return -1; + } + + Timer *timer = Timer::timerInstance(); + if (!timer) { + qWarning() << "A QmlTime.Timer instance is required."; + return -1; + } + + timer->setWillParent(willParent); + + if (!timer->component()) { + qWarning() << "The timer has no component"; + return -1; + } + + timer->run(iterations); + + return 0; +} + +#include "qmltime.moc" diff --git a/tools/qmltime/qmltime.pro b/tools/qmltime/qmltime.pro new file mode 100644 index 0000000000..fa93e91af0 --- /dev/null +++ b/tools/qmltime/qmltime.pro @@ -0,0 +1,10 @@ +CONFIG += testcase +TEMPLATE = app +TARGET = qmltime +QT += qml testlib quick +QT += quick-private +macx:CONFIG -= app_bundle + +SOURCES += qmltime.cpp + +DEFINES += QT_DISABLE_DEPRECATED_BEFORE=0 diff --git a/tools/qmltime/tests/anchors/empty.qml b/tools/qmltime/tests/anchors/empty.qml new file mode 100644 index 0000000000..309b4caa7e --- /dev/null +++ b/tools/qmltime/tests/anchors/empty.qml @@ -0,0 +1,67 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + Item { + Item { + anchors.leftMargin: 0 + } + Item { + anchors.leftMargin: 0 + } + Item { + anchors.leftMargin: 0 + } + Item { + anchors.leftMargin: 0 + } + Item { + anchors.leftMargin: 0 + } + Item { + anchors.leftMargin: 0 + } + Item { + anchors.leftMargin: 0 + } + } + } + } +} + diff --git a/tools/qmltime/tests/anchors/fill.qml b/tools/qmltime/tests/anchors/fill.qml new file mode 100644 index 0000000000..df32da66e5 --- /dev/null +++ b/tools/qmltime/tests/anchors/fill.qml @@ -0,0 +1,74 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + Item { + Item { + anchors.fill: parent + anchors.leftMargin: 0 + } + Item { + anchors.fill: parent + anchors.leftMargin: 0 + } + Item { + anchors.fill: parent + anchors.leftMargin: 0 + } + Item { + anchors.fill: parent + anchors.leftMargin: 0 + } + Item { + anchors.fill: parent + anchors.leftMargin: 0 + } + Item { + anchors.fill: parent + anchors.leftMargin: 0 + } + Item { + anchors.fill: parent + anchors.leftMargin: 0 + } + } + } + } +} + diff --git a/tools/qmltime/tests/anchors/null.qml b/tools/qmltime/tests/anchors/null.qml new file mode 100644 index 0000000000..8a1ae0c25d --- /dev/null +++ b/tools/qmltime/tests/anchors/null.qml @@ -0,0 +1,60 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + Item { + Item { + } + Item { + } + Item { + } + Item { + } + Item { + } + Item { + } + Item { + } + } + } + } +} + diff --git a/tools/qmltime/tests/animation/large.qml b/tools/qmltime/tests/animation/large.qml new file mode 100644 index 0000000000..0c791961dd --- /dev/null +++ b/tools/qmltime/tests/animation/large.qml @@ -0,0 +1,74 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + ParallelAnimation { + NumberAnimation { duration: 500 } + NumberAnimation { duration: 4000; } + NumberAnimation { duration: 2000; easing.type: "OutBack"} + ColorAnimation { duration: 3000} + SequentialAnimation { + PauseAnimation { duration: 1000 } + ScriptAction { script: doSomething(); } + PauseAnimation { duration: 800 } + ScriptAction { script: doSomethingElse(); } + PauseAnimation { duration: 800 } + ParallelAnimation { + NumberAnimation { duration: 200;} + SequentialAnimation { + PauseAnimation { duration: 200} + ParallelAnimation { + NumberAnimation { duration: 300;} + NumberAnimation { duration: 300;} + } + NumberAnimation { from: 0; to: 1; duration: 500 } + PauseAnimation { duration: 200 } + NumberAnimation { from: 1; to: 0; duration: 500 } + } + SequentialAnimation { + PauseAnimation { duration: 150} + NumberAnimation { duration: 300; easing.type: "OutBounce" } + } + } + } + } + } + } + +} diff --git a/tools/qmltime/tests/animation/largeNoProps.qml b/tools/qmltime/tests/animation/largeNoProps.qml new file mode 100644 index 0000000000..734ee46b77 --- /dev/null +++ b/tools/qmltime/tests/animation/largeNoProps.qml @@ -0,0 +1,74 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + ParallelAnimation { + NumberAnimation { } + NumberAnimation { } + NumberAnimation { } + ColorAnimation { } + SequentialAnimation { + PauseAnimation { } + ScriptAction { } + PauseAnimation { } + ScriptAction { } + PauseAnimation { } + ParallelAnimation { + NumberAnimation { } + SequentialAnimation { + PauseAnimation { } + ParallelAnimation { + NumberAnimation { } + NumberAnimation { } + } + NumberAnimation { } + PauseAnimation { } + NumberAnimation { } + } + SequentialAnimation { + PauseAnimation { } + NumberAnimation { } + } + } + } + } + } + } + +} diff --git a/tools/qmltime/tests/item_creation/children.qml b/tools/qmltime/tests/item_creation/children.qml new file mode 100644 index 0000000000..87085c1134 --- /dev/null +++ b/tools/qmltime/tests/item_creation/children.qml @@ -0,0 +1,67 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + Item { + children: [ + Rectangle { }, + Rectangle { }, + Item { }, + Image { }, + Text { }, + Item { }, + Item { }, + Image { }, + Image { }, + Row { }, + Image { }, + Image { }, + Column { }, + Row { }, + Text { }, + Text { }, + Text { }, + MouseArea { } + ] + + } + } + } + +} diff --git a/tools/qmltime/tests/item_creation/data.qml b/tools/qmltime/tests/item_creation/data.qml new file mode 100644 index 0000000000..96804fda40 --- /dev/null +++ b/tools/qmltime/tests/item_creation/data.qml @@ -0,0 +1,67 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + Item { + data: [ + Rectangle { }, + Rectangle { }, + Item { }, + Image { }, + Text { }, + Item { }, + Item { }, + Image { }, + Image { }, + Row { }, + Image { }, + Image { }, + Column { }, + Row { }, + Text { }, + Text { }, + Text { }, + MouseArea { } + ] + + } + } + } + +} diff --git a/tools/qmltime/tests/item_creation/no_creation.qml b/tools/qmltime/tests/item_creation/no_creation.qml new file mode 100644 index 0000000000..64561eb211 --- /dev/null +++ b/tools/qmltime/tests/item_creation/no_creation.qml @@ -0,0 +1,45 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + Item { + } + } + } +} diff --git a/tools/qmltime/tests/item_creation/resources.qml b/tools/qmltime/tests/item_creation/resources.qml new file mode 100644 index 0000000000..c896666b9a --- /dev/null +++ b/tools/qmltime/tests/item_creation/resources.qml @@ -0,0 +1,67 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + Item { + resources: [ + Rectangle { }, + Rectangle { }, + Item { }, + Image { }, + Text { }, + Item { }, + Item { }, + Image { }, + Image { }, + Row { }, + Image { }, + Image { }, + Column { }, + Row { }, + Text { }, + Text { }, + Text { }, + MouseArea { } + ] + + } + } + } + +} diff --git a/tools/qmltime/tests/loader/Loaded.qml b/tools/qmltime/tests/loader/Loaded.qml new file mode 100644 index 0000000000..8dedef1361 --- /dev/null +++ b/tools/qmltime/tests/loader/Loaded.qml @@ -0,0 +1,40 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 + +Item { + Rectangle {} + Text {} + Image {} +} diff --git a/tools/qmltime/tests/loader/component_loader.qml b/tools/qmltime/tests/loader/component_loader.qml new file mode 100644 index 0000000000..9c245aeb21 --- /dev/null +++ b/tools/qmltime/tests/loader/component_loader.qml @@ -0,0 +1,49 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + Item { + Loader { + sourceComponent: Loaded {} + } + } + } + } +} + diff --git a/tools/qmltime/tests/loader/empty_loader.qml b/tools/qmltime/tests/loader/empty_loader.qml new file mode 100644 index 0000000000..9f288f8ad5 --- /dev/null +++ b/tools/qmltime/tests/loader/empty_loader.qml @@ -0,0 +1,48 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + Item { + Loader {} + Loaded {} + } + } + } +} + diff --git a/tools/qmltime/tests/loader/no_loader.qml b/tools/qmltime/tests/loader/no_loader.qml new file mode 100644 index 0000000000..c84b9d3dd6 --- /dev/null +++ b/tools/qmltime/tests/loader/no_loader.qml @@ -0,0 +1,47 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + Item { + Loaded {} + } + } + } +} + diff --git a/tools/qmltime/tests/loader/source_loader.qml b/tools/qmltime/tests/loader/source_loader.qml new file mode 100644 index 0000000000..41a1792d2c --- /dev/null +++ b/tools/qmltime/tests/loader/source_loader.qml @@ -0,0 +1,49 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + Item { + Loader { + source: "Loaded.qml" + } + } + } + } +} + diff --git a/tools/qmltime/tests/positioner_creation/no_positioner.qml b/tools/qmltime/tests/positioner_creation/no_positioner.qml new file mode 100644 index 0000000000..09a3fb4321 --- /dev/null +++ b/tools/qmltime/tests/positioner_creation/no_positioner.qml @@ -0,0 +1,70 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + QmlTime.Timer { + component: Component { + Item { + Rectangle { } + Rectangle { } + Item { + Image { } + Text { } + } + + Item { + Item { + Image { } + Image { } + Item { + Image { } + Image { } + } + } + + Item { + Item { + Text { } + Text { } + } + Text { } + } + } + MouseArea { } + } + } + } +} diff --git a/tools/qmltime/tests/positioner_creation/null_positioner.qml b/tools/qmltime/tests/positioner_creation/null_positioner.qml new file mode 100644 index 0000000000..957688bcee --- /dev/null +++ b/tools/qmltime/tests/positioner_creation/null_positioner.qml @@ -0,0 +1,67 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + QmlTime.Timer { + component: Component { + Item { + Rectangle { } + Rectangle { } + Item { + Image { } + Text { } + } + + Item { + Item { + Image { } + Image { } + Row { } + Image { } + Image { } + } + + Column { } + Row { } + Text { } + Text { } + Text { } + } + MouseArea { } + } + } + } +} diff --git a/tools/qmltime/tests/positioner_creation/positioner.qml b/tools/qmltime/tests/positioner_creation/positioner.qml new file mode 100644 index 0000000000..4e6f08a1fe --- /dev/null +++ b/tools/qmltime/tests/positioner_creation/positioner.qml @@ -0,0 +1,70 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + QmlTime.Timer { + component: Component { + Item { + Rectangle { } + Rectangle { } + Item { + Image { } + Text { } + } + + Item { + Item { + Image { } + Image { } + Row { + Image { } + Image { } + } + } + + Column { + Row { + Text { } + Text { } + } + Text { } + } + } + MouseArea { } + } + } + } +} diff --git a/tools/qmltime/tests/vmemetaobject/null.qml b/tools/qmltime/tests/vmemetaobject/null.qml new file mode 100644 index 0000000000..f695c989a3 --- /dev/null +++ b/tools/qmltime/tests/vmemetaobject/null.qml @@ -0,0 +1,46 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + QtObject { + } + } + } + +} diff --git a/tools/qmltime/tests/vmemetaobject/property.qml b/tools/qmltime/tests/vmemetaobject/property.qml new file mode 100644 index 0000000000..f0ccabe2f0 --- /dev/null +++ b/tools/qmltime/tests/vmemetaobject/property.qml @@ -0,0 +1,51 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Component { + QtObject { + property string s + property string s2 + property string s3 + property string s4 + } + } + } + +} + diff --git a/tools/qmltime/textingrid.qml b/tools/qmltime/textingrid.qml new file mode 100644 index 0000000000..69dbdb5dd6 --- /dev/null +++ b/tools/qmltime/textingrid.qml @@ -0,0 +1,65 @@ +/**************************************************************************** +** +** Copyright (C) 2015 The Qt Company Ltd. +** Contact: http://www.qt.io/licensing/ +** +** This file is part of the QtQml module of the Qt Toolkit. +** +** $QT_BEGIN_LICENSE:LGPL21$ +** Commercial License Usage +** Licensees holding valid commercial Qt licenses may use this file in +** accordance with the commercial license agreement provided with the +** Software or, alternatively, in accordance with the terms contained in +** a written agreement between you and The Qt Company. For licensing terms +** and conditions see http://www.qt.io/terms-conditions. For further +** information use the contact form at http://www.qt.io/contact-us. +** +** GNU Lesser General Public License Usage +** Alternatively, this file may be used under the terms of the GNU Lesser +** General Public License version 2.1 or version 3 as published by the Free +** Software Foundation and appearing in the file LICENSE.LGPLv21 and +** LICENSE.LGPLv3 included in the packaging of this file. Please review the +** following information to ensure the GNU Lesser General Public License +** requirements will be met: https://www.gnu.org/licenses/lgpl.html and +** http://www.gnu.org/licenses/old-licenses/lgpl-2.1.html. +** +** As a special exception, The Qt Company gives you certain additional +** rights. These rights are described in The Qt Company LGPL Exception +** version 1.1, included in the file LGPL_EXCEPTION.txt in this package. +** +** $QT_END_LICENSE$ +** +****************************************************************************/ + +import QtQuick 2.0 +import QmlTime 1.0 as QmlTime + +Item { + + QmlTime.Timer { + component: Grid { + width: 480 + height: width + + id: grid + columns: 7 + rows: 6 + + Repeater { + model: 42 + Text { + width: grid.width / grid.columns; height: width + color: "blue" + text: index + font.pixelSize: 15 + font.bold: true + horizontalAlignment: Text.AlignHCenter + verticalAlignment: Text.AlignVCenter + + } + } + + } + } +} + -- cgit v1.2.3