update
This commit is contained in:
parent
e2ff752ed9
commit
6a23b04422
|
@ -2,73 +2,62 @@ name: MacOS
|
||||||
on:
|
on:
|
||||||
push:
|
push:
|
||||||
paths:
|
paths:
|
||||||
- '*.txt'
|
- '*.pro'
|
||||||
- 'example/**'
|
|
||||||
- 'src/**'
|
- 'src/**'
|
||||||
- 'scripts/**'
|
|
||||||
- '.github/workflows/macos.yml'
|
- '.github/workflows/macos.yml'
|
||||||
pull_request:
|
pull_request:
|
||||||
paths:
|
paths:
|
||||||
- '*.txt'
|
- '*.pro'
|
||||||
- 'example/**'
|
|
||||||
- 'src/**'
|
- 'src/**'
|
||||||
- 'scripts/**'
|
|
||||||
- '.github/workflows/macos.yml'
|
- '.github/workflows/macos.yml'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
name: Build
|
name: Build
|
||||||
runs-on: ${{ matrix.os }}
|
runs-on: ${{ matrix.os }}
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
os: [macos-12]
|
os: [macos-11.0]
|
||||||
qt_ver: [6.5.0]
|
qt_ver: [5.15.2]
|
||||||
qt_arch: [clang_64]
|
qt_arch: [clang_64]
|
||||||
env:
|
env:
|
||||||
targetName: example
|
targetName: example
|
||||||
steps:
|
steps:
|
||||||
- name: Check out repository
|
# macos 11.0 默认环境变了,要指定
|
||||||
uses: actions/checkout@v3
|
- name: prepare env
|
||||||
with:
|
if: ${{ matrix.os == 'macos-11.0' }}
|
||||||
submodules: recursive
|
run: |
|
||||||
|
softwareupdate --all --install --force
|
||||||
|
sudo xcode-select --print-path
|
||||||
|
sudo xcode-select --switch /Library/Developer/CommandLineTools
|
||||||
- name: Install Qt
|
- name: Install Qt
|
||||||
uses: jurplel/install-qt-action@v3
|
uses: jurplel/install-qt-action@v2
|
||||||
with:
|
with:
|
||||||
version: ${{ matrix.qt_ver }}
|
version: ${{ matrix.qt_ver }}
|
||||||
cache: ${{steps.cache-qt.outputs.cache-hit}}
|
cached: 'false'
|
||||||
arch: ${{ matrix.qt_arch }}
|
- uses: actions/checkout@v2
|
||||||
modules: 'qt5compat qtmultimedia qtshadertools qtimageformats'
|
|
||||||
|
|
||||||
- name: Set up Ninja
|
|
||||||
uses: seanmiddleditch/gha-setup-ninja@v3
|
|
||||||
with:
|
with:
|
||||||
version: 1.10.2
|
submodules: recursive
|
||||||
|
|
||||||
- name: build macos
|
- name: build macos
|
||||||
run: |
|
run: |
|
||||||
cmake --version
|
qmake
|
||||||
mkdir build
|
make
|
||||||
cd build
|
# 打包
|
||||||
cmake -DCMAKE_MESSAGE_LOG_LEVEL=STATUS -DCMAKE_PREFIX_PATH=/Users/runner/work/FluentUI/Qt/6.5.0/macos -DCMAKE_C_COMPILER=clang -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_BUILD_TYPE=Release -GNinja ..
|
|
||||||
cmake --build . --target all --config Release --parallel
|
|
||||||
|
|
||||||
- name: package
|
- name: package
|
||||||
run: |
|
run: |
|
||||||
# 拷贝依赖
|
# 拷贝依赖
|
||||||
macdeployqt bin/release/${targetName}.app -qmldir=. -verbose=1 -dmg
|
macdeployqt bin/release/${targetName}.app -qmldir=. -verbose=1 -dmg
|
||||||
|
# 上传artifacts
|
||||||
- uses: actions/upload-artifact@v2
|
- uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: ${{ env.targetName }}_${{ matrix.os }}_${{matrix.qt_ver}}.zip
|
name: ${{ env.targetName }}_${{ matrix.os }}_${{matrix.qt_ver}}.zip
|
||||||
path: bin/release/${{ env.targetName }}.app
|
path: bin/release/${{ env.targetName }}.app
|
||||||
|
# tag 上传Release
|
||||||
- name: uploadRelease
|
- name: uploadRelease
|
||||||
if: startsWith(github.event.ref, 'refs/tags/')
|
if: startsWith(github.event.ref, 'refs/tags/')
|
||||||
uses: svenstaro/upload-release-action@v2
|
uses: svenstaro/upload-release-action@v2
|
||||||
with:
|
with:
|
||||||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
file: bin/release/${{ env.targetName }}.dmg
|
file: bin/release/${{ env.targetName }}.dmg
|
||||||
asset_name: ${{ env.targetName }}_${{ github.ref_name }}_${{ matrix.os }}_Qt${{ matrix.qt_ver }}.dmg
|
asset_name: ${{ env.targetName }}_${{ matrix.os }}_${{ matrix.qt_ver }}.dmg
|
||||||
tag: ${{ github.ref }}
|
tag: ${{ github.ref }}
|
||||||
overwrite: true
|
overwrite: true
|
|
@ -1,21 +1,17 @@
|
||||||
name: Ubuntu
|
name: Ubuntu
|
||||||
|
# Qt官方没有linux平台的x86包
|
||||||
on:
|
on:
|
||||||
workflow_dispatch:
|
workflow_dispatch:
|
||||||
push:
|
push:
|
||||||
paths:
|
paths:
|
||||||
- '*.txt'
|
- '*.pro'
|
||||||
- 'src/**'
|
- 'src/**'
|
||||||
- 'example/**'
|
|
||||||
- 'scripts/**'
|
|
||||||
- '.github/workflows/ubuntu.yml'
|
- '.github/workflows/ubuntu.yml'
|
||||||
pull_request:
|
pull_request:
|
||||||
paths:
|
paths:
|
||||||
- '*.txt'
|
- '*.pro'
|
||||||
- 'src/**'
|
- 'src/**'
|
||||||
- 'example/**'
|
|
||||||
- 'scripts/**'
|
|
||||||
- '.github/workflows/ubuntu.yml'
|
- '.github/workflows/ubuntu.yml'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
name: Build
|
name: Build
|
||||||
|
@ -23,68 +19,49 @@ jobs:
|
||||||
strategy:
|
strategy:
|
||||||
matrix:
|
matrix:
|
||||||
os: [ubuntu-20.04]
|
os: [ubuntu-20.04]
|
||||||
qt_ver: [6.5.0]
|
qt_ver: [5.15.2]
|
||||||
qt_arch: [gcc_64]
|
qt_arch: [gcc_64]
|
||||||
env:
|
env:
|
||||||
targetName: example
|
targetName: example
|
||||||
steps:
|
steps:
|
||||||
- name: Check out repository
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
with:
|
|
||||||
submodules: recursive
|
|
||||||
|
|
||||||
- name: Install Qt
|
- name: Install Qt
|
||||||
uses: jurplel/install-qt-action@v3
|
uses: jurplel/install-qt-action@v2
|
||||||
with:
|
with:
|
||||||
version: ${{ matrix.qt_ver }}
|
version: ${{ matrix.qt_ver }}
|
||||||
cache: ${{steps.cache-qt.outputs.cache-hit}}
|
cached: 'false'
|
||||||
arch: ${{ matrix.qt_arch }}
|
|
||||||
modules: 'qt5compat qtmultimedia qtshadertools qtimageformats'
|
|
||||||
|
|
||||||
- name: Set up Ninja
|
|
||||||
uses: seanmiddleditch/gha-setup-ninja@v3
|
|
||||||
with:
|
|
||||||
version: 1.10.2
|
|
||||||
|
|
||||||
- name: ubuntu install GL library
|
- name: ubuntu install GL library
|
||||||
run: sudo apt-get install -y libxcb-cursor0 libgl1-mesa-dev libxcb1-dev libgtk-3-dev libxkbcommon-x11-dev libxcb-icccm4-dev libxcb-image0-dev libxcb-keysyms1-dev libxcb-randr0-dev libxcb-shape0-dev libxcb-xfixes0-dev libxcb-xinerama0-dev libxcb-sync-dev libxcb-render-util0-dev libxcb-shm0-dev
|
run: sudo apt-get install -y libgl1-mesa-dev libxcb1-dev libgtk-3-dev libxkbcommon-x11-dev libxcb-icccm4-dev libxcb-image0-dev libxcb-keysyms1-dev libxcb-randr0-dev libxcb-shape0-dev libxcb-xfixes0-dev libxcb-xinerama0-dev libxcb-sync-dev libxcb-render-util0-dev libxcb-shm0-dev
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
submodules: recursive
|
||||||
- name: build ubuntu
|
- name: build ubuntu
|
||||||
run: |
|
run: |
|
||||||
ninja --version
|
qmake
|
||||||
cmake --version
|
make
|
||||||
mkdir build
|
|
||||||
cd build
|
|
||||||
cmake -DCMAKE_MESSAGE_LOG_LEVEL=STATUS -DCMAKE_PREFIX_PATH=/home/runner/work/FluentUI/Qt/6.5.0/gcc_64 -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DCMAKE_BUILD_TYPE=Release -GNinja ..
|
|
||||||
cmake --build . --target all --config Release --parallel
|
|
||||||
|
|
||||||
- name: install QT linux deploy
|
- name: install QT linux deploy
|
||||||
uses: miurahr/install-linuxdeploy-action@v1
|
uses: miurahr/install-linuxdeploy-action@v1
|
||||||
with:
|
with:
|
||||||
plugins: qt appimage
|
plugins: qt appimage
|
||||||
|
# 打包
|
||||||
- name: Check if svg file exists
|
|
||||||
run: if [ ! -f "${targetName}.svg" ]; then echo "File not found, creating..."; touch ${targetName}.svg; fi
|
|
||||||
|
|
||||||
- name: package
|
- name: package
|
||||||
run: |
|
run: |
|
||||||
# make sure Qt plugin finds QML sources so it can deploy the imported files
|
# make sure Qt plugin finds QML sources so it can deploy the imported files
|
||||||
export QML_SOURCES_PATHS=./
|
export QML_SOURCES_PATHS=src
|
||||||
# 拷贝依赖
|
# 拷贝依赖
|
||||||
linuxdeploy-x86_64.AppImage --plugin=qt --output=appimage --create-desktop-file --icon-file=${targetName}.svg --executable=bin/release/${targetName} --appdir bin/release/
|
linuxdeploy-x86_64.AppImage --plugin=qt --output=appimage --create-desktop-file --icon-file=${targetName}.svg --executable=bin/release/${targetName} --appdir bin/release/
|
||||||
mv ${{ env.targetName }}-*.AppImage ${{ env.targetName }}.AppImage
|
mv ${{ env.targetName }}-*.AppImage ${{ env.targetName }}.AppImage
|
||||||
|
# 上传artifacts
|
||||||
- uses: actions/upload-artifact@v2
|
- uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: ${{ env.targetName }}_${{ matrix.os }}_${{matrix.qt_ver}}
|
name: ${{ env.targetName }}_${{ matrix.os }}_${{matrix.qt_ver}}
|
||||||
path: ${{ env.targetName }}.AppImage
|
path: ${{ env.targetName }}.AppImage
|
||||||
|
# tag 上传Release
|
||||||
- name: uploadRelease
|
- name: uploadRelease
|
||||||
if: startsWith(github.event.ref, 'refs/tags/')
|
if: startsWith(github.event.ref, 'refs/tags/')
|
||||||
uses: svenstaro/upload-release-action@v2
|
uses: svenstaro/upload-release-action@v2
|
||||||
with:
|
with:
|
||||||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
file: ${{ env.targetName }}.AppImage
|
file: ${{ env.targetName }}.AppImage
|
||||||
asset_name: ${{ env.targetName }}_${{ github.ref_name }}_${{ matrix.os }}_Qt${{ matrix.qt_ver }}.AppImage
|
asset_name: ${{ env.targetName }}_${{ matrix.os }}_${{ matrix.qt_ver }}.AppImage
|
||||||
tag: ${{ github.ref }}
|
tag: ${{ github.ref }}
|
||||||
overwrite: true
|
overwrite: true
|
|
@ -1,91 +0,0 @@
|
||||||
name: Windows MinGW
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
paths:
|
|
||||||
- '*.txt'
|
|
||||||
- 'src/**'
|
|
||||||
- 'example/**'
|
|
||||||
- 'scripts/**'
|
|
||||||
- '.github/workflows/windows-mingw.yml'
|
|
||||||
pull_request:
|
|
||||||
paths:
|
|
||||||
- '*.txt'
|
|
||||||
- 'example/**'
|
|
||||||
- 'src/**'
|
|
||||||
- 'scripts/**'
|
|
||||||
- '.github/workflows/windows-mingw.yml'
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
build:
|
|
||||||
name: Build
|
|
||||||
runs-on: windows-2022
|
|
||||||
strategy:
|
|
||||||
matrix:
|
|
||||||
include:
|
|
||||||
- qt_arch: win64_mingw
|
|
||||||
qt_ver: 6.5.0
|
|
||||||
qt_tools: "tools_mingw,9.0.0-1-202203221220,qt.tools.win64_mingw900"
|
|
||||||
qt_tools_mingw_install: mingw900_64
|
|
||||||
env:
|
|
||||||
targetName: example.exe
|
|
||||||
fileName: example
|
|
||||||
steps:
|
|
||||||
- name: Check out repository
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
with:
|
|
||||||
submodules: recursive
|
|
||||||
|
|
||||||
- name: Install Qt
|
|
||||||
uses: jurplel/install-qt-action@v3
|
|
||||||
with:
|
|
||||||
version: ${{ matrix.qt_ver }}
|
|
||||||
arch: ${{ matrix.qt_arch }}
|
|
||||||
cache: ${{steps.cache-qt.outputs.cache-hit}}
|
|
||||||
modules: 'qt5compat qtmultimedia qtshadertools qtimageformats'
|
|
||||||
|
|
||||||
- name: Qt6 environment configuration
|
|
||||||
if: ${{ startsWith( matrix.qt_ver, 6 ) }}
|
|
||||||
shell: pwsh
|
|
||||||
run: |
|
|
||||||
Write-Output "${{ env.Qt6_DIR }}/bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
|
|
||||||
Write-Output "${{ env.Qt6_DIR }}/../../Tools/${{ matrix.qt_tools_mingw_install }}/bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
|
|
||||||
|
|
||||||
- name: where is cmake & where is mingw32-make
|
|
||||||
shell: pwsh
|
|
||||||
run: |
|
|
||||||
Get-Command -Name 'cmake' | Format-List
|
|
||||||
Get-Command -Name 'mingw32-make' | Format-List
|
|
||||||
|
|
||||||
- name: mingw-build
|
|
||||||
id: build
|
|
||||||
shell: cmd
|
|
||||||
run: |
|
|
||||||
mkdir build
|
|
||||||
cd build
|
|
||||||
cmake -DCMAKE_MESSAGE_LOG_LEVEL=STATUS -DCMAKE_PREFIX_PATH=D:\a\FluentUI\Qt\6.5.0\mingw_64 -DCMAKE_C_COMPILER=gcc -DCMAKE_CXX_COMPILER=g++ -DCMAKE_BUILD_TYPE=Release -GNinja ..
|
|
||||||
cmake --build . --target all --config Release --parallel
|
|
||||||
|
|
||||||
- name: package
|
|
||||||
id: package
|
|
||||||
env:
|
|
||||||
archiveName: ${{ env.fileName }}-${{ matrix.qt_arch }}-${{ matrix.qt_ver }}
|
|
||||||
shell: pwsh
|
|
||||||
run: |
|
|
||||||
& scripts\windows-mingw-publish.ps1 ${env:archiveName} ${env:targetName}
|
|
||||||
$name = ${env:archiveName}
|
|
||||||
echo "::set-output name=packageName::$name"
|
|
||||||
|
|
||||||
- uses: actions/upload-artifact@v2
|
|
||||||
with:
|
|
||||||
name: ${{ steps.package.outputs.packageName }}
|
|
||||||
path: ${{ steps.package.outputs.packageName }}
|
|
||||||
|
|
||||||
- name: uploadRelease
|
|
||||||
if: startsWith(github.event.ref, 'refs/tags/')
|
|
||||||
uses: svenstaro/upload-release-action@v2
|
|
||||||
with:
|
|
||||||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
|
||||||
file: ${{ steps.package.outputs.packageName }}.zip
|
|
||||||
asset_name: ${{ env.fileName }}_${{ github.ref_name }}_${{ matrix.qt_arch }}_Qt${{ matrix.qt_ver }}.zip
|
|
||||||
tag: ${{ github.ref }}
|
|
||||||
overwrite: true
|
|
|
@ -1,63 +1,69 @@
|
||||||
name: Windows
|
name: Windows
|
||||||
on:
|
on:
|
||||||
|
# push代码时触发workflow
|
||||||
push:
|
push:
|
||||||
paths:
|
paths:
|
||||||
- '*.txt'
|
- '*.pro'
|
||||||
- 'src/**'
|
- 'src/**'
|
||||||
- 'example/**'
|
|
||||||
- 'scripts/**'
|
|
||||||
- '.github/workflows/windows.yml'
|
- '.github/workflows/windows.yml'
|
||||||
pull_request:
|
pull_request:
|
||||||
paths:
|
paths:
|
||||||
- '*.txt'
|
- '*.pro'
|
||||||
- 'example/**'
|
|
||||||
- 'src/**'
|
- 'src/**'
|
||||||
- 'scripts/**'
|
|
||||||
- '.github/workflows/windows.yml'
|
- '.github/workflows/windows.yml'
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
build:
|
build:
|
||||||
name: Build
|
name: Build
|
||||||
runs-on: ${{ matrix.os }}
|
# 运行平台, windows-latest目前是windows server 2019
|
||||||
|
# 参考文档 https://github.com/actions/virtual-environments/blob/main/images/win/Windows2019-Readme.md
|
||||||
|
runs-on: windows-2019
|
||||||
strategy:
|
strategy:
|
||||||
|
# 矩阵配置
|
||||||
matrix:
|
matrix:
|
||||||
os: [windows-2019]
|
|
||||||
include:
|
include:
|
||||||
- qt_ver: 6.5.0
|
# 5.15.2 参考 https://mirrors.cloud.tencent.com/qt/online/qtsdkrepository/windows_x86/desktop/qt5_5152/
|
||||||
|
- qt_ver: 5.15.2
|
||||||
|
qt_arch: win32_msvc2019
|
||||||
|
msvc_arch: x86
|
||||||
|
qt_arch_install: msvc2019
|
||||||
|
- qt_ver: 5.15.2
|
||||||
qt_arch: win64_msvc2019_64
|
qt_arch: win64_msvc2019_64
|
||||||
msvc_arch: x64
|
msvc_arch: x64
|
||||||
qt_arch_install: msvc2019_64
|
qt_arch_install: msvc2019_64
|
||||||
env:
|
env:
|
||||||
targetName: example.exe
|
targetName: example.exe
|
||||||
fileName: example
|
fileName: example
|
||||||
|
# 步骤
|
||||||
steps:
|
steps:
|
||||||
- name: Check out repository
|
# 安装Qt
|
||||||
uses: actions/checkout@v3
|
- name: Install Qt
|
||||||
|
# 使用外部action。这个action专门用来安装Qt
|
||||||
|
uses: jurplel/install-qt-action@v2
|
||||||
|
with:
|
||||||
|
# Version of Qt to install
|
||||||
|
version: ${{ matrix.qt_ver }}
|
||||||
|
# Target platform for build
|
||||||
|
# target: ${{ matrix.qt_target }}
|
||||||
|
arch: ${{ matrix.qt_arch }}
|
||||||
|
cached: 'false'
|
||||||
|
aqtversion: '==2.0.5'
|
||||||
|
# 拉取代码
|
||||||
|
- uses: actions/checkout@v2
|
||||||
with:
|
with:
|
||||||
submodules: recursive
|
submodules: recursive
|
||||||
|
# msvc编译
|
||||||
- name: Install Qt
|
|
||||||
uses: jurplel/install-qt-action@v3
|
|
||||||
with:
|
|
||||||
version: ${{ matrix.qt_ver }}
|
|
||||||
arch: ${{ matrix.qt_arch }}
|
|
||||||
cache: ${{steps.cache-qt.outputs.cache-hit}}
|
|
||||||
modules: 'qt5compat qtmultimedia qtshadertools qtimageformats qtspeech'
|
|
||||||
|
|
||||||
- name: msvc-build
|
- name: msvc-build
|
||||||
id: build
|
id: build
|
||||||
shell: cmd
|
shell: cmd
|
||||||
run: |
|
run: |
|
||||||
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" ${{ matrix.msvc_arch }}
|
call "C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvarsall.bat" ${{ matrix.msvc_arch }}
|
||||||
mkdir build
|
qmake
|
||||||
cd build
|
nmake
|
||||||
cmake -DCMAKE_MESSAGE_LOG_LEVEL=STATUS -DCMAKE_PREFIX_PATH=D:\a\FluentUI\Qt\6.5.0\msvc2019_64 -DCMAKE_C_COMPILER=cl -DCMAKE_CXX_COMPILER=cl -DCMAKE_BUILD_TYPE=Release -GNinja ..
|
|
||||||
cmake --build . --target all --config Release --parallel
|
|
||||||
echo winSdkDir=%WindowsSdkDir% >> %GITHUB_ENV%
|
echo winSdkDir=%WindowsSdkDir% >> %GITHUB_ENV%
|
||||||
echo winSdkVer=%WindowsSdkVersion% >> %GITHUB_ENV%
|
echo winSdkVer=%WindowsSdkVersion% >> %GITHUB_ENV%
|
||||||
echo vcToolsInstallDir=%VCToolsInstallDir% >> %GITHUB_ENV%
|
echo vcToolsInstallDir=%VCToolsInstallDir% >> %GITHUB_ENV%
|
||||||
echo vcToolsRedistDir=%VCToolsRedistDir% >> %GITHUB_ENV%
|
echo vcToolsRedistDir=%VCToolsRedistDir% >> %GITHUB_ENV%
|
||||||
|
# 打包
|
||||||
- name: package
|
- name: package
|
||||||
id: package
|
id: package
|
||||||
env:
|
env:
|
||||||
|
@ -69,18 +75,19 @@ jobs:
|
||||||
# 记录packageName给后续step
|
# 记录packageName给后续step
|
||||||
$name = ${env:archiveName}
|
$name = ${env:archiveName}
|
||||||
echo "::set-output name=packageName::$name"
|
echo "::set-output name=packageName::$name"
|
||||||
|
# tag 查询github-Release
|
||||||
|
# 上传artifacts
|
||||||
- uses: actions/upload-artifact@v2
|
- uses: actions/upload-artifact@v2
|
||||||
with:
|
with:
|
||||||
name: ${{ steps.package.outputs.packageName }}
|
name: ${{ steps.package.outputs.packageName }}
|
||||||
path: ${{ steps.package.outputs.packageName }}
|
path: ${{ steps.package.outputs.packageName }}
|
||||||
|
# tag 上传Release
|
||||||
- name: uploadRelease
|
- name: uploadRelease
|
||||||
if: startsWith(github.event.ref, 'refs/tags/')
|
if: startsWith(github.event.ref, 'refs/tags/')
|
||||||
uses: svenstaro/upload-release-action@v2
|
uses: svenstaro/upload-release-action@v2
|
||||||
with:
|
with:
|
||||||
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
repo_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
file: ${{ steps.package.outputs.packageName }}.zip
|
file: ${{ steps.package.outputs.packageName }}.zip
|
||||||
asset_name: ${{ env.fileName }}_${{ github.ref_name }}_${{ matrix.qt_arch }}_Qt${{ matrix.qt_ver }}.zip
|
asset_name: ${{ steps.package.outputs.packageName }}.zip
|
||||||
tag: ${{ github.ref }}
|
tag: ${{ github.ref }}
|
||||||
overwrite: true
|
overwrite: true
|
|
@ -1,4 +1,6 @@
|
||||||
cmake_minimum_required(VERSION 3.20)
|
cmake_minimum_required(VERSION 3.20)
|
||||||
|
set(CMAKE_CXX_STANDARD 17)
|
||||||
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||||
|
|
||||||
project(FluentUI VERSION 0.1 LANGUAGES CXX)
|
project(FluentUI VERSION 0.1 LANGUAGES CXX)
|
||||||
|
|
||||||
|
|
|
@ -1,13 +1,9 @@
|
||||||
cmake_minimum_required(VERSION 3.20)
|
cmake_minimum_required(VERSION 3.20)
|
||||||
|
set(CMAKE_CXX_STANDARD 17)
|
||||||
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||||
|
|
||||||
project(example VERSION 0.1 LANGUAGES CXX)
|
project(example VERSION 0.1 LANGUAGES CXX)
|
||||||
|
|
||||||
#配置通用编译
|
|
||||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
|
||||||
if(APPLE)
|
|
||||||
set(CMAKE_OSX_ARCHITECTURES "arm64;x86_64" CACHE STRING "" FORCE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
#设置可执行文件输出目录
|
#设置可执行文件输出目录
|
||||||
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
|
if(CMAKE_BUILD_TYPE STREQUAL "Debug")
|
||||||
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_SOURCE_DIR}/bin/debug)
|
set(CMAKE_RUNTIME_OUTPUT_DIRECTORY ${CMAKE_SOURCE_DIR}/bin/debug)
|
||||||
|
@ -21,15 +17,13 @@ file(TO_CMAKE_PATH "/" PATH_SEPARATOR)
|
||||||
#设置版本号
|
#设置版本号
|
||||||
add_definitions(-DVERSION=1,3,7,3)
|
add_definitions(-DVERSION=1,3,7,3)
|
||||||
|
|
||||||
find_package(Qt6 REQUIRED COMPONENTS Quick)
|
find_package(Qt5 REQUIRED COMPONENTS Quick)
|
||||||
|
|
||||||
if(QT_VERSION VERSION_GREATER_EQUAL "6.3")
|
set(CMAKE_AUTOMOC ON)
|
||||||
qt_standard_project_setup()
|
set(CMAKE_AUTORCC ON)
|
||||||
else()
|
set(CMAKE_AUTOUIC ON)
|
||||||
set(CMAKE_AUTOMOC ON)
|
|
||||||
set(CMAKE_AUTORCC ON)
|
include_directories(${CMAKE_CURRENT_SOURCE_DIR})
|
||||||
set(CMAKE_AUTOUIC ON)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
#遍历所有Cpp文件
|
#遍历所有Cpp文件
|
||||||
file(GLOB_RECURSE CPP_FILES *.cpp *.h)
|
file(GLOB_RECURSE CPP_FILES *.cpp *.h)
|
||||||
|
@ -54,12 +48,12 @@ endforeach(filepath)
|
||||||
|
|
||||||
#添加可执行文件
|
#添加可执行文件
|
||||||
if (CMAKE_SYSTEM_NAME STREQUAL "Windows")
|
if (CMAKE_SYSTEM_NAME STREQUAL "Windows")
|
||||||
qt_add_executable(example
|
add_executable(example
|
||||||
${sources_files}
|
${sources_files}
|
||||||
example.rc
|
example.rc
|
||||||
)
|
)
|
||||||
else ()
|
else ()
|
||||||
qt_add_executable(example
|
add_executable(example
|
||||||
${sources_files}
|
${sources_files}
|
||||||
)
|
)
|
||||||
endif ()
|
endif ()
|
||||||
|
@ -80,13 +74,8 @@ if(WIN32)
|
||||||
)
|
)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
#添加qml模块
|
#设置编译对象
|
||||||
qt_add_qml_module(example
|
target_sources(example PRIVATE example.qrc)
|
||||||
URI example
|
|
||||||
VERSION 1.0
|
|
||||||
QML_FILES ${qml_files}
|
|
||||||
RESOURCES ${resource_files}
|
|
||||||
)
|
|
||||||
|
|
||||||
#设置属性
|
#设置属性
|
||||||
set_target_properties(example PROPERTIES
|
set_target_properties(example PROPERTIES
|
||||||
|
@ -98,22 +87,12 @@ set_target_properties(example PROPERTIES
|
||||||
)
|
)
|
||||||
|
|
||||||
#链接库
|
#链接库
|
||||||
if (FLUENTUI_BUILD_STATIC_LIB)
|
target_link_libraries(example PRIVATE
|
||||||
target_link_libraries(example PRIVATE
|
Qt::Quick
|
||||||
Qt6::Quick
|
|
||||||
fluentui
|
|
||||||
fluentuiplugin
|
fluentuiplugin
|
||||||
FramelessHelper::Core
|
FramelessHelper::Core
|
||||||
FramelessHelper::Quick
|
FramelessHelper::Quick
|
||||||
)
|
)
|
||||||
else()
|
|
||||||
target_link_libraries(example PRIVATE
|
|
||||||
Qt6::Quick
|
|
||||||
fluentuiplugin
|
|
||||||
FramelessHelper::Core
|
|
||||||
FramelessHelper::Quick
|
|
||||||
)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
#安装
|
#安装
|
||||||
install(TARGETS example
|
install(TARGETS example
|
||||||
|
|
|
@ -0,0 +1,177 @@
|
||||||
|
<RCC>
|
||||||
|
<qresource prefix="/example">
|
||||||
|
<file>res/svg/avatar_1.svg</file>
|
||||||
|
<file>res/svg/avatar_2.svg</file>
|
||||||
|
<file>res/svg/avatar_3.svg</file>
|
||||||
|
<file>res/svg/avatar_4.svg</file>
|
||||||
|
<file>res/svg/avatar_5.svg</file>
|
||||||
|
<file>res/svg/avatar_6.svg</file>
|
||||||
|
<file>res/svg/avatar_7.svg</file>
|
||||||
|
<file>res/svg/avatar_8.svg</file>
|
||||||
|
<file>res/svg/avatar_9.svg</file>
|
||||||
|
<file>res/svg/avatar_10.svg</file>
|
||||||
|
<file>res/svg/avatar_11.svg</file>
|
||||||
|
<file>res/svg/avatar_12.svg</file>
|
||||||
|
<file>res/image/banner_1.jpg</file>
|
||||||
|
<file>res/image/banner_2.jpg</file>
|
||||||
|
<file>res/image/banner_3.jpg</file>
|
||||||
|
<file>res/image/logo_openai.png</file>
|
||||||
|
<file>res/image/favicon.ico</file>
|
||||||
|
<file>res/image/bg_home_header.png</file>
|
||||||
|
<file>res/image/ic_home_github.png</file>
|
||||||
|
<file>res/image/control/Acrylic.png</file>
|
||||||
|
<file>res/image/control/AnimatedIcon.png</file>
|
||||||
|
<file>res/image/control/AnimatedVisualPlayer.png</file>
|
||||||
|
<file>res/image/control/AnimationInterop.png</file>
|
||||||
|
<file>res/image/control/AppBarButton.png</file>
|
||||||
|
<file>res/image/control/AppBarSeparator.png</file>
|
||||||
|
<file>res/image/control/AppBarToggleButton.png</file>
|
||||||
|
<file>res/image/control/AutomationProperties.png</file>
|
||||||
|
<file>res/image/control/AutoSuggestBox.png</file>
|
||||||
|
<file>res/image/control/Border.png</file>
|
||||||
|
<file>res/image/control/BreadcrumbBar.png</file>
|
||||||
|
<file>res/image/control/Button.png</file>
|
||||||
|
<file>res/image/control/CalendarDatePicker.png</file>
|
||||||
|
<file>res/image/control/CalendarView.png</file>
|
||||||
|
<file>res/image/control/Canvas.png</file>
|
||||||
|
<file>res/image/control/Checkbox.png</file>
|
||||||
|
<file>res/image/control/Clipboard.png</file>
|
||||||
|
<file>res/image/control/ColorPaletteResources.png</file>
|
||||||
|
<file>res/image/control/ColorPicker.png</file>
|
||||||
|
<file>res/image/control/ComboBox.png</file>
|
||||||
|
<file>res/image/control/CommandBar.png</file>
|
||||||
|
<file>res/image/control/CommandBarFlyout.png</file>
|
||||||
|
<file>res/image/control/CompactSizing.png</file>
|
||||||
|
<file>res/image/control/ConnectedAnimation.png</file>
|
||||||
|
<file>res/image/control/ContentDialog.png</file>
|
||||||
|
<file>res/image/control/CreateMultipleWindows.png</file>
|
||||||
|
<file>res/image/control/DataGrid.png</file>
|
||||||
|
<file>res/image/control/DatePicker.png</file>
|
||||||
|
<file>res/image/control/DropDownButton.png</file>
|
||||||
|
<file>res/image/control/EasingFunction.png</file>
|
||||||
|
<file>res/image/control/Expander.png</file>
|
||||||
|
<file>res/image/control/FilePicker.png</file>
|
||||||
|
<file>res/image/control/FlipView.png</file>
|
||||||
|
<file>res/image/control/Flyout.png</file>
|
||||||
|
<file>res/image/control/Grid.png</file>
|
||||||
|
<file>res/image/control/GridView.png</file>
|
||||||
|
<file>res/image/control/HyperlinkButton.png</file>
|
||||||
|
<file>res/image/control/IconElement.png</file>
|
||||||
|
<file>res/image/control/Image.png</file>
|
||||||
|
<file>res/image/control/ImplicitTransition.png</file>
|
||||||
|
<file>res/image/control/InfoBadge.png</file>
|
||||||
|
<file>res/image/control/InfoBar.png</file>
|
||||||
|
<file>res/image/control/InkCanvas.png</file>
|
||||||
|
<file>res/image/control/InkToolbar.png</file>
|
||||||
|
<file>res/image/control/InputValidation.png</file>
|
||||||
|
<file>res/image/control/ItemsRepeater.png</file>
|
||||||
|
<file>res/image/control/Line.png</file>
|
||||||
|
<file>res/image/control/ListBox.png</file>
|
||||||
|
<file>res/image/control/ListView.png</file>
|
||||||
|
<file>res/image/control/MediaPlayerElement.png</file>
|
||||||
|
<file>res/image/control/MenuBar.png</file>
|
||||||
|
<file>res/image/control/MenuFlyout.png</file>
|
||||||
|
<file>res/image/control/NavigationView.png</file>
|
||||||
|
<file>res/image/control/NumberBox.png</file>
|
||||||
|
<file>res/image/control/PageTransition.png</file>
|
||||||
|
<file>res/image/control/ParallaxView.png</file>
|
||||||
|
<file>res/image/control/PasswordBox.png</file>
|
||||||
|
<file>res/image/control/PersonPicture.png</file>
|
||||||
|
<file>res/image/control/PipsPager.png</file>
|
||||||
|
<file>res/image/control/Pivot.png</file>
|
||||||
|
<file>res/image/control/ProgressBar.png</file>
|
||||||
|
<file>res/image/control/ProgressRing.png</file>
|
||||||
|
<file>res/image/control/PullToRefresh.png</file>
|
||||||
|
<file>res/image/control/RadialGradientBrush.png</file>
|
||||||
|
<file>res/image/control/RadioButton.png</file>
|
||||||
|
<file>res/image/control/RadioButtons.png</file>
|
||||||
|
<file>res/image/control/RatingControl.png</file>
|
||||||
|
<file>res/image/control/RelativePanel.png</file>
|
||||||
|
<file>res/image/control/RepeatButton.png</file>
|
||||||
|
<file>res/image/control/RevealFocus.png</file>
|
||||||
|
<file>res/image/control/RichEditBox.png</file>
|
||||||
|
<file>res/image/control/RichTextBlock.png</file>
|
||||||
|
<file>res/image/control/ScrollViewer.png</file>
|
||||||
|
<file>res/image/control/SemanticZoom.png</file>
|
||||||
|
<file>res/image/control/Shape.png</file>
|
||||||
|
<file>res/image/control/Slider.png</file>
|
||||||
|
<file>res/image/control/Sound.png</file>
|
||||||
|
<file>res/image/control/SplitButton.png</file>
|
||||||
|
<file>res/image/control/SplitView.png</file>
|
||||||
|
<file>res/image/control/StackPanel.png</file>
|
||||||
|
<file>res/image/control/StandardUICommand.png</file>
|
||||||
|
<file>res/image/control/SwipeControl.png</file>
|
||||||
|
<file>res/image/control/TabView.png</file>
|
||||||
|
<file>res/image/control/TeachingTip.png</file>
|
||||||
|
<file>res/image/control/TextBlock.png</file>
|
||||||
|
<file>res/image/control/TextBox.png</file>
|
||||||
|
<file>res/image/control/ThemeTransition.png</file>
|
||||||
|
<file>res/image/control/TimePicker.png</file>
|
||||||
|
<file>res/image/control/TitleBar.png</file>
|
||||||
|
<file>res/image/control/ToggleButton.png</file>
|
||||||
|
<file>res/image/control/ToggleSplitButton.png</file>
|
||||||
|
<file>res/image/control/ToggleSwitch.png</file>
|
||||||
|
<file>res/image/control/ToolTip.png</file>
|
||||||
|
<file>res/image/control/TreeView.png</file>
|
||||||
|
<file>res/image/control/VariableSizedWrapGrid.png</file>
|
||||||
|
<file>res/image/control/Viewbox.png</file>
|
||||||
|
<file>res/image/control/WebView.png</file>
|
||||||
|
<file>res/image/control/XamlUICommand.png</file>
|
||||||
|
<file>res/svg/home.svg</file>
|
||||||
|
<file>res/svg/home_dark.svg</file>
|
||||||
|
<file>res/image/qrcode_wx.jpg</file>
|
||||||
|
<file>res/image/qrcode_zfb.jpg</file>
|
||||||
|
<file>qml/App.qml</file>
|
||||||
|
<file>qml/component/CodeExpander.qml</file>
|
||||||
|
<file>qml/global/ItemsFooter.qml</file>
|
||||||
|
<file>qml/global/ItemsOriginal.qml</file>
|
||||||
|
<file>qml/global/MainEvent.qml</file>
|
||||||
|
<file>qml/global/qmldir</file>
|
||||||
|
<file>qml/page/T_Acrylic.qml</file>
|
||||||
|
<file>qml/page/T_Awesome.qml</file>
|
||||||
|
<file>qml/page/T_Badge.qml</file>
|
||||||
|
<file>qml/page/T_BreadcrumbBar.qml</file>
|
||||||
|
<file>qml/page/T_Buttons.qml</file>
|
||||||
|
<file>qml/page/T_CalendarPicker.qml</file>
|
||||||
|
<file>qml/page/T_Carousel.qml</file>
|
||||||
|
<file>qml/page/T_CheckBox.qml</file>
|
||||||
|
<file>qml/page/T_ColorPicker.qml</file>
|
||||||
|
<file>qml/page/T_ComboBox.qml</file>
|
||||||
|
<file>qml/page/T_DatePicker.qml</file>
|
||||||
|
<file>qml/page/T_Dialog.qml</file>
|
||||||
|
<file>qml/page/T_Expander.qml</file>
|
||||||
|
<file>qml/page/T_FlipView.qml</file>
|
||||||
|
<file>qml/page/T_Home.qml</file>
|
||||||
|
<file>qml/page/T_InfoBar.qml</file>
|
||||||
|
<file>qml/page/T_Menu.qml</file>
|
||||||
|
<file>qml/page/T_MultiWindow.qml</file>
|
||||||
|
<file>qml/page/T_Pivot.qml</file>
|
||||||
|
<file>qml/page/T_Progress.qml</file>
|
||||||
|
<file>qml/page/T_RatingControl.qml</file>
|
||||||
|
<file>qml/page/T_Rectangle.qml</file>
|
||||||
|
<file>qml/page/T_Settings.qml</file>
|
||||||
|
<file>qml/page/T_Slider.qml</file>
|
||||||
|
<file>qml/page/T_StatusView.qml</file>
|
||||||
|
<file>qml/page/T_TableView.qml</file>
|
||||||
|
<file>qml/page/T_TabView.qml</file>
|
||||||
|
<file>qml/page/T_Text.qml</file>
|
||||||
|
<file>qml/page/T_TextBox.qml</file>
|
||||||
|
<file>qml/page/T_Theme.qml</file>
|
||||||
|
<file>qml/page/T_TimePicker.qml</file>
|
||||||
|
<file>qml/page/T_ToggleSwitch.qml</file>
|
||||||
|
<file>qml/page/T_Tooltip.qml</file>
|
||||||
|
<file>qml/page/T_TreeView.qml</file>
|
||||||
|
<file>qml/page/T_Typography.qml</file>
|
||||||
|
<file>qml/window/AboutWindow.qml</file>
|
||||||
|
<file>qml/window/LoginWindow.qml</file>
|
||||||
|
<file>qml/window/MainWindow.qml</file>
|
||||||
|
<file>qml/window/SingleInstanceWindow.qml</file>
|
||||||
|
<file>qml/window/SingleTaskWindow.qml</file>
|
||||||
|
<file>qml/window/StandardWindow.qml</file>
|
||||||
|
<file>qml/component/CustomWindow.qml</file>
|
||||||
|
<file>qml/page/T_Image.qml</file>
|
||||||
|
<file>qml/page/T_Pagination.qml</file>
|
||||||
|
<file>qml/page/T_RadioButton.qml</file>
|
||||||
|
<file>qml/page/T_RemoteLoader.qml</file>
|
||||||
|
</qresource>
|
||||||
|
</RCC>
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
Window {
|
Window {
|
||||||
id: app
|
id: app
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
FluExpander{
|
FluExpander{
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import org.wangwenx190.FramelessHelper
|
import org.wangwenx190.FramelessHelper 1.0
|
||||||
|
|
||||||
FluWindow {
|
FluWindow {
|
||||||
|
|
||||||
|
@ -50,15 +50,6 @@ FluWindow {
|
||||||
window.show()
|
window.show()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Connections{
|
|
||||||
target: FluTheme
|
|
||||||
function onDarkChanged(){
|
|
||||||
if (FluTheme.dark)
|
|
||||||
FramelessUtils.systemTheme = FramelessHelperConstants.Dark
|
|
||||||
else
|
|
||||||
FramelessUtils.systemTheme = FramelessHelperConstants.Light
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function setHitTestVisible(com){
|
function setHitTestVisible(com){
|
||||||
framless_helper.setHitTestVisible(com)
|
framless_helper.setHitTestVisible(com)
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
pragma Singleton
|
pragma Singleton
|
||||||
|
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
FluObject{
|
FluObject{
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
pragma Singleton
|
pragma Singleton
|
||||||
|
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
FluObject{
|
FluObject{
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
pragma Singleton
|
pragma Singleton
|
||||||
|
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
QtObject {
|
QtObject {
|
||||||
property int displayMode : FluNavigationView.Auto
|
property int displayMode : FluNavigationView.Auto
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
FluContentPage {
|
FluContentPage {
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,9 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Controls.Basic
|
import FluentUI 1.0
|
||||||
import FluentUI
|
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
@ -58,7 +58,6 @@ FluScrollablePage{
|
||||||
width: parent.width
|
width: parent.width
|
||||||
height: parent.height
|
height: parent.height
|
||||||
contentWidth: width
|
contentWidth: width
|
||||||
maximumFlickVelocity: 1680
|
|
||||||
contentHeight: text_info.height
|
contentHeight: text_info.height
|
||||||
ScrollBar.vertical: FluScrollBar {}
|
ScrollBar.vertical: FluScrollBar {}
|
||||||
FluText{
|
FluText{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import "qrc:///example/qml/global"
|
import "qrc:///example/qml/global"
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage {
|
FluScrollablePage {
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluPage{
|
FluPage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/global"
|
import "qrc:///example/qml/global"
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
|
|
|
@ -1,9 +1,9 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluContentPage{
|
FluContentPage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage{
|
FluScrollablePage{
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
FluScrollablePage {
|
FluScrollablePage {
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
FluContentPage {
|
FluContentPage {
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
CustomWindow {
|
CustomWindow {
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
CustomWindow {
|
CustomWindow {
|
||||||
|
|
|
@ -1,10 +1,10 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import Qt.labs.platform
|
import Qt.labs.platform 1.0
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import example
|
import example 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
import "qrc:///example/qml/global"
|
import "qrc:///example/qml/global"
|
||||||
|
|
||||||
|
@ -37,7 +37,7 @@ CustomWindow {
|
||||||
SystemTrayIcon {
|
SystemTrayIcon {
|
||||||
id:system_tray
|
id:system_tray
|
||||||
visible: true
|
visible: true
|
||||||
icon.source: "qrc:/example/res/image/favicon.ico"
|
iconSource: "qrc:/example/res/image/favicon.ico"
|
||||||
tooltip: "FluentUI"
|
tooltip: "FluentUI"
|
||||||
menu: Menu {
|
menu: Menu {
|
||||||
MenuItem {
|
MenuItem {
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
CustomWindow {
|
CustomWindow {
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
CustomWindow {
|
CustomWindow {
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "qrc:///example/qml/component"
|
import "qrc:///example/qml/component"
|
||||||
|
|
||||||
CustomWindow {
|
CustomWindow {
|
||||||
|
|
|
@ -26,7 +26,7 @@ int main(int argc, char *argv[])
|
||||||
FramelessConfig::instance()->set(Global::Option::DisableLazyInitializationForMicaMaterial);
|
FramelessConfig::instance()->set(Global::Option::DisableLazyInitializationForMicaMaterial);
|
||||||
FramelessConfig::instance()->set(Global::Option::CenterWindowBeforeShow);
|
FramelessConfig::instance()->set(Global::Option::CenterWindowBeforeShow);
|
||||||
FramelessConfig::instance()->set(Global::Option::ForceNonNativeBackgroundBlur);
|
FramelessConfig::instance()->set(Global::Option::ForceNonNativeBackgroundBlur);
|
||||||
FramelessConfig::instance()->set(Global::Option::EnableBlurBehindWindow);
|
FramelessConfig::instance()->set(Global::Option::EnableBlurBehindWindow,false);
|
||||||
#ifdef Q_OS_MACOS
|
#ifdef Q_OS_MACOS
|
||||||
FramelessConfig::instance()->set(Global::Option::ForceNonNativeBackgroundBlur,false);
|
FramelessConfig::instance()->set(Global::Option::ForceNonNativeBackgroundBlur,false);
|
||||||
#endif
|
#endif
|
||||||
|
|
|
@ -1,7 +1,3 @@
|
||||||
#if defined(_MSC_VER) && (_MSC_VER >= 1600)
|
|
||||||
#pragma execution_character_set("utf-8")
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef STDAFX_H
|
#ifndef STDAFX_H
|
||||||
#define STDAFX_H
|
#define STDAFX_H
|
||||||
|
|
||||||
|
|
|
@ -1 +1 @@
|
||||||
Subproject commit f977a78d0ee8cf5f5dc723e8c5e9da8846d420b9
|
Subproject commit 20e12e5ec056b8d0959a4d30b715832f2a5d7a70
|
|
@ -1,15 +1,7 @@
|
||||||
cmake_minimum_required(VERSION 3.20)
|
cmake_minimum_required(VERSION 3.20)
|
||||||
|
set(CMAKE_CXX_STANDARD 17)
|
||||||
if (FLUENTUI_BUILD_STATIC_LIB)
|
|
||||||
project(fluentui LANGUAGES CXX)
|
|
||||||
else()
|
|
||||||
project(fluentuiplugin LANGUAGES CXX)
|
|
||||||
endif()
|
|
||||||
#配置通用编译
|
|
||||||
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
set(CMAKE_CXX_STANDARD_REQUIRED ON)
|
||||||
if(APPLE)
|
project(fluentuiplugin LANGUAGES CXX)
|
||||||
set(CMAKE_OSX_ARCHITECTURES "arm64;x86_64" CACHE STRING "" FORCE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
#设置QML插件输出目录->D:\Qt\6.4.3\msvc2019_64\qml\FluentUI
|
#设置QML插件输出目录->D:\Qt\6.4.3\msvc2019_64\qml\FluentUI
|
||||||
set(QML_PLUGIN_DIRECTORY ${CMAKE_PREFIX_PATH}/qml/FluentUI)
|
set(QML_PLUGIN_DIRECTORY ${CMAKE_PREFIX_PATH}/qml/FluentUI)
|
||||||
|
@ -17,14 +9,16 @@ set(QML_PLUGIN_DIRECTORY ${CMAKE_PREFIX_PATH}/qml/FluentUI)
|
||||||
#设置版本号
|
#设置版本号
|
||||||
add_definitions(-DVERSION=1,3,7,3)
|
add_definitions(-DVERSION=1,3,7,3)
|
||||||
|
|
||||||
find_package(Qt6 REQUIRED COMPONENTS Core Quick Qml)
|
find_package(Qt5 REQUIRED COMPONENTS Core Quick Qml)
|
||||||
|
|
||||||
if(QT_VERSION VERSION_GREATER_EQUAL "6.3")
|
set(CMAKE_AUTOMOC ON)
|
||||||
qt_standard_project_setup()
|
set(CMAKE_AUTORCC ON)
|
||||||
else()
|
set(CMAKE_AUTOUIC ON)
|
||||||
set(CMAKE_AUTOMOC ON)
|
|
||||||
set(CMAKE_AUTORCC ON)
|
if (FLUENTUI_BUILD_STATIC_LIB)
|
||||||
set(CMAKE_AUTOUIC ON)
|
add_definitions(-DQT_PLUGIN)
|
||||||
|
add_definitions(-DQT_STATICPLUGIN=1)
|
||||||
|
add_definitions(-DFLUENTUI_BUILD_STATIC_LIB=1)
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
#遍历所有Cpp文件
|
#遍历所有Cpp文件
|
||||||
|
@ -48,48 +42,30 @@ foreach(filepath ${RES_PATHS})
|
||||||
list(APPEND resource_files ${filename})
|
list(APPEND resource_files ${filename})
|
||||||
endforeach(filepath)
|
endforeach(filepath)
|
||||||
|
|
||||||
#修改资源文件导出路径
|
|
||||||
foreach(filepath IN LISTS qml_files resource_files)
|
|
||||||
string(REPLACE "imports/FluentUI/" "" filename ${filepath})
|
|
||||||
set_source_files_properties(${filepath} PROPERTIES QT_RESOURCE_ALIAS ${filename})
|
|
||||||
endforeach()
|
|
||||||
|
|
||||||
#添加qml模块
|
#添加qml模块
|
||||||
|
include(cmake/QmlPlugin.cmake)
|
||||||
if (FLUENTUI_BUILD_STATIC_LIB)
|
if (FLUENTUI_BUILD_STATIC_LIB)
|
||||||
set(LIB_TYPE "STATIC")
|
set(LIB_TYPE "STATIC")
|
||||||
else()
|
else()
|
||||||
set(LIB_TYPE "SHARED")
|
set(LIB_TYPE "SHARED")
|
||||||
endif()
|
endif()
|
||||||
qt_add_library(${PROJECT_NAME} ${LIB_TYPE})
|
|
||||||
if (FLUENTUI_BUILD_STATIC_LIB)
|
|
||||||
qt_add_qml_module(${PROJECT_NAME}
|
|
||||||
#在静态库编译中使用PLUGIN_TARGET会导致链接失败
|
|
||||||
OUTPUT_DIRECTORY ${QML_PLUGIN_DIRECTORY}
|
|
||||||
VERSION 1.0
|
|
||||||
URI "FluentUI"
|
|
||||||
#修改qmltypes文件名称。默认fluentuiplugin.qmltypes,使用默认名称有时候import FluentUI会爆红,所以修改成plugins.qmltypes
|
|
||||||
TYPEINFO "plugins.qmltypes"
|
|
||||||
SOURCES ${sources_files} fluentui.rc
|
|
||||||
QML_FILES ${qml_files}
|
|
||||||
RESOURCES ${resource_files}
|
|
||||||
)
|
|
||||||
else()
|
|
||||||
qt_add_qml_module(${PROJECT_NAME}
|
|
||||||
#没有下面这行代码就会生成fluentuiplugin.dll与fluentuipluginplugin.dll两个动态库
|
|
||||||
PLUGIN_TARGET fluentuiplugin
|
|
||||||
OUTPUT_DIRECTORY ${QML_PLUGIN_DIRECTORY}
|
|
||||||
VERSION 1.0
|
|
||||||
URI "FluentUI"
|
|
||||||
#修改qmltypes文件名称。默认fluentuiplugin.qmltypes,使用默认名称有时候import FluentUI会爆红,所以修改成plugins.qmltypes
|
|
||||||
TYPEINFO "plugins.qmltypes"
|
|
||||||
SOURCES ${sources_files} fluentui.rc
|
|
||||||
QML_FILES ${qml_files}
|
|
||||||
RESOURCES ${resource_files}
|
|
||||||
)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
|
add_qmlplugin(fluentuiplugin
|
||||||
|
URI "FluentUI"
|
||||||
|
VERSION 1.0
|
||||||
|
SOURCES ${sources_files} fluentui.rc fluentui.qrc
|
||||||
|
QMLFILES ${qml_files}
|
||||||
|
QMLDIR imports/FluentUI
|
||||||
|
BINARY_DIR ${QML_PLUGIN_DIRECTORY}
|
||||||
|
LIBTYPE ${LIB_TYPE}
|
||||||
|
)
|
||||||
|
|
||||||
|
if(FLUENTUI_BUILD_STATIC_LIB)
|
||||||
|
SET_TARGET_PROPERTIES(fluentuiplugin PROPERTIES
|
||||||
|
AUTOMOC_MOC_OPTIONS -Muri=FluentUI)
|
||||||
|
endif()
|
||||||
#链接库
|
#链接库
|
||||||
target_link_libraries(${PROJECT_NAME} PUBLIC
|
target_link_libraries(fluentuiplugin PUBLIC
|
||||||
Qt::CorePrivate
|
Qt::CorePrivate
|
||||||
Qt::QuickPrivate
|
Qt::QuickPrivate
|
||||||
Qt::QmlPrivate
|
Qt::QmlPrivate
|
||||||
|
|
|
@ -26,9 +26,6 @@ class FluApp : public QObject
|
||||||
* @brief routes 路由表
|
* @brief routes 路由表
|
||||||
*/
|
*/
|
||||||
Q_PROPERTY_AUTO(QJsonObject,routes);
|
Q_PROPERTY_AUTO(QJsonObject,routes);
|
||||||
|
|
||||||
QML_NAMED_ELEMENT(FluApp)
|
|
||||||
QML_SINGLETON
|
|
||||||
private:
|
private:
|
||||||
/**
|
/**
|
||||||
* @brief FluApp 将默认构造函数设置为私有,则qml创建单例就会走create工厂方法创建单例
|
* @brief FluApp 将默认构造函数设置为私有,则qml创建单例就会走create工厂方法创建单例
|
||||||
|
|
|
@ -44,8 +44,6 @@ class FluColors : public QObject
|
||||||
Q_PROPERTY_AUTO(FluColorSet*,Blue);
|
Q_PROPERTY_AUTO(FluColorSet*,Blue);
|
||||||
Q_PROPERTY_AUTO(FluColorSet*,Teal);
|
Q_PROPERTY_AUTO(FluColorSet*,Teal);
|
||||||
Q_PROPERTY_AUTO(FluColorSet*,Green);
|
Q_PROPERTY_AUTO(FluColorSet*,Green);
|
||||||
QML_NAMED_ELEMENT(FluColors)
|
|
||||||
QML_SINGLETON
|
|
||||||
private:
|
private:
|
||||||
explicit FluColors(QObject *parent = nullptr);
|
explicit FluColors(QObject *parent = nullptr);
|
||||||
static FluColors* m_instance;
|
static FluColors* m_instance;
|
||||||
|
|
|
@ -1,4 +1,13 @@
|
||||||
#include "FluTextStyle.h"
|
#include "FluTextStyle.h"
|
||||||
|
FluTextStyle* FluTextStyle::m_instance = nullptr;
|
||||||
|
|
||||||
|
FluTextStyle *FluTextStyle::getInstance()
|
||||||
|
{
|
||||||
|
if(FluTextStyle::m_instance == nullptr){
|
||||||
|
FluTextStyle::m_instance = new FluTextStyle;
|
||||||
|
}
|
||||||
|
return FluTextStyle::m_instance;
|
||||||
|
}
|
||||||
|
|
||||||
FluTextStyle::FluTextStyle(QObject *parent)
|
FluTextStyle::FluTextStyle(QObject *parent)
|
||||||
: QObject{parent}
|
: QObject{parent}
|
||||||
|
|
|
@ -10,7 +10,6 @@ class FluTextStyle : public QObject
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
public:
|
public:
|
||||||
explicit FluTextStyle(QObject *parent = nullptr);
|
|
||||||
Q_PROPERTY_AUTO(QFont,Caption);
|
Q_PROPERTY_AUTO(QFont,Caption);
|
||||||
Q_PROPERTY_AUTO(QFont,Body);
|
Q_PROPERTY_AUTO(QFont,Body);
|
||||||
Q_PROPERTY_AUTO(QFont,BodyStrong);
|
Q_PROPERTY_AUTO(QFont,BodyStrong);
|
||||||
|
@ -18,10 +17,12 @@ public:
|
||||||
Q_PROPERTY_AUTO(QFont,Title);
|
Q_PROPERTY_AUTO(QFont,Title);
|
||||||
Q_PROPERTY_AUTO(QFont,TitleLarge);
|
Q_PROPERTY_AUTO(QFont,TitleLarge);
|
||||||
Q_PROPERTY_AUTO(QFont,Display);
|
Q_PROPERTY_AUTO(QFont,Display);
|
||||||
QML_NAMED_ELEMENT(FluTextStyle)
|
private:
|
||||||
QML_SINGLETON
|
static FluTextStyle* m_instance;
|
||||||
signals:
|
|
||||||
|
|
||||||
|
public:
|
||||||
|
explicit FluTextStyle(QObject *parent = nullptr);
|
||||||
|
static FluTextStyle *getInstance();
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // FLUTEXTSTYLE_H
|
#endif // FLUTEXTSTYLE_H
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#ifndef FLUTHEME_H
|
#ifndef FLUTHEME_H
|
||||||
#define FLUTHEME_H
|
#define FLUTHEME_H
|
||||||
|
|
||||||
#include <QObject>
|
#include <QObject>
|
||||||
|
@ -36,9 +36,6 @@ class FluTheme : public QObject
|
||||||
* @brief 是否开启动画效果
|
* @brief 是否开启动画效果
|
||||||
*/
|
*/
|
||||||
Q_PROPERTY_AUTO(bool,enableAnimation);
|
Q_PROPERTY_AUTO(bool,enableAnimation);
|
||||||
|
|
||||||
QML_NAMED_ELEMENT(FluTheme)
|
|
||||||
QML_SINGLETON
|
|
||||||
private:
|
private:
|
||||||
static FluTheme* m_instance;
|
static FluTheme* m_instance;
|
||||||
explicit FluTheme(QObject *parent = nullptr);
|
explicit FluTheme(QObject *parent = nullptr);
|
||||||
|
|
|
@ -11,9 +11,6 @@
|
||||||
class FluTools : public QObject
|
class FluTools : public QObject
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
|
|
||||||
QML_NAMED_ELEMENT(FluTools)
|
|
||||||
QML_SINGLETON
|
|
||||||
private:
|
private:
|
||||||
explicit FluTools(QObject *parent = nullptr);
|
explicit FluTools(QObject *parent = nullptr);
|
||||||
static FluTools* m_instance;
|
static FluTools* m_instance;
|
||||||
|
|
|
@ -14,7 +14,6 @@
|
||||||
class WindowHelper : public QObject
|
class WindowHelper : public QObject
|
||||||
{
|
{
|
||||||
Q_OBJECT
|
Q_OBJECT
|
||||||
QML_NAMED_ELEMENT(WindowHelper)
|
|
||||||
public:
|
public:
|
||||||
explicit WindowHelper(QObject *parent = nullptr);
|
explicit WindowHelper(QObject *parent = nullptr);
|
||||||
|
|
||||||
|
|
|
@ -0,0 +1,141 @@
|
||||||
|
include(CMakeParseArguments)
|
||||||
|
find_package(Qt5 REQUIRED COMPONENTS Core)
|
||||||
|
### Finds where to qmlplugindump binary is installed
|
||||||
|
### Requires that 'qmake' directory is in PATH
|
||||||
|
function(FindQmlPluginDump)
|
||||||
|
get_target_property (QT_QMAKE_EXECUTABLE Qt5::qmake IMPORTED_LOCATION)
|
||||||
|
execute_process(
|
||||||
|
COMMAND ${QT_QMAKE_EXECUTABLE} -query QT_INSTALL_BINS
|
||||||
|
OUTPUT_VARIABLE QT_BIN_DIR
|
||||||
|
OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||||
|
)
|
||||||
|
set(QMLPLUGINDUMP_BIN ${QT_BIN_DIR}/qmlplugindump PARENT_SCOPE)
|
||||||
|
endfunction()
|
||||||
|
|
||||||
|
### Sets QT_INSTALL_QML to the directory where QML Plugins should be installed
|
||||||
|
function(FindQtInstallQml)
|
||||||
|
execute_process(
|
||||||
|
COMMAND ${QT_QMAKE_EXECUTABLE} -query QT_INSTALL_QML
|
||||||
|
OUTPUT_VARIABLE PROC_RESULT
|
||||||
|
OUTPUT_STRIP_TRAILING_WHITESPACE
|
||||||
|
)
|
||||||
|
set(QT_INSTALL_QML ${PROC_RESULT} PARENT_SCOPE)
|
||||||
|
endfunction()
|
||||||
|
|
||||||
|
function(add_qmlplugin TARGET)
|
||||||
|
set(options NO_AUTORCC NO_AUTOMOC)
|
||||||
|
set(oneValueArgs URI VERSION BINARY_DIR QMLDIR LIBTYPE)
|
||||||
|
set(multiValueArgs SOURCES QMLFILES QMLFILESALIAS)
|
||||||
|
cmake_parse_arguments(QMLPLUGIN "${options}" "${oneValueArgs}" "${multiValueArgs}" ${ARGN})
|
||||||
|
|
||||||
|
### At least TARGET, URI and VERSION must be specified
|
||||||
|
if(NOT QMLPLUGIN_URI OR NOT QMLPLUGIN_VERSION OR NOT QMLPLUGIN_QMLDIR OR NOT QMLPLUGIN_LIBTYPE)
|
||||||
|
message(WARNING "TARGET,URI,VERSION,qmldir and LIBTYPE must be set, no files generated")
|
||||||
|
return()
|
||||||
|
endif()
|
||||||
|
|
||||||
|
### Depending on project hierarchy, one might want to specify a custom binary dir
|
||||||
|
if(NOT QMLPLUGIN_BINARY_DIR)
|
||||||
|
set(QMLPLUGIN_BINARY_DIR ${CMAKE_BINARY_DIR}/${QMLPLUGIN_URI})
|
||||||
|
endif()
|
||||||
|
|
||||||
|
### Source files
|
||||||
|
add_library(${TARGET} ${QMLPLUGIN_LIBTYPE}
|
||||||
|
${QMLPLUGIN_SOURCES}
|
||||||
|
)
|
||||||
|
set(LIBRARY_OUTPUT_PATH ${CMAKE_CURRENT_BINARY_DIR}/lib)
|
||||||
|
### QML files, just to make them visible in the editor
|
||||||
|
add_custom_target("${TARGET}-qmlfiles" SOURCES ${QMLPLUGIN_QMLFILES})
|
||||||
|
|
||||||
|
### No AutoMOC or AutoRCC
|
||||||
|
if(QMLPLUGIN_NO_AUTORCC)
|
||||||
|
set_target_properties(${TARGET} PROPERTIES AUTOMOC OFF)
|
||||||
|
else()
|
||||||
|
set_target_properties(${TARGET} PROPERTIES AUTOMOC ON)
|
||||||
|
endif()
|
||||||
|
if(QMLPLUGIN_NO_AUTOMOC)
|
||||||
|
set_target_properties(${TARGET} PROPERTIES AUTOMOC OFF)
|
||||||
|
else()
|
||||||
|
set_target_properties(${TARGET} PROPERTIES AUTOMOC ON)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
if (${QMLPLUGIN_LIBTYPE} MATCHES "SHARED")
|
||||||
|
### Find location of qmlplugindump (stored in QMLPLUGINDUMP_BIN)
|
||||||
|
FindQmlPluginDump()
|
||||||
|
### Find where to install QML Plugins (stored in QT_INSTALL_QML)
|
||||||
|
FindQtInstallQml()
|
||||||
|
|
||||||
|
|
||||||
|
if(QMLPLUGIN_BINARY_DIR)
|
||||||
|
set(MAKE_QMLPLUGINDIR_COMMAND ${CMAKE_COMMAND} -E make_directory ${QMLPLUGIN_BINARY_DIR})
|
||||||
|
endif()
|
||||||
|
set(COPY_QMLDIR_COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_LIST_DIR}/${QMLPLUGIN_QMLDIR}/qmldir $<TARGET_FILE_DIR:${TARGET}>/${QMLPLUGIN_URI}/qmldir)
|
||||||
|
set(INSTALL_QMLDIR_COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_LIST_DIR}/${QMLPLUGIN_QMLDIR}/qmldir ${QMLPLUGIN_BINARY_DIR}/qmldir)
|
||||||
|
set(COPY_LIBRARY_COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_BINARY_DIR}/$<TARGET_FILE_NAME:${TARGET}> $<TARGET_FILE_DIR:${TARGET}>/${QMLPLUGIN_URI})
|
||||||
|
set(INSTALL_LIBRARY_COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_BINARY_DIR}/$<TARGET_FILE_NAME:${TARGET}> ${QMLPLUGIN_BINARY_DIR})
|
||||||
|
if(QMLPLUGIN_QMLDIR)
|
||||||
|
set(COPY_QMLFILES_COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_LIST_DIR}/${QMLPLUGIN_QMLDIR} $<TARGET_FILE_DIR:${TARGET}>/${QMLPLUGIN_URI})
|
||||||
|
else()
|
||||||
|
set(COPY_QMLFILES_COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_CURRENT_LIST_DIR}/${QMLPLUGIN_QMLFILES} $<TARGET_FILE_DIR:${TARGET}>/${QMLPLUGIN_URI})
|
||||||
|
endif()
|
||||||
|
set(INSTALL_QMLFILES_COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_CURRENT_LIST_DIR}/${QMLPLUGIN_QMLDIR} ${QMLPLUGIN_BINARY_DIR})
|
||||||
|
set(GENERATE_QMLTYPES_COMMAND ${QMLPLUGINDUMP_BIN} -nonrelocatable ${QMLPLUGIN_URI} ${QMLPLUGIN_VERSION} ${CMAKE_CURRENT_BINARY_DIR} > ${CMAKE_CURRENT_BINARY_DIR}/${QMLPLUGIN_URI}/plugins.qmltypes)
|
||||||
|
set(INSTALL_QMLTYPES_COMMAND ${QMLPLUGINDUMP_BIN} -nonrelocatable ${QMLPLUGIN_URI} ${QMLPLUGIN_VERSION} ${CMAKE_CURRENT_BINARY_DIR} > ${QMLPLUGIN_BINARY_DIR}/plugins.qmltypes)
|
||||||
|
### Copy qmldir from project source to binary dir
|
||||||
|
if(QMLPLUGIN_BINARY_DIR)
|
||||||
|
add_custom_command(
|
||||||
|
TARGET ${TARGET}
|
||||||
|
POST_BUILD
|
||||||
|
COMMAND ${MAKE_QMLPLUGINDIR_COMMAND}
|
||||||
|
COMMAND ${COPY_QMLDIR_COMMAND}
|
||||||
|
COMMENT "Copying qmldir to binary directory"
|
||||||
|
)
|
||||||
|
else()
|
||||||
|
add_custom_command(
|
||||||
|
TARGET ${TARGET}
|
||||||
|
POST_BUILD
|
||||||
|
COMMAND ${COPY_QMLDIR_COMMAND}
|
||||||
|
COMMENT "Copying qmldir to binary directory"
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
### Copy lib from binary dir to binary plugin dir
|
||||||
|
add_custom_command(
|
||||||
|
TARGET ${TARGET}
|
||||||
|
POST_BUILD
|
||||||
|
COMMAND ${COPY_LIBRARY_COMMAND}
|
||||||
|
COMMENT "Copying Lib to binary plugin directory"
|
||||||
|
)
|
||||||
|
|
||||||
|
### Copy QML-files from project source to binary dir
|
||||||
|
if(QMLPLUGIN_QMLFILES)
|
||||||
|
add_custom_command(
|
||||||
|
TARGET ${TARGET}
|
||||||
|
POST_BUILD
|
||||||
|
COMMAND ${COPY_QMLFILES_COMMAND}
|
||||||
|
COMMENT "Copying QML files to binary directory"
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
|
||||||
|
### Create command to generate plugin.qmltypes after build
|
||||||
|
add_custom_command(
|
||||||
|
TARGET ${TARGET}
|
||||||
|
POST_BUILD
|
||||||
|
COMMAND ${GENERATE_QMLTYPES_COMMAND}
|
||||||
|
COMMENT "Generating plugin.qmltypes"
|
||||||
|
)
|
||||||
|
|
||||||
|
string(REPLACE "." "/" QMLPLUGIN_INSTALL_URI ${QMLPLUGIN_URI})
|
||||||
|
|
||||||
|
### Install library
|
||||||
|
add_custom_command(
|
||||||
|
TARGET ${TARGET}
|
||||||
|
POST_BUILD
|
||||||
|
COMMAND ${INSTALL_QMLDIR_COMMAND}
|
||||||
|
COMMAND ${INSTALL_LIBRARY_COMMAND}
|
||||||
|
COMMAND ${INSTALL_QMLFILES_COMMAND}
|
||||||
|
COMMAND ${INSTALL_QMLTYPES_COMMAND}
|
||||||
|
COMMENT "Install library and aditional files"
|
||||||
|
)
|
||||||
|
endif()
|
||||||
|
endfunction()
|
|
@ -0,0 +1,92 @@
|
||||||
|
<RCC>
|
||||||
|
<qresource prefix="/FluentUI">
|
||||||
|
<file>imports/FluentUI/Controls/FluAcrylic.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluAppBar.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluArea.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluAutoSuggestBox.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluBreadcrumbBar.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluButton.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluCalendarPicker.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluCalendarView.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluCheckBox.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluColorPicker.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluColorView.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluComboBox.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluContentPage.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluControl.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluCopyableText.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluDatePicker.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluDropDownButton.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluExpander.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluFilledButton.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluFlipView.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluHorizontalHeaderView.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluIcon.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluIconButton.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluImage.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluItem.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluItemDelegate.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluMenu.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluMenuBar.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluMenuItem.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluMenuSeparator.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluMultilineTextBox.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluNavigationView.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluPage.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluPagination.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluPaneItem.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluPaneItemEmpty.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluPaneItemHeader.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluPaneItemSeparator.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluPasswordBox.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluPivot.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluPopup.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluProgressBar.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluProgressRing.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluRadioButton.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluRatingControl.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluRectangle.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluRemoteLoader.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluScrollablePage.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluScrollIndicator.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluShadow.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluSlider.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluSpinBox.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluTableModelColumn.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluTableView.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluTabView.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluText.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluTextBoxBackground.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluTextBoxMenu.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluTextButton.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluTimePicker.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluToggleSwitch.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluTooltip.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluTreeView.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluVerticalHeaderView.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluBadge.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluCarousel.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluContentDialog.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluDivider.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluFocusRectangle.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluInfoBar.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluMenuBarItem.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluObject.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluPaneItemExpander.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluPivotItem.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluRadioButtons.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluScrollBar.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluStatusView.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluTextBox.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluToggleButton.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/FluWindow.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/ColorPicker/ColorPicker.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/ColorPicker/Content/Checkerboard.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/ColorPicker/Content/ColorSlider.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/ColorPicker/Content/NumberBox.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/ColorPicker/Content/PanelBorder.qml</file>
|
||||||
|
<file>imports/FluentUI/Controls/ColorPicker/Content/SBPicker.qml</file>
|
||||||
|
<file>imports/FluentUI/Font/Segoe_Fluent_Icons.ttf</file>
|
||||||
|
<file>imports/FluentUI/qmldir</file>
|
||||||
|
</qresource>
|
||||||
|
</RCC>
|
|
@ -0,0 +1,62 @@
|
||||||
|
#include "fluentuiplugin.h"
|
||||||
|
#include <QtQml/QQmlExtensionPlugin>
|
||||||
|
#include <QGuiApplication>
|
||||||
|
#include <qdebug.h>
|
||||||
|
#include "WindowHelper.h"
|
||||||
|
#include "Def.h"
|
||||||
|
#include "FluApp.h"
|
||||||
|
#include "FluColors.h"
|
||||||
|
#include "FluTheme.h"
|
||||||
|
#include "FluTools.h"
|
||||||
|
#include "FluTextStyle.h"
|
||||||
|
int major = 1;
|
||||||
|
int minor = 0;
|
||||||
|
static FluentUIPlugin instance;
|
||||||
|
|
||||||
|
FluentUIPlugin::FluentUIPlugin()
|
||||||
|
{
|
||||||
|
#ifdef FLUENTUI_BUILD_STATIC_LIB
|
||||||
|
Q_INIT_RESOURCE(fluentui);
|
||||||
|
#endif
|
||||||
|
}
|
||||||
|
|
||||||
|
void FluentUIPlugin::registerTypes(const char *uri)
|
||||||
|
{
|
||||||
|
qmlRegisterType<WindowHelper>(uri,major,minor,"WindowHelper");
|
||||||
|
qmlRegisterType<FluColorSet>(uri,major,minor,"FluColorSet");
|
||||||
|
qmlRegisterUncreatableMetaObject(Fluent_Awesome::staticMetaObject, uri,major,minor,"FluentIcons", "Access to enums & flags only");
|
||||||
|
qmlRegisterUncreatableMetaObject(Fluent_DarkMode::staticMetaObject, uri,major,minor,"FluDarkMode", "Access to enums & flags only");
|
||||||
|
}
|
||||||
|
|
||||||
|
#ifdef FLUENTUI_BUILD_STATIC_LIB
|
||||||
|
void FluentUIPlugin::registerTypes()
|
||||||
|
{
|
||||||
|
instance()->registerTypes("FluentUI");
|
||||||
|
}
|
||||||
|
|
||||||
|
FluentUIPlugin* FluentUIPlugin::instance()
|
||||||
|
{
|
||||||
|
static FluentUIPlugin instance;
|
||||||
|
return &instance;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
void FluentUIPlugin::initializeEngine(QQmlEngine *engine, const char *uri)
|
||||||
|
{
|
||||||
|
Q_UNUSED(uri)
|
||||||
|
#ifdef Q_OS_WIN
|
||||||
|
QFont font;
|
||||||
|
font.setFamily("Microsoft YaHei");
|
||||||
|
QGuiApplication::setFont(font);
|
||||||
|
#endif
|
||||||
|
FluApp* app = FluApp::getInstance();
|
||||||
|
engine->rootContext()->setContextProperty("FluApp",app);
|
||||||
|
FluColors* colors = FluColors::getInstance();
|
||||||
|
engine->rootContext()->setContextProperty("FluColors",colors);
|
||||||
|
FluTheme* theme = FluTheme::getInstance();
|
||||||
|
engine->rootContext()->setContextProperty("FluTheme",theme);
|
||||||
|
FluTools* tools = FluTools::getInstance();
|
||||||
|
engine->rootContext()->setContextProperty("FluTools",tools);
|
||||||
|
FluTextStyle* textStyle = FluTextStyle::getInstance();
|
||||||
|
engine->rootContext()->setContextProperty("FluTextStyle",textStyle);
|
||||||
|
engine->addImportPath("qrc:/FluentUI/imports/");
|
||||||
|
}
|
|
@ -0,0 +1,23 @@
|
||||||
|
#ifndef FLUENTUIPLUGIN_H
|
||||||
|
#define FLUENTUIPLUGIN_H
|
||||||
|
|
||||||
|
#include <QQmlExtensionPlugin>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
class FluentUIPlugin : public QQmlExtensionPlugin
|
||||||
|
{
|
||||||
|
Q_OBJECT
|
||||||
|
Q_PLUGIN_METADATA(IID QQmlExtensionInterface_iid)
|
||||||
|
|
||||||
|
public:
|
||||||
|
FluentUIPlugin();
|
||||||
|
void registerTypes(const char *uri) Q_DECL_OVERRIDE;
|
||||||
|
#ifdef FLUENTUI_BUILD_STATIC_LIB
|
||||||
|
static void registerTypes();
|
||||||
|
static FluentUIPlugin* instance();
|
||||||
|
#endif
|
||||||
|
void initializeEngine(QQmlEngine *engine, const char *uri) Q_DECL_OVERRIDE;
|
||||||
|
};
|
||||||
|
|
||||||
|
#endif // FLUENTUIPLUGIN_H
|
|
@ -1,6 +1,6 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import "Content"
|
import "Content"
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
|
|
||||||
Grid {
|
Grid {
|
||||||
id: root
|
id: root
|
||||||
property int cellSide: 5
|
property int cellSide: 5
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
property int cursorHeight: 7
|
property int cursorHeight: 7
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
|
|
||||||
Row {
|
Row {
|
||||||
property alias caption: captionBox.text
|
property alias caption: captionBox.text
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
width : 40; height : 15; radius: 2
|
width : 40; height : 15; radius: 2
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
id: root
|
id: root
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import Qt5Compat.GraphicalEffects
|
import QtGraphicalEffects 1.0
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
id: control
|
id: control
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
Rectangle{
|
Rectangle{
|
||||||
property string title: ""
|
property string title: ""
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
default property alias content: container.data
|
default property alias content: container.data
|
||||||
|
|
|
@ -1,6 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import QtQuick.Controls 2.15
|
||||||
|
import FluentUI 1.0
|
||||||
|
|
||||||
FluTextBox{
|
FluTextBox{
|
||||||
property var items:[]
|
property var items:[]
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
Rectangle{
|
Rectangle{
|
||||||
property bool isDot: false
|
property bool isDot: false
|
||||||
|
|
|
@ -1,7 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
property int textSize: 15
|
property int textSize: 15
|
||||||
|
|
|
@ -1,7 +1,6 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Controls.Basic
|
import FluentUI 1.0
|
||||||
import FluentUI
|
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
property bool disabled: false
|
property bool disabled: false
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
property color dividerColor: FluTheme.dark ? Qt.rgba(77/255,77/255,77/255,1) : Qt.rgba(239/255,239/255,239/255,1)
|
property color dividerColor: FluTheme.dark ? Qt.rgba(77/255,77/255,77/255,1) : Qt.rgba(239/255,239/255,239/255,1)
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
enum DisplayMode {
|
enum DisplayMode {
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
property bool flagXChanged: true
|
property bool flagXChanged: true
|
||||||
|
|
|
@ -1,8 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Controls.Basic
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Layouts
|
import FluentUI 1.0
|
||||||
import FluentUI
|
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
property bool disabled: false
|
property bool disabled: false
|
||||||
|
@ -26,6 +25,11 @@ Button {
|
||||||
property var clickListener : function(){
|
property var clickListener : function(){
|
||||||
checked = !checked
|
checked = !checked
|
||||||
}
|
}
|
||||||
|
onCheckableChanged: {
|
||||||
|
if(checkable){
|
||||||
|
checkable = false
|
||||||
|
}
|
||||||
|
}
|
||||||
id:control
|
id:control
|
||||||
enabled: !disabled
|
enabled: !disabled
|
||||||
onClicked: clickListener()
|
onClicked: clickListener()
|
||||||
|
|
|
@ -1,9 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Controls.Basic
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Window
|
import FluentUI 1.0
|
||||||
import FluentUI
|
|
||||||
|
|
||||||
Button{
|
Button{
|
||||||
id:control
|
id:control
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import "ColorPicker"
|
import "ColorPicker"
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Controls.Basic
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
import QtQuick.Templates as T
|
import QtQuick.Templates 2.15 as T
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
id: control
|
id: control
|
||||||
|
@ -44,7 +44,7 @@ ComboBox {
|
||||||
topPadding: 6 - control.padding
|
topPadding: 6 - control.padding
|
||||||
bottomPadding: 6 - control.padding
|
bottomPadding: 6 - control.padding
|
||||||
renderType: FluTheme.nativeText ? Text.NativeRendering : Text.QtRendering
|
renderType: FluTheme.nativeText ? Text.NativeRendering : Text.QtRendering
|
||||||
selectionColor: Qt.alpha(FluTheme.primaryColor.lightest,0.6)
|
selectionColor: FluTheme.primaryColor.lightest
|
||||||
selectedTextColor: color
|
selectedTextColor: color
|
||||||
text: control.editable ? control.editText : control.displayText
|
text: control.editable ? control.editText : control.displayText
|
||||||
enabled: control.editable
|
enabled: control.editable
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
FluPopup {
|
FluPopup {
|
||||||
id: popup
|
id: popup
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
FluPage {
|
FluPage {
|
||||||
property alias title: text_title.text
|
property alias title: text_title.text
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls.impl
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Templates as T
|
import FluentUI 1.0
|
||||||
|
import QtQuick.Templates 2.15 as T
|
||||||
|
|
||||||
T.Button {
|
T.Button {
|
||||||
id: control
|
id: control
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
TextEdit {
|
TextEdit {
|
||||||
property color textColor: FluTheme.dark ? FluColors.White : FluColors.Grey220
|
property color textColor: FluTheme.dark ? FluColors.White : FluColors.Grey220
|
||||||
|
@ -17,7 +17,7 @@ TextEdit {
|
||||||
selectByMouse: true
|
selectByMouse: true
|
||||||
selectedTextColor: color
|
selectedTextColor: color
|
||||||
bottomPadding: 0
|
bottomPadding: 0
|
||||||
selectionColor: Qt.alpha(FluTheme.primaryColor.lightest,0.6)
|
selectionColor: FluTheme.primaryColor.lightest
|
||||||
font:FluTextStyle.Body
|
font:FluTextStyle.Body
|
||||||
onSelectedTextChanged: {
|
onSelectedTextChanged: {
|
||||||
control.forceActiveFocus()
|
control.forceActiveFocus()
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts 1.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
property color dividerColor: FluTheme.dark ? Qt.rgba(77/255,77/255,77/255,1) : Qt.rgba(239/255,239/255,239/255,1)
|
property color dividerColor: FluTheme.dark ? Qt.rgba(77/255,77/255,77/255,1) : Qt.rgba(239/255,239/255,239/255,1)
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Window
|
import QtQuick.Window 2.15
|
||||||
import FluentUI
|
import FluentUI 1.0
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
color: FluTheme.dark ? Qt.rgba(60/255,60/255,60/255,1) : Qt.rgba(210/255,210/255,210/255,1)
|
color: FluTheme.dark ? Qt.rgba(60/255,60/255,60/255,1) : Qt.rgba(210/255,210/255,210/255,1)
|
||||||
|
|
|
@ -1,8 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick 2.15
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls 2.15
|
||||||
import QtQuick.Controls.Basic
|
import QtQuick.Window 2.15
|
||||||
import QtQuick.Window
|
import FluentUI 1.0
|
||||||
import FluentUI
|
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
property bool disabled: false
|
property bool disabled: false
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue