diff --git a/CMakeLists.txt b/CMakeLists.txt index d64a443e..e017628b 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -7,7 +7,7 @@ set(CMAKE_CXX_STANDARD_REQUIRED ON) find_package(ECM 6.0.0 REQUIRED NO_MODULE) set(CMAKE_MODULE_PATH ${ECM_MODULE_PATH}) -set(PROJECT_VERSION "6.8.0") +set(PROJECT_VERSION "6.7.91") set(PROJECT_VERSION_MAJOR 6) set(CMAKE_AUTOMOC ON) @@ -27,7 +27,6 @@ include(ECMConfiguredInstall) include(ECMGenerateDBusServiceFile) include(ECMFindQmlModule) include(ECMGenerateExportHeader) -include(ECMSetupVersion) include(ECMGenerateQmlTypes) include(ECMDeprecationSettings) include(ECMQmlModule) diff --git a/plasma/atpootb/.clang-format b/plasma/atpootb/.clang-format new file mode 100644 index 00000000..9b5ae0af --- /dev/null +++ b/plasma/atpootb/.clang-format @@ -0,0 +1,95 @@ +--- +# SPDX-FileCopyrightText: 2019 Christoph Cullmann +# SPDX-FileCopyrightText: 2019 Gernot Gebhard +# +# SPDX-License-Identifier: MIT + +# This file got automatically created by ECM, do not edit +# See https://clang.llvm.org/docs/ClangFormatStyleOptions.html for the config options +# and https://community.kde.org/Policies/Frameworks_Coding_Style#Clang-format_automatic_code_formatting +# for clang-format tips & tricks +--- +Language: JavaScript +DisableFormat: true +--- +Language: Json +DisableFormat: false +IndentWidth: 4 +--- + +# Style for C++ +Language: Cpp + +# base is WebKit coding style: https://webkit.org/code-style-guidelines/ +# below are only things set that diverge from this style! +BasedOnStyle: WebKit + +# enforce C++11 (e.g. for std::vector> +Standard: Cpp11 + +# 4 spaces indent +TabWidth: 4 + +# 2 * 80 wide lines +ColumnLimit: 160 + +# sort includes inside line separated groups +SortIncludes: true + +# break before braces on function, namespace and class definitions. +BreakBeforeBraces: Linux + +# CrlInstruction *a; +PointerAlignment: Right + +# horizontally aligns arguments after an open bracket. +AlignAfterOpenBracket: Align + +# don't move all parameters to new line +AllowAllParametersOfDeclarationOnNextLine: false + +# no single line functions +AllowShortFunctionsOnASingleLine: None + +# no single line enums +AllowShortEnumsOnASingleLine: false + +# always break before you encounter multi line strings +AlwaysBreakBeforeMultilineStrings: true + +# don't move arguments to own lines if they are not all on the same +BinPackArguments: false + +# don't move parameters to own lines if they are not all on the same +BinPackParameters: false + +# In case we have an if statement with multiple lines the operator should be at the beginning of the line +# but we do not want to break assignments +BreakBeforeBinaryOperators: NonAssignment + +# format C++11 braced lists like function calls +Cpp11BracedListStyle: true + +# do not put a space before C++11 braced lists +SpaceBeforeCpp11BracedList: false + +# remove empty lines +KeepEmptyLinesAtTheStartOfBlocks: false + +# no namespace indentation to keep indent level low +NamespaceIndentation: None + +# we use template< without space. +SpaceAfterTemplateKeyword: false + +# Always break after template declaration +AlwaysBreakTemplateDeclarations: true + +# macros for which the opening brace stays attached. +ForEachMacros: [ foreach, Q_FOREACH, BOOST_FOREACH, forever, Q_FOREVER, QBENCHMARK, QBENCHMARK_ONCE , wl_resource_for_each, wl_resource_for_each_safe ] + +# keep lambda formatting multi-line if not empty +AllowShortLambdasOnASingleLine: Empty + +# We do not want clang-format to put all arguments on a new line +AllowAllArgumentsOnNextLine: false diff --git a/plasma/atpootb/CMakeLists.txt b/plasma/atpootb/CMakeLists.txt index 15c77817..a97e69a7 100644 --- a/plasma/atpootb/CMakeLists.txt +++ b/plasma/atpootb/CMakeLists.txt @@ -1,19 +1,71 @@ # SPDX-FileCopyrightText: 2025 WackyIdeas # SPDX-License-Identifier: BSD-3-Clause -configure_file(config.h.cmake config.h) -kauth_install_actions(io.gitgud.wackyideas.ootb kauth.actions) +cmake_minimum_required(VERSION 3.16) + +project(atpootb VERSION 0.1) + +include(FeatureSummary) + +set(QT6_MIN_VERSION 6.5.0) +set(KF6_MIN_VERSION 6.12.0) + +find_package(ECM ${KF6_MIN_VERSION} REQUIRED NO_MODULE) + +set(CMAKE_MODULE_PATH ${CMAKE_MODULE_PATH} ${ECM_MODULE_PATH}) + +include(FeatureSummary) +include(KDEInstallDirs) +include(KDECMakeSettings) +include(KDECompilerSettings NO_POLICY_SCOPE) +include(ECMSetupVersion) +include(ECMFindQmlModule) +include(KDEGitCommitHooks) +include(KDEClangFormat) ecm_setup_version(${PROJECT_VERSION} VARIABLE_PREFIX ATPOOTB VERSION_HEADER "${CMAKE_CURRENT_BINARY_DIR}/src/version-atpootb.h" ) + +remove_definitions(-DQT_NO_CAST_FROM_ASCII) +set(QT_EXTRA_COMPONENTS) +list(APPEND QT_EXTRA_COMPONENTS Widgets) + +find_package(Qt6 ${QT6_MIN_VERSION} REQUIRED COMPONENTS Core Gui Qml QuickControls2 Svg ${QT_EXTRA_COMPONENTS}) +find_package(KF6 ${KF6_MIN_VERSION} REQUIRED COMPONENTS Kirigami KCMUtils Package CoreAddons Config I18n Auth) + +find_package(KWin REQUIRED COMPONENTS + kwin +) + +set(KAUTH_ACTIONS_QML true CACHE BOOL "Build with KAuth prompts") + +if(KAUTH_ACTIONS_QML) + message("Enabled KAuth") +else() + message("Disabled KAuth") +endif() configure_file(config.h.cmake src/config.h) -add_executable(atpootbcursor_authhelper src/ootbauthhelper.cpp src/ootbauthhelper.h) -target_link_libraries(atpootbcursor_authhelper KF6::AuthCore KF6::ConfigCore KF6::I18n Qt6::DBus Qt6::Core) +qt_policy(SET QTP0001 NEW) -install(TARGETS atpootbcursor_authhelper DESTINATION ${KAUTH_HELPER_INSTALL_DIR}) -kauth_install_helper_files(atpootbcursor_authhelper io.gitgud.wackyideas.ootb root) +ecm_find_qmlmodule(org.kde.kirigamiaddons.formcard 1.0) + +kauth_install_actions(io.gitgud.wackyideas.ootb kauth.actions) + +add_executable(ootbcursor_authhelper src/ootbauthhelper.cpp src/ootbauthhelper.h) +target_link_libraries(ootbcursor_authhelper KF6::AuthCore KF6::ConfigCore KF6::I18n Qt6::DBus Qt6::Core) + +install(TARGETS ootbcursor_authhelper DESTINATION ${KAUTH_HELPER_INSTALL_DIR}) +kauth_install_helper_files(ootbcursor_authhelper io.gitgud.wackyideas.ootb root) add_subdirectory(src) + +ki18n_install(po) + +feature_summary(WHAT ALL INCLUDE_QUIET_PACKAGES FATAL_ON_MISSING_REQUIRED_PACKAGES) + +file(GLOB_RECURSE ALL_CLANG_FORMAT_SOURCE_FILES src/*.cpp src/*.h) +kde_clang_format(${ALL_CLANG_FORMAT_SOURCE_FILES}) +kde_configure_git_pre_commit_hook(CHECKS CLANG_FORMAT) diff --git a/plasma/atpootb/CMakeLists.txt.user b/plasma/atpootb/CMakeLists.txt.user new file mode 100644 index 00000000..5b490edc --- /dev/null +++ b/plasma/atpootb/CMakeLists.txt.user @@ -0,0 +1,311 @@ + + + + + + EnvironmentId + {1b3896b9-3e46-4402-9292-45012cbe064f} + + + ProjectExplorer.Project.ActiveTarget + 0 + + + ProjectExplorer.Project.EditorSettings + + true + true + true + + Cpp + + CppGlobal + + + + QmlJS + + QmlJSGlobal + + + 2 + UTF-8 + false + 4 + false + 0 + 80 + true + true + 1 + 0 + false + true + false + 2 + true + true + 0 + 8 + true + false + 1 + true + true + true + *.md, *.MD, Makefile + false + true + true + + + + ProjectExplorer.Project.PluginSettings + + + true + false + true + true + true + true + + false + + + 0 + true + + true + true + Builtin.DefaultTidyAndClazy + 4 + true + + + + true + + + + + ProjectExplorer.Project.Target.0 + + Desktop + true + Desktop + Desktop + {9d6baf0a-3d40-404a-aa49-97bb01685c6d} + 0 + 0 + 0 + + Debug + 2 + false + + -DCMAKE_PROJECT_INCLUDE_BEFORE:FILEPATH=%{BuildConfig:BuildDirectory:NativeFilePath}/.qtc/package-manager/auto-setup.cmake +-DCMAKE_C_COMPILER:FILEPATH=%{Compiler:Executable:C} +-DCMAKE_CXX_COMPILER:FILEPATH=%{Compiler:Executable:Cxx} +-DCMAKE_GENERATOR:STRING=Ninja +-DQT_QMAKE_EXECUTABLE:FILEPATH=%{Qt:qmakeExecutable} +-DCMAKE_CXX_FLAGS_INIT:STRING=%{Qt:QML_DEBUG_FLAG} +-DCMAKE_PREFIX_PATH:PATH=%{Qt:QT_INSTALL_PREFIX} +-DCMAKE_BUILD_TYPE:STRING=Debug +-DCMAKE_COLOR_DIAGNOSTICS:BOOL=ON + 0 + /mnt/792afca2-ecd6-4e41-938a-2e818d0f60d1/home/anon/qt_projects/atpootb/build/Desktop-Debug + + + + + all + + false + + true + Build + CMakeProjectManager.MakeStep + + 1 + Build + Build + ProjectExplorer.BuildSteps.Build + + + + + + clean + + false + + true + Build + CMakeProjectManager.MakeStep + + 1 + Clean + Clean + ProjectExplorer.BuildSteps.Clean + + 2 + false + + false + + Debug + CMakeProjectManager.CMakeBuildConfiguration + 0 + 0 + + + 0 + Deploy + Deploy + ProjectExplorer.BuildSteps.Deploy + + 1 + + false + ProjectExplorer.DefaultDeployConfiguration + + + + + + + + + false + + true + ApplicationManagerPlugin.Deploy.CMakePackageStep + + + install-package --acknowledge + true + Install Application Manager package + ApplicationManagerPlugin.Deploy.InstallPackageStep + + + + + + + + 2 + Deploy + Deploy + ProjectExplorer.BuildSteps.Deploy + + 1 + + false + ApplicationManagerPlugin.Deploy.Configuration + + 2 + + true + true + 0 + true + + 2 + + false + -e cpu-cycles --call-graph dwarf,4096 -F 250 + atpootb + CMakeProjectManager.CMakeRunConfiguration. + atpootb + false + true + true + true + /mnt/792afca2-ecd6-4e41-938a-2e818d0f60d1/home/anon/qt_projects/atpootb/build/Desktop-Debug/bin + + 1 + + 1 + + + 0 + Deploy + Deploy + ProjectExplorer.BuildSteps.Deploy + + 1 + + false + ProjectExplorer.DefaultDeployConfiguration + + + + + + + + + false + + true + ApplicationManagerPlugin.Deploy.CMakePackageStep + + + install-package --acknowledge + true + Install Application Manager package + ApplicationManagerPlugin.Deploy.InstallPackageStep + + + + + + + + 2 + Deploy + Deploy + ProjectExplorer.BuildSteps.Deploy + + 1 + + false + ApplicationManagerPlugin.Deploy.Configuration + + 2 + + true + true + 0 + true + + 2 + + false + -e cpu-cycles --call-graph dwarf,4096 -F 250 + atpootb + CMakeProjectManager.CMakeRunConfiguration. + atpootb + false + true + true + true + /mnt/792afca2-ecd6-4e41-938a-2e818d0f60d1/home/anon/qt_projects/atpootb/build/Desktop-Debug/bin + + 1 + + + + ProjectExplorer.Project.TargetCount + 1 + + + ProjectExplorer.Project.Updater.FileVersion + 22 + + + Version + 22 + + diff --git a/plasma/atpootb/install.sh b/plasma/atpootb/install.sh new file mode 100644 index 00000000..b21dc0bc --- /dev/null +++ b/plasma/atpootb/install.sh @@ -0,0 +1,6 @@ +#!/bin/bash + +mkdir -p build +cd build +cmake -DCMAKE_INSTALL_PREFIX=/usr -G Ninja .. +ninja