diff options
Diffstat (limited to 'examples/widgets')
147 files changed, 441 insertions, 192 deletions
diff --git a/examples/widgets/animation/easing/CMakeLists.txt b/examples/widgets/animation/easing/CMakeLists.txt index 2067b0c0d3..1073e7eb4f 100644 --- a/examples/widgets/animation/easing/CMakeLists.txt +++ b/examples/widgets/animation/easing/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/animation/easing") @@ -21,17 +21,18 @@ qt_add_executable(easing main.cpp window.cpp window.h ) + set_target_properties(easing PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(easing PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(easing_resource_files "images/qt-logo.png" diff --git a/examples/widgets/desktop/screenshot/CMakeLists.txt b/examples/widgets/desktop/screenshot/CMakeLists.txt index 95bba7ee31..c3fce5efcf 100644 --- a/examples/widgets/desktop/screenshot/CMakeLists.txt +++ b/examples/widgets/desktop/screenshot/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/desktop/screenshot") @@ -19,10 +19,12 @@ qt_add_executable(screenshot main.cpp screenshot.cpp screenshot.h ) + set_target_properties(screenshot PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(screenshot PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/desktop/systray/CMakeLists.txt b/examples/widgets/desktop/systray/CMakeLists.txt index c2b0d859ba..4f87873bee 100644 --- a/examples/widgets/desktop/systray/CMakeLists.txt +++ b/examples/widgets/desktop/systray/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/desktop/systray") @@ -19,17 +19,18 @@ qt_add_executable(systray main.cpp window.cpp window.h ) + set_target_properties(systray PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(systray PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(systray_resource_files "images/bad.png" diff --git a/examples/widgets/dialogs/classwizard/CMakeLists.txt b/examples/widgets/dialogs/classwizard/CMakeLists.txt index c9c4b44f59..fb1ff096eb 100644 --- a/examples/widgets/dialogs/classwizard/CMakeLists.txt +++ b/examples/widgets/dialogs/classwizard/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/classwizard") @@ -19,17 +19,18 @@ qt_add_executable(classwizard classwizard.cpp classwizard.h main.cpp ) + set_target_properties(classwizard PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(classwizard PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(classwizard_resource_files "images/background.png" diff --git a/examples/widgets/dialogs/extension/CMakeLists.txt b/examples/widgets/dialogs/extension/CMakeLists.txt index 243fb13a47..ac443d27d1 100644 --- a/examples/widgets/dialogs/extension/CMakeLists.txt +++ b/examples/widgets/dialogs/extension/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/extension") @@ -19,10 +19,12 @@ qt_add_executable(extension finddialog.cpp finddialog.h main.cpp ) + set_target_properties(extension PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(extension PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/dialogs/findfiles/CMakeLists.txt b/examples/widgets/dialogs/findfiles/CMakeLists.txt index 4d870b193e..d93ad390e7 100644 --- a/examples/widgets/dialogs/findfiles/CMakeLists.txt +++ b/examples/widgets/dialogs/findfiles/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/findfiles") @@ -19,10 +19,12 @@ qt_add_executable(findfiles main.cpp window.cpp window.h ) + set_target_properties(findfiles PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(findfiles PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/dialogs/licensewizard/CMakeLists.txt b/examples/widgets/dialogs/licensewizard/CMakeLists.txt index c043ff18fd..cc4c48b3f0 100644 --- a/examples/widgets/dialogs/licensewizard/CMakeLists.txt +++ b/examples/widgets/dialogs/licensewizard/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/licensewizard") @@ -19,10 +19,12 @@ qt_add_executable(licensewizard licensewizard.cpp licensewizard.h main.cpp ) + set_target_properties(licensewizard PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(licensewizard PUBLIC Qt::Core Qt::Gui @@ -30,7 +32,6 @@ target_link_libraries(licensewizard PUBLIC Qt::Widgets ) - # Resources: set(licensewizard_resource_files "images/logo.png" diff --git a/examples/widgets/dialogs/standarddialogs/CMakeLists.txt b/examples/widgets/dialogs/standarddialogs/CMakeLists.txt index 5a709a5cee..d5b7705601 100644 --- a/examples/widgets/dialogs/standarddialogs/CMakeLists.txt +++ b/examples/widgets/dialogs/standarddialogs/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/standarddialogs") @@ -19,10 +19,12 @@ qt_add_executable(standarddialogs dialog.cpp dialog.h main.cpp ) + set_target_properties(standarddialogs PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(standarddialogs PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/dialogs/tabdialog/CMakeLists.txt b/examples/widgets/dialogs/tabdialog/CMakeLists.txt index 13d41ddee8..51f8ab8be9 100644 --- a/examples/widgets/dialogs/tabdialog/CMakeLists.txt +++ b/examples/widgets/dialogs/tabdialog/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/tabdialog") @@ -19,10 +19,12 @@ qt_add_executable(tabdialog main.cpp tabdialog.cpp tabdialog.h ) + set_target_properties(tabdialog PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(tabdialog PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/dialogs/trivialwizard/CMakeLists.txt b/examples/widgets/dialogs/trivialwizard/CMakeLists.txt index 9502ebbd78..eff5e5c33d 100644 --- a/examples/widgets/dialogs/trivialwizard/CMakeLists.txt +++ b/examples/widgets/dialogs/trivialwizard/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/dialogs/trivialwizard") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(trivialwizard trivialwizard.cpp ) + set_target_properties(trivialwizard PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(trivialwizard PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/draganddrop/draggableicons/CMakeLists.txt b/examples/widgets/draganddrop/draggableicons/CMakeLists.txt index ee157bbf25..c73c54d32b 100644 --- a/examples/widgets/draganddrop/draggableicons/CMakeLists.txt +++ b/examples/widgets/draganddrop/draggableicons/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/draggableicons") @@ -19,17 +19,18 @@ qt_add_executable(draggableicons dragwidget.cpp dragwidget.h main.cpp ) + set_target_properties(draggableicons PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(draggableicons PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(draggableicons_resource_files "images/boat.png" diff --git a/examples/widgets/draganddrop/draggabletext/CMakeLists.txt b/examples/widgets/draganddrop/draggabletext/CMakeLists.txt index 7aba6ac56c..34758858e8 100644 --- a/examples/widgets/draganddrop/draggabletext/CMakeLists.txt +++ b/examples/widgets/draganddrop/draggabletext/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/draggabletext") @@ -19,17 +19,18 @@ qt_add_executable(draggabletext dragwidget.cpp dragwidget.h main.cpp ) + set_target_properties(draggabletext PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(draggabletext PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(draggabletext_resource_files "words.txt" diff --git a/examples/widgets/draganddrop/dropsite/CMakeLists.txt b/examples/widgets/draganddrop/dropsite/CMakeLists.txt index a3a4d0fbe8..e602f7c7f4 100644 --- a/examples/widgets/draganddrop/dropsite/CMakeLists.txt +++ b/examples/widgets/draganddrop/dropsite/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/dropsite") @@ -20,10 +20,12 @@ qt_add_executable(dropsite dropsitewindow.cpp dropsitewindow.h main.cpp ) + set_target_properties(dropsite PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dropsite PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt b/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt index 2f2087fd3d..462c48254b 100644 --- a/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt +++ b/examples/widgets/draganddrop/fridgemagnets/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/draganddrop/fridgemagnets") @@ -20,17 +20,18 @@ qt_add_executable(fridgemagnets dragwidget.cpp dragwidget.h main.cpp ) + set_target_properties(fridgemagnets PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(fridgemagnets PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(fridgemagnets_resource_files "words.txt" diff --git a/examples/widgets/draganddrop/puzzle/CMakeLists.txt b/examples/widgets/draganddrop/puzzle/CMakeLists.txt index cf6350f16d..221b152540 100644 --- a/examples/widgets/draganddrop/puzzle/CMakeLists.txt +++ b/examples/widgets/draganddrop/puzzle/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/draganddrop_puzzle") @@ -21,17 +21,18 @@ qt_add_executable(draganddrop_puzzle pieceslist.cpp pieceslist.h puzzlewidget.cpp puzzlewidget.h ) + set_target_properties(draganddrop_puzzle PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(draganddrop_puzzle PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(puzzle_resource_files "example.jpg" diff --git a/examples/widgets/effects/blurpicker/CMakeLists.txt b/examples/widgets/effects/blurpicker/CMakeLists.txt index 679b788ed8..b4f1c48306 100644 --- a/examples/widgets/effects/blurpicker/CMakeLists.txt +++ b/examples/widgets/effects/blurpicker/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/effects/blurpicker") @@ -20,17 +20,18 @@ qt_add_executable(blurpicker blurpicker.cpp blurpicker.h main.cpp ) + set_target_properties(blurpicker PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(blurpicker PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(blurpicker_resource_files "images/accessories-calculator.png" diff --git a/examples/widgets/effects/fademessage/CMakeLists.txt b/examples/widgets/effects/fademessage/CMakeLists.txt index c561189f5a..c81897b073 100644 --- a/examples/widgets/effects/fademessage/CMakeLists.txt +++ b/examples/widgets/effects/fademessage/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/effects/fademessage") @@ -19,17 +19,18 @@ qt_add_executable(fademessage fademessage.cpp fademessage.h main.cpp ) + set_target_properties(fademessage PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(fademessage PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(fademessage_resource_files "background.jpg" diff --git a/examples/widgets/gallery/CMakeLists.txt b/examples/widgets/gallery/CMakeLists.txt index 6cee5313b8..19f1dd053c 100644 --- a/examples/widgets/gallery/CMakeLists.txt +++ b/examples/widgets/gallery/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/gallery") @@ -19,10 +19,12 @@ qt_add_executable(gallery main.cpp widgetgallery.cpp widgetgallery.h ) + set_target_properties(gallery PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(gallery PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/gestures/imagegestures/CMakeLists.txt b/examples/widgets/gestures/imagegestures/CMakeLists.txt index 9094bfab3d..3380aac969 100644 --- a/examples/widgets/gestures/imagegestures/CMakeLists.txt +++ b/examples/widgets/gestures/imagegestures/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/gestures/imagegestures") @@ -20,10 +20,12 @@ qt_add_executable(imagegestures main.cpp mainwidget.cpp mainwidget.h ) + set_target_properties(imagegestures PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(imagegestures PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt b/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt index f4151c77b5..7ec2bcf31e 100644 --- a/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt +++ b/examples/widgets/graphicsview/anchorlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/anchorlayout") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(anchorlayout main.cpp ) + set_target_properties(anchorlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(anchorlayout PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt b/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt index a788419124..2d3f57dbaf 100644 --- a/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt +++ b/examples/widgets/graphicsview/basicgraphicslayouts/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/basicgraphicslayouts") @@ -20,17 +20,18 @@ qt_add_executable(basicgraphicslayouts main.cpp window.cpp window.h ) + set_target_properties(basicgraphicslayouts PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(basicgraphicslayouts PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(basicgraphicslayouts_resource_files "images/block.png" diff --git a/examples/widgets/graphicsview/chip/CMakeLists.txt b/examples/widgets/graphicsview/chip/CMakeLists.txt index dc48cdd84f..d187ddeacf 100644 --- a/examples/widgets/graphicsview/chip/CMakeLists.txt +++ b/examples/widgets/graphicsview/chip/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/chip") @@ -24,17 +24,18 @@ qt_add_executable(chip mainwindow.cpp mainwindow.h view.cpp view.h ) + set_target_properties(chip PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(chip PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(images_resource_files "fileprint.png" diff --git a/examples/widgets/graphicsview/collidingmice/CMakeLists.txt b/examples/widgets/graphicsview/collidingmice/CMakeLists.txt index aab329528f..f45831533c 100644 --- a/examples/widgets/graphicsview/collidingmice/CMakeLists.txt +++ b/examples/widgets/graphicsview/collidingmice/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/collidingmice") @@ -19,17 +19,18 @@ qt_add_executable(collidingmice main.cpp mouse.cpp mouse.h ) + set_target_properties(collidingmice PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(collidingmice PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(mice_resource_files "images/cheese.jpg" diff --git a/examples/widgets/graphicsview/diagramscene/CMakeLists.txt b/examples/widgets/graphicsview/diagramscene/CMakeLists.txt index 5559f16dea..d2d056d2a6 100644 --- a/examples/widgets/graphicsview/diagramscene/CMakeLists.txt +++ b/examples/widgets/graphicsview/diagramscene/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/diagramscene") @@ -23,17 +23,18 @@ qt_add_executable(diagramscene main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(diagramscene PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(diagramscene PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(diagramscene_resource_files "images/background1.png" diff --git a/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt b/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt index eb4f8bf00f..f18037b25e 100644 --- a/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt +++ b/examples/widgets/graphicsview/dragdroprobot/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/dragdroprobot") @@ -20,17 +20,18 @@ qt_add_executable(dragdroprobot main.cpp robot.cpp robot.h ) + set_target_properties(dragdroprobot PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dragdroprobot PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(robot_resource_files "images/head.png" diff --git a/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt b/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt index 369ed964c5..f7aa44fc38 100644 --- a/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt +++ b/examples/widgets/graphicsview/elasticnodes/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/elasticnodes") @@ -21,10 +21,12 @@ qt_add_executable(elasticnodes main.cpp node.cpp node.h ) + set_target_properties(elasticnodes PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(elasticnodes PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt b/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt index 63eecd3be9..6f37c28b98 100644 --- a/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt +++ b/examples/widgets/graphicsview/embeddeddialogs/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/embeddeddialogs") @@ -20,17 +20,18 @@ qt_add_executable(embeddeddialogs embeddeddialog.cpp embeddeddialog.h embeddeddialog.ui main.cpp ) + set_target_properties(embeddeddialogs PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(embeddeddialogs PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(embeddeddialogs_resource_files "No-Ones-Laughing-3.jpg" diff --git a/examples/widgets/graphicsview/flowlayout/CMakeLists.txt b/examples/widgets/graphicsview/flowlayout/CMakeLists.txt index 9093f6303b..ffcbdb14c4 100644 --- a/examples/widgets/graphicsview/flowlayout/CMakeLists.txt +++ b/examples/widgets/graphicsview/flowlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview_flowlayout") @@ -20,10 +20,12 @@ qt_add_executable(graphicsview_flowlayout main.cpp window.cpp window.h ) + set_target_properties(graphicsview_flowlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(graphicsview_flowlayout PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt b/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt index 73f25bb156..24571d9533 100644 --- a/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt +++ b/examples/widgets/graphicsview/simpleanchorlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/simpleanchorlayout") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(simpleanchorlayout main.cpp ) + set_target_properties(simpleanchorlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(simpleanchorlayout PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt b/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt index 92056a1c51..6261c536ef 100644 --- a/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt +++ b/examples/widgets/graphicsview/weatheranchorlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/graphicsview/weatheranchorlayout") @@ -18,17 +18,18 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(weatheranchorlayout main.cpp ) + set_target_properties(weatheranchorlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(weatheranchorlayout PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(weatheranchorlayout_resource_files "images/5days.jpg" diff --git a/examples/widgets/itemviews/addressbook/CMakeLists.txt b/examples/widgets/itemviews/addressbook/CMakeLists.txt index e697186600..b8cbdce144 100644 --- a/examples/widgets/itemviews/addressbook/CMakeLists.txt +++ b/examples/widgets/itemviews/addressbook/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/addressbook") @@ -23,10 +23,12 @@ qt_add_executable(addressbook newaddresstab.cpp newaddresstab.h tablemodel.cpp tablemodel.h ) + set_target_properties(addressbook PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(addressbook PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt b/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt index 3046ab25b1..2540b04454 100644 --- a/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt +++ b/examples/widgets/itemviews/basicsortfiltermodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/basicsortfiltermodel") @@ -19,10 +19,12 @@ qt_add_executable(basicsortfiltermodel main.cpp window.cpp window.h ) + set_target_properties(basicsortfiltermodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(basicsortfiltermodel PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/chart/CMakeLists.txt b/examples/widgets/itemviews/chart/CMakeLists.txt index 8e749211f2..7d79621dd7 100644 --- a/examples/widgets/itemviews/chart/CMakeLists.txt +++ b/examples/widgets/itemviews/chart/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/chart") @@ -20,17 +20,18 @@ qt_add_executable(chart mainwindow.cpp mainwindow.h pieview.cpp pieview.h ) + set_target_properties(chart PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(chart PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(chart_resource_files "qtdata.cht" diff --git a/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt b/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt index 0538d4ecd8..2f99f283b9 100644 --- a/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt +++ b/examples/widgets/itemviews/coloreditorfactory/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/coloreditorfactory") @@ -20,10 +20,12 @@ qt_add_executable(coloreditorfactory main.cpp window.cpp window.h ) + set_target_properties(coloreditorfactory PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(coloreditorfactory PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt b/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt index 9bd809dab9..6fc429c966 100644 --- a/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt +++ b/examples/widgets/itemviews/combowidgetmapper/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/combowidgetmapper") @@ -19,10 +19,12 @@ qt_add_executable(combowidgetmapper main.cpp window.cpp window.h ) + set_target_properties(combowidgetmapper PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(combowidgetmapper PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt b/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt index da4d4bdf0a..0c5f9be3b4 100644 --- a/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt +++ b/examples/widgets/itemviews/customsortfiltermodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/customsortfiltermodel") @@ -21,17 +21,18 @@ qt_add_executable(customsortfiltermodel mysortfilterproxymodel.cpp mysortfilterproxymodel.h window.cpp window.h ) + set_target_properties(customsortfiltermodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(customsortfiltermodel PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(customsortfiltermodel_resource_files "images/find.png" diff --git a/examples/widgets/itemviews/dirview/CMakeLists.txt b/examples/widgets/itemviews/dirview/CMakeLists.txt index cea54f5847..a371e8726b 100644 --- a/examples/widgets/itemviews/dirview/CMakeLists.txt +++ b/examples/widgets/itemviews/dirview/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/dirview") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(dirview main.cpp ) + set_target_properties(dirview PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dirview PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt b/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt index 8dfaf171be..ddcd00b8f2 100644 --- a/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt +++ b/examples/widgets/itemviews/editabletreemodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/editabletreemodel") @@ -21,17 +21,18 @@ qt_add_executable(editabletreemodel treeitem.cpp treeitem.h treemodel.cpp treemodel.h ) + set_target_properties(editabletreemodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(editabletreemodel PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(editabletreemodel_resource_files "default.txt" diff --git a/examples/widgets/itemviews/fetchmore/CMakeLists.txt b/examples/widgets/itemviews/fetchmore/CMakeLists.txt index 2ea49fd210..f65c61ca0e 100644 --- a/examples/widgets/itemviews/fetchmore/CMakeLists.txt +++ b/examples/widgets/itemviews/fetchmore/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/fetchmore") @@ -20,10 +20,12 @@ qt_add_executable(fetchmore main.cpp window.cpp window.h ) + set_target_properties(fetchmore PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(fetchmore PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/flattreeview/CMakeLists.txt b/examples/widgets/itemviews/flattreeview/CMakeLists.txt index c15fe84734..9ba0a1e159 100644 --- a/examples/widgets/itemviews/flattreeview/CMakeLists.txt +++ b/examples/widgets/itemviews/flattreeview/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/flattreeview") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(flattreeview main.cpp ) + set_target_properties(flattreeview PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(flattreeview PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/frozencolumn/CMakeLists.txt b/examples/widgets/itemviews/frozencolumn/CMakeLists.txt index 6180a204ac..3351cdf409 100644 --- a/examples/widgets/itemviews/frozencolumn/CMakeLists.txt +++ b/examples/widgets/itemviews/frozencolumn/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/frozencolumn") @@ -19,17 +19,18 @@ qt_add_executable(frozencolumn freezetablewidget.cpp freezetablewidget.h main.cpp ) + set_target_properties(frozencolumn PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(frozencolumn PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(grades_resource_files "grades.txt" diff --git a/examples/widgets/itemviews/interview/CMakeLists.txt b/examples/widgets/itemviews/interview/CMakeLists.txt index 9574b24d50..0d88dbdb7d 100644 --- a/examples/widgets/itemviews/interview/CMakeLists.txt +++ b/examples/widgets/itemviews/interview/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/interview") @@ -19,17 +19,18 @@ qt_add_executable(interview main.cpp model.cpp model.h ) + set_target_properties(interview PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(interview PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(interview_resource_files "images/folder.png" diff --git a/examples/widgets/itemviews/pixelator/CMakeLists.txt b/examples/widgets/itemviews/pixelator/CMakeLists.txt index be4cb6afc1..0ccd085d8f 100644 --- a/examples/widgets/itemviews/pixelator/CMakeLists.txt +++ b/examples/widgets/itemviews/pixelator/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/pixelator") @@ -24,17 +24,18 @@ qt_add_executable(pixelator mainwindow.cpp mainwindow.h pixeldelegate.cpp pixeldelegate.h ) + set_target_properties(pixelator PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(pixelator PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(images_resource_files "images/qt.png" diff --git a/examples/widgets/itemviews/puzzle/CMakeLists.txt b/examples/widgets/itemviews/puzzle/CMakeLists.txt index 4761852664..b3e9f368fd 100644 --- a/examples/widgets/itemviews/puzzle/CMakeLists.txt +++ b/examples/widgets/itemviews/puzzle/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/puzzle") @@ -21,17 +21,18 @@ qt_add_executable(itemviews_puzzle piecesmodel.cpp piecesmodel.h puzzlewidget.cpp puzzlewidget.h ) + set_target_properties(itemviews_puzzle PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(itemviews_puzzle PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(puzzle_resource_files "example.jpg" diff --git a/examples/widgets/itemviews/simpledommodel/CMakeLists.txt b/examples/widgets/itemviews/simpledommodel/CMakeLists.txt index 47c26d1b2e..5b98f68848 100644 --- a/examples/widgets/itemviews/simpledommodel/CMakeLists.txt +++ b/examples/widgets/itemviews/simpledommodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/simpledommodel") @@ -21,10 +21,12 @@ qt_add_executable(simpledommodel main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(simpledommodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(simpledommodel PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt b/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt index f6d8aae118..8e6d40274f 100644 --- a/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt +++ b/examples/widgets/itemviews/simpletreemodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/simpletreemodel") @@ -20,17 +20,18 @@ qt_add_executable(simpletreemodel treeitem.cpp treeitem.h treemodel.cpp treemodel.h ) + set_target_properties(simpletreemodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(simpletreemodel PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(simpletreemodel_resource_files "default.txt" diff --git a/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt b/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt index 14ad9bd96c..d34149f224 100644 --- a/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt +++ b/examples/widgets/itemviews/simplewidgetmapper/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/simplewidgetmapper") @@ -19,10 +19,12 @@ qt_add_executable(simplewidgetmapper main.cpp window.cpp window.h ) + set_target_properties(simplewidgetmapper PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(simplewidgetmapper PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt b/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt index bcea33915c..a16eb0c53c 100644 --- a/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt +++ b/examples/widgets/itemviews/spinboxdelegate/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/spinboxdelegate") @@ -19,10 +19,12 @@ qt_add_executable(spinboxdelegate delegate.cpp delegate.h main.cpp ) + set_target_properties(spinboxdelegate PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(spinboxdelegate PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/spreadsheet/CMakeLists.txt b/examples/widgets/itemviews/spreadsheet/CMakeLists.txt index e0089a0ed9..2fd1d6b52a 100644 --- a/examples/widgets/itemviews/spreadsheet/CMakeLists.txt +++ b/examples/widgets/itemviews/spreadsheet/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/spreadsheet") @@ -25,10 +25,12 @@ qt_add_executable(spreadsheet spreadsheetdelegate.cpp spreadsheetdelegate.h spreadsheetitem.cpp spreadsheetitem.h ) + set_target_properties(spreadsheet PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(spreadsheet PUBLIC Qt::Core Qt::Gui @@ -39,7 +41,6 @@ if (TARGET Qt::PrintSupport) target_link_libraries(spreadsheet PUBLIC Qt::PrintSupport) endif() - # Resources: set(spreadsheet_resource_files "images/interview.png" diff --git a/examples/widgets/itemviews/stardelegate/CMakeLists.txt b/examples/widgets/itemviews/stardelegate/CMakeLists.txt index 136dc7c83d..44fdd068c5 100644 --- a/examples/widgets/itemviews/stardelegate/CMakeLists.txt +++ b/examples/widgets/itemviews/stardelegate/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/stardelegate") @@ -21,10 +21,12 @@ qt_add_executable(stardelegate stareditor.cpp stareditor.h starrating.cpp starrating.h ) + set_target_properties(stardelegate PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(stardelegate PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/itemviews/storageview/CMakeLists.txt b/examples/widgets/itemviews/storageview/CMakeLists.txt index 43a11e9f12..6338e214e9 100644 --- a/examples/widgets/itemviews/storageview/CMakeLists.txt +++ b/examples/widgets/itemviews/storageview/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/itemviews/storageview") @@ -19,10 +19,12 @@ qt_add_executable(storageview main.cpp storagemodel.cpp storagemodel.h ) + set_target_properties(storageview PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(storageview PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/layouts/basiclayouts/CMakeLists.txt b/examples/widgets/layouts/basiclayouts/CMakeLists.txt index 52518163a1..40c27a4a9e 100644 --- a/examples/widgets/layouts/basiclayouts/CMakeLists.txt +++ b/examples/widgets/layouts/basiclayouts/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/layouts/basiclayouts") @@ -19,10 +19,12 @@ qt_add_executable(basiclayouts dialog.cpp dialog.h main.cpp ) + set_target_properties(basiclayouts PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(basiclayouts PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/layouts/borderlayout/CMakeLists.txt b/examples/widgets/layouts/borderlayout/CMakeLists.txt index 3c04f1b66a..4b725eb6a5 100644 --- a/examples/widgets/layouts/borderlayout/CMakeLists.txt +++ b/examples/widgets/layouts/borderlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/layouts/borderlayout") @@ -20,10 +20,12 @@ qt_add_executable(borderlayout main.cpp window.cpp window.h ) + set_target_properties(borderlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(borderlayout PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt b/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt index 565829c1c2..fc0f545baa 100644 --- a/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt +++ b/examples/widgets/layouts/dynamiclayouts/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/layouts/dynamiclayouts") @@ -19,10 +19,12 @@ qt_add_executable(dynamiclayouts dialog.cpp dialog.h main.cpp ) + set_target_properties(dynamiclayouts PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dynamiclayouts PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/layouts/flowlayout/CMakeLists.txt b/examples/widgets/layouts/flowlayout/CMakeLists.txt index c28668fb49..762b95f64f 100644 --- a/examples/widgets/layouts/flowlayout/CMakeLists.txt +++ b/examples/widgets/layouts/flowlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/layouts/flowlayout") @@ -20,10 +20,12 @@ qt_add_executable(flowlayout main.cpp window.cpp window.h ) + set_target_properties(flowlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(flowlayout PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/mainwindows/application/CMakeLists.txt b/examples/widgets/mainwindows/application/CMakeLists.txt index 262548a6e1..297a8a31a8 100644 --- a/examples/widgets/mainwindows/application/CMakeLists.txt +++ b/examples/widgets/mainwindows/application/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/application") @@ -19,17 +19,18 @@ qt_add_executable(application main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(application PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(application PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(application_resource_files "images/copy.png" diff --git a/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt b/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt index 5dff006c70..599633909f 100644 --- a/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt +++ b/examples/widgets/mainwindows/dockwidgets/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/dockwidgets") @@ -22,10 +22,12 @@ qt_add_executable(dockwidgets main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(dockwidgets PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dockwidgets PUBLIC Qt::Core Qt::Gui @@ -36,7 +38,6 @@ if (TARGET Qt::PrintSupport) target_link_libraries(dockwidgets PUBLIC Qt::PrintSupport) endif() - # Resources: set(dockwidgets_resource_files "images/new.png" diff --git a/examples/widgets/mainwindows/mainwindow/CMakeLists.txt b/examples/widgets/mainwindows/mainwindow/CMakeLists.txt index ee04a59d94..3eb634287e 100644 --- a/examples/widgets/mainwindows/mainwindow/CMakeLists.txt +++ b/examples/widgets/mainwindows/mainwindow/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/mainwindow") @@ -21,17 +21,18 @@ qt_add_executable(mainwindow mainwindow.cpp mainwindow.h toolbar.cpp toolbar.h ) + set_target_properties(mainwindow PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mainwindow PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(mainwindow_resource_files "qt.png" diff --git a/examples/widgets/mainwindows/mdi/CMakeLists.txt b/examples/widgets/mainwindows/mdi/CMakeLists.txt index 7a2efef80f..ce72767f1c 100644 --- a/examples/widgets/mainwindows/mdi/CMakeLists.txt +++ b/examples/widgets/mainwindows/mdi/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/mdi") @@ -20,17 +20,18 @@ qt_add_executable(mdi mainwindow.cpp mainwindow.h mdichild.cpp mdichild.h ) + set_target_properties(mdi PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mdi PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(mdi_resource_files "images/copy.png" diff --git a/examples/widgets/mainwindows/menus/CMakeLists.txt b/examples/widgets/mainwindows/menus/CMakeLists.txt index ee5eb4e616..61ccd76f16 100644 --- a/examples/widgets/mainwindows/menus/CMakeLists.txt +++ b/examples/widgets/mainwindows/menus/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/menus") @@ -19,10 +19,12 @@ qt_add_executable(menus main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(menus PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(menus PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/mainwindows/sdi/CMakeLists.txt b/examples/widgets/mainwindows/sdi/CMakeLists.txt index 89b3228293..616f096edf 100644 --- a/examples/widgets/mainwindows/sdi/CMakeLists.txt +++ b/examples/widgets/mainwindows/sdi/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/mainwindows/sdi") @@ -19,17 +19,18 @@ qt_add_executable(sdi main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(sdi PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(sdi PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(sdi_resource_files "images/copy.png" diff --git a/examples/widgets/painting/affine/CMakeLists.txt b/examples/widgets/painting/affine/CMakeLists.txt index 88792be8f0..bf27c49fce 100644 --- a/examples/widgets/painting/affine/CMakeLists.txt +++ b/examples/widgets/painting/affine/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/affine") @@ -23,10 +23,12 @@ qt_add_executable(affine main.cpp xform.cpp xform.h ) + set_target_properties(affine PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(affine PUBLIC ../shared ) @@ -42,7 +44,6 @@ target_link_libraries(affine PUBLIC painting_shared::painting_shared ) - # Resources: set(shared_resource_files "../shared/images/button_normal_cap_left.png" @@ -90,6 +91,7 @@ qt_add_resources(affine "shared" FILES ${shared_resource_files} ) + set(affine_resource_files "bg1.jpg" "xform.cpp" diff --git a/examples/widgets/painting/basicdrawing/CMakeLists.txt b/examples/widgets/painting/basicdrawing/CMakeLists.txt index 83faca559e..574f508412 100644 --- a/examples/widgets/painting/basicdrawing/CMakeLists.txt +++ b/examples/widgets/painting/basicdrawing/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/basicdrawing") @@ -20,17 +20,18 @@ qt_add_executable(basicdrawing renderarea.cpp renderarea.h window.cpp window.h ) + set_target_properties(basicdrawing PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(basicdrawing PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(basicdrawing_resource_files "images/brick.png" diff --git a/examples/widgets/painting/composition/CMakeLists.txt b/examples/widgets/painting/composition/CMakeLists.txt index 62156d45e4..ca8c2e0214 100644 --- a/examples/widgets/painting/composition/CMakeLists.txt +++ b/examples/widgets/painting/composition/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/composition") @@ -23,10 +23,12 @@ qt_add_executable(composition composition.cpp composition.h main.cpp ) + set_target_properties(composition PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(composition PUBLIC ../shared ) @@ -42,7 +44,6 @@ target_link_libraries(composition PUBLIC painting_shared::painting_shared ) - # Resources: set(shared_resource_files "../shared/images/button_normal_cap_left.png" @@ -90,6 +91,7 @@ qt_add_resources(composition "shared" FILES ${shared_resource_files} ) + set(composition_resource_files "composition.cpp" "composition.html" diff --git a/examples/widgets/painting/concentriccircles/CMakeLists.txt b/examples/widgets/painting/concentriccircles/CMakeLists.txt index 72ed7d8776..a37cc58b1f 100644 --- a/examples/widgets/painting/concentriccircles/CMakeLists.txt +++ b/examples/widgets/painting/concentriccircles/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/concentriccircles") @@ -20,10 +20,12 @@ qt_add_executable(concentriccircles main.cpp window.cpp window.h ) + set_target_properties(concentriccircles PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(concentriccircles PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/painting/deform/CMakeLists.txt b/examples/widgets/painting/deform/CMakeLists.txt index 1174cf5a27..12f48f7891 100644 --- a/examples/widgets/painting/deform/CMakeLists.txt +++ b/examples/widgets/painting/deform/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/deform") @@ -23,10 +23,12 @@ qt_add_executable(deform main.cpp pathdeform.cpp pathdeform.h ) + set_target_properties(deform PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(deform PUBLIC ../shared ) @@ -42,7 +44,6 @@ target_link_libraries(deform PUBLIC painting_shared::painting_shared ) - # Resources: set(shared_resource_files "../shared/images/button_normal_cap_left.png" @@ -90,6 +91,7 @@ qt_add_resources(deform "shared" FILES ${shared_resource_files} ) + set(deform_resource_files "pathdeform.cpp" "pathdeform.html" diff --git a/examples/widgets/painting/fontsampler/CMakeLists.txt b/examples/widgets/painting/fontsampler/CMakeLists.txt index e0b683ba33..5e92a51620 100644 --- a/examples/widgets/painting/fontsampler/CMakeLists.txt +++ b/examples/widgets/painting/fontsampler/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/fontsampler") @@ -23,10 +23,12 @@ qt_add_executable(fontsampler mainwindow.cpp mainwindow.h mainwindowbase.ui ) + set_target_properties(fontsampler PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(fontsampler PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/painting/gradients/CMakeLists.txt b/examples/widgets/painting/gradients/CMakeLists.txt index 6de1d3c47e..5df3d78ac1 100644 --- a/examples/widgets/painting/gradients/CMakeLists.txt +++ b/examples/widgets/painting/gradients/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/gradients") @@ -23,10 +23,12 @@ qt_add_executable(gradients gradients.cpp gradients.h main.cpp ) + set_target_properties(gradients PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(gradients PUBLIC ../shared ) @@ -42,7 +44,6 @@ target_link_libraries(gradients PUBLIC painting_shared::painting_shared ) - # Resources: set(shared_resource_files "../shared/images/button_normal_cap_left.png" @@ -90,6 +91,7 @@ qt_add_resources(gradients "shared" FILES ${shared_resource_files} ) + set(gradients_resource_files "gradients.cpp" "gradients.html" diff --git a/examples/widgets/painting/imagecomposition/CMakeLists.txt b/examples/widgets/painting/imagecomposition/CMakeLists.txt index 2887d84002..e5ff8cb82f 100644 --- a/examples/widgets/painting/imagecomposition/CMakeLists.txt +++ b/examples/widgets/painting/imagecomposition/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/imagecomposition") @@ -19,17 +19,18 @@ qt_add_executable(imagecomposition imagecomposer.cpp imagecomposer.h main.cpp ) + set_target_properties(imagecomposition PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(imagecomposition PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(imagecomposition_resource_files "images/butterfly.png" diff --git a/examples/widgets/painting/painterpaths/CMakeLists.txt b/examples/widgets/painting/painterpaths/CMakeLists.txt index f4530521dc..8bb43e775f 100644 --- a/examples/widgets/painting/painterpaths/CMakeLists.txt +++ b/examples/widgets/painting/painterpaths/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/painterpaths") @@ -20,10 +20,12 @@ qt_add_executable(painterpaths renderarea.cpp renderarea.h window.cpp window.h ) + set_target_properties(painterpaths PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(painterpaths PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/painting/pathstroke/CMakeLists.txt b/examples/widgets/painting/pathstroke/CMakeLists.txt index 9e28706529..63c804c7ce 100644 --- a/examples/widgets/painting/pathstroke/CMakeLists.txt +++ b/examples/widgets/painting/pathstroke/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/pathstroke") @@ -23,10 +23,12 @@ qt_add_executable(pathstroke main.cpp pathstroke.cpp pathstroke.h ) + set_target_properties(pathstroke PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(pathstroke PUBLIC ../shared ) @@ -42,7 +44,6 @@ target_link_libraries(pathstroke PUBLIC painting_shared::painting_shared ) - # Resources: set(shared_resource_files "../shared/images/button_normal_cap_left.png" @@ -90,6 +91,7 @@ qt_add_resources(pathstroke "shared" FILES ${shared_resource_files} ) + set(pathstroke_resource_files "pathstroke.cpp" "pathstroke.html" diff --git a/examples/widgets/painting/shared/CMakeLists.txt b/examples/widgets/painting/shared/CMakeLists.txt index bd1b2ef5c6..a81b1413c7 100644 --- a/examples/widgets/painting/shared/CMakeLists.txt +++ b/examples/widgets/painting/shared/CMakeLists.txt @@ -7,6 +7,7 @@ target_sources(painting_shared PRIVATE hoverpoints.cpp hoverpoints.h ${moc_files} ) + target_link_libraries(painting_shared PUBLIC Qt::Widgets) target_include_directories(painting_shared PUBLIC "${CMAKE_CURRENT_SOURCE_DIR}") diff --git a/examples/widgets/painting/transformations/CMakeLists.txt b/examples/widgets/painting/transformations/CMakeLists.txt index 990871318f..7c1c6495d7 100644 --- a/examples/widgets/painting/transformations/CMakeLists.txt +++ b/examples/widgets/painting/transformations/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/painting/transformations") @@ -20,10 +20,12 @@ qt_add_executable(transformations renderarea.cpp renderarea.h window.cpp window.h ) + set_target_properties(transformations PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(transformations PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/richtext/calendar/CMakeLists.txt b/examples/widgets/richtext/calendar/CMakeLists.txt index c883b30dcc..28b8249e84 100644 --- a/examples/widgets/richtext/calendar/CMakeLists.txt +++ b/examples/widgets/richtext/calendar/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/richtext/calendar") @@ -19,10 +19,12 @@ qt_add_executable(calendar main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(calendar PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(calendar PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/richtext/orderform/CMakeLists.txt b/examples/widgets/richtext/orderform/CMakeLists.txt index 32646d7b59..da099b79f1 100644 --- a/examples/widgets/richtext/orderform/CMakeLists.txt +++ b/examples/widgets/richtext/orderform/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/richtext/orderform") @@ -20,10 +20,12 @@ qt_add_executable(orderform main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(orderform PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(orderform PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt b/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt index d9a20cccd4..732c285cc6 100644 --- a/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt +++ b/examples/widgets/richtext/syntaxhighlighter/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/richtext/syntaxhighlighter") @@ -20,10 +20,12 @@ qt_add_executable(syntaxhighlighter main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(syntaxhighlighter PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(syntaxhighlighter PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/richtext/textedit/CMakeLists.txt b/examples/widgets/richtext/textedit/CMakeLists.txt index 3a29d09a61..1e22a14614 100644 --- a/examples/widgets/richtext/textedit/CMakeLists.txt +++ b/examples/widgets/richtext/textedit/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/richtext/textedit") @@ -22,10 +22,12 @@ qt_add_executable(textedit main.cpp textedit.cpp textedit.h ) + set_target_properties(textedit PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(textedit PUBLIC Qt::Core Qt::Gui @@ -36,7 +38,6 @@ if (TARGET Qt::PrintSupport) target_link_libraries(textedit PUBLIC Qt::PrintSupport) endif() - # Resources: set(textedit_resource_files "example.html" diff --git a/examples/widgets/scroller/graphicsview/CMakeLists.txt b/examples/widgets/scroller/graphicsview/CMakeLists.txt index 5f768c8694..36721aeae0 100644 --- a/examples/widgets/scroller/graphicsview/CMakeLists.txt +++ b/examples/widgets/scroller/graphicsview/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/scroller/graphicsview") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(graphicsview main.cpp ) + set_target_properties(graphicsview PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(graphicsview PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tools/completer/CMakeLists.txt b/examples/widgets/tools/completer/CMakeLists.txt index 8ec960dafd..21cd750de8 100644 --- a/examples/widgets/tools/completer/CMakeLists.txt +++ b/examples/widgets/tools/completer/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/completer") @@ -20,17 +20,18 @@ qt_add_executable(completer main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(completer PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(completer PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(completer_resource_files "resources/countries.txt" diff --git a/examples/widgets/tools/customcompleter/CMakeLists.txt b/examples/widgets/tools/customcompleter/CMakeLists.txt index 9e0bbee241..558262f948 100644 --- a/examples/widgets/tools/customcompleter/CMakeLists.txt +++ b/examples/widgets/tools/customcompleter/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/customcompleter") @@ -20,17 +20,18 @@ qt_add_executable(customcompleter mainwindow.cpp mainwindow.h textedit.cpp textedit.h ) + set_target_properties(customcompleter PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(customcompleter PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(customcompleter_resource_files "resources/wordlist.txt" diff --git a/examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt b/examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt index 3fcbe17172..29183a7c1f 100644 --- a/examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt +++ b/examples/widgets/tools/echoplugin/echowindow/CMakeLists.txt @@ -3,10 +3,12 @@ qt_add_executable(echopluginwindow echowindow.cpp echowindow.h main.cpp ) + set_target_properties(echopluginwindow PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(echopluginwindow PRIVATE Qt::Core Qt::Gui diff --git a/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt b/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt index fb727aa1d7..7d63180a87 100644 --- a/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt +++ b/examples/widgets/tools/echoplugin/plugin/CMakeLists.txt @@ -1,12 +1,15 @@ qt_add_plugin(echoplugin CLASS_NAME EchoPlugin ) + target_sources(echoplugin PRIVATE echoplugin.cpp echoplugin.h ) + set_target_properties(echoplugin PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/echowindow" ) + target_include_directories(echoplugin PUBLIC ../echowindow ) diff --git a/examples/widgets/tools/i18n/CMakeLists.txt b/examples/widgets/tools/i18n/CMakeLists.txt index 0cb230a805..362fa96c8f 100644 --- a/examples/widgets/tools/i18n/CMakeLists.txt +++ b/examples/widgets/tools/i18n/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/i18n") @@ -20,17 +20,18 @@ qt_add_executable(i18n main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(i18n PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(i18n PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(i18n_resource_files "translations/i18n_ar.qm" diff --git a/examples/widgets/tools/plugandpaint/app/CMakeLists.txt b/examples/widgets/tools/plugandpaint/app/CMakeLists.txt index 3e46331f81..f2b5b4937f 100644 --- a/examples/widgets/tools/plugandpaint/app/CMakeLists.txt +++ b/examples/widgets/tools/plugandpaint/app/CMakeLists.txt @@ -5,10 +5,12 @@ qt_add_executable(plugandpaint paintarea.cpp paintarea.h plugindialog.cpp plugindialog.h ) + set_target_properties(plugandpaint PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(plugandpaint PRIVATE Qt::Widgets pnp_basictools diff --git a/examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt b/examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt index 0056205319..638bb53ef6 100644 --- a/examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt +++ b/examples/widgets/tools/plugandpaint/plugins/basictools/CMakeLists.txt @@ -2,9 +2,11 @@ qt_add_plugin(pnp_basictools STATIC CLASS_NAME BasicToolsPlugin ) + target_sources(pnp_basictools PRIVATE basictoolsplugin.cpp basictoolsplugin.h ) + target_include_directories(pnp_basictools PUBLIC ../../app ) diff --git a/examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt b/examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt index 2332f84399..4a3dd45de9 100644 --- a/examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt +++ b/examples/widgets/tools/plugandpaint/plugins/extrafilters/CMakeLists.txt @@ -1,12 +1,15 @@ qt_add_plugin(pnp_extrafilters CLASS_NAME ExtraFiltersPlugin ) + target_sources(pnp_extrafilters PRIVATE extrafiltersplugin.cpp extrafiltersplugin.h ) + set_target_properties(pnp_extrafilters PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/app" ) + target_include_directories(pnp_extrafilters PUBLIC ../../app ) diff --git a/examples/widgets/tools/regularexpression/CMakeLists.txt b/examples/widgets/tools/regularexpression/CMakeLists.txt index 85f9a81156..c249eda5ac 100644 --- a/examples/widgets/tools/regularexpression/CMakeLists.txt +++ b/examples/widgets/tools/regularexpression/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/regularexpression") @@ -19,17 +19,18 @@ qt_add_executable(regularexpression main.cpp regularexpressiondialog.cpp regularexpressiondialog.h ) + set_target_properties(regularexpression PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(regularexpression PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(regularexpression_resource_files "images/copy.png" diff --git a/examples/widgets/tools/settingseditor/CMakeLists.txt b/examples/widgets/tools/settingseditor/CMakeLists.txt index e1b6f95eb5..11795c260b 100644 --- a/examples/widgets/tools/settingseditor/CMakeLists.txt +++ b/examples/widgets/tools/settingseditor/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/settingseditor") @@ -22,10 +22,12 @@ qt_add_executable(settingseditor settingstree.cpp settingstree.h variantdelegate.cpp variantdelegate.h ) + set_target_properties(settingseditor PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(settingseditor PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tools/styleplugin/plugin/CMakeLists.txt b/examples/widgets/tools/styleplugin/plugin/CMakeLists.txt index 30a06231c1..fb2b877ca6 100644 --- a/examples/widgets/tools/styleplugin/plugin/CMakeLists.txt +++ b/examples/widgets/tools/styleplugin/plugin/CMakeLists.txt @@ -1,13 +1,16 @@ qt_add_plugin(simplestyleplugin CLASS_NAME SimpleStylePlugin ) + target_sources(simplestyleplugin PRIVATE simplestyle.cpp simplestyle.h simplestyleplugin.cpp simplestyleplugin.h ) + set_target_properties(simplestyleplugin PROPERTIES LIBRARY_OUTPUT_DIRECTORY "${PROJECT_BINARY_DIR}/stylewindow/styles" ) + target_link_libraries(simplestyleplugin PRIVATE Qt::Core Qt::Gui diff --git a/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt b/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt index aab63afbf2..fe844aaf4b 100644 --- a/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt +++ b/examples/widgets/tools/styleplugin/stylewindow/CMakeLists.txt @@ -2,15 +2,18 @@ qt_add_executable(styleplugin main.cpp stylewindow.cpp stylewindow.h ) + set_target_properties(styleplugin PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(styleplugin PRIVATE Qt::Core Qt::Gui Qt::Widgets ) + if(NOT QT6_IS_SHARED_LIBS_BUILD) target_link_libraries(styleplugin PRIVATE simplestyleplugin diff --git a/examples/widgets/tools/treemodelcompleter/CMakeLists.txt b/examples/widgets/tools/treemodelcompleter/CMakeLists.txt index 1e641fc5b2..64b5e67309 100644 --- a/examples/widgets/tools/treemodelcompleter/CMakeLists.txt +++ b/examples/widgets/tools/treemodelcompleter/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/treemodelcompleter") @@ -20,17 +20,18 @@ qt_add_executable(treemodelcompleter mainwindow.cpp mainwindow.h treemodelcompleter.cpp treemodelcompleter.h ) + set_target_properties(treemodelcompleter PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(treemodelcompleter PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(treemodelcompleter_resource_files "resources/treemodel.txt" diff --git a/examples/widgets/tools/undo/CMakeLists.txt b/examples/widgets/tools/undo/CMakeLists.txt index 113b3b5a6d..0b9e5047e6 100644 --- a/examples/widgets/tools/undo/CMakeLists.txt +++ b/examples/widgets/tools/undo/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/undo") @@ -21,17 +21,18 @@ qt_add_executable(undo main.cpp mainwindow.cpp mainwindow.h mainwindow.ui ) + set_target_properties(undo PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(undo PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(undo_resource_files "icons/background.png" diff --git a/examples/widgets/tools/undoframework/CMakeLists.txt b/examples/widgets/tools/undoframework/CMakeLists.txt index c142f5d863..0d43d4a669 100644 --- a/examples/widgets/tools/undoframework/CMakeLists.txt +++ b/examples/widgets/tools/undoframework/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tools/undoframework") @@ -22,17 +22,18 @@ qt_add_executable(undoframework main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(undoframework PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(undoframework PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(undoframework_resource_files "images/cross.png" diff --git a/examples/widgets/touch/dials/CMakeLists.txt b/examples/widgets/touch/dials/CMakeLists.txt index a7a6153631..36789c0714 100644 --- a/examples/widgets/touch/dials/CMakeLists.txt +++ b/examples/widgets/touch/dials/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/touch/dials") @@ -19,10 +19,12 @@ qt_add_executable(dials dials.ui main.cpp ) + set_target_properties(dials PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(dials PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/touch/fingerpaint/CMakeLists.txt b/examples/widgets/touch/fingerpaint/CMakeLists.txt index f2ed4be8df..d7f22940f3 100644 --- a/examples/widgets/touch/fingerpaint/CMakeLists.txt +++ b/examples/widgets/touch/fingerpaint/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/touch/fingerpaint") @@ -23,10 +23,12 @@ qt_add_executable(fingerpaint mainwindow.cpp mainwindow.h scribblearea.cpp scribblearea.h ) + set_target_properties(fingerpaint PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(fingerpaint PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/touch/knobs/CMakeLists.txt b/examples/widgets/touch/knobs/CMakeLists.txt index f92bb52a59..e921365791 100644 --- a/examples/widgets/touch/knobs/CMakeLists.txt +++ b/examples/widgets/touch/knobs/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/touch/knobs") @@ -19,10 +19,12 @@ qt_add_executable(knobs knob.cpp knob.h main.cpp ) + set_target_properties(knobs PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(knobs PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/touch/pinchzoom/CMakeLists.txt b/examples/widgets/touch/pinchzoom/CMakeLists.txt index 19a9fe6c67..d7528ea8f0 100644 --- a/examples/widgets/touch/pinchzoom/CMakeLists.txt +++ b/examples/widgets/touch/pinchzoom/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/touch/pinchzoom") @@ -20,17 +20,18 @@ qt_add_executable(pinchzoom main.cpp mouse.cpp mouse.h ) + set_target_properties(pinchzoom PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(pinchzoom PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(mice_resource_files "images/cheese.jpg" diff --git a/examples/widgets/tutorials/addressbook/part1/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part1/CMakeLists.txt index c7f30def59..d30c561486 100644 --- a/examples/widgets/tutorials/addressbook/part1/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part1/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part1") @@ -19,10 +19,12 @@ qt_add_executable(part1 addressbook.cpp addressbook.h main.cpp ) + set_target_properties(part1 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part1 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt index 9cb1ff02a9..16019b2d0a 100644 --- a/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part2/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part2") @@ -19,10 +19,12 @@ qt_add_executable(part2 addressbook.cpp addressbook.h main.cpp ) + set_target_properties(part2 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part2 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt index 56385d9d25..232fb299c7 100644 --- a/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part3/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part3") @@ -19,10 +19,12 @@ qt_add_executable(part3 addressbook.cpp addressbook.h main.cpp ) + set_target_properties(part3 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part3 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt index cf99c3b801..04f72d3450 100644 --- a/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part4/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part4") @@ -19,10 +19,12 @@ qt_add_executable(part4 addressbook.cpp addressbook.h main.cpp ) + set_target_properties(part4 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part4 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt index 96ac3257d7..343bc60657 100644 --- a/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part5/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part5") @@ -20,10 +20,12 @@ qt_add_executable(part5 finddialog.cpp finddialog.h main.cpp ) + set_target_properties(part5 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part5 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt index 673996b9a5..91d4c0cf8d 100644 --- a/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part6/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part6") @@ -20,10 +20,12 @@ qt_add_executable(part6 finddialog.cpp finddialog.h main.cpp ) + set_target_properties(part6 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part6 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt b/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt index 41a89a2753..dbd4e49d50 100644 --- a/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt +++ b/examples/widgets/tutorials/addressbook/part7/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/addressbook/part7") @@ -20,10 +20,12 @@ qt_add_executable(part7 finddialog.cpp finddialog.h main.cpp ) + set_target_properties(part7 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(part7 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt index 97bd513ef5..90cf464550 100644 --- a/examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt +++ b/examples/widgets/tutorials/gettingStarted/gsQt/part1/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part1") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(getting_started_part1 main.cpp ) + set_target_properties(getting_started_part1 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(getting_started_part1 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt index c10322046b..cdb39fd2b4 100644 --- a/examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt +++ b/examples/widgets/tutorials/gettingStarted/gsQt/part2/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part2") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(getting_started_part2 main.cpp ) + set_target_properties(getting_started_part2 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(getting_started_part2 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt index d5e5dfb603..6a4f3c4faf 100644 --- a/examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt +++ b/examples/widgets/tutorials/gettingStarted/gsQt/part3/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part3") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(getting_started_part3 main.cpp ) + set_target_properties(getting_started_part3 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(getting_started_part3 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt index 6531bce71c..f4a28f0f0b 100644 --- a/examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt +++ b/examples/widgets/tutorials/gettingStarted/gsQt/part4/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part4") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(getting_started_part4 main.cpp ) + set_target_properties(getting_started_part4 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(getting_started_part4 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt b/examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt index 1cdc84dd71..71f4df16cc 100644 --- a/examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt +++ b/examples/widgets/tutorials/gettingStarted/gsQt/part5/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/gettingStarted/gsQt/part5") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(getting_started_part5 main.cpp ) + set_target_properties(getting_started_part5 PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(getting_started_part5 PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt b/examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt index 045e6409d6..39f6753490 100644 --- a/examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/1_readonly/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/1_readonly") @@ -19,10 +19,12 @@ qt_add_executable(mv_readonly main.cpp mymodel.cpp mymodel.h ) + set_target_properties(mv_readonly PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_readonly PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt b/examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt index c3e9a29d54..7479df3cec 100644 --- a/examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/2_formatting/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/2_formatting") @@ -19,10 +19,12 @@ qt_add_executable(mv_formatting main.cpp mymodel.cpp mymodel.h ) + set_target_properties(mv_formatting PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_formatting PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt b/examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt index b8a4c9ba1f..99fcf9bbe7 100644 --- a/examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/3_changingmodel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/3_changingmodel") @@ -19,10 +19,12 @@ qt_add_executable(mv_changingmodel main.cpp mymodel.cpp mymodel.h ) + set_target_properties(mv_changingmodel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_changingmodel PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt b/examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt index 80d55f3096..1b3a4462b7 100644 --- a/examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/4_headers/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/4_headers") @@ -19,10 +19,12 @@ qt_add_executable(mv_headers main.cpp mymodel.cpp mymodel.h ) + set_target_properties(mv_headers PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_headers PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt b/examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt index 61cffe039f..bcfaf4f539 100644 --- a/examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/5_edit/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/5_edit") @@ -20,10 +20,12 @@ qt_add_executable(mv_edit mainwindow.cpp mainwindow.h mymodel.cpp mymodel.h ) + set_target_properties(mv_edit PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_edit PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt b/examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt index b4ba1d7256..8d269c53fb 100644 --- a/examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/6_treeview/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/6_treeview") @@ -19,10 +19,12 @@ qt_add_executable(mv_tree main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(mv_tree PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_tree PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt b/examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt index aef8718e5f..5ae8c349fc 100644 --- a/examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt +++ b/examples/widgets/tutorials/modelview/7_selections/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/modelview/7_selections") @@ -19,10 +19,12 @@ qt_add_executable(mv_selections main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(mv_selections PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mv_selections PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/notepad/CMakeLists.txt b/examples/widgets/tutorials/notepad/CMakeLists.txt index aa11c84a6b..cdfe9a7c54 100644 --- a/examples/widgets/tutorials/notepad/CMakeLists.txt +++ b/examples/widgets/tutorials/notepad/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/notepad") @@ -22,17 +22,18 @@ qt_add_executable(notepad main.cpp notepad.cpp notepad.h notepad.ui ) + set_target_properties(notepad PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(notepad PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(notepad_resource_files "images/bold.png" diff --git a/examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt b/examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt index e88197dc95..f0d619b99a 100644 --- a/examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt +++ b/examples/widgets/tutorials/widgets/childwidget/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/childwidget") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(childwidget main.cpp ) + set_target_properties(childwidget PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(childwidget PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt b/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt index e3b31cfa4e..c0fd8e402e 100644 --- a/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt +++ b/examples/widgets/tutorials/widgets/nestedlayouts/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/nestedlayouts") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(nestedlayouts main.cpp ) + set_target_properties(nestedlayouts PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(nestedlayouts PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt b/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt index 14bd7a63fa..8e396dd499 100644 --- a/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt +++ b/examples/widgets/tutorials/widgets/toplevel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/toplevel") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(toplevel main.cpp ) + set_target_properties(toplevel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(toplevel PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt b/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt index ae8b995868..0f5f8cac09 100644 --- a/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt +++ b/examples/widgets/tutorials/widgets/windowlayout/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/tutorials/widgets/windowlayout") @@ -18,10 +18,12 @@ find_package(Qt6 REQUIRED COMPONENTS Core Gui Widgets) qt_add_executable(windowlayout main.cpp ) + set_target_properties(windowlayout PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(windowlayout PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/analogclock/CMakeLists.txt b/examples/widgets/widgets/analogclock/CMakeLists.txt index b775b23485..c2272d1c58 100644 --- a/examples/widgets/widgets/analogclock/CMakeLists.txt +++ b/examples/widgets/widgets/analogclock/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/analogclock") @@ -19,10 +19,12 @@ qt_add_executable(analogclock analogclock.cpp analogclock.h main.cpp ) + set_target_properties(analogclock PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(analogclock PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/calculator/CMakeLists.txt b/examples/widgets/widgets/calculator/CMakeLists.txt index 419e4e3bd1..632b29830d 100644 --- a/examples/widgets/widgets/calculator/CMakeLists.txt +++ b/examples/widgets/widgets/calculator/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/calculator") @@ -20,10 +20,12 @@ qt_add_executable(calculator calculator.cpp calculator.h main.cpp ) + set_target_properties(calculator PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(calculator PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/calendarwidget/CMakeLists.txt b/examples/widgets/widgets/calendarwidget/CMakeLists.txt index b1ee4577f1..ded17a89b2 100644 --- a/examples/widgets/widgets/calendarwidget/CMakeLists.txt +++ b/examples/widgets/widgets/calendarwidget/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/calendarwidget") @@ -19,10 +19,12 @@ qt_add_executable(calendarwidget main.cpp window.cpp window.h ) + set_target_properties(calendarwidget PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(calendarwidget PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/charactermap/CMakeLists.txt b/examples/widgets/widgets/charactermap/CMakeLists.txt index 65956f7afd..5b04621e1c 100644 --- a/examples/widgets/widgets/charactermap/CMakeLists.txt +++ b/examples/widgets/widgets/charactermap/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/charactermap") @@ -20,10 +20,12 @@ qt_add_executable(charactermap main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(charactermap PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(charactermap PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/codeeditor/CMakeLists.txt b/examples/widgets/widgets/codeeditor/CMakeLists.txt index 9eb4f1a8bd..4d00611116 100644 --- a/examples/widgets/widgets/codeeditor/CMakeLists.txt +++ b/examples/widgets/widgets/codeeditor/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/codeeditor") @@ -19,10 +19,12 @@ qt_add_executable(codeeditor codeeditor.cpp codeeditor.h main.cpp ) + set_target_properties(codeeditor PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(codeeditor PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/digitalclock/CMakeLists.txt b/examples/widgets/widgets/digitalclock/CMakeLists.txt index e2e1c4a1e3..722a91245a 100644 --- a/examples/widgets/widgets/digitalclock/CMakeLists.txt +++ b/examples/widgets/widgets/digitalclock/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/digitalclock") @@ -19,10 +19,12 @@ qt_add_executable(digitalclock digitalclock.cpp digitalclock.h main.cpp ) + set_target_properties(digitalclock PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(digitalclock PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/elidedlabel/CMakeLists.txt b/examples/widgets/widgets/elidedlabel/CMakeLists.txt index feb46d9720..0b83c6f08b 100644 --- a/examples/widgets/widgets/elidedlabel/CMakeLists.txt +++ b/examples/widgets/widgets/elidedlabel/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/elidedlabel") @@ -20,10 +20,12 @@ qt_add_executable(elidedlabel main.cpp testwidget.cpp testwidget.h ) + set_target_properties(elidedlabel PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(elidedlabel PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/groupbox/CMakeLists.txt b/examples/widgets/widgets/groupbox/CMakeLists.txt index 9108a0a868..a77209454f 100644 --- a/examples/widgets/widgets/groupbox/CMakeLists.txt +++ b/examples/widgets/widgets/groupbox/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/groupbox") @@ -19,10 +19,12 @@ qt_add_executable(groupbox main.cpp window.cpp window.h ) + set_target_properties(groupbox PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(groupbox PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/icons/CMakeLists.txt b/examples/widgets/widgets/icons/CMakeLists.txt index 52a59c1d3d..5db4cf58e8 100644 --- a/examples/widgets/widgets/icons/CMakeLists.txt +++ b/examples/widgets/widgets/icons/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/icons") @@ -22,10 +22,12 @@ qt_add_executable(icons main.cpp mainwindow.cpp mainwindow.h ) + set_target_properties(icons PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_compile_definitions(icons PUBLIC SRCDIR="${CMAKE_CURRENT_SOURCE_DIR}" ) diff --git a/examples/widgets/widgets/imageviewer/CMakeLists.txt b/examples/widgets/widgets/imageviewer/CMakeLists.txt index 96b782b0cd..6fda6fbaeb 100644 --- a/examples/widgets/widgets/imageviewer/CMakeLists.txt +++ b/examples/widgets/widgets/imageviewer/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/imageviewer") @@ -22,10 +22,12 @@ qt_add_executable(imageviewer imageviewer.cpp imageviewer.h main.cpp ) + set_target_properties(imageviewer PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(imageviewer PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/lineedits/CMakeLists.txt b/examples/widgets/widgets/lineedits/CMakeLists.txt index 7cc503cdfc..6b42e04b43 100644 --- a/examples/widgets/widgets/lineedits/CMakeLists.txt +++ b/examples/widgets/widgets/lineedits/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/lineedits") @@ -19,10 +19,12 @@ qt_add_executable(lineedits main.cpp window.cpp window.h ) + set_target_properties(lineedits PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(lineedits PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/mousebuttons/CMakeLists.txt b/examples/widgets/widgets/mousebuttons/CMakeLists.txt index 8083642320..5e4067cafd 100644 --- a/examples/widgets/widgets/mousebuttons/CMakeLists.txt +++ b/examples/widgets/widgets/mousebuttons/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/mousebuttons") @@ -19,10 +19,12 @@ qt_add_executable(mousebuttons buttontester.cpp buttontester.h main.cpp ) + set_target_properties(mousebuttons PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(mousebuttons PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/movie/CMakeLists.txt b/examples/widgets/widgets/movie/CMakeLists.txt index 37ff633a6a..74f6480667 100644 --- a/examples/widgets/widgets/movie/CMakeLists.txt +++ b/examples/widgets/widgets/movie/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/movie") @@ -19,10 +19,12 @@ qt_add_executable(movie main.cpp movieplayer.cpp movieplayer.h ) + set_target_properties(movie PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(movie PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/scribble/CMakeLists.txt b/examples/widgets/widgets/scribble/CMakeLists.txt index 92001b138f..9827312ccb 100644 --- a/examples/widgets/widgets/scribble/CMakeLists.txt +++ b/examples/widgets/widgets/scribble/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/scribble") @@ -23,10 +23,12 @@ qt_add_executable(scribble mainwindow.cpp mainwindow.h scribblearea.cpp scribblearea.h ) + set_target_properties(scribble PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(scribble PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/shapedclock/CMakeLists.txt b/examples/widgets/widgets/shapedclock/CMakeLists.txt index 5271bcf096..e941da0390 100644 --- a/examples/widgets/widgets/shapedclock/CMakeLists.txt +++ b/examples/widgets/widgets/shapedclock/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/shapedclock") @@ -19,10 +19,12 @@ qt_add_executable(shapedclock main.cpp shapedclock.cpp shapedclock.h ) + set_target_properties(shapedclock PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(shapedclock PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/sliders/CMakeLists.txt b/examples/widgets/widgets/sliders/CMakeLists.txt index 8354eef6af..615ecdf288 100644 --- a/examples/widgets/widgets/sliders/CMakeLists.txt +++ b/examples/widgets/widgets/sliders/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/sliders") @@ -20,10 +20,12 @@ qt_add_executable(sliders slidersgroup.cpp slidersgroup.h window.cpp window.h ) + set_target_properties(sliders PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(sliders PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/spinboxes/CMakeLists.txt b/examples/widgets/widgets/spinboxes/CMakeLists.txt index bc38a8f360..835cf9148f 100644 --- a/examples/widgets/widgets/spinboxes/CMakeLists.txt +++ b/examples/widgets/widgets/spinboxes/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/spinboxes") @@ -19,10 +19,12 @@ qt_add_executable(spinboxes main.cpp window.cpp window.h ) + set_target_properties(spinboxes PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(spinboxes PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/styles/CMakeLists.txt b/examples/widgets/widgets/styles/CMakeLists.txt index ca478eccaa..d472c1efd2 100644 --- a/examples/widgets/widgets/styles/CMakeLists.txt +++ b/examples/widgets/widgets/styles/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/styles") @@ -20,17 +20,18 @@ qt_add_executable(styles norwegianwoodstyle.cpp norwegianwoodstyle.h widgetgallery.cpp widgetgallery.h ) + set_target_properties(styles PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(styles PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(styles_resource_files "images/woodbackground.png" diff --git a/examples/widgets/widgets/stylesheet/CMakeLists.txt b/examples/widgets/widgets/stylesheet/CMakeLists.txt index 743859d5cb..b91fde9f74 100644 --- a/examples/widgets/widgets/stylesheet/CMakeLists.txt +++ b/examples/widgets/widgets/stylesheet/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/stylesheet") @@ -20,17 +20,18 @@ qt_add_executable(stylesheet mainwindow.cpp mainwindow.h mainwindow.ui stylesheeteditor.cpp stylesheeteditor.h stylesheeteditor.ui ) + set_target_properties(stylesheet PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(stylesheet PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(stylesheet_resource_files "images/checkbox_checked.png" diff --git a/examples/widgets/widgets/tablet/CMakeLists.txt b/examples/widgets/widgets/tablet/CMakeLists.txt index f2faeef3f9..ede90ce392 100644 --- a/examples/widgets/widgets/tablet/CMakeLists.txt +++ b/examples/widgets/widgets/tablet/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/tablet") @@ -21,17 +21,18 @@ qt_add_executable(qttablet tabletapplication.cpp tabletapplication.h tabletcanvas.cpp tabletcanvas.h ) + set_target_properties(qttablet PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(qttablet PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(images_resource_files "images/cursor-airbrush.png" diff --git a/examples/widgets/widgets/tetrix/CMakeLists.txt b/examples/widgets/widgets/tetrix/CMakeLists.txt index 6e76e5c9f0..b60c882d1d 100644 --- a/examples/widgets/widgets/tetrix/CMakeLists.txt +++ b/examples/widgets/widgets/tetrix/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/tetrix") @@ -21,10 +21,12 @@ qt_add_executable(tetrix tetrixpiece.cpp tetrixpiece.h tetrixwindow.cpp tetrixwindow.h ) + set_target_properties(tetrix PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(tetrix PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/tooltips/CMakeLists.txt b/examples/widgets/widgets/tooltips/CMakeLists.txt index 8126e7eb06..2172beba37 100644 --- a/examples/widgets/widgets/tooltips/CMakeLists.txt +++ b/examples/widgets/widgets/tooltips/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/tooltips") @@ -20,17 +20,18 @@ qt_add_executable(tooltips shapeitem.cpp shapeitem.h sortingbox.cpp sortingbox.h ) + set_target_properties(tooltips PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(tooltips PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(tooltips_resource_files "images/circle.png" diff --git a/examples/widgets/widgets/validators/CMakeLists.txt b/examples/widgets/widgets/validators/CMakeLists.txt index c6e9ea905f..0151d68d0e 100644 --- a/examples/widgets/widgets/validators/CMakeLists.txt +++ b/examples/widgets/widgets/validators/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/validators") @@ -22,17 +22,18 @@ qt_add_executable(validators validators.ui validatorwidget.cpp validatorwidget.h ) + set_target_properties(validators PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(validators PUBLIC Qt::Core Qt::Gui Qt::Widgets ) - # Resources: set(validators_resource_files "ledoff.png" diff --git a/examples/widgets/widgets/wiggly/CMakeLists.txt b/examples/widgets/widgets/wiggly/CMakeLists.txt index 26bd8d14e8..92b0b34156 100644 --- a/examples/widgets/widgets/wiggly/CMakeLists.txt +++ b/examples/widgets/widgets/wiggly/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/wiggly") @@ -20,10 +20,12 @@ qt_add_executable(wiggly main.cpp wigglywidget.cpp wigglywidget.h ) + set_target_properties(wiggly PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(wiggly PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/widgets/windowflags/CMakeLists.txt b/examples/widgets/widgets/windowflags/CMakeLists.txt index 914bfd60eb..697f72fcfb 100644 --- a/examples/widgets/widgets/windowflags/CMakeLists.txt +++ b/examples/widgets/widgets/windowflags/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/widgets/windowflags") @@ -20,10 +20,12 @@ qt_add_executable(windowflags main.cpp previewwindow.cpp previewwindow.h ) + set_target_properties(windowflags PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_link_libraries(windowflags PUBLIC Qt::Core Qt::Gui diff --git a/examples/widgets/windowcontainer/CMakeLists.txt b/examples/widgets/windowcontainer/CMakeLists.txt index b4f948311f..5af9687b13 100644 --- a/examples/widgets/windowcontainer/CMakeLists.txt +++ b/examples/widgets/windowcontainer/CMakeLists.txt @@ -8,7 +8,7 @@ set(CMAKE_AUTORCC ON) set(CMAKE_AUTOUIC ON) if(NOT DEFINED INSTALL_EXAMPLESDIR) - set(INSTALL_EXAMPLESDIR "examples") + set(INSTALL_EXAMPLESDIR "examples") endif() set(INSTALL_EXAMPLEDIR "${INSTALL_EXAMPLESDIR}/widgets/windowcontainer") @@ -19,10 +19,12 @@ qt_add_executable(windowcontainer ../../opengl/openglwindow/openglwindow.cpp ../../opengl/openglwindow/openglwindow.h windowcontainer.cpp ) + set_target_properties(windowcontainer PROPERTIES WIN32_EXECUTABLE TRUE MACOSX_BUNDLE TRUE ) + target_include_directories(windowcontainer PUBLIC ../../opengl/openglwindow ) |