diff options
author | Jan Arve Sæther <jan-arve.saether@qt.io> | 2023-02-28 18:03:41 +0100 |
---|---|---|
committer | Jan Arve Sæther <jan-arve.saether@qt.io> | 2023-03-07 11:38:40 +0100 |
commit | 556a56104e64ccb8f18c3605ee21e3bc170a3cd3 (patch) | |
tree | 6a8290d0fc96bc0aa7767d336b0de634e554079d | |
parent | 74078c5fc6a0031e5c4ffdabfc1001bc1b154bdc (diff) | |
download | qtbase-556a56104e64ccb8f18c3605ee21e3bc170a3cd3.tar.gz |
Move anchor layout example to manual tests
Change-Id: I9c9a9dbcdaf705a31208b80b71e978938a492142
Reviewed-by: Oliver Eftevaag <oliver.eftevaag@qt.io>
(cherry picked from commit 5773c3ac28dc3f7bd5e6e4571b99f944199fd9d7)
-rw-r--r-- | doc/global/manifest-meta.qdocconf | 1 | ||||
-rw-r--r-- | examples/widgets/doc/images/graphicsanchorlayout-example.png | bin | 24372 -> 0 bytes | |||
-rw-r--r-- | examples/widgets/doc/src/graphicsview-anchorlayout.qdoc | 57 | ||||
-rw-r--r-- | examples/widgets/graphicsview/CMakeLists.txt | 1 | ||||
-rw-r--r-- | examples/widgets/graphicsview/anchorlayout/CMakeLists.txt | 36 | ||||
-rw-r--r-- | examples/widgets/graphicsview/graphicsview.pro | 1 | ||||
-rw-r--r-- | tests/manual/qgraphicslayout/anchorlayout/CMakeLists.txt | 17 | ||||
-rw-r--r-- | tests/manual/qgraphicslayout/anchorlayout/anchorlayout.pro (renamed from examples/widgets/graphicsview/anchorlayout/anchorlayout.pro) | 0 | ||||
-rw-r--r-- | tests/manual/qgraphicslayout/anchorlayout/main.cpp (renamed from examples/widgets/graphicsview/anchorlayout/main.cpp) | 0 |
9 files changed, 17 insertions, 96 deletions
diff --git a/doc/global/manifest-meta.qdocconf b/doc/global/manifest-meta.qdocconf index a57946dd6e..872ff46d05 100644 --- a/doc/global/manifest-meta.qdocconf +++ b/doc/global/manifest-meta.qdocconf @@ -179,7 +179,6 @@ manifestmeta.ios.names = "QtCore/Contiguous Cache Example" \ "QtWidgets/Blur Picker Effect Example" \ "QtWidgets/Fade Message Effect Example" \ "QtWidgets/Lighting Effect Example" \ - "QtWidgets/Anchor Layout Example" \ "QtWidgets/Basic Graphics Layouts Example" \ "QtWidgets/40000 Chips" \ "QtWidgets/Colliding Mice Example" \ diff --git a/examples/widgets/doc/images/graphicsanchorlayout-example.png b/examples/widgets/doc/images/graphicsanchorlayout-example.png Binary files differdeleted file mode 100644 index 3f35fdb6b7..0000000000 --- a/examples/widgets/doc/images/graphicsanchorlayout-example.png +++ /dev/null diff --git a/examples/widgets/doc/src/graphicsview-anchorlayout.qdoc b/examples/widgets/doc/src/graphicsview-anchorlayout.qdoc deleted file mode 100644 index ec74367f9b..0000000000 --- a/examples/widgets/doc/src/graphicsview-anchorlayout.qdoc +++ /dev/null @@ -1,57 +0,0 @@ -// Copyright (C) 2016 The Qt Company Ltd. -// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR GFDL-1.3-no-invariants-only - -/*! - \example graphicsview/anchorlayout - \title Anchor Layout Example - \ingroup examples-graphicsview-layout - \brief Demonstrates anchor layout in a graphics view scene. - - The Anchor Layout example demonstrates the use of the QGraphicsAnchorLayout - class. - - \image graphicsanchorlayout-example.png - - The basic steps of this example are: - \list - \li Create a QGraphicsScene - \li Create widgets - \li Create a QGraphicsAnchorLayout - \li Create a QGraphicsWidget - \li Add vertical and horizontal anchors between the widgets - \li View the scene with a QGraphicsView object - \endlist - - \section1 Creating a QGraphicsScene - - \quotefromfile graphicsview/anchorlayout/main.cpp - \skipto QGraphicsScene - \printuntil setSceneRect - - \section1 Creating Widgets - - \skipto QGraphicsProxyWidget - \printuntil *g - - \section1 Creating a Layout - - \skipto QGraphicsAnchorLayout - \printuntil l->setSpacing - - \section1 Creating a QGraphicsWidget - - \skipto QGraphicsWidget - \printuntil setLayout(l) - - \section1 Adding Anchors - - \skipto vertical - \printuntil l->addAnchor(f, Qt::AnchorRight - - \section1 Viewing the Scene with QGraphicsView - - \skipto scene.addItem - \printuntil view.show - - \sa {Simple Anchor Layout Example} -*/ diff --git a/examples/widgets/graphicsview/CMakeLists.txt b/examples/widgets/graphicsview/CMakeLists.txt index 496d2179bb..e0d291312e 100644 --- a/examples/widgets/graphicsview/CMakeLists.txt +++ b/examples/widgets/graphicsview/CMakeLists.txt @@ -8,7 +8,6 @@ qt_internal_add_example(collidingmice) qt_internal_add_example(basicgraphicslayouts) qt_internal_add_example(diagramscene) qt_internal_add_example(flowlayout) -qt_internal_add_example(anchorlayout) qt_internal_add_example(simpleanchorlayout) if(QT_FEATURE_cursor AND QT_FEATURE_draganddrop) qt_internal_add_example(dragdroprobot) diff --git a/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt b/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt deleted file mode 100644 index 73197b56dd..0000000000 --- a/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt +++ /dev/null @@ -1,36 +0,0 @@ -# Copyright (C) 2022 The Qt Company Ltd. -# SPDX-License-Identifier: BSD-3-Clause - -cmake_minimum_required(VERSION 3.16) -project(anchorlayout LANGUAGES CXX) - -if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") -endif() - -set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/anchorlayout") - -find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) - -qt_standard_project_setup() - -qt_add_executable(anchorlayout - main.cpp -) - -set_target_properties(anchorlayout PROPERTIES - WIN32_EXECUTABLE TRUE - MACOSX_BUNDLE TRUE -) - -target_link_libraries(anchorlayout PRIVATE - Qt6::Core - Qt6::Gui - Qt6::Widgets -) - -install(TARGETS anchorlayout - RUNTIME DESTINATION "${INSTALL_EXAMPLEDIR}" - BUNDLE DESTINATION "${INSTALL_EXAMPLEDIR}" - LIBRARY DESTINATION "${INSTALL_EXAMPLEDIR}" -) diff --git a/examples/widgets/graphicsview/graphicsview.pro b/examples/widgets/graphicsview/graphicsview.pro index 218ee991ce..b3e49050ba 100644 --- a/examples/widgets/graphicsview/graphicsview.pro +++ b/examples/widgets/graphicsview/graphicsview.pro @@ -8,7 +8,6 @@ SUBDIRS = \ diagramscene \ dragdroprobot \ flowlayout \ - anchorlayout \ simpleanchorlayout contains(DEFINES, QT_NO_CURSOR)|!qtConfig(draganddrop): SUBDIRS -= dragdroprobot diff --git a/tests/manual/qgraphicslayout/anchorlayout/CMakeLists.txt b/tests/manual/qgraphicslayout/anchorlayout/CMakeLists.txt new file mode 100644 index 0000000000..13331a74a8 --- /dev/null +++ b/tests/manual/qgraphicslayout/anchorlayout/CMakeLists.txt @@ -0,0 +1,17 @@ +# Copyright (C) 2022 The Qt Company Ltd. +# SPDX-License-Identifier: BSD-3-Clause + +##################################################################### +## anchorlayout Binary: +##################################################################### +cmake_minimum_required(VERSION 3.16) + +qt_internal_add_manual_test(anchorlayout + GUI + SOURCES + main.cpp + LIBRARIES + Qt::Gui + Qt::Widgets +) + diff --git a/examples/widgets/graphicsview/anchorlayout/anchorlayout.pro b/tests/manual/qgraphicslayout/anchorlayout/anchorlayout.pro index 1afba2747c..1afba2747c 100644 --- a/examples/widgets/graphicsview/anchorlayout/anchorlayout.pro +++ b/tests/manual/qgraphicslayout/anchorlayout/anchorlayout.pro diff --git a/examples/widgets/graphicsview/anchorlayout/main.cpp b/tests/manual/qgraphicslayout/anchorlayout/main.cpp index ee8f94f236..ee8f94f236 100644 --- a/examples/widgets/graphicsview/anchorlayout/main.cpp +++ b/tests/manual/qgraphicslayout/anchorlayout/main.cpp |