Skip to content

Latest commit

 

History

559 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

English | 简体中文

Fluent-Qt logo

Fluent-Qt

A cross-platform Fluent-style C++ UI component library for Qt Widgets.

CI GitHub stars MIT License Platform Qt Widgets Qt C++17 PyPI

Fluent-Qt Gallery preview

Try the live C++ Web Gallery · Project website · Questions & community

Fluent-Qt is a cross-platform Fluent UI component library for Qt Widgets. It provides native controls for input, navigation, collections, data grids, overlays, and windows while preserving Qt's object model and CMake workflow. It supports Windows, macOS, Linux, WebAssembly, Light/Dark themes, C++, and optional PySide6 bindings, and can be added directly to existing projects.

🤖 Build with AI

Use build-fluentqt-gui in Codex, Claude Code, or Cursor, then describe the desktop app you want. Example · Install and use

🧱 Dependencies

Scope Dependencies
FluentQt C++ library C++17, CMake 3.16+, Qt Widgets 5.15+ or 6.2+
C++ Gallery FluentQt, Qt Network, spdlog/fmt
C++ WebAssembly Qt 6.9.3 wasm_singlethread, Emscripten 3.1.70
Tests FluentQt, Qt Test/Network, GTest, spdlog/fmt
Optional PySide6 bindings Qt 6.2+; Python 3.10+ for source builds

🚀 Quick Start

Link FluentQt to a CMake project using one of the following methods. FetchContent is recommended for new projects.

C++ setup

Integration CMake
FetchContent integration FetchContent_MakeAvailable(fluentqt)
Source integration add_subdirectory(Fluent-Qt)
Installed package integration find_package(FluentQt CONFIG REQUIRED)

FetchContent integration

cmake_minimum_required(VERSION 3.16)
project(my_app LANGUAGES CXX)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

include(FetchContent)
FetchContent_Declare(
    fluentqt
    GIT_REPOSITORY https://github.com/calvinhxx/Fluent-Qt.git
    GIT_TAG v1.7.2
    GIT_SHALLOW TRUE
)
FetchContent_MakeAvailable(fluentqt)

add_executable(my_app main.cpp)
target_link_libraries(my_app PRIVATE FluentQt::FluentQt)

Source integration

Place the Fluent-Qt source in the project's Fluent-Qt directory:

cmake_minimum_required(VERSION 3.16)
project(my_app LANGUAGES CXX)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

add_subdirectory(Fluent-Qt)

add_executable(my_app main.cpp)
target_link_libraries(my_app PRIVATE FluentQt::FluentQt)

Installed package integration

cmake_minimum_required(VERSION 3.16)
project(my_app LANGUAGES CXX)

set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_STANDARD_REQUIRED ON)

find_package(FluentQt CONFIG REQUIRED)

add_executable(my_app main.cpp)
target_link_libraries(my_app PRIVATE FluentQt::FluentQt)

If FluentQt is outside the system search path, configure with -DCMAKE_PREFIX_PATH=/path/to/fluentqt.

C++ minimal example

main.cpp:

#include <FluentQt/FluentQt.h>

#include <QApplication>
#include <QVBoxLayout>
#include <QWidget>

int main(int argc, char* argv[])
{
    fluent::prepareHighDpiApplication();
    QApplication app(argc, argv);
    fluent::initializeResources();
    app.setFont(Typography::fontStyle(Typography::FontRole::Body).toQFont());

    fluent::windowing::Window window;
    window.setWindowTitle(QStringLiteral("FluentQt Hello World"));
    window.resize(480, 320);

    auto* content = new QWidget;
    auto* layout = new QVBoxLayout(content);
    layout->setContentsMargins(32, 32, 32, 32);

    auto* button = new fluent::basicinput::Button(
        QStringLiteral("Hello from FluentQt"), content);
    button->setFluentStyle(fluent::basicinput::Button::Accent);
    layout->addStretch();
    layout->addWidget(button, 0, Qt::AlignCenter);
    layout->addStretch();

    window.setContentWidget(content);
    window.show();
    return app.exec();
}

See examples/hello_world for the complete project, or run the fluentqt_hello_world target directly from an IDE.

Optional Python compatibility

The PySide6 compatibility layer exposes Fluent-Qt's native C++ widgets to Python through Shiboken6.

python -m pip install FluentQt
import sys

import fluentqt
from PySide6.QtCore import Qt
from PySide6.QtWidgets import QApplication, QVBoxLayout, QWidget
from fluentqt.basicinput import Button
from fluentqt.windowing import Window

def main() -> int:
    fluentqt.prepare_high_dpi_application()
    app = QApplication(sys.argv)
    fluentqt.initialize_resources()
    app.setFont(fluentqt.font_for_role(fluentqt.FontRole.Body))

    window = Window()
    window.setWindowTitle("FluentQt Hello World")
    window.resize(480, 320)

    content = QWidget()
    layout = QVBoxLayout(content)
    layout.setContentsMargins(32, 32, 32, 32)

    button = Button("Hello from FluentQt", content)
    button.setFluentStyle(Button.ButtonStyle.Accent)
    layout.addStretch()
    layout.addWidget(button, 0, Qt.AlignCenter)
    layout.addStretch()

    window.setContentWidget(content)
    window.show()
    return app.exec()

if __name__ == "__main__":
    sys.exit(main())

See bindings/pyside6/examples/hello_world for the complete Python example.

🛠 Build

Library

cmake -S . -B build/fluentqt \
  -DCMAKE_BUILD_TYPE=Release \
  -DCMAKE_PREFIX_PATH=/path/to/Qt
cmake --build build/fluentqt --config Release --target FluentQt --parallel
cmake --install build/fluentqt --config Release \
  --component Development --prefix /path/to/install

Source package

Create the reduced library source package for offline or source integration:

cmake --build build/fluentqt --target fluent_qt_source_package

WebAssembly

Build the WebAssembly Gallery with Qt 6.9.3 wasm_singlethread and Emscripten 3.1.70:

source "$HOME/Qt/Tools/emsdk/emsdk_env.sh"
export QT_WASM_ROOT="$HOME/Qt/6.9.3/wasm_singlethread"
export QT_HOST_ROOT="$HOME/Qt/6.9.3/macos"
cmake --preset wasm
cmake --build --preset wasm --parallel
python3 -m http.server 4173 --bind 127.0.0.1 --directory build/wasm

Open http://127.0.0.1:4173/app/index.html. See the WebAssembly workflow for setup, testing, CI, deployment, and platform notes.

🖼 Gallery

Gallery is used to browse, demonstrate, and validate FluentQt components.

C++ Web Gallery

Online: project website · standalone page.

C++ Gallery packages

Download the Gallery for the required platform, Qt version, and architecture from GitHub Releases:

Platform Qt 5 / x64 Qt 6 / x64 Qt 6 / ARM64 Format
Windows 5.15.2 6.2.4 6.9.3 .exe
macOS 5.15.2 6.9.3 6.9.3 .dmg
Linux 5.15 6.2.4 6.2.4 .deb

Run the C++ Gallery locally

Platform x64 preset ARM64 preset
Windows vcpkg-windows vcpkg-windows-arm64
macOS vcpkg-osx-x64 vcpkg-osx
Linux vcpkg-linux vcpkg-linux-arm64

Replace PRESET with a value from the table:

cmake --preset PRESET
cmake --build --preset PRESET --target fluent_qt_gallery --parallel

Package the C++ Gallery locally

Platform x64 packaging preset ARM64 packaging preset Format
Windows vcpkg-windows-installer vcpkg-windows-arm64-installer .exe
macOS vcpkg-osx-x64-dmg vcpkg-osx-dmg .dmg
Linux vcpkg-linux-deb vcpkg-linux-arm64-deb .deb

See the Packaging Workflow for exact local packaging commands.

Python compatibility Gallery

The Python Gallery is available from PyPI.

python -m pip install FluentQt-Gallery
python -m fluentqt_gallery

FluentQt-Gallery installs the matching FluentQt version automatically.

📚 Documentation

🔗 References

Entry Purpose
Windows UI Kit (Community) Fluent / Windows visual reference
WinUI Gallery Component behavior and sample page reference

License

Fluent-Qt's own source code is released under the MIT License. Bundled assets and packaged runtime dependencies retain their upstream terms; versions, provenance, source-availability rules, and license locations are listed in THIRD_PARTY_NOTICES.md. Product names, logos, and external design references are addressed in TRADEMARKS.md.

About

Modern Fluent / WinUI-style Qt Widgets components and Gallery for native C++ desktop apps, optional PySide6 bindings, and WebAssembly.

Topics

Resources

Code of conduct

Contributing

Security policy

Stars

66 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages