Kylin/Fluent/CMakeLists.txt
2024-08-31 04:13:21 +08:00

65 lines
1.6 KiB
CMake

find_package(QT NAMES Qt6 Qt5 REQUIRED COMPONENTS Gui Quick QuickControls2)
find_package(Qt${QT_VERSION_MAJOR} REQUIRED COMPONENTS Gui Quick QuickControls2)
qt_standard_project_setup(REQUIRES 6.5)
add_library(Fluent
AsyncEvent.h
QClassStdStream.h QClassStdStream.cpp
)
set_source_files_properties(qml/Router.qml PROPERTIES
QT_QML_SINGLETON_TYPE TRUE
)
qt6_add_qml_module(Fluent
URI Fluent
VERSION 1.0
SOURCES
AccentColor.h AccentColor.cpp
App.h App.cpp
CircularReveal.h CircularReveal.cpp
Colors.h Colors.cpp
Frameless.h Frameless.cpp
Icons.h
Rectangle.h Rectangle.cpp
TextStyle.h TextStyle.cpp
Theme.h Theme.cpp
Utilities.h Utilities.cpp
QML_FILES
qml/Acrylic.qml
qml/AppBar.qml
qml/Button.qml
qml/ContentDialog.qml
qml/ControlBackground.qml
qml/FilledButton.qml
qml/FocusRectangle.qml
qml/Icon.qml
qml/IconButton.qml
qml/ImageButton.qml
qml/InfoBar.qml
qml/Loader.qml
qml/Object.qml
qml/Popup.qml
qml/ProgressRing.qml
qml/Router.qml
qml/ScrollBar.qml
qml/Shadow.qml
qml/Text.qml
qml/Tooltip.qml
qml/Window.qml
RESOURCES
resources/noise.png
resources/FluentIcons.ttf
)
target_include_directories(Fluent
INTERFACE ${CMAKE_CURRENT_SOURCE_DIR}
)
target_link_libraries(Fluent
PUBLIC Qt${QT_VERSION_MAJOR}::Gui
PRIVATE Qt${QT_VERSION_MAJOR}::Quick
INTERFACE Qt${QT_VERSION_MAJOR}::QuickControls2
)