├── .clang-format ├── .clang-format-all ├── .github └── workflows │ ├── android.yml │ ├── ios-macos-11_0.yml- │ ├── ios.yml │ ├── macos.yml │ ├── ubuntu.yml │ ├── windows-2019.yml │ └── windows-2022.yml ├── .qmake.conf ├── .tag ├── 3rdparty ├── 3rdparty.pri └── TaoCommon │ ├── .clang-format │ ├── .qmake.conf │ ├── .tag │ ├── LICENSE │ ├── README.md │ ├── TaoCommon.pro │ ├── demo │ ├── CommonWithModule │ │ ├── CommonWithModule.pro │ │ ├── main.cpp │ │ ├── main.qml │ │ └── qml.qrc │ ├── CommonWithSource │ │ ├── CommonWithSource.pro │ │ ├── main.cpp │ │ ├── main.qml │ │ └── qml.qrc │ ├── ExampleLog │ │ ├── ExampleLog.pro │ │ └── main.cpp │ └── demo.pro │ ├── doc │ └── QtCreaterInstall.png │ ├── mkspecs │ └── features │ │ ├── taoBuildPath.prf │ │ ├── taoBundle.prf │ │ ├── taoVersion.prf │ │ └── vcpkg.prf │ ├── src │ ├── TaoCommon │ │ ├── CMakeLists.txt │ │ ├── Common │ │ │ ├── FileReadWrite.h │ │ │ ├── JsonSerialize.h │ │ │ ├── MathHelp.h │ │ │ ├── ObjectMap.h │ │ │ ├── Package.h │ │ │ ├── PropertyHelper.h │ │ │ └── Subject.h │ │ ├── Frameless │ │ │ ├── TaoFrameLessView.cpp │ │ │ └── TaoFrameLessView.h │ │ ├── Logger │ │ │ ├── Logger.cpp │ │ │ ├── Logger.h │ │ │ └── LoggerTemplate.h │ │ ├── QuickModel │ │ │ ├── QuickListItemBase.cpp │ │ │ ├── QuickListItemBase.h │ │ │ ├── QuickListModel.cpp │ │ │ ├── QuickListModel.h │ │ │ └── QuickModelBase.hpp │ │ ├── QuickTool │ │ │ ├── QuickTool.cpp │ │ │ └── QuickTool.h │ │ ├── QuickTree │ │ │ └── Model │ │ │ │ ├── QuickTreeItem.h │ │ │ │ ├── QuickTreeModel.cpp │ │ │ │ └── QuickTreeModel.h │ │ ├── TaoCommon.pri │ │ ├── TaoCommon.pro │ │ ├── TaoCommonGlobal.h │ │ ├── TaoCommonInstall.pri │ │ ├── Thread │ │ │ ├── ThreadCommon.h │ │ │ ├── ThreadPool.cpp │ │ │ ├── ThreadPool.h │ │ │ └── ThreadWorkerController.h │ │ └── Trans │ │ │ ├── Trans.cpp │ │ │ └── Trans.h │ └── src.pro │ ├── sync.profile │ └── tests │ ├── auto │ ├── auto.pro │ └── cmake │ │ ├── CMakeLists.txt │ │ └── cmake.pro │ └── tests.pro ├── CMakeLists.txt ├── LICENSE ├── MarketPlace ├── TaoQuick_descript.md └── TaoQuick_manifest.json ├── README-zh.md ├── README.md ├── TaoQuick.pro ├── TaoQuick.sln ├── clang-foramt-All.ps1 ├── cmake ├── taoCommon.cmake └── taoVersion.cmake ├── doc ├── cmake1.png ├── cmake2.png ├── cmake5.png ├── cmake6.png ├── core.png ├── start1.png ├── start2.png ├── start3.png ├── start4.png ├── start5.png ├── struct1.png ├── vs1.png ├── vs2.png ├── vs3.png ├── vs4.png ├── vs5.png ├── vs6.png └── vs7.png ├── examples ├── CMakeLists.txt ├── HelloTaoQuick1 │ ├── HelloTaoQuick1.pro │ ├── Res.qrc │ ├── main.cpp │ └── main.qml ├── HelloTaoQuick2 │ ├── CMakeLists.txt │ ├── main.cpp │ ├── main.qml │ ├── qml.qrc │ └── taoQuick.cmake ├── HelloTaoQuick3 │ ├── HelloTaoQuick3.sln │ └── HelloTaoQuick3 │ │ ├── HelloTaoQuick3.vcxproj │ │ ├── HelloTaoQuick3.vcxproj.filters │ │ ├── main.cpp │ │ ├── main.qml │ │ ├── qml.qrc │ │ └── taoQuick.props ├── TaoQuickShow │ ├── App.rc │ ├── CMakeLists.txt │ ├── Contents.qrc │ ├── Contents │ │ ├── Animation │ │ │ ├── AnimationBase.qml │ │ │ ├── Board.qml │ │ │ ├── Circle.qml │ │ │ ├── Cleavage.qml │ │ │ ├── Cross.qml │ │ │ ├── Diagonal.qml │ │ │ ├── Dissolve.qml │ │ │ ├── Enter.qml │ │ │ ├── Grad.qml │ │ │ ├── Louver.qml │ │ │ ├── Rhombus.qml │ │ │ ├── Square.qml │ │ │ └── Wheel.qml │ │ ├── Effect │ │ │ ├── ARound.qml │ │ │ ├── Arrow.qml │ │ │ ├── EditJoggle.qml │ │ │ ├── Effects │ │ │ │ ├── TAround.qml │ │ │ │ ├── TArrow.qml │ │ │ │ ├── TRingPage.qml │ │ │ │ ├── TSoundByte.qml │ │ │ │ └── TSwapper.qml │ │ │ ├── RingPage.qml │ │ │ ├── SoundByte.qml │ │ │ └── Swapper.qml │ │ ├── General │ │ │ ├── Buttons.qml │ │ │ ├── DataEntrys.qml │ │ │ ├── Drags.qml │ │ │ ├── EdgeTabBar.qml │ │ │ ├── Images.qml │ │ │ ├── Labels.qml │ │ │ ├── ListViewWithTab.qml │ │ │ ├── Miscs.qml │ │ │ ├── RoundRects.qml │ │ │ ├── Shapes.qml │ │ │ └── Tables.qml │ │ ├── PageSwitch │ │ │ ├── Board.qml │ │ │ ├── Circle.qml │ │ │ ├── Cleavage.qml │ │ │ ├── Cross.qml │ │ │ ├── Diagonal.qml │ │ │ ├── Dissolve.qml │ │ │ ├── FadeInOut.qml │ │ │ ├── Grad.qml │ │ │ ├── Louver.qml │ │ │ ├── PageSwitchBase.qml │ │ │ ├── Rhombus.qml │ │ │ ├── Sector.qml │ │ │ ├── Square.qml │ │ │ └── Wheel.qml │ │ ├── ShaderEffect │ │ │ ├── CloudHole.qml │ │ │ ├── Planet.qml │ │ │ ├── Planet1.png │ │ │ ├── Snail.qml │ │ │ └── SuperMario.qml │ │ └── ShapeGallery │ │ │ ├── ShapeCapStyles.qml │ │ │ ├── ShapeCircle.qml │ │ │ ├── ShapeCubicBezier.qml │ │ │ ├── ShapeEllipse.qml │ │ │ ├── ShapeEllipticalArc.qml │ │ │ ├── ShapeJoinStyles.qml │ │ │ ├── ShapeQuadraticBezier.qml │ │ │ ├── ShapeRectrangle.qml │ │ │ └── ShapeTriangle.qml │ ├── Image.qrc │ ├── Image │ │ ├── Button │ │ │ ├── download_black.png │ │ │ ├── download_blue.png │ │ │ ├── download_gray.png │ │ │ ├── download_red.png │ │ │ ├── download_white.png │ │ │ └── expand.png │ │ ├── Common │ │ │ ├── left.png │ │ │ ├── left_hovered.png │ │ │ ├── menu.png │ │ │ ├── right.png │ │ │ ├── right_hovered.png │ │ │ ├── view.png │ │ │ ├── windmill.png │ │ │ └── wizard.png │ │ ├── Effect │ │ │ ├── Dissolve_1.jpg │ │ │ ├── Dissolve_2.png │ │ │ ├── Girls │ │ │ │ ├── girl1.jpeg │ │ │ │ ├── girl10.jpeg │ │ │ │ ├── girl11.jpeg │ │ │ │ ├── girl12.jpeg │ │ │ │ ├── girl14.jpeg │ │ │ │ ├── girl15.jpeg │ │ │ │ ├── girl2.jpeg │ │ │ │ ├── girl3.jpeg │ │ │ │ ├── girl4.jpeg │ │ │ │ ├── girl5.jpeg │ │ │ │ ├── girl6.jpeg │ │ │ │ ├── girl7.jpeg │ │ │ │ ├── girl8.jpeg │ │ │ │ └── girl9.jpeg │ │ │ ├── arrow.png │ │ │ ├── astronomy.jpg │ │ │ ├── baby.jpg │ │ │ ├── girl.jpg │ │ │ └── soundRect.png │ │ ├── Tao │ │ │ ├── weixin.jpg │ │ │ └── zhifubao.jpg │ │ ├── Window │ │ │ ├── about_gray.png │ │ │ ├── about_white.png │ │ │ ├── close_gray.png │ │ │ ├── close_white.png │ │ │ ├── flower.jpg │ │ │ ├── lang_gray.png │ │ │ ├── lang_white.png │ │ │ ├── max_gray.png │ │ │ ├── max_white.png │ │ │ ├── minimal_gray.png │ │ │ ├── minimal_white.png │ │ │ ├── normal_gray.png │ │ │ ├── normal_white.png │ │ │ ├── settings_gray.png │ │ │ ├── settings_white.png │ │ │ ├── skin_gray.png │ │ │ └── skin_white.png │ │ └── logo │ │ │ ├── milk.ico │ │ │ ├── milk.png │ │ │ ├── milk_32.png │ │ │ └── milk_48.png │ ├── Qml.qrc │ ├── Qml │ │ ├── Biz │ │ │ ├── CircleText.qml │ │ │ ├── CloseBtn.qml │ │ │ ├── ExpandBtn.qml │ │ │ ├── LangBtn.qml │ │ │ └── SkinBtn.qml │ │ ├── Dialog │ │ │ ├── AboutDialog.qml │ │ │ └── SettingsDialog.qml │ │ ├── Page │ │ │ ├── ControlsShow.qml │ │ │ └── Home.qml │ │ ├── Pane │ │ │ ├── ContentModel.qml │ │ │ ├── LeftPane.qml │ │ │ ├── RightPane.qml │ │ │ └── TitlePane.qml │ │ └── main.qml │ ├── Src │ │ ├── AppInfo.cpp │ │ ├── AppInfo.h │ │ ├── DeviceAddTable │ │ │ ├── DeviceAddItem.cpp │ │ │ ├── DeviceAddItem.h │ │ │ ├── DeviceAddModel.cpp │ │ │ └── DeviceAddModel.h │ │ ├── main.cpp │ │ └── stdafx.h │ ├── TaoQuickShow.pri │ ├── TaoQuickShow.pro │ ├── TaoQuickShow.svg │ ├── TaoQuickShow.vcxproj │ ├── TaoQuickShow.vcxproj.filters │ ├── Trans │ │ ├── keys.json │ │ └── language_zh.json │ ├── Ver-u16.h │ ├── Ver-u8.h │ ├── milk.icns │ ├── milk.ico │ └── trnas.ps1 └── examples.pro ├── mkspecs └── features │ ├── taoBuildPath.prf │ ├── taoBundle.prf │ └── taoVersion.prf ├── preview ├── Arrow.png ├── AtomJoggle.gif ├── Buttons-en.png ├── Buttons.png ├── ClickShow.gif ├── Data-en.png ├── Data.png ├── EdgeTab.gif ├── I18n-en.png ├── I18n.png ├── ListViewWithTab.gif ├── SuperMario.png ├── Table-en.png ├── Table.png ├── byte.png ├── designer.png ├── main-en.png ├── main.png ├── rect-en.png ├── rect.png ├── skin-en.png ├── skin.png ├── snail.png ├── wizard-en.png ├── wizard.gif └── wizard.png ├── scripts ├── manulaDeployment.bat └── windows-publish.ps1 ├── src ├── TaoQuick.pri ├── TaoQuick │ ├── Images │ │ ├── Check.png │ │ ├── ComboBox_Down.png │ │ ├── Expanded.png │ │ ├── Icon_Camera_Offline.png │ │ ├── Icon_Camera_Online.png │ │ ├── Search.png │ │ ├── Search_Clear.png │ │ ├── Table_Asc.png │ │ ├── Table_Asc_Hovered.png │ │ ├── Table_Desc.png │ │ ├── Table_Desc_Hovered.png │ │ ├── arrow-down.png │ │ ├── arrow-left.png │ │ ├── arrow-right.png │ │ ├── arrow-up.png │ │ ├── ellipsis.png │ │ ├── last.png │ │ ├── left.png │ │ ├── next.png │ │ ├── particle.png │ │ ├── radio-checked-disabled.png │ │ ├── radio-checked-hover.png │ │ ├── radio-checked-normal.png │ │ ├── radio-unchecked-disabled.png │ │ ├── radio-unchecked-hover.png │ │ ├── radio-unchecked-normal.png │ │ ├── right.png │ │ ├── rotate.png │ │ └── spinner.png │ ├── Qml │ │ ├── Basic │ │ │ ├── BasicText.qml │ │ │ ├── BasicTooltip.qml │ │ │ ├── CusCallLater.qml │ │ │ ├── MoveArea.qml │ │ │ ├── RoundRectangle.qml │ │ │ ├── RoundRectangleShape.qml │ │ │ └── TransArea.qml │ │ ├── CusBackground │ │ │ └── CusBackground.qml │ │ ├── CusButton │ │ │ ├── CusButton.qml │ │ │ ├── CusButton_Blue.qml │ │ │ ├── CusButton_Gradient.qml │ │ │ ├── CusButton_Image.qml │ │ │ ├── CusButton_ImageBackground.qml │ │ │ ├── CusButton_ImageColorOverlay.qml │ │ │ ├── CusButton_Red.qml │ │ │ ├── CusButton_White.qml │ │ │ ├── CusRadioButton.qml │ │ │ ├── CusRoundTabButton.qml │ │ │ └── CusTextButton.qml │ │ ├── CusCheckBox │ │ │ ├── CusCheckBox.qml │ │ │ └── CusSwitch.qml │ │ ├── CusComboBox │ │ │ └── CusComboBox.qml │ │ ├── CusConfig.qml │ │ ├── CusImage │ │ │ ├── CusImage.qml │ │ │ ├── CusImageOverlay.qml │ │ │ └── CusImage_Tip.qml │ │ ├── CusInput │ │ │ ├── CusIPAddress.qml │ │ │ ├── CusTextField.qml │ │ │ ├── CusTextField_Btn.qml │ │ │ ├── CusTextField_Search.qml │ │ │ ├── CusTextField_Valid.qml │ │ │ └── CusTextInput.qml │ │ ├── CusLabel │ │ │ ├── CusLabel.qml │ │ │ ├── CusLabel_Center.qml │ │ │ └── CusLabel_Left.qml │ │ ├── CusListView │ │ │ └── CusListView.qml │ │ ├── CusPopup │ │ │ ├── CusPopup.qml │ │ │ ├── CusToolTip_Triangle.qml │ │ │ └── CusTriangleTipBorder.qml │ │ ├── CusScroll │ │ │ └── CusScrollBar.qml │ │ ├── CusSlider │ │ │ ├── CusSlider.qml │ │ │ └── CusSlider_Spin.qml │ │ ├── CusSpinBox │ │ │ ├── CusSpinBox.qml │ │ │ └── CusSpinBox_HourMinute.qml │ │ ├── CusTable │ │ │ ├── CusTableConstant.qml │ │ │ ├── CusTableHeader.qml │ │ │ ├── CusTableRow.qml │ │ │ └── CusTableView.qml │ │ ├── CusWizard │ │ │ ├── CusWizard.qml │ │ │ └── CusWizardPage.qml │ │ ├── Effect │ │ │ ├── Animation │ │ │ │ ├── ABoard.qml │ │ │ │ ├── ACircle.qml │ │ │ │ ├── ACleavage.qml │ │ │ │ ├── ACross.qml │ │ │ │ ├── ADiagonal.qml │ │ │ │ ├── ADissolve.qml │ │ │ │ ├── AGrad.qml │ │ │ │ ├── ALouver.qml │ │ │ │ ├── ARhombus.qml │ │ │ │ ├── ARiseSet.qml │ │ │ │ ├── ASector.qml │ │ │ │ ├── ASlowEnter.qml │ │ │ │ ├── ASquare.qml │ │ │ │ └── AWheel.qml │ │ │ ├── AtomJoggle.qml │ │ │ ├── ClickShow.qml │ │ │ ├── CusEffectCommon.qml │ │ │ ├── CusShaderToy.qml │ │ │ └── PageSwitch │ │ │ │ ├── SBoard.qml │ │ │ │ ├── SCircle.qml │ │ │ │ ├── SCleavage.qml │ │ │ │ ├── SCross.qml │ │ │ │ ├── SDiagonal.qml │ │ │ │ ├── SDissolve.qml │ │ │ │ ├── SFadeInOut.qml │ │ │ │ ├── SGrad.qml │ │ │ │ ├── SLouver.qml │ │ │ │ ├── SRhombus.qml │ │ │ │ ├── SSector.qml │ │ │ │ ├── SSquare.qml │ │ │ │ └── SWheel.qml │ │ └── Misc │ │ │ ├── CusBusyIndicator.qml │ │ │ ├── CusDialog.qml │ │ │ ├── CusDragItem.qml │ │ │ ├── CusFPS.qml │ │ │ ├── CusPageIndicator.qml │ │ │ ├── CusRectDraw.qml │ │ │ ├── CusResizeBorder.qml │ │ │ ├── CusShortCutKeys.qml │ │ │ └── CusTemplateDragBorder.qml │ ├── TaoQuick.qrc │ ├── UpdateDesignerMetainfo.ps1 │ ├── UpdateQmldirAndQrc.ps1 │ ├── designer │ │ ├── TaoQuick.metainfo │ │ └── images │ │ │ ├── BasicText.png │ │ │ ├── BasicTooltip.png │ │ │ ├── CusBackground.png │ │ │ ├── CusBusyIndicator.png │ │ │ ├── CusButton.png │ │ │ ├── CusButton_Blue.png │ │ │ ├── CusButton_Gradient.png │ │ │ ├── CusButton_Image.png │ │ │ ├── CusButton_ImageColorOverlay.png │ │ │ ├── CusButton_Red.png │ │ │ ├── CusButton_White.png │ │ │ ├── CusCheckBox.png │ │ │ ├── CusComboBox.png │ │ │ ├── CusDialog.png │ │ │ ├── CusDragItem.png │ │ │ ├── CusFPS.png │ │ │ ├── CusImage.png │ │ │ ├── CusImage_Tip.png │ │ │ ├── CusLabel.png │ │ │ ├── CusListView.png │ │ │ ├── CusPopup.png │ │ │ ├── CusRectDraw.png │ │ │ ├── CusResizeBorder.png │ │ │ ├── CusScrollBar.png │ │ │ ├── CusShortCutKeys.png │ │ │ ├── CusSlider.png │ │ │ ├── CusSlider_Spin.png │ │ │ ├── CusSpinBox.png │ │ │ ├── CusSpinBox_HourMinute.png │ │ │ ├── CusSwitch.png │ │ │ ├── CusTableHeader.png │ │ │ ├── CusTableRow.png │ │ │ ├── CusTableView.png │ │ │ ├── CusTemplateDragBorder.png │ │ │ ├── CusTextButton.png │ │ │ ├── CusTextField.png │ │ │ ├── CusTextField_Btn.png │ │ │ ├── CusTextField_Search.png │ │ │ ├── CusTextField_Valid.png │ │ │ ├── CusTextInput.png │ │ │ ├── CusToolTip_Triangle.png │ │ │ ├── CusTriangleTipBorder.png │ │ │ ├── MoveArea.png │ │ │ └── TransArea.png │ └── qmldir ├── taoQuick.cmake └── taoQuick.props ├── taoVersionInfo.h └── 入门指南.md /.github/workflows/ios-macos-11_0.yml-: -------------------------------------------------------------------------------- 1 | name: ios-macos-11_0 2 | on: 3 | # push代码时触发workflow 4 | push: 5 | paths: 6 | - '3rdparty/**' 7 | - 'examples/**' 8 | - 'mkspecs/**' 9 | - 'src/**' 10 | - '.qmake.conf' 11 | - 'TaoQuick.pro' 12 | - '.github/workflows/ios-macos-11_0.yml' 13 | # pull_request时触发workflow 14 | pull_request: 15 | paths: 16 | - '3rdparty/**' 17 | - 'examples/**' 18 | - 'mkspecs/**' 19 | - 'src/**' 20 | - '.qmake.conf' 21 | - 'TaoQuick.pro' 22 | - '.github/workflows/ios-macos-11_0.yml' 23 | jobs: 24 | build: 25 | name: Build 26 | runs-on: ${{ matrix.os }} 27 | strategy: 28 | matrix: 29 | os: [macos-11.0] 30 | qt_ver: [5.15.2] 31 | qt_target: [ios] 32 | steps: 33 | - name: prepare env 34 | run: | 35 | softwareupdate --all --install --force 36 | 37 | - name: Install Qt 38 | # if: steps.cacheqt.outputs.cache-hit != 'true' 39 | uses: jurplel/install-qt-action@v2.10.0 40 | with: 41 | # Version of Qt to install 42 | version: ${{ matrix.qt_ver }} 43 | # Target platform for build 44 | target: ${{ matrix.qt_target }} 45 | 46 | - uses: actions/checkout@v2 47 | with: 48 | fetch-depth: 1 49 | submodules: 'true' 50 | - name: build ios 51 | run: | 52 | sudo xcode-select --print-path 53 | sudo xcode-select --switch /Applications/Xcode_13.1.app 54 | qmake -r -spec macx-ios-clang CONFIG+=release CONFIG+=iphoneos 55 | make 56 | -------------------------------------------------------------------------------- /.github/workflows/ios.yml: -------------------------------------------------------------------------------- 1 | name: IOS 2 | on: 3 | # push代码时触发workflow 4 | push: 5 | paths: 6 | - '3rdparty/**' 7 | - 'examples/**' 8 | - 'mkspecs/**' 9 | - 'src/**' 10 | - '.qmake.conf' 11 | - 'TaoQuick.pro' 12 | - '.github/workflows/ios.yml' 13 | # pull_request时触发workflow 14 | pull_request: 15 | paths: 16 | - '3rdparty/**' 17 | - 'examples/**' 18 | - 'mkspecs/**' 19 | - 'src/**' 20 | - '.qmake.conf' 21 | - 'TaoQuick.pro' 22 | - '.github/workflows/ios.yml' 23 | jobs: 24 | build: 25 | name: Build 26 | runs-on: ${{ matrix.os }} 27 | strategy: 28 | matrix: 29 | os: [macos-10.15] 30 | qt_ver: [5.12.10,5.15.2] 31 | qt_target: [ios] 32 | steps: 33 | - name: Install Qt 34 | # if: steps.cacheqt.outputs.cache-hit != 'true' 35 | uses: jurplel/install-qt-action@v2 36 | with: 37 | # Version of Qt to install 38 | version: ${{ matrix.qt_ver }} 39 | # Target platform for build 40 | target: ${{ matrix.qt_target }} 41 | 42 | - uses: actions/checkout@v2 43 | with: 44 | fetch-depth: 1 45 | submodules: 'true' 46 | - name: build ios 47 | run: | 48 | qmake -r -spec macx-ios-clang CONFIG+=release CONFIG+=iphoneos 49 | make 50 | -------------------------------------------------------------------------------- /.qmake.conf: -------------------------------------------------------------------------------- 1 | TaoQuick_SOURCE_TREE = $$PWD 2 | 3 | TaoQuick_BUILD_TREE = $$PWD/build 4 | 5 | TaoQuick_RUN_TREE = $$PWD/bin 6 | 7 | TaoQuick_3RDPARTY_TREE = $$PWD/3rdparty 8 | 9 | TaoQuick_VERSION_MAJOR = 0.3 10 | -------------------------------------------------------------------------------- /.tag: -------------------------------------------------------------------------------- 1 | d1e8f51756bacd23eaaf96dcb54465cd61deaf92 2 | -------------------------------------------------------------------------------- /3rdparty/3rdparty.pri: -------------------------------------------------------------------------------- 1 | include($$PWD/TaoCommon/src/TaoCommon.pri) 2 | 3 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/.qmake.conf: -------------------------------------------------------------------------------- 1 | #Workaround for Issue #60 2 | CONFIG += git_build 3 | 4 | load(qt_build_config) 5 | 6 | MODULE_VERSION = 0.1.0 7 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/.tag: -------------------------------------------------------------------------------- 1 | d1e8f51756bacd23eaaf96dcb54465cd61deaf92 2 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018 JaredTao jared2020@163.com 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/TaoCommon.pro: -------------------------------------------------------------------------------- 1 | load(qt_parts) 2 | CONFIG += ordered 3 | #SUBDIRS += demo 4 | OTHER_FILES += \ 5 | .* \ 6 | _clang-format \ 7 | LICENSE \ 8 | *.md \ 9 | *.profile \ 10 | .github/workflows/* 11 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/demo/CommonWithModule/CommonWithModule.pro: -------------------------------------------------------------------------------- 1 | QT += quick 2 | 3 | # example use TaoCommon as Qt module. 4 | 5 | QT += TaoCommon 6 | CONFIG += c++11 7 | 8 | SOURCES += \ 9 | main.cpp 10 | 11 | RESOURCES += qml.qrc 12 | 13 | target.path = $$[QT_INSTALL_EXAMPLES]/TaoCommon/CommonWithModule 14 | INSTALLS += target 15 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/demo/CommonWithModule/main.cpp: -------------------------------------------------------------------------------- 1 | #include "Logger/Logger.h" 2 | #include 3 | #include 4 | int main(int argc, char* argv[]) 5 | { 6 | QGuiApplication app(argc, argv); 7 | Logger::initLog(); 8 | QQmlApplicationEngine engine; 9 | const QUrl url(QStringLiteral("qrc:/main.qml")); 10 | QObject::connect( 11 | &engine, &QQmlApplicationEngine::objectCreated, &app, 12 | [url](QObject* obj, const QUrl& objUrl) { 13 | if (!obj && url == objUrl) 14 | QCoreApplication::exit(-1); 15 | }, 16 | Qt::QueuedConnection); 17 | engine.load(url); 18 | 19 | return app.exec(); 20 | } 21 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/demo/CommonWithModule/main.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.12 2 | import QtQuick.Window 2.12 3 | 4 | Window { 5 | visible: true 6 | width: 640 7 | height: 480 8 | title: qsTr("Hello World") 9 | Component.onCompleted: { 10 | console.log("Hello") 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/demo/CommonWithModule/qml.qrc: -------------------------------------------------------------------------------- 1 | 2 | 3 | main.qml 4 | 5 | 6 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/demo/CommonWithSource/CommonWithSource.pro: -------------------------------------------------------------------------------- 1 | QT += quick 2 | 3 | CONFIG += c++11 4 | 5 | SOURCES += \ 6 | main.cpp 7 | 8 | RESOURCES += qml.qrc 9 | 10 | # example use TaoCommon from source code. 11 | 12 | include($$PWD/../../src/TaoCommon/TaoCommon.pri) 13 | target.path = $$[QT_INSTALL_EXAMPLES]/TaoCommon/CommonWithSource 14 | INSTALLS += target 15 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/demo/CommonWithSource/main.cpp: -------------------------------------------------------------------------------- 1 | #include "Logger/Logger.h" 2 | #include 3 | #include 4 | int main(int argc, char* argv[]) 5 | { 6 | 7 | QGuiApplication app(argc, argv); 8 | Logger::initLog(); 9 | QQmlApplicationEngine engine; 10 | const QUrl url(QStringLiteral("qrc:/main.qml")); 11 | QObject::connect( 12 | &engine, &QQmlApplicationEngine::objectCreated, &app, 13 | [url](QObject* obj, const QUrl& objUrl) { 14 | if (!obj && url == objUrl) 15 | QCoreApplication::exit(-1); 16 | }, 17 | Qt::QueuedConnection); 18 | engine.load(url); 19 | 20 | return app.exec(); 21 | } 22 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/demo/CommonWithSource/main.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.12 2 | import QtQuick.Window 2.12 3 | 4 | Window { 5 | visible: true 6 | width: 640 7 | height: 480 8 | title: qsTr("Hello World") 9 | Component.onCompleted: { 10 | console.log("Hello") 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/demo/CommonWithSource/qml.qrc: -------------------------------------------------------------------------------- 1 | 2 | 3 | main.qml 4 | 5 | 6 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/demo/ExampleLog/ExampleLog.pro: -------------------------------------------------------------------------------- 1 | TEMPLATE = app 2 | 3 | QT += TaoCommon 4 | 5 | SOURCES += main.cpp 6 | 7 | target.path = $$[QT_INSTALL_EXAMPLES]/TaoCommon/ExampleLog 8 | INSTALLS += target 9 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/demo/demo.pro: -------------------------------------------------------------------------------- 1 | TEMPLATE = subdirs 2 | 3 | SUBDIRS += \ 4 | CommonWithSource 5 | 6 | qtHaveModule(TaoCommon): SUBDIRS += \ 7 | ExampleLog \ 8 | CommonWithModule 9 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/doc/QtCreaterInstall.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/3rdparty/TaoCommon/doc/QtCreaterInstall.png -------------------------------------------------------------------------------- /3rdparty/TaoCommon/mkspecs/features/taoBuildPath.prf: -------------------------------------------------------------------------------- 1 | defineTest(setBuildPath) { 2 | buildPath = $$1 3 | CONFIG(debug,debug|release){ 4 | MOC_DIR = $${buildPath}/debug/moc 5 | RCC_DIR = $${buildPath}/debug/rcc 6 | UI_DIR = $${buildPath}/debug/ui 7 | OBJECTS_DIR = $${buildPath}/debug/obj 8 | QMLCACHE_DIR = $${buildPath}/debug/qmlcache 9 | } else { 10 | MOC_DIR = $${buildPath}/release/moc 11 | RCC_DIR = $${buildPath}/release/rcc 12 | UI_DIR = $${buildPath}/release/ui 13 | OBJECTS_DIR = $${buildPath}/release/obj 14 | QMLCACHE_DIR = $${buildPath}/release/qmlcache 15 | } 16 | export(MOC_DIR) 17 | export(RCC_DIR) 18 | export(UI_DIR) 19 | export(OBJECTS_DIR) 20 | export(QMLCACHE_DIR) 21 | } 22 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/mkspecs/features/taoBundle.prf: -------------------------------------------------------------------------------- 1 | defineReplace(getBundlePath) { 2 | appName = $$1 3 | BundlePath = 4 | macos{ 5 | CONFIG(debug, debug|release){ 6 | CONFIG -=app_bundle 7 | } else { 8 | BundlePath=$${appName}.app/Contents/MacOS/ 9 | } 10 | } 11 | export(CONFIG) 12 | return ($$BundlePath) 13 | } 14 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/mkspecs/features/taoVersion.prf: -------------------------------------------------------------------------------- 1 | defineTest(setTaoVersion) { 2 | TAO_VERSION_TAG = 1.0 3 | 4 | # current commit hash 5 | REVISION=$$system("git rev-parse HEAD") 6 | REVISION=$$str_member($${REVISION}, 0, $$num_add(10, -1)) 7 | isEmpty(REVISION) { 8 | REVISION = 0000000000 9 | } 10 | 11 | # last tag 12 | Ver=$$system("git describe --abbrev=0 --tags") 13 | isEmpty(Ver) { 14 | Ver=0.0.0 15 | } 16 | VerList =$$split(Ver, .) 17 | MAJ = $$take_first(VerList) 18 | MIN = $$take_first(VerList) 19 | PAT = $$take_first(VerList) 20 | equals(TEMPLATE, lib) { 21 | CONFIG += skip_target_version_ext 22 | VER_MAJ = $${MAJ} 23 | VER_MIN = $${MIN} 24 | VER_PAT = $${PAT} 25 | VERSION = $${Ver} 26 | } 27 | 28 | DEFINES += TaoREVISION=$${REVISION} 29 | DEFINES += TaoREVISIONSTR=\"\\\"$${REVISION}\\\"\" 30 | DEFINES += TaoVer=\"\\\"$${Ver}\\\"\" 31 | DEFINES += TaoMAJ=$${MAJ} 32 | DEFINES += TaoMIN=$${MIN} 33 | DEFINES += TaoPAT=$${PAT} 34 | DEFINES += TaoDATETIME=\"\\\"$${_DATE_}\\\"\" 35 | DEFINES += TaoCompilerVendor=\"\\\"$${QT_VERSION} $${QMAKE_PLATFORM} $${QMAKE_COMPILER} $${QMAKE_TARGET.arch}\\\"\" 36 | 37 | export(CONFIG) 38 | export(VER_MAJ) 39 | export(VER_MIN) 40 | export(VER_PAT) 41 | export(VERSION) 42 | export(DEFINES) 43 | } 44 | 45 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/mkspecs/features/vcpkg.prf: -------------------------------------------------------------------------------- 1 | defineTest(useVcpkgLib) { 2 | 3 | names=$$eval(1) 4 | isEmpty(names) { 5 | message( names is empty) 6 | return(true) 7 | } 8 | win32 { 9 | vcpkgRoot=$$clean_path($$(VCPKG_ROOT)) 10 | vcpkgTriplet=$$(VCPKG_DEFAULT_TRIPLET) 11 | vcpkgInstall= 12 | vcpkgBin= 13 | exists($$vcpkgRoot) { 14 | isEmpty($$vcpkgTriplet) { 15 | equals(QT_ARCH, x86) { 16 | vcpkgTriplet = x86-windows 17 | } else: equals(QT_ARCH, x86_64) { 18 | vcpkgTriplet = x64-windows 19 | } 20 | } 21 | vcpkgInstall=$$vcpkgRoot/installed/$$vcpkgTriplet 22 | } 23 | exists($$vcpkgInstall) { 24 | message(vcpkgInstall $$vcpkgInstall) 25 | INCLUDEPATH += $$vcpkgInstall/include 26 | CONFIG(debug,debug|release){ 27 | LIBS += -L$$vcpkgInstall/debug/lib 28 | LIBS += -L$$vcpkgInstall/debug/bin 29 | } else { 30 | LIBS += -L$$vcpkgInstall/lib 31 | LIBS += -L$$vcpkgInstall/bin 32 | } 33 | } 34 | # todo copy dll to destdir 35 | for(libName, names) { 36 | tname = $$qt5LibraryTarget($$libName) 37 | LIBS += -l$$tname 38 | } 39 | export(INCLUDEPATH) 40 | export(LIBS) 41 | } 42 | return(true) 43 | } 44 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | set(TaoCommonPath ${CMAKE_CURRENT_SOURCE_DIR} PARENT_SCOPE) 2 | file(GLOB_RECURSE files *.h *.hpp *.cpp *.c) 3 | if(WIN32) 4 | list(FILTER files EXCLUDE REGEX ".*_unix.cpp$") 5 | else() 6 | list(FILTER files EXCLUDE REGEX ".*_win.cpp$") 7 | endif() 8 | set(TaoCommonFiles ${files} PARENT_SCOPE) 9 | message("TaoCommonFiles ${files}") 10 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/Common/MathHelp.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | #include 5 | // inRange 检查 value 小于等于 max, 大于等于min 6 | 7 | // inRange通用模版函数 8 | template 9 | static bool inRange(const T& value, const T& min, const T& max) 10 | { 11 | if (min <= value && value <= max) 12 | { 13 | return true; 14 | } 15 | return false; 16 | } 17 | // inRange 模版偏特化,遇到double时,使用std的 "浮点数比较" 代替 "常规比较", 规避精度误差 18 | template <> 19 | static bool inRange(const double& value, const double& min, const double& max) 20 | { 21 | if (std::isgreaterequal(value, min) && std::islessequal(value, max)) 22 | { 23 | return true; 24 | } 25 | return false; 26 | } 27 | // inRange 模版偏特化,遇到float时,使用std的"浮点数比较" 代替 "常规比较", 规避精度误差 28 | template <> 29 | static bool inRange(const float& value, const float& min, const float& max) 30 | { 31 | if (std::isgreaterequal(value, min) && std::islessequal(value, max)) 32 | { 33 | return true; 34 | } 35 | return false; 36 | } 37 | // clamp, 限制 value在 [min - Max]区间. 38 | template 39 | static T clamp(const T& value, const T& min, const T& max) 40 | { 41 | return std::max(min, std::min(value, max)); 42 | } 43 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/Common/Package.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | #include 5 | #include 6 | // 简易的封包、拆包。主要用在socket中传输连续的数据时,处理粘在一起的问题。 7 | // 这段代码是经过很多实际项目验证的,可放心使用。 8 | // 适用的场景很简单,就是前面4个字节是头部,表示数据的长度,紧跟着就是那么长的数据。头和数据,加起来就是一个包。 9 | 10 | // 假定头部占一个uint32的长度 11 | const int static headerLength = sizeof(quint32); 12 | 13 | // 封包。 入参为数据,返回值是 数据前面加一个头. 这就是一个数据包了 14 | static QByteArray pack(const QByteArray& data) 15 | { 16 | QByteArray header(headerLength, 0); 17 | QDataStream os(&header, QIODevice::WriteOnly); 18 | os << static_cast(data.length()); 19 | return header + data; 20 | } 21 | // 拆包。入参为连续的数据,返回值是拆出来的所有包列表 22 | static QByteArrayList unpack(const QByteArray& data) 23 | { 24 | QByteArrayList list; 25 | QDataStream inStream(data); 26 | quint32 sum = data.size(); 27 | quint32 pos = 0; 28 | while (pos + headerLength < sum) 29 | { 30 | quint32 packageLen = 0; 31 | packageLen = 0; 32 | inStream >> packageLen; 33 | if (packageLen + headerLength > sum - pos) 34 | { 35 | break; 36 | } 37 | QByteArray subPackage = data.mid(pos + headerLength, packageLen); 38 | inStream.skipRawData(packageLen); 39 | list.append(subPackage); 40 | pos += headerLength + packageLen; 41 | } 42 | return list; 43 | } 44 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/Frameless/TaoFrameLessView.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "Common/PropertyHelper.h" 3 | #include "TaoCommonGlobal.h" 4 | #include 5 | #include 6 | #include 7 | 8 | // 简易的无边框窗口,主要用来实现自定义标题栏。 9 | // 支持标题栏拖动和边缘改变大小,不做深度处理 10 | struct TaoFrameLessViewPrivate; 11 | class TAO_API TaoFrameLessView : public QQuickView 12 | { 13 | Q_OBJECT 14 | using Super = QQuickView; 15 | AUTO_PROPERTY(int, borderWidth, 4) 16 | public: 17 | explicit TaoFrameLessView(QWindow* parent = nullptr); 18 | ~TaoFrameLessView(); 19 | 20 | static QRect calcCenterGeo(const QRect& screenGeo, const QSize& normalSize); 21 | public slots: 22 | void moveToScreenCenter(); 23 | void move(int x, int y); 24 | 25 | QPoint mousePosition() const; 26 | 27 | QPoint globalPosToWindowPos(const QPoint& pos) const; 28 | signals: 29 | void mousePressed(int xPos, int yPos, int button); 30 | 31 | protected: 32 | void mousePressEvent(QMouseEvent* event) override; 33 | void mouseReleaseEvent(QMouseEvent* event) override; 34 | void mouseMoveEvent(QMouseEvent* event) override; 35 | 36 | Qt::Edges getPosEdges(const QPoint& pos) const; 37 | Qt::CursorShape getCursorShapeByEdge(const Qt::Edges& edges); 38 | 39 | void doMoveTo(const QPoint& nowPos); 40 | 41 | private: 42 | std::unique_ptr d; 43 | }; 44 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/Logger/Logger.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "TaoCommonGlobal.h" 3 | #include 4 | #include 5 | namespace Logger 6 | { 7 | #ifdef _DEBUG 8 | #define LOG_DEBUG qDebug() << __FILE__ << __LINE__ 9 | #define LOG_INFO qInfo() << __FILE__ << __LINE__ 10 | #define LOG_WARN qWarning() << __FILE__ << __LINE__ 11 | #define LOG_CRIT qCritical() << __FILE__ << __LINE__ 12 | #else 13 | #define LOG_DEBUG qDebug() 14 | #define LOG_INFO qInfo() 15 | #define LOG_WARN qWarning() 16 | #define LOG_CRIT qCritical() 17 | #endif 18 | // 初始化Log存储。包括创建Log文件夹、删除超过最大数的log(仅初始化时删除,运行过程中不删除)。 19 | // logPath 存储路径 20 | // logMaxCount 最大数 21 | // async 是否异步存储 默认异步存储。异步存储会缓存log,达到一定数量、或者软件退出时才写入文件。 22 | void TAO_API initLog(const QString& logPath = QStringLiteral("Log"), int logMaxCount = 1024, bool async = true); 23 | } // namespace Logger 24 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/QuickModel/QuickListItemBase.cpp: -------------------------------------------------------------------------------- 1 | #include "QuickModel/QuickListItemBase.h" 2 | 3 | QuickListItemBase::QuickListItemBase(QObject* parent) 4 | : QObject(parent) 5 | { 6 | } 7 | 8 | QuickListItemBase::~QuickListItemBase() { } 9 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/QuickModel/QuickListItemBase.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include "Common/PropertyHelper.h" 4 | #include "TaoCommonGlobal.h" 5 | #include 6 | class TAO_API QuickListItemBase : public QObject 7 | { 8 | Q_OBJECT 9 | 10 | AUTO_PROPERTY(bool, isChecked, false) 11 | AUTO_PROPERTY(bool, isSelected, false) 12 | AUTO_PROPERTY(bool, isAlternate, false) 13 | 14 | public: 15 | explicit QuickListItemBase(QObject* parent = nullptr); 16 | virtual ~QuickListItemBase() override; 17 | QuickListItemBase(const QuickListItemBase& other) 18 | { 19 | set_isChecked(other.isChecked()); 20 | set_isSelected(other.isSelected()); 21 | set_isAlternate(other.isAlternate()); 22 | } 23 | 24 | QuickListItemBase& operator=(const QuickListItemBase& other) 25 | { 26 | set_isChecked(other.isChecked()); 27 | set_isSelected(other.isSelected()); 28 | set_isAlternate(other.isAlternate()); 29 | return *this; 30 | } 31 | // Model call this for search. return true if contents match key, others return false. 32 | virtual bool match(const QString& key) 33 | { 34 | Q_UNUSED(key) 35 | return true; 36 | } 37 | 38 | }; 39 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/QuickTool/QuickTool.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | #include 5 | #include 6 | #include 7 | #include 8 | #include 9 | class QuickTool : public QObject 10 | { 11 | Q_OBJECT 12 | using Super = QObject; 13 | 14 | public: 15 | explicit QuickTool(QObject* parent = nullptr); 16 | explicit QuickTool(QObject* rootObject, QObject* parent = nullptr); 17 | virtual ~QuickTool() override; 18 | Q_INVOKABLE void setRootObjet(QObject* rootObj) 19 | { 20 | pRootObject = rootObj; 21 | } 22 | QObject* rootObject() const 23 | { 24 | return pRootObject; 25 | } 26 | void findRootByNode(QObject* nodeObject); 27 | 28 | public: 29 | Q_INVOKABLE QObject* getObject(const QString& targetObjName) const; 30 | 31 | Q_INVOKABLE QVariant getObjectProperty(QObject* targetObj, const QString& propertyName) const; 32 | Q_INVOKABLE void setObjectProperty(QObject* targetObj, const QString& propertyName, const QVariant& value) const; 33 | 34 | Q_INVOKABLE QVariant getObjectProperty(const QString& targetObjName, const QString& propertyName) const; 35 | Q_INVOKABLE void setObjectProperty(const QString& targetObjName, const QString& propertyName, const QVariant& value) const; 36 | 37 | Q_INVOKABLE QRect getItemGeometryToScene(const QString& targetObjName) const; 38 | 39 | Q_INVOKABLE void setAppOverrideCursor(QCursor cursor); 40 | Q_INVOKABLE void restoreAppOverrideCursor(); 41 | 42 | Q_INVOKABLE QPoint cursorGlobalPos() const; 43 | 44 | private: 45 | QObject* pRootObject = nullptr; 46 | }; 47 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/TaoCommon.pri: -------------------------------------------------------------------------------- 1 | !build_TaoCommon_lib:{ 2 | DEFINES +=TaoCommon_NO_LIB 3 | } 4 | 5 | INCLUDEPATH += $$PWD 6 | 7 | HEADERS += \ 8 | $$PWD/Common/FileReadWrite.h \ 9 | $$PWD/Common/JsonSerialize.h \ 10 | $$PWD/Common/ObjectMap.h \ 11 | $$PWD/Common/Package.h \ 12 | $$PWD/Common/PropertyHelper.h \ 13 | $$PWD/Common/Subject.h \ 14 | $$PWD/Common/MathHelp.h \ 15 | $$PWD/Frameless/TaoFrameLessView.h \ 16 | $$PWD/Logger/Logger.h \ 17 | $$PWD/Logger/LoggerTemplate.h \ 18 | $$PWD/QuickTool/QuickTool.h \ 19 | $$PWD/QuickTree/Model/QuickTreeItem.h \ 20 | $$PWD/QuickTree/Model/QuickTreeModel.h \ 21 | $$PWD/TaoCommonGlobal.h \ 22 | $$PWD/QuickModel/QuickListItemBase.h \ 23 | $$PWD/QuickModel/QuickListModel.h \ 24 | $$PWD/QuickModel/QuickModelBase.hpp \ 25 | $$PWD/Thread/ThreadCommon.h \ 26 | $$PWD/Thread/ThreadPool.h \ 27 | $$PWD/Thread/ThreadWorkerController.h \ 28 | $$PWD/Trans/Trans.h 29 | 30 | SOURCES += \ 31 | $$PWD/Logger/Logger.cpp \ 32 | $$PWD/QuickTool/QuickTool.cpp \ 33 | $$PWD/QuickModel/QuickListItemBase.cpp \ 34 | $$PWD/QuickModel/QuickListModel.cpp \ 35 | $$PWD/QuickTree/Model/QuickTreeModel.cpp \ 36 | $$PWD/Thread/ThreadPool.cpp \ 37 | $$PWD/Trans/Trans.cpp \ 38 | $$PWD/Frameless/TaoFrameLessView.cpp 39 | 40 | 41 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/TaoCommon.pro: -------------------------------------------------------------------------------- 1 | TARGET = TaoCommon 2 | 3 | load(qt_module) 4 | 5 | QT += core gui quick 6 | QMAKE_TARGET_COMPANY = "jaredtao.github.io" 7 | QMAKE_TARGET_COPYRIGHT = "Copyright (C) 2019-2022 JaredTao " 8 | QMAKE_TARGET_PRODUCT = "TaoCommon" 9 | QMAKE_TARGET_DESCRIPTION = "common use code for Qt." 10 | 11 | CONFIG += build_TaoCommon_lib 12 | DEFINES += TaoCommon_Library 13 | 14 | include(TaoCommon.pri) 15 | 16 | include(TaoCommonInstall.pri) 17 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/TaoCommonGlobal.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | 4 | #if !defined(BUILD_STATIC) && !defined(TaoCommon_NO_LIB) 5 | #if defined(TaoCommon_Library) 6 | #define TAO_API Q_DECL_EXPORT 7 | #else 8 | #define TAO_API Q_DECL_IMPORT 9 | #endif 10 | #else 11 | #define TAO_API 12 | #endif 13 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/TaoCommonInstall.pri: -------------------------------------------------------------------------------- 1 | headersTargetPath=$$[QT_INSTALL_HEADERS]/$$MODULE_INCNAME 2 | message("QMAKE_INSTALL_DIR $$headersTargetPath") 3 | 4 | gHeader.files=$$PWD/TaoCommonGlobal.h 5 | gHeader.path=$$headersTargetPath 6 | 7 | commonHeader.files=$$PWD/Common/*.h 8 | commonHeader.path=$$headersTargetPath/Common 9 | 10 | framelessHeader.files=$$PWD/Frameless/*.h 11 | framelessHeader.path=$$headersTargetPath/Frameless 12 | 13 | loggerHeader.files=$$PWD/Logger/*.h 14 | loggerHeader.path=$$headersTargetPath/Logger 15 | 16 | quickModelHeader.files=$$PWD/QuickModel/*.h 17 | quickModelHeader.path=$$headersTargetPath/QuickModel 18 | 19 | quickToolHeader.files=$$PWD/QuickTool/*.h 20 | quickToolHeader.path=$$headersTargetPath/QuickTool 21 | 22 | threadHeader.files=$$PWD/Thread/*.h 23 | threadHeader.path=$$headersTargetPath/Thread 24 | 25 | transHeader.files=$$PWD/Trans/*.h 26 | transHeader.path=$$headersTargetPath/Trans 27 | 28 | 29 | INSTALLS += \ 30 | gHeader commonHeader framelessHeader loggerHeader quickModelHeader \ 31 | quickToolHeader threadHeader transHeader 32 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/Thread/ThreadCommon.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include 3 | #include 4 | namespace TaoCommon 5 | { 6 | using WorkCallback = std::function; 7 | using WorkResultCallback = std::function; 8 | } // namespace TaoCommon 9 | Q_DECLARE_METATYPE(TaoCommon::WorkCallback); 10 | Q_DECLARE_METATYPE(TaoCommon::WorkResultCallback); 11 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/Thread/ThreadPool.cpp: -------------------------------------------------------------------------------- 1 | #include "ThreadPool.h" 2 | 3 | #include 4 | namespace TaoCommon 5 | { 6 | ThreadObject::ThreadObject(const WorkCallback& work) 7 | : m_workCall(work) 8 | { 9 | } 10 | void ThreadObject::run() 11 | { 12 | bool ok = m_workCall(); 13 | emit readyResult(ok); 14 | } 15 | // workCall in sub thread, resultCall in main thread 16 | void ThreadPool::work(const WorkCallback& workCall, const WorkResultCallback& resultCall) 17 | { 18 | ThreadObject* obj = new ThreadObject(workCall); 19 | obj->setAutoDelete(true); 20 | connect(obj, &ThreadObject::readyResult, this, resultCall); 21 | QThreadPool::globalInstance()->start(obj); 22 | } 23 | } // namespace TaoCommon 24 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/TaoCommon/Thread/ThreadPool.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | #include "TaoCommonGlobal.h" 3 | #include "ThreadCommon.h" 4 | #include 5 | #include 6 | namespace TaoCommon 7 | { 8 | // 对Qt线程池的简单封装,适合一次性执行的任务。 9 | // 用法: ThreadPool::getInstance()->work(workCall, resultCall) 10 | // workCall是在新线程中执行的任务,resultCall是任务执行完成后,回到调用线程中用来处理执行结果。 11 | // 不支持任务取消、暂停。 12 | 13 | class ThreadObject 14 | : public QObject 15 | , public QRunnable 16 | { 17 | Q_OBJECT 18 | public: 19 | explicit ThreadObject(const WorkCallback& work); 20 | void run() override; 21 | signals: 22 | void readyResult(bool); 23 | 24 | private: 25 | WorkCallback m_workCall; 26 | }; 27 | class TAO_API ThreadPool : public QObject 28 | { 29 | Q_OBJECT 30 | public: 31 | static ThreadPool* getInstance() 32 | { 33 | static ThreadPool poll; 34 | return &poll; 35 | } 36 | // workCall in sub thread, resultCall in main thread 37 | void work(const WorkCallback& workCall, const WorkResultCallback& resultCall); 38 | 39 | private: 40 | ThreadPool() { } 41 | }; 42 | } // namespace TaoCommon 43 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/src/src.pro: -------------------------------------------------------------------------------- 1 | TEMPLATE = subdirs 2 | CONFIG += ordered 3 | SUBDIRS += TaoCommon 4 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/sync.profile: -------------------------------------------------------------------------------- 1 | %modules = ( 2 | "TaoCommon" => "$basedir/src/TaoCommon/", 3 | ); 4 | %dependencies = ( 5 | "qtbase" => "", 6 | ); 7 | %classnames = ( 8 | 9 | ); 10 | 11 | 12 | 13 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/tests/auto/auto.pro: -------------------------------------------------------------------------------- 1 | TEMPLATE = subdirs 2 | SUBDIRS += cmake -------------------------------------------------------------------------------- /3rdparty/TaoCommon/tests/auto/cmake/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | 2 | cmake_minimum_required(VERSION 2.8) 3 | 4 | project(qmake_cmake_files) 5 | 6 | enable_testing() 7 | 8 | find_package(Qt5Core REQUIRED) 9 | 10 | include("${_Qt5CTestMacros}") 11 | 12 | test_module_includes( 13 | TaoCommon 14 | ) 15 | -------------------------------------------------------------------------------- /3rdparty/TaoCommon/tests/auto/cmake/cmake.pro: -------------------------------------------------------------------------------- 1 | 2 | # Cause make to do nothing. 3 | TEMPLATE = subdirs 4 | 5 | CMAKE_QT_MODULES_UNDER_TEST = charts 6 | 7 | CONFIG += ctest_testcase -------------------------------------------------------------------------------- /3rdparty/TaoCommon/tests/tests.pro: -------------------------------------------------------------------------------- 1 | TEMPLATE = subdirs 2 | SUBDIRS += auto -------------------------------------------------------------------------------- /CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.14) 2 | project (TaoQuick LANGUAGES CXX) 3 | 4 | SET(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake) 5 | 6 | set(CMAKE_AUTOUIC ON) 7 | set(CMAKE_AUTOMOC ON) 8 | set(CMAKE_AUTORCC ON) 9 | 10 | # use c++11 11 | set(CMAKE_CXX_STANDARD 17) 12 | set(CMAKE_CXX_STANDARD_REQUIRED ON) 13 | # use test 14 | #enable_testing() 15 | 16 | if (NOT PROJECT_BINARY_DIR) 17 | set(PROJECT_BINARY_DIR build) 18 | endif() 19 | #if (NOT QT_DIR) 20 | # set(QT_DIR "E:/qt5-install/lib/cmake/Qt6") 21 | #endif() 22 | #if (NOT Qt5_DIR) 23 | # set(Qt5_DIR ${QT_DIR}) 24 | #endif() 25 | #if (NOT Qt6_DIR) 26 | # set(Qt6_DIR ${QT_DIR}) 27 | #endif() 28 | set (EXECUTABLE_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bin) 29 | set (LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bin) 30 | 31 | if (NOT CMAKE_BUILD_TYPE) 32 | set(CMAKE_BUILD_TYPE "Release") 33 | endif() 34 | message("Build Type " ${CMAKE_BUILD_TYPE}) 35 | 36 | 37 | set_property(GLOBAL PROPERTY USE_FOLDERS ON) 38 | 39 | if(MSVC) 40 | add_compile_options("$<$:/utf-8>") 41 | add_compile_options("$<$:/utf-8>") 42 | set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /D_UNICODE /DUNICODE") 43 | endif() 44 | 45 | add_subdirectory(examples) 46 | 47 | #if (NOT CMAKE_NO_BUILD_TEST) 48 | # add_subdirectory(test) 49 | #endif() 50 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2018-2021 JaredTao jared2020@163.com 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /MarketPlace/TaoQuick_manifest.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "http://qt.io/schema/extension-schema-v1#", 3 | "title": "TaoQuick", 4 | "extensionType": [ 5 | "library" 6 | ], 7 | "version": "1.0.0", 8 | "vendor": { 9 | "name": "jaredtao", 10 | "url": "https://jaredtao.github.io" 11 | }, 12 | "contact": "jared2020@163.com", 13 | "copyright": [ "jaredtao (jared2020@163.com)" ], 14 | "author": "jared", 15 | "icon": "https://github.com/jaredtao/TaoQuick/blob/master/examples/TaoQuickShow/Image/logo/milk.png", 16 | "licenses": [ 17 | { "licenseType": "MIT", 18 | "licenseUrl": "https://github.com/jaredtao/TaoQuick/blob/master/LICENSE" } 19 | ], 20 | "created": "2018-12-03", 21 | "lastUpdate": "2021-01-26", 22 | "platforms": [ 23 | "macOS 10.14", "Windows 1803" 24 | ], 25 | "qtVersions": [ 26 | "5.9.0", "5.12.10", "5.15.2" 27 | ], 28 | "tags": [ 29 | "Component Library", "Quick Controls 2" ], 30 | "price": { 31 | "listprice": 0 32 | }, 33 | "support": "jared2020@163.com", 34 | "bugUrl": "https://github.com/jaredtao/TaoQuick/issues", 35 | "sourceRepoUrl": "https://github.com/jaredtao/TaoQuick", 36 | "dependencies": [ 37 | "Quick" 38 | ] 39 | } -------------------------------------------------------------------------------- /TaoQuick.pro: -------------------------------------------------------------------------------- 1 | defineTest(minQtVersion) { 2 | maj = $$1 3 | min = $$2 4 | patch = $$3 5 | isEqual(QT_MAJOR_VERSION, $$maj) { 6 | isEqual(QT_MINOR_VERSION, $$min) { 7 | isEqual(QT_PATCH_VERSION, $$patch) { 8 | return(true) 9 | } 10 | greaterThan(QT_PATCH_VERSION, $$patch) { 11 | return(true) 12 | } 13 | } 14 | greaterThan(QT_MINOR_VERSION, $$min) { 15 | return(true) 16 | } 17 | } 18 | greaterThan(QT_MAJOR_VERSION, $$maj) { 19 | return(true) 20 | } 21 | return(false) 22 | } 23 | 24 | !minQtVersion(5, 9, 0) { 25 | error("TaoQuick minimum supported Qt5 version is 5.9.0") 26 | } 27 | 28 | TEMPLATE = subdirs 29 | 30 | SUBDIRS += \ 31 | # src \ 32 | examples 33 | CONFIG+= ordered 34 | 35 | OTHER_FILES += *.md \ 36 | LICENSE \ 37 | .clang-format \ 38 | .qmake.conf \ 39 | .github/workflows/* \ 40 | scripts/* \ 41 | mkspecs/features/* 42 | -------------------------------------------------------------------------------- /TaoQuick.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio Version 17 4 | VisualStudioVersion = 17.11.35431.28 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "TaoQuickShow", "examples\TaoQuickShow\TaoQuickShow.vcxproj", "{459D668B-0F88-4B38-9C16-E28F89505358}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|x64 = Debug|x64 11 | Release|x64 = Release|x64 12 | EndGlobalSection 13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 14 | {459D668B-0F88-4B38-9C16-E28F89505358}.Debug|x64.ActiveCfg = Debug|x64 15 | {459D668B-0F88-4B38-9C16-E28F89505358}.Debug|x64.Build.0 = Debug|x64 16 | {459D668B-0F88-4B38-9C16-E28F89505358}.Release|x64.ActiveCfg = Release|x64 17 | {459D668B-0F88-4B38-9C16-E28F89505358}.Release|x64.Build.0 = Release|x64 18 | EndGlobalSection 19 | GlobalSection(SolutionProperties) = preSolution 20 | HideSolutionNode = FALSE 21 | EndGlobalSection 22 | GlobalSection(ExtensibilityGlobals) = postSolution 23 | SolutionGuid = {DC052BAA-5D0E-46CB-A268-F382FB176B69} 24 | EndGlobalSection 25 | EndGlobal 26 | -------------------------------------------------------------------------------- /clang-foramt-All.ps1: -------------------------------------------------------------------------------- 1 | $scriptDir=$PSScriptRoot 2 | $currentDir=Get-Location 3 | Write-Host "currentDir" $currentDir 4 | Write-Host "scriptDir" $scriptDir 5 | $names="*.h","*.cpp","*.c","*.hpp" 6 | Get-ChildItem -Include $names -Recurse $currentDir | ForEach-Object { 7 | clang-format -i $_.FullName 8 | } -------------------------------------------------------------------------------- /cmake/taoCommon.cmake: -------------------------------------------------------------------------------- 1 | add_subdirectory(${CMAKE_SOURCE_DIR}/3rdparty ${CMAKE_SOURCE_DIR}/build/3rdparty) 2 | -------------------------------------------------------------------------------- /cmake/taoVersion.cmake: -------------------------------------------------------------------------------- 1 | find_package(Git) 2 | if(Git_FOUND) 3 | message("Git found: ${GIT_EXECUTABLE}") 4 | endif() 5 | 6 | set (REVISION "0000000000") 7 | execute_process( 8 | COMMAND ${GIT_EXECUTABLE} rev-parse HEAD 9 | WORKING_DIRECTORY ${PROJECT_SOURCE_DIR} 10 | OUTPUT_VARIABLE OUTPUT) 11 | if (OUTPUT) 12 | string(SUBSTRING ${OUTPUT} 0 10 REVISION) 13 | endif() 14 | message("REVISION ${REVISION}") 15 | add_compile_definitions(TaoREVISIONSTR="${REVISION}") 16 | 17 | set (TAG "0.0.0.0") 18 | execute_process( 19 | COMMAND ${GIT_EXECUTABLE} describe --abbrev=0 --tags 20 | WORKING_DIRECTORY ${PROJECT_SOURCE_DIR} 21 | OUTPUT_VARIABLE OUTPUT) 22 | if(OUTPUT) 23 | string(STRIP ${OUTPUT} TAG) 24 | endif() 25 | message("TAG ${TAG}") 26 | add_compile_definitions(TaoVer="${TAG}") 27 | string(REPLACE "." ";" VERSION_LIST ${TAG}) 28 | list(GET VERSION_LIST 0 TAG_VERSION_MAJOR) 29 | list(GET VERSION_LIST 1 TAG_VERSION_MINOR) 30 | list(GET VERSION_LIST 2 TAG_VERSION_PATCH) 31 | add_compile_definitions(TaoMAJ=${TAG_VERSION_MAJOR}) 32 | add_compile_definitions(TaoMIN=${TAG_VERSION_MINOR}) 33 | add_compile_definitions(TaoPAT=${TAG_VERSION_PATCH}) 34 | 35 | string(TIMESTAMP DateTime "%Y-%m-%d %H:%M:%S") 36 | add_compile_definitions(TaoDATETIME="${DateTime}") 37 | add_compile_definitions(CXX_COMPILER_ID="${CMAKE_CXX_COMPILER_ID}") 38 | -------------------------------------------------------------------------------- /doc/cmake1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/cmake1.png -------------------------------------------------------------------------------- /doc/cmake2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/cmake2.png -------------------------------------------------------------------------------- /doc/cmake5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/cmake5.png -------------------------------------------------------------------------------- /doc/cmake6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/cmake6.png -------------------------------------------------------------------------------- /doc/core.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/core.png -------------------------------------------------------------------------------- /doc/start1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/start1.png -------------------------------------------------------------------------------- /doc/start2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/start2.png -------------------------------------------------------------------------------- /doc/start3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/start3.png -------------------------------------------------------------------------------- /doc/start4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/start4.png -------------------------------------------------------------------------------- /doc/start5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/start5.png -------------------------------------------------------------------------------- /doc/struct1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/struct1.png -------------------------------------------------------------------------------- /doc/vs1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/vs1.png -------------------------------------------------------------------------------- /doc/vs2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/vs2.png -------------------------------------------------------------------------------- /doc/vs3.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/vs3.png -------------------------------------------------------------------------------- /doc/vs4.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/vs4.png -------------------------------------------------------------------------------- /doc/vs5.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/vs5.png -------------------------------------------------------------------------------- /doc/vs6.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/vs6.png -------------------------------------------------------------------------------- /doc/vs7.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/doc/vs7.png -------------------------------------------------------------------------------- /examples/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | add_subdirectory(TaoQuickShow) -------------------------------------------------------------------------------- /examples/HelloTaoQuick1/HelloTaoQuick1.pro: -------------------------------------------------------------------------------- 1 | TEMPLATE = app 2 | 3 | QT += gui quick qml quickcontrols2 4 | 5 | SOURCES += main.cpp 6 | 7 | RESOURCES += Res.qrc 8 | 9 | include(../../src/TaoQuick.pri) 10 | 11 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick1/Res.qrc: -------------------------------------------------------------------------------- 1 | 2 | 3 | main.qml 4 | 5 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick1/main.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | int main(int argc, char** argv) 6 | { 7 | QGuiApplication app(argc, argv); 8 | QQuickView view; 9 | view.engine()->addImportPath(TaoQuickImportPath); 10 | view.rootContext()->setContextProperty("taoQuickImportPath", TaoQuickImportPath); 11 | 12 | view.setSource(QUrl("qrc:/main.qml")); 13 | view.show(); 14 | 15 | return app.exec(); 16 | } -------------------------------------------------------------------------------- /examples/HelloTaoQuick1/main.qml: -------------------------------------------------------------------------------- 1 | import QtQml 2.0 2 | import QtQuick 2.9 3 | 4 | import QtQuick.Controls 2.0 5 | 6 | import TaoQuick 1.0 7 | 8 | Rectangle { 9 | color: "lightblue" 10 | width: 640 11 | height: 480 12 | CusButton_Blue { 13 | width: 120 14 | height: 36 15 | anchors.centerIn: parent 16 | text: "Hello" 17 | onClicked: { 18 | console.log("hello TaoQuick") 19 | } 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick2/CMakeLists.txt: -------------------------------------------------------------------------------- 1 | cmake_minimum_required(VERSION 3.14) 2 | 3 | project(HelloTaoQuick2 LANGUAGES CXX) 4 | 5 | set(CMAKE_INCLUDE_CURRENT_DIR ON) 6 | 7 | set(CMAKE_AUTOUIC ON) 8 | set(CMAKE_AUTOMOC ON) 9 | set(CMAKE_AUTORCC ON) 10 | 11 | set(CMAKE_CXX_STANDARD 11) 12 | set(CMAKE_CXX_STANDARD_REQUIRED ON) 13 | 14 | include(taoQuick.cmake) 15 | 16 | find_package(QT NAMES Qt6 Qt5 COMPONENTS Core Quick REQUIRED) 17 | find_package(Qt${QT_VERSION_MAJOR} COMPONENTS Core Quick REQUIRED) 18 | 19 | if(ANDROID) 20 | add_library(HelloTaoQuick2 SHARED 21 | main.cpp 22 | qml.qrc 23 | ) 24 | else() 25 | add_executable(HelloTaoQuick2 26 | main.cpp 27 | qml.qrc 28 | ${TaoQuickRes} 29 | ) 30 | endif() 31 | 32 | target_compile_definitions(HelloTaoQuick2 33 | PRIVATE $<$,$>:QT_QML_DEBUG>) 34 | target_link_libraries(HelloTaoQuick2 35 | PRIVATE Qt${QT_VERSION_MAJOR}::Core Qt${QT_VERSION_MAJOR}::Quick) 36 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick2/main.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | int main(int argc, char* argv[]) 5 | { 6 | QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling); 7 | 8 | QGuiApplication app(argc, argv); 9 | 10 | QQmlApplicationEngine engine; 11 | engine.addImportPath(TaoQuickImportPath); 12 | engine.rootContext()->setContextProperty("taoQuickImportPath", TaoQuickImportPath); 13 | const QUrl url(QStringLiteral("qrc:/main.qml")); 14 | QObject::connect( 15 | &engine, 16 | &QQmlApplicationEngine::objectCreated, 17 | &app, 18 | [url](QObject* obj, const QUrl& objUrl) 19 | { 20 | if (!obj && url == objUrl) 21 | QCoreApplication::exit(-1); 22 | }, 23 | Qt::QueuedConnection); 24 | engine.load(url); 25 | 26 | return app.exec(); 27 | } 28 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick2/main.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.12 2 | import QtQuick.Window 2.12 3 | import QtQuick 2.9 4 | import TaoQuick 1.0 5 | Window { 6 | width: 640 7 | height: 480 8 | visible: true 9 | title: qsTr("Hello World") 10 | CusButton_Blue { 11 | width: 120 12 | height: 36 13 | anchors.centerIn: parent 14 | text: "Hello" 15 | onClicked: { 16 | console.log("hello TaoQuick") 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick2/qml.qrc: -------------------------------------------------------------------------------- 1 | 2 | 3 | main.qml 4 | 5 | 6 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick2/taoQuick.cmake: -------------------------------------------------------------------------------- 1 | set(TaoQuickPath ${CMAKE_SOURCE_DIR}/../../src/TaoQuick/imports) 2 | 3 | if (CMAKE_BUILD_TYPE MATCHES "Release") 4 | set(TaoQuickRes ${TaoQuickPath}/TaoQuick/TaoQuick.qrc CACHE STRING "tao quick res path") 5 | set(TaoQuickImportPath "qrc:///" CACHE STRING "tao quick import path") 6 | else() 7 | set(TaoQuickImportPath "file:///${TaoQuickPath}" CACHE STRING "tao quick import path") 8 | endif() 9 | add_compile_definitions(TaoQuickImportPath="${TaoQuickImportPath}") 10 | 11 | add_compile_definitions(QML_IMPORT_PATH="${TaoQuickPath}") 12 | add_compile_definitions(QML2_IMPORT_PATH="${TaoQuickPath}") 13 | add_compile_definitions(QML_DESIGNER_IMPORT_PATH="${TaoQuickPath}") 14 | 15 | 16 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick3/HelloTaoQuick3.sln: -------------------------------------------------------------------------------- 1 |  2 | Microsoft Visual Studio Solution File, Format Version 12.00 3 | # Visual Studio Version 17 4 | VisualStudioVersion = 17.5.33627.172 5 | MinimumVisualStudioVersion = 10.0.40219.1 6 | Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "HelloTaoQuick3", "HelloTaoQuick3\HelloTaoQuick3.vcxproj", "{4091D318-EF85-4A5B-B4B7-DDF7A92C2269}" 7 | EndProject 8 | Global 9 | GlobalSection(SolutionConfigurationPlatforms) = preSolution 10 | Debug|x64 = Debug|x64 11 | Release|x64 = Release|x64 12 | EndGlobalSection 13 | GlobalSection(ProjectConfigurationPlatforms) = postSolution 14 | {4091D318-EF85-4A5B-B4B7-DDF7A92C2269}.Debug|x64.ActiveCfg = Debug|x64 15 | {4091D318-EF85-4A5B-B4B7-DDF7A92C2269}.Debug|x64.Build.0 = Debug|x64 16 | {4091D318-EF85-4A5B-B4B7-DDF7A92C2269}.Release|x64.ActiveCfg = Release|x64 17 | {4091D318-EF85-4A5B-B4B7-DDF7A92C2269}.Release|x64.Build.0 = Release|x64 18 | EndGlobalSection 19 | GlobalSection(SolutionProperties) = preSolution 20 | HideSolutionNode = FALSE 21 | EndGlobalSection 22 | GlobalSection(ExtensibilityGlobals) = postSolution 23 | SolutionGuid = {3AD2632C-A9D2-4450-8503-26757BD9C66B} 24 | EndGlobalSection 25 | EndGlobal 26 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick3/HelloTaoQuick3/HelloTaoQuick3.vcxproj.filters: -------------------------------------------------------------------------------- 1 |  2 | 3 | 4 | 5 | {4FC737F1-C7A5-4376-A066-2A32D752A2FF} 6 | qml;cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx 7 | 8 | 9 | {93995380-89BD-4b04-88EB-625FBE52EBFB} 10 | h;hh;hpp;hxx;hm;inl;inc;xsd 11 | 12 | 13 | {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} 14 | qrc;rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms 15 | 16 | 17 | {99349809-55BA-4b9d-BF79-8FDBB0286EB3} 18 | ui 19 | 20 | 21 | {639EADAA-A684-42e4-A9AD-28FC9BCB8F7C} 22 | ts 23 | 24 | 25 | 26 | 27 | Source Files 28 | 29 | 30 | Resource Files 31 | 32 | 33 | Source Files 34 | 35 | 36 | 37 | 38 | Resource Files 39 | 40 | 41 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick3/HelloTaoQuick3/main.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | int main(int argc, char *argv[]) 5 | { 6 | #if defined(Q_OS_WIN) 7 | QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling); 8 | #endif 9 | 10 | QGuiApplication app(argc, argv); 11 | 12 | QQmlApplicationEngine engine; 13 | 14 | QString importPath = TaoQuickImportPath; 15 | importPath = importPath.replace("\\", "/"); 16 | engine.addImportPath(importPath); 17 | engine.rootContext()->setContextProperty("taoQuickImportPath", importPath); 18 | 19 | engine.load(QUrl(QStringLiteral("qrc:/main.qml"))); 20 | if (engine.rootObjects().isEmpty()) 21 | return -1; 22 | 23 | return app.exec(); 24 | } 25 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick3/HelloTaoQuick3/main.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Window 2.2 3 | import TaoQuick 1.0 4 | Window { 5 | visible: true 6 | width: 640 7 | height: 480 8 | title: qsTr("Hello World") 9 | CusButton_Blue { 10 | width: 120 11 | height: 36 12 | anchors.centerIn: parent 13 | text: "Hello" 14 | onClicked: { 15 | console.log("hello TaoQuick") 16 | } 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick3/HelloTaoQuick3/qml.qrc: -------------------------------------------------------------------------------- 1 | 2 | 3 | main.qml 4 | 5 | 6 | -------------------------------------------------------------------------------- /examples/HelloTaoQuick3/HelloTaoQuick3/taoQuick.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | TaoQuickImportPath=R"(file:///$(ProjectDir)..\..\..\src)";%(PreprocessorDefinitions) 8 | 9 | 10 | 11 | 12 | TaoQuickImportPath="qrc:/";%(PreprocessorDefinitions) 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/App.rc: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/App.rc -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Animation/AnimationBase.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | Item { 6 | anchors.fill: parent 7 | signal replayClicked 8 | CusButton { 9 | anchors { 10 | left: parent.left 11 | bottom: parent.bottom 12 | margins: 10 13 | } 14 | text: qsTr("Replay") + trans.transString 15 | onClicked: { 16 | replayClicked() 17 | } 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Animation/Board.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | 4 | import TaoQuick 1.0 5 | 6 | 7 | AnimationBase { 8 | anchors.fill: parent 9 | Image { 10 | id: src 11 | source: imgPath + "Effect/girl.jpg" 12 | visible: false 13 | } 14 | Row { 15 | anchors.centerIn: parent 16 | spacing: 20 17 | ABoard { 18 | id: a1 19 | width: 460 20 | height: 280 21 | effectSource.sourceItem: src 22 | } 23 | ABoard { 24 | id: a2 25 | width: 460 26 | height: 280 27 | dir: directToBottom 28 | effectSource.sourceItem: src 29 | } 30 | } 31 | Component.onCompleted: { 32 | ani.start() 33 | } 34 | SequentialAnimation { 35 | id: ani 36 | ScriptAction {script: {a1.restart() } } 37 | PauseAnimation {duration: 1200} 38 | ScriptAction {script: {a2.restart() } } 39 | } 40 | onReplayClicked: { 41 | ani.restart() 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Animation/Circle.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | AnimationBase { 6 | anchors.fill: parent 7 | Image { 8 | id: src 9 | source: imgPath + "Effect/Girls/girl1.jpeg" 10 | visible: false 11 | } 12 | Grid { 13 | anchors.centerIn: parent 14 | columns: 2 15 | spacing: 40 16 | ACircle { 17 | id: s1 18 | width: 250 19 | height: 375 20 | dir: directFromInner 21 | effectSource.sourceItem: src 22 | } 23 | ACircle { 24 | id: s2 25 | width: 250 26 | height: 375 27 | dir: directFromOuter 28 | effectSource.sourceItem: src 29 | } 30 | } 31 | Component.onCompleted: { 32 | ani.start() 33 | } 34 | SequentialAnimation { 35 | id: ani 36 | ScriptAction {script: {s1.restart() } } 37 | PauseAnimation {duration: 1200} 38 | ScriptAction {script: {s2.restart() } } 39 | } 40 | onReplayClicked: { 41 | ani.restart() 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Animation/Cleavage.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | AnimationBase { 6 | anchors.fill: parent 7 | Image { 8 | id: src 9 | width: 230 10 | height: 140 11 | source: imgPath + "Effect/Girls/girl2.jpeg" 12 | visible: false 13 | } 14 | Grid { 15 | anchors.centerIn: parent 16 | columns: 2 17 | spacing: 40 18 | ACleavage { 19 | id: s1 20 | width: 250 21 | height: 375 22 | dir: directHorizonToInner 23 | effectSource.sourceItem: src 24 | } 25 | ACleavage { 26 | id: s2 27 | width: 250 28 | height: 375 29 | dir: directHorizonToOuter 30 | effectSource.sourceItem: src 31 | } 32 | ACleavage { 33 | id: s3 34 | width: 250 35 | height: 375 36 | dir: directVerticalToInner 37 | effectSource.sourceItem: src 38 | } 39 | ACleavage { 40 | id: s4 41 | width: 250 42 | height: 375 43 | dir: directVerticalToOuter 44 | effectSource.sourceItem: src 45 | } 46 | } 47 | Component.onCompleted: { 48 | ani.start() 49 | } 50 | SequentialAnimation { 51 | id: ani 52 | ScriptAction {script: {s1.restart() } } 53 | PauseAnimation {duration: 1200} 54 | ScriptAction {script: {s2.restart() } } 55 | PauseAnimation {duration: 1200} 56 | ScriptAction {script: {s3.restart() } } 57 | PauseAnimation {duration: 1200} 58 | ScriptAction {script: {s4.restart() } } 59 | } 60 | onReplayClicked: { 61 | ani.restart() 62 | } 63 | } 64 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Animation/Cross.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | AnimationBase { 6 | anchors.fill: parent 7 | Image { 8 | id: src 9 | source: imgPath + "Effect/Girls/girl3.jpeg" 10 | visible: false 11 | } 12 | Grid { 13 | anchors.centerIn: parent 14 | columns: 2 15 | spacing: 40 16 | 17 | ACross { 18 | id: s1 19 | width: 250 20 | height: 375 21 | dir: directFromInner 22 | effectSource.sourceItem: src 23 | } 24 | ACross { 25 | id: s2 26 | width: 250 27 | height: 375 28 | dir: directFromOuter 29 | effectSource.sourceItem: src 30 | } 31 | } 32 | Component.onCompleted: { 33 | ani.start() 34 | } 35 | SequentialAnimation { 36 | id: ani 37 | ScriptAction {script: {s1.restart() } } 38 | PauseAnimation {duration: 1200} 39 | ScriptAction {script: {s2.restart() } } 40 | } 41 | onReplayClicked: { 42 | ani.restart() 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Animation/Diagonal.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | AnimationBase { 6 | anchors.fill: parent 7 | Image { 8 | id: src 9 | source: imgPath + "Effect/Girls/girl4.jpeg" 10 | visible: false 11 | } 12 | Grid { 13 | anchors.centerIn: parent 14 | columns: 2 15 | spacing: 40 16 | ADiagonal { 17 | id: d1 18 | width: 250 19 | height: 375 20 | dir: directFromLeftTop 21 | effectSource.sourceItem: src 22 | } 23 | ADiagonal { 24 | id: d2 25 | width: 250 26 | height: 375 27 | dir: directFromRightBottom 28 | effectSource.sourceItem: src 29 | } 30 | ADiagonal { 31 | id: d3 32 | width: 250 33 | height: 375 34 | dir: directFromRightTop 35 | effectSource.sourceItem: src 36 | } 37 | ADiagonal { 38 | id: d4 39 | width: 250 40 | height: 375 41 | dir: directFromLeftBottom 42 | effectSource.sourceItem: src 43 | } 44 | } 45 | Component.onCompleted: { 46 | ani.start() 47 | } 48 | SequentialAnimation { 49 | id: ani 50 | ScriptAction {script: {d1.restart() } } 51 | PauseAnimation {duration: 1200} 52 | ScriptAction {script: {d2.restart() } } 53 | PauseAnimation {duration: 1200} 54 | ScriptAction {script: {d3.restart() } } 55 | PauseAnimation {duration: 1200} 56 | ScriptAction {script: {d4.restart() } } 57 | } 58 | onReplayClicked: { 59 | ani.restart() 60 | } 61 | } 62 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Animation/Dissolve.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | AnimationBase { 6 | anchors.fill: parent 7 | Image { 8 | id: src 9 | source: imgPath + "Effect/Girls/girl5.jpeg" 10 | visible: false 11 | } 12 | Image { 13 | id: dissolveSrc1 14 | source: imgPath + "Effect/Dissolve_1.jpg" 15 | visible: false 16 | } 17 | Image { 18 | id: dissolveSrc2 19 | source: imgPath + "Effect/Dissolve_2.png" 20 | visible: false 21 | } 22 | Row { 23 | anchors.centerIn: parent 24 | spacing: 40 25 | ADissolve { 26 | id: a1 27 | width: 250 28 | height: 375 29 | duration: 1800 30 | effectSource.sourceItem: src 31 | dissolveSource.sourceItem: dissolveSrc1 32 | } 33 | ADissolve { 34 | id: a2 35 | width: 250 36 | height: 375 37 | duration: 1800 38 | effectSource.sourceItem: src 39 | dissolveSource.sourceItem: dissolveSrc2 40 | } 41 | } 42 | Component.onCompleted: { 43 | ani.start() 44 | } 45 | SequentialAnimation { 46 | id: ani 47 | ScriptAction {script: {a1.restart() } } 48 | PauseAnimation {duration: 2000} 49 | ScriptAction {script: {a2.restart() } } 50 | } 51 | onReplayClicked: { 52 | ani.restart() 53 | } 54 | } 55 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Animation/Grad.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | AnimationBase { 6 | anchors.fill: parent 7 | Image { 8 | id: src 9 | 10 | source: imgPath + "Effect/Girls/girl6.jpeg" 11 | visible: false 12 | } 13 | Grid { 14 | anchors.centerIn: parent 15 | columns: 2 16 | spacing: 40 17 | AGrad { 18 | id: g1 19 | width: 250 20 | height: 375 21 | effectSource.sourceItem: src 22 | } 23 | 24 | AGrad { 25 | id: g2 26 | width: 250 27 | height: 375 28 | dir: directFromRight 29 | effectSource.sourceItem: src 30 | } 31 | 32 | AGrad { 33 | id: g3 34 | width: 250 35 | height: 375 36 | dir: directFromTop 37 | effectSource.sourceItem: src 38 | } 39 | AGrad { 40 | id: g4 41 | dir: directFromBottom 42 | width: 250 43 | height: 375 44 | effectSource.sourceItem: src 45 | 46 | } 47 | } 48 | Component.onCompleted: { 49 | ani.start() 50 | } 51 | SequentialAnimation { 52 | id: ani 53 | ScriptAction {script: {g1.restart() } } 54 | PauseAnimation {duration: 1200} 55 | ScriptAction {script: {g2.restart() } } 56 | PauseAnimation {duration: 1200} 57 | ScriptAction {script: {g3.restart() } } 58 | PauseAnimation {duration: 1200} 59 | ScriptAction {script: {g4.restart() } } 60 | } 61 | onReplayClicked: { 62 | ani.restart() 63 | } 64 | } 65 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Animation/Louver.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | AnimationBase { 6 | anchors.fill: parent 7 | Image { 8 | id: src 9 | source: imgPath + "Effect/Girls/girl7.jpeg" 10 | visible: false 11 | } 12 | Grid { 13 | anchors.centerIn: parent 14 | spacing: 40 15 | columns: 2 16 | 17 | ALouver { 18 | id: l1 19 | width: 250 20 | height: 375 21 | effectSource.sourceItem: src 22 | } 23 | ALouver { 24 | id: l2 25 | width: 250 26 | height: 375 27 | dir: directHorizonReverse 28 | effectSource.sourceItem: src 29 | } 30 | ALouver { 31 | id: l3 32 | width: 250 33 | height: 375 34 | dir: directVertical 35 | effectSource.sourceItem: src 36 | } 37 | ALouver { 38 | id: l4 39 | width: 250 40 | height: 375 41 | dir: directVerticalReverse 42 | effectSource.sourceItem: src 43 | } 44 | 45 | } 46 | Component.onCompleted: { 47 | ani.start() 48 | } 49 | SequentialAnimation { 50 | id: ani 51 | ScriptAction {script: {l1.restart() } } 52 | PauseAnimation {duration: 1200} 53 | ScriptAction {script: {l2.restart() } } 54 | PauseAnimation {duration: 1200} 55 | ScriptAction {script: {l3.restart() } } 56 | PauseAnimation {duration: 1200} 57 | ScriptAction {script: {l4.restart() } } 58 | } 59 | onReplayClicked: { 60 | ani.restart() 61 | } 62 | } 63 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Animation/Rhombus.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | AnimationBase { 6 | anchors.fill: parent 7 | Image { 8 | id: src 9 | source: imgPath + "Effect/Girls/girl8.jpeg" 10 | visible: false 11 | } 12 | Grid { 13 | anchors.centerIn: parent 14 | spacing: 40 15 | columns: 2 16 | 17 | ARhombus { 18 | id: l1 19 | width: 250 20 | height: 375 21 | dir: directFromInner 22 | effectSource.sourceItem: src 23 | } 24 | ARhombus { 25 | id: l2 26 | width: 250 27 | height: 375 28 | dir: directFromOuter 29 | effectSource.sourceItem: src 30 | } 31 | 32 | 33 | } 34 | Component.onCompleted: { 35 | ani.start() 36 | } 37 | SequentialAnimation { 38 | id: ani 39 | ScriptAction {script: {l1.restart() } } 40 | PauseAnimation {duration: 1200} 41 | ScriptAction {script: {l2.restart() } } 42 | } 43 | onReplayClicked: { 44 | ani.restart() 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Animation/Square.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | AnimationBase { 6 | anchors.fill: parent 7 | Image { 8 | id: src 9 | source: imgPath + "Effect/Girls/girl9.jpeg" 10 | visible: false 11 | } 12 | Grid { 13 | anchors.centerIn: parent 14 | columns: 2 15 | spacing: 40 16 | ASquare { 17 | id: s1 18 | width: 250 19 | height: 375 20 | dir: directFromInner 21 | effectSource.sourceItem: src 22 | } 23 | ASquare { 24 | id: s2 25 | width: 250 26 | height: 375 27 | dir: directFromOuter 28 | effectSource.sourceItem: src 29 | } 30 | } 31 | Component.onCompleted: { 32 | ani.start() 33 | } 34 | SequentialAnimation { 35 | id: ani 36 | ScriptAction {script: {s1.restart() } } 37 | PauseAnimation {duration: 1200} 38 | ScriptAction {script: {s2.restart() } } 39 | } 40 | onReplayClicked: { 41 | ani.restart() 42 | } 43 | } 44 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Animation/Wheel.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | AnimationBase { 6 | anchors.fill: parent 7 | Image { 8 | id: src 9 | source: imgPath + "Effect/Girls/girl10.jpeg" 10 | visible: false 11 | } 12 | Grid { 13 | anchors.centerIn: parent 14 | columns: 2 15 | spacing: 40 16 | AWheel { 17 | id: s1 18 | width: 250 19 | height: 375 20 | dir: directClockwise 21 | effectSource.sourceItem: src 22 | } 23 | AWheel { 24 | id: s2 25 | width: 250 26 | height: 375 27 | dir: directCounterClockwise 28 | effectSource.sourceItem: src 29 | } 30 | ASector { 31 | id: s3 32 | width: 250 33 | height: 375 34 | effectSource.sourceItem: src 35 | } 36 | } 37 | Component.onCompleted: { 38 | ani.start() 39 | } 40 | SequentialAnimation { 41 | id: ani 42 | ScriptAction {script: {s1.restart() } } 43 | PauseAnimation {duration: 1200} 44 | ScriptAction {script: {s2.restart() } } 45 | PauseAnimation {duration: 1200} 46 | ScriptAction {script: {s3.restart() } } 47 | } 48 | onReplayClicked: { 49 | ani.restart() 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Effect/EditJoggle.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import "./Effects" 4 | 5 | import TaoQuick 1.0 6 | 7 | Item { 8 | anchors.fill: parent 9 | Rectangle { 10 | id: textRect 11 | width: 400 12 | height: 300 13 | anchors.centerIn: parent 14 | color: Qt.rgba(0.1, 0.2, 0.3) 15 | 16 | TextEdit { 17 | id: textArea 18 | anchors { 19 | fill: parent 20 | margins: 10 21 | } 22 | width: parent.width - 20 23 | selectByMouse: true 24 | color: "red" 25 | font.pixelSize: 16 26 | onTextChanged: { 27 | if (text.length > 0) { 28 | atomJoggle.joggle(100, 4) 29 | } 30 | } 31 | AtomJoggle { 32 | id: atomJoggle 33 | anchors.fill: parent 34 | targetWin: view 35 | targetEdit: textArea 36 | } 37 | } 38 | } 39 | CusLabel { 40 | text: qsTr("Input on above rect to try Atom-Joggle effect") 41 | anchors { 42 | top: textRect.bottom 43 | topMargin: 10 44 | horizontalCenter: parent.horizontalCenter 45 | } 46 | } 47 | 48 | } 49 | 50 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Effect/Effects/TArrow.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | Image { 4 | id: root 5 | x: 10 6 | y: 10 7 | source: imgPath + "Effect/arrow.png" 8 | visible: false 9 | function run() { 10 | visible = true; 11 | pathAnimation.start(); 12 | } 13 | PathAnimation { 14 | id: pathAnimation 15 | target: root 16 | loops: -1 17 | duration: 2400 18 | orientation: PathAnimation.TopFirst 19 | path: Path{ 20 | startX: 10 21 | startY: 10 22 | PathCurve { x: 60; y: 15} 23 | PathCurve { x: 110; y: 205} 24 | PathCurve { x: 210; y: 200} 25 | PathCurve { x: 260; y: 35} 26 | PathCurve { x: 310; y: 25} 27 | } 28 | } 29 | } 30 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Effect/Effects/TSwapper.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | Item { 4 | id: r 5 | property url source 6 | 7 | Image { 8 | id: img1 9 | anchors.fill: parent 10 | source: r.source 11 | opacity: 1 12 | } 13 | Image { 14 | id: img2 15 | anchors.fill: parent 16 | source: r.source 17 | opacity: 0.5 18 | rotation: 180 19 | } 20 | 21 | SequentialAnimation { 22 | running: true 23 | loops: Animation.Infinite 24 | 25 | PauseAnimation { 26 | duration: 5 * 1000 27 | } 28 | ParallelAnimation { 29 | NumberAnimation { target: img1; property:"opacity"; to: 0.5; duration: 1000 } 30 | NumberAnimation { target: img2; property:"opacity"; to: 1; duration: 1000 } 31 | } 32 | 33 | PauseAnimation { 34 | duration: 5 * 1000 35 | } 36 | ParallelAnimation { 37 | NumberAnimation { target: img1; property:"opacity"; to: 1; duration: 1000 } 38 | NumberAnimation { target: img2; property:"opacity"; to: 0.5; duration: 1000 } 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Effect/SoundByte.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import "./Effects" 4 | Rectangle { 5 | anchors.fill: parent 6 | color: "black" 7 | TSoundByte { 8 | id: src 9 | anchors.centerIn: parent 10 | anchors.verticalCenterOffset: -100 11 | interval: 240 12 | } 13 | 14 | ShaderEffectSource { 15 | id: mirror 16 | width: src.width 17 | height: src.height 18 | x: src.x 19 | y: src.y + src.height + 10 20 | opacity: 0.3 21 | sourceItem: src 22 | transform: Rotation { 23 | origin.x: mirror.width/2 24 | origin.y: mirror.height/2 25 | axis.x: 1; axis.y: 0; axis.z: 0 26 | angle: 180 27 | } 28 | //no effect 29 | //textureMirroring: ShaderEffectSource.MirrorHorizontally 30 | 31 | } 32 | } 33 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/Effect/Swapper.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import "./Effects" 4 | TSwapper { 5 | source: imgPath + "Effect/astronomy.jpg" 6 | anchors.fill: parent 7 | } 8 | 9 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/General/Images.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | Item { 6 | anchors.fill: parent 7 | Column { 8 | anchors.centerIn: parent 9 | spacing: 10 10 | CusLabel { 11 | text: qsTr("General Image") + trans.transString 12 | wrapMode: Label.WordWrap 13 | width: 400 14 | } 15 | CusImage { 16 | width: 225 17 | height: 150 18 | source: imgPath + "Effect/baby.jpg" 19 | } 20 | Item { 21 | width: 10 22 | height: 30 23 | } 24 | CusLabel { 25 | text: qsTr("Image with tip") + trans.transString 26 | wrapMode: Label.WordWrap 27 | width: 400 28 | } 29 | CusImage_Tip { 30 | width: 450 31 | height: 300 32 | source: imgPath + "Effect/girl.jpg" 33 | tipText: "i am Image tip" 34 | } 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/General/Labels.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | Item { 6 | anchors.fill: parent 7 | Column { 8 | anchors.centerIn: parent 9 | spacing: 10 10 | CusLabel { 11 | text: qsTr("Hello, TaoQuick") + trans.transString 12 | wrapMode: Label.WordWrap 13 | width: 400 14 | font.pixelSize: 12 15 | } 16 | CusLabel { 17 | text: qsTr("Hello, TaoQuick") + trans.transString 18 | wrapMode: Label.WordWrap 19 | width: 400 20 | font.pixelSize: 14 21 | } 22 | CusLabel { 23 | text: qsTr("Hello, TaoQuick") + trans.transString 24 | wrapMode: Label.WordWrap 25 | width: 400 26 | font.pixelSize: 16 27 | } 28 | CusLabel { 29 | text: qsTr("Hello, TaoQuick") + trans.transString 30 | wrapMode: Label.WordWrap 31 | width: 400 32 | font.pixelSize: 18 33 | } 34 | CusLabel { 35 | text: qsTr("Hello, TaoQuick") + trans.transString 36 | wrapMode: Label.WordWrap 37 | width: 400 38 | font.pixelSize: 20 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/Board.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | PageSwitchBase { 6 | id: c 7 | anchors.fill: parent 8 | 9 | images:[ 10 | imgPath + "Effect/Girls/girl1.jpeg", 11 | imgPath + "Effect/Girls/girl2.jpeg", 12 | imgPath + "Effect/Girls/girl3.jpeg", 13 | imgPath + "Effect/Girls/girl4.jpeg", 14 | imgPath + "Effect/Girls/girl5.jpeg", 15 | imgPath + "Effect/Girls/girl6.jpeg", 16 | imgPath + "Effect/Girls/girl7.jpeg", 17 | imgPath + "Effect/Girls/girl8.jpeg", 18 | imgPath + "Effect/Girls/girl9.jpeg", 19 | imgPath + "Effect/Girls/girl10.jpeg", 20 | imgPath + "Effect/Girls/girl11.jpeg", 21 | imgPath + "Effect/Girls/girl12.jpeg", 22 | imgPath + "Effect/Girls/girl14.jpeg", 23 | imgPath + "Effect/Girls/girl15.jpeg" 24 | ] 25 | dirs: ["ToRight","ToBottom"] 26 | 27 | Item { 28 | width: 400 29 | height: 600 30 | anchors.centerIn: parent 31 | Repeater { 32 | model: images 33 | SBoard { 34 | anchors.fill: parent 35 | sourceItem: Image { source: images[index] } 36 | dir: c.dir 37 | state: index === c.currentIndex ? "show" : "hide" 38 | } 39 | } 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/Circle.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | PageSwitchBase { 6 | id: c 7 | anchors.fill: parent 8 | 9 | images:[ 10 | imgPath + "Effect/Girls/girl1.jpeg", 11 | imgPath + "Effect/Girls/girl2.jpeg", 12 | imgPath + "Effect/Girls/girl3.jpeg", 13 | imgPath + "Effect/Girls/girl4.jpeg", 14 | imgPath + "Effect/Girls/girl5.jpeg", 15 | imgPath + "Effect/Girls/girl6.jpeg", 16 | imgPath + "Effect/Girls/girl7.jpeg", 17 | imgPath + "Effect/Girls/girl8.jpeg", 18 | imgPath + "Effect/Girls/girl9.jpeg", 19 | imgPath + "Effect/Girls/girl10.jpeg", 20 | imgPath + "Effect/Girls/girl11.jpeg", 21 | imgPath + "Effect/Girls/girl12.jpeg", 22 | imgPath + "Effect/Girls/girl14.jpeg", 23 | imgPath + "Effect/Girls/girl15.jpeg" 24 | ] 25 | dirs: ["FromInner","FromOuter"] 26 | Item { 27 | width: 400 28 | height: 600 29 | anchors.centerIn: parent 30 | Repeater { 31 | model: images 32 | SCircle { 33 | anchors.fill: parent 34 | sourceItem: Image { source: images[index] } 35 | dir: c.dir 36 | state: index === c.currentIndex ? "show" : "hide" 37 | } 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/Cleavage.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | PageSwitchBase { 6 | id: c 7 | anchors.fill: parent 8 | 9 | images:[ 10 | imgPath + "Effect/Girls/girl1.jpeg", 11 | imgPath + "Effect/Girls/girl2.jpeg", 12 | imgPath + "Effect/Girls/girl3.jpeg", 13 | imgPath + "Effect/Girls/girl4.jpeg", 14 | imgPath + "Effect/Girls/girl5.jpeg", 15 | imgPath + "Effect/Girls/girl6.jpeg", 16 | imgPath + "Effect/Girls/girl7.jpeg", 17 | imgPath + "Effect/Girls/girl8.jpeg", 18 | imgPath + "Effect/Girls/girl9.jpeg", 19 | imgPath + "Effect/Girls/girl10.jpeg", 20 | imgPath + "Effect/Girls/girl11.jpeg", 21 | imgPath + "Effect/Girls/girl12.jpeg", 22 | imgPath + "Effect/Girls/girl14.jpeg", 23 | imgPath + "Effect/Girls/girl15.jpeg" 24 | ] 25 | dirs: ["HorizonToInner", 26 | "HorizonToOuter" , 27 | "VerticalToInner" , 28 | "VerticalToOuter" ] 29 | 30 | Item { 31 | width: 400 32 | height: 600 33 | anchors.centerIn: parent 34 | Repeater { 35 | model: images 36 | SCleavage { 37 | anchors.fill: parent 38 | sourceItem: Image { source: images[index] } 39 | dir: c.dir 40 | state: index === c.currentIndex ? "show" : "hide" 41 | } 42 | } 43 | } 44 | 45 | } 46 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/Cross.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | PageSwitchBase { 6 | id: c 7 | anchors.fill: parent 8 | 9 | images:[ 10 | imgPath + "Effect/Girls/girl1.jpeg", 11 | imgPath + "Effect/Girls/girl2.jpeg", 12 | imgPath + "Effect/Girls/girl3.jpeg", 13 | imgPath + "Effect/Girls/girl4.jpeg", 14 | imgPath + "Effect/Girls/girl5.jpeg", 15 | imgPath + "Effect/Girls/girl6.jpeg", 16 | imgPath + "Effect/Girls/girl7.jpeg", 17 | imgPath + "Effect/Girls/girl8.jpeg", 18 | imgPath + "Effect/Girls/girl9.jpeg", 19 | imgPath + "Effect/Girls/girl10.jpeg", 20 | imgPath + "Effect/Girls/girl11.jpeg", 21 | imgPath + "Effect/Girls/girl12.jpeg", 22 | imgPath + "Effect/Girls/girl14.jpeg", 23 | imgPath + "Effect/Girls/girl15.jpeg" 24 | ] 25 | dirs: ["FromInner","FromOuter"] 26 | Item { 27 | width: 400 28 | height: 600 29 | anchors.centerIn: parent 30 | Repeater { 31 | model: images 32 | SCross { 33 | anchors.fill: parent 34 | sourceItem: Image { source: images[index] } 35 | dir: c.dir 36 | state: index === c.currentIndex ? "show" : "hide" 37 | } 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/Diagonal.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | 6 | PageSwitchBase { 7 | id: c 8 | anchors.fill: parent 9 | 10 | images:[ 11 | imgPath + "Effect/Girls/girl1.jpeg", 12 | imgPath + "Effect/Girls/girl2.jpeg", 13 | imgPath + "Effect/Girls/girl3.jpeg", 14 | imgPath + "Effect/Girls/girl4.jpeg", 15 | imgPath + "Effect/Girls/girl5.jpeg", 16 | imgPath + "Effect/Girls/girl6.jpeg", 17 | imgPath + "Effect/Girls/girl7.jpeg", 18 | imgPath + "Effect/Girls/girl8.jpeg", 19 | imgPath + "Effect/Girls/girl9.jpeg", 20 | imgPath + "Effect/Girls/girl10.jpeg", 21 | imgPath + "Effect/Girls/girl11.jpeg", 22 | imgPath + "Effect/Girls/girl12.jpeg", 23 | imgPath + "Effect/Girls/girl14.jpeg", 24 | imgPath + "Effect/Girls/girl15.jpeg" 25 | ] 26 | dirs: ["FromLeftTop", 27 | "FromRightTop", 28 | "FromLeftBottom", 29 | "FromRightBottom"] 30 | Item { 31 | width: 400 32 | height: 600 33 | anchors.centerIn: parent 34 | Repeater { 35 | model: images 36 | SDiagonal { 37 | anchors.fill: parent 38 | sourceItem: Image { source: images[index] } 39 | dir: c.dir 40 | state: index === c.currentIndex ? "show" : "hide" 41 | } 42 | } 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/Dissolve.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | PageSwitchBase { 6 | id: c 7 | anchors.fill: parent 8 | 9 | images:[ 10 | imgPath + "Effect/Girls/girl1.jpeg", 11 | imgPath + "Effect/Girls/girl2.jpeg", 12 | imgPath + "Effect/Girls/girl3.jpeg", 13 | imgPath + "Effect/Girls/girl4.jpeg", 14 | imgPath + "Effect/Girls/girl5.jpeg", 15 | imgPath + "Effect/Girls/girl6.jpeg", 16 | imgPath + "Effect/Girls/girl7.jpeg", 17 | imgPath + "Effect/Girls/girl8.jpeg", 18 | imgPath + "Effect/Girls/girl9.jpeg", 19 | imgPath + "Effect/Girls/girl10.jpeg", 20 | imgPath + "Effect/Girls/girl11.jpeg", 21 | imgPath + "Effect/Girls/girl12.jpeg", 22 | imgPath + "Effect/Girls/girl14.jpeg", 23 | imgPath + "Effect/Girls/girl15.jpeg" 24 | ] 25 | Image { 26 | id: dissolveSrc1 27 | source: imgPath + "Effect/Dissolve_1.jpg" 28 | visible: false 29 | } 30 | Image { 31 | id: dissolveSrc2 32 | source: imgPath + "Effect/Dissolve_2.png" 33 | visible: false 34 | } 35 | Item { 36 | width: 400 37 | height: 600 38 | anchors.centerIn: parent 39 | Repeater { 40 | model: images 41 | SDissolve { 42 | anchors.fill: parent 43 | sourceItem: Image { source: images[index] } 44 | dissolveImage: dissolveSrc1 45 | state: index === c.currentIndex ? "show" : "hide" 46 | } 47 | } 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/FadeInOut.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | PageSwitchBase { 6 | id: c 7 | 8 | anchors.fill: parent 9 | 10 | images:[ 11 | imgPath + "Effect/Girls/girl1.jpeg", 12 | imgPath + "Effect/Girls/girl2.jpeg", 13 | imgPath + "Effect/Girls/girl3.jpeg", 14 | imgPath + "Effect/Girls/girl4.jpeg", 15 | imgPath + "Effect/Girls/girl5.jpeg", 16 | imgPath + "Effect/Girls/girl6.jpeg", 17 | imgPath + "Effect/Girls/girl7.jpeg", 18 | imgPath + "Effect/Girls/girl8.jpeg", 19 | imgPath + "Effect/Girls/girl9.jpeg", 20 | imgPath + "Effect/Girls/girl10.jpeg", 21 | imgPath + "Effect/Girls/girl11.jpeg", 22 | imgPath + "Effect/Girls/girl12.jpeg", 23 | imgPath + "Effect/Girls/girl14.jpeg", 24 | imgPath + "Effect/Girls/girl15.jpeg" 25 | ] 26 | Item { 27 | width: 400 28 | height: 600 29 | anchors.centerIn: parent 30 | Repeater { 31 | model: images 32 | SFadeInOut { 33 | anchors.fill: parent 34 | sourceItem: Image { source: images[index] } 35 | state: index === c.currentIndex ? "show" : "hide" 36 | } 37 | } 38 | } 39 | } 40 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/Grad.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | PageSwitchBase { 6 | id: c 7 | anchors.fill: parent 8 | 9 | images:[ 10 | imgPath + "Effect/Girls/girl1.jpeg", 11 | imgPath + "Effect/Girls/girl2.jpeg", 12 | imgPath + "Effect/Girls/girl3.jpeg", 13 | imgPath + "Effect/Girls/girl4.jpeg", 14 | imgPath + "Effect/Girls/girl5.jpeg", 15 | imgPath + "Effect/Girls/girl6.jpeg", 16 | imgPath + "Effect/Girls/girl7.jpeg", 17 | imgPath + "Effect/Girls/girl8.jpeg", 18 | imgPath + "Effect/Girls/girl9.jpeg", 19 | imgPath + "Effect/Girls/girl10.jpeg", 20 | imgPath + "Effect/Girls/girl11.jpeg", 21 | imgPath + "Effect/Girls/girl12.jpeg", 22 | imgPath + "Effect/Girls/girl14.jpeg", 23 | imgPath + "Effect/Girls/girl15.jpeg" 24 | ] 25 | dirs: ["FromLeft", "FromRight", "FromTop", "FromBottom"] 26 | Item { 27 | width: 400 28 | height: 600 29 | anchors.centerIn: parent 30 | Repeater { 31 | model: images 32 | SGrad { 33 | anchors.fill: parent 34 | sourceItem: Image { source: images[index] } 35 | dir: c.dir 36 | state: index === c.currentIndex ? "show" : "hide" 37 | } 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/Louver.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | PageSwitchBase { 6 | id: c 7 | anchors.fill: parent 8 | 9 | images:[ 10 | imgPath + "Effect/Girls/girl1.jpeg", 11 | imgPath + "Effect/Girls/girl2.jpeg", 12 | imgPath + "Effect/Girls/girl3.jpeg", 13 | imgPath + "Effect/Girls/girl4.jpeg", 14 | imgPath + "Effect/Girls/girl5.jpeg", 15 | imgPath + "Effect/Girls/girl6.jpeg", 16 | imgPath + "Effect/Girls/girl7.jpeg", 17 | imgPath + "Effect/Girls/girl8.jpeg", 18 | imgPath + "Effect/Girls/girl9.jpeg", 19 | imgPath + "Effect/Girls/girl10.jpeg", 20 | imgPath + "Effect/Girls/girl11.jpeg", 21 | imgPath + "Effect/Girls/girl12.jpeg", 22 | imgPath + "Effect/Girls/girl14.jpeg", 23 | imgPath + "Effect/Girls/girl15.jpeg" 24 | ] 25 | dirs: ["Horizon", "Vertical", "HorizonReverse", "VerticalReverse"] 26 | Item { 27 | width: 400 28 | height: 600 29 | anchors.centerIn: parent 30 | Repeater { 31 | model: images 32 | SLouver { 33 | anchors.fill: parent 34 | dir: c.dir 35 | sourceItem: Image { source: images[index]} 36 | state: index === c.currentIndex ? "show" : "hide" 37 | } 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/PageSwitchBase.qml: -------------------------------------------------------------------------------- 1 | import QtQml 2.0 2 | import QtQuick 2.9 3 | import QtQuick.Controls 2.2 4 | import TaoQuick 1.0 5 | 6 | Item { 7 | id: base 8 | property int currentIndex: -1 9 | property var images 10 | property int maxCount: images.length 11 | property var dirs 12 | property int dir: -1 13 | Component.onCompleted: { 14 | currentIndex = 0 15 | dir = 0 16 | } 17 | Column { 18 | anchors { 19 | left: parent.left 20 | bottom: parent.bottom 21 | margins: 10 22 | } 23 | CusSwitch { 24 | id: autoPlaySwitch 25 | text: qsTr("Auto Play") + trans.transString 26 | checked: true 27 | } 28 | CusComboBox { 29 | model: dirs 30 | visible: count > 0 31 | currentIndex: base.currentIndex 32 | implicitWidth: 180 33 | onCurrentIndexChanged: { 34 | if (base.dir !== currentIndex) { 35 | base.dir = currentIndex 36 | } 37 | } 38 | } 39 | } 40 | Timer { 41 | id: autoPlayTimer 42 | interval: 2800 43 | running: autoPlaySwitch.checked 44 | repeat: true 45 | property bool reserve: false 46 | triggeredOnStart: true 47 | onTriggered: { 48 | if (reserve) { 49 | base.currentIndex-- 50 | } else { 51 | base.currentIndex++ 52 | } 53 | if (base.currentIndex >= images.length - 1) { 54 | reserve = true 55 | } else if (base.currentIndex <= 0) { 56 | reserve = false 57 | } 58 | } 59 | } 60 | } 61 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/Rhombus.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | PageSwitchBase { 6 | id: c 7 | anchors.fill: parent 8 | 9 | images:[ 10 | imgPath + "Effect/Girls/girl1.jpeg", 11 | imgPath + "Effect/Girls/girl2.jpeg", 12 | imgPath + "Effect/Girls/girl3.jpeg", 13 | imgPath + "Effect/Girls/girl4.jpeg", 14 | imgPath + "Effect/Girls/girl5.jpeg", 15 | imgPath + "Effect/Girls/girl6.jpeg", 16 | imgPath + "Effect/Girls/girl7.jpeg", 17 | imgPath + "Effect/Girls/girl8.jpeg", 18 | imgPath + "Effect/Girls/girl9.jpeg", 19 | imgPath + "Effect/Girls/girl10.jpeg", 20 | imgPath + "Effect/Girls/girl11.jpeg", 21 | imgPath + "Effect/Girls/girl12.jpeg", 22 | imgPath + "Effect/Girls/girl14.jpeg", 23 | imgPath + "Effect/Girls/girl15.jpeg" 24 | ] 25 | dirs: ["FromInner","FromOuter"] 26 | Item { 27 | width: 400 28 | height: 600 29 | anchors.centerIn: parent 30 | Repeater { 31 | model: images 32 | SRhombus { 33 | anchors.fill: parent 34 | sourceItem: Image { source: images[index] } 35 | dir: c.dir 36 | state: index === c.currentIndex ? "show" : "hide" 37 | } 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/Sector.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | PageSwitchBase { 6 | id: c 7 | anchors.fill: parent 8 | 9 | images:[ 10 | imgPath + "Effect/Girls/girl1.jpeg", 11 | imgPath + "Effect/Girls/girl2.jpeg", 12 | imgPath + "Effect/Girls/girl3.jpeg", 13 | imgPath + "Effect/Girls/girl4.jpeg", 14 | imgPath + "Effect/Girls/girl5.jpeg", 15 | imgPath + "Effect/Girls/girl6.jpeg", 16 | imgPath + "Effect/Girls/girl7.jpeg", 17 | imgPath + "Effect/Girls/girl8.jpeg", 18 | imgPath + "Effect/Girls/girl9.jpeg", 19 | imgPath + "Effect/Girls/girl10.jpeg", 20 | imgPath + "Effect/Girls/girl11.jpeg", 21 | imgPath + "Effect/Girls/girl12.jpeg", 22 | imgPath + "Effect/Girls/girl14.jpeg", 23 | imgPath + "Effect/Girls/girl15.jpeg" 24 | ] 25 | Item { 26 | width: 400 27 | height: 600 28 | anchors.centerIn: parent 29 | Repeater { 30 | model: images 31 | SSector { 32 | anchors.fill: parent 33 | sourceItem: Image { source: images[index] } 34 | state: index === c.currentIndex ? "show" : "hide" 35 | } 36 | } 37 | } 38 | } 39 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/Square.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | PageSwitchBase { 6 | id: c 7 | anchors.fill: parent 8 | 9 | images:[ 10 | imgPath + "Effect/Girls/girl1.jpeg", 11 | imgPath + "Effect/Girls/girl2.jpeg", 12 | imgPath + "Effect/Girls/girl3.jpeg", 13 | imgPath + "Effect/Girls/girl4.jpeg", 14 | imgPath + "Effect/Girls/girl5.jpeg", 15 | imgPath + "Effect/Girls/girl6.jpeg", 16 | imgPath + "Effect/Girls/girl7.jpeg", 17 | imgPath + "Effect/Girls/girl8.jpeg", 18 | imgPath + "Effect/Girls/girl9.jpeg", 19 | imgPath + "Effect/Girls/girl10.jpeg", 20 | imgPath + "Effect/Girls/girl11.jpeg", 21 | imgPath + "Effect/Girls/girl12.jpeg", 22 | imgPath + "Effect/Girls/girl14.jpeg", 23 | imgPath + "Effect/Girls/girl15.jpeg" 24 | ] 25 | dirs: ["FromInner","FromOuter"] 26 | Item { 27 | width: 400 28 | height: 600 29 | anchors.centerIn: parent 30 | Repeater { 31 | model: images 32 | SSquare { 33 | anchors.fill: parent 34 | sourceItem: Image { source: images[index] } 35 | dir: c.dir 36 | state: index === c.currentIndex ? "show" : "hide" 37 | } 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/PageSwitch/Wheel.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | PageSwitchBase { 6 | id: c 7 | anchors.fill: parent 8 | 9 | images:[ 10 | imgPath + "Effect/Girls/girl1.jpeg", 11 | imgPath + "Effect/Girls/girl2.jpeg", 12 | imgPath + "Effect/Girls/girl3.jpeg", 13 | imgPath + "Effect/Girls/girl4.jpeg", 14 | imgPath + "Effect/Girls/girl5.jpeg", 15 | imgPath + "Effect/Girls/girl6.jpeg", 16 | imgPath + "Effect/Girls/girl7.jpeg", 17 | imgPath + "Effect/Girls/girl8.jpeg", 18 | imgPath + "Effect/Girls/girl9.jpeg", 19 | imgPath + "Effect/Girls/girl10.jpeg", 20 | imgPath + "Effect/Girls/girl11.jpeg", 21 | imgPath + "Effect/Girls/girl12.jpeg", 22 | imgPath + "Effect/Girls/girl14.jpeg", 23 | imgPath + "Effect/Girls/girl15.jpeg" 24 | ] 25 | dirs: ["Clockwise","CounterClockwise"] 26 | Item { 27 | width: 400 28 | height: 600 29 | anchors.centerIn: parent 30 | Repeater { 31 | model: images 32 | SWheel { 33 | anchors.fill: parent 34 | sourceItem: Image { source: images[index] } 35 | dir: c.dir 36 | state: index === c.currentIndex ? "show" : "hide" 37 | } 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/ShaderEffect/Planet1.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Contents/ShaderEffect/Planet1.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/ShapeGallery/ShapeCapStyles.qml: -------------------------------------------------------------------------------- 1 | import QtQml 2.0 2 | import QtQuick 2.12 3 | import QtQuick.Controls 2.12 4 | import QtQuick.Shapes 1.12 5 | 6 | Rectangle { 7 | color: "lightGray" 8 | 9 | Shape { 10 | anchors.centerIn: parent 11 | width: 200 12 | height: 100 13 | 14 | ShapePath { 15 | id: rootPath 16 | strokeColor: "black" 17 | strokeWidth: 20 18 | 19 | property int index: 0 20 | property variant styles: [ ShapePath.FlatCap, ShapePath.SquareCap, ShapePath.RoundCap ] 21 | property variant styleText: [ "FlatCap", "SquareCap", "RoundCap" ] 22 | 23 | capStyle: styles[index] 24 | startX: 40; startY: 30 25 | 26 | PathLine { x: 40; y: 100} 27 | PathLine { x: 80; y: 100 } 28 | PathLine { x: 80; y: 30} 29 | PathLine { x: 160; y: 30} 30 | PathLine { x: 160; y: 100} 31 | } 32 | } 33 | 34 | Timer { 35 | interval: 1000 36 | repeat: true 37 | running: true 38 | onTriggered: rootPath.index = (rootPath.index + 1) % 3 39 | } 40 | 41 | Text { 42 | anchors.left: parent.left 43 | text: rootPath.styleText[rootPath.index] 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/ShapeGallery/ShapeCircle.qml: -------------------------------------------------------------------------------- 1 | import QtQml 2.0 2 | import QtQuick 2.12 3 | import QtQuick.Controls 2.12 4 | import QtQuick.Shapes 1.12 5 | 6 | 7 | Rectangle { 8 | width: 120 9 | height: 120 10 | color: th.pressed ? "steelBlue" : "lightGray" 11 | 12 | TapHandler { id: th } 13 | 14 | Shape { 15 | id: circ 16 | anchors.fill: parent 17 | 18 | SequentialAnimation on opacity { 19 | loops: Animation.Infinite 20 | NumberAnimation { from: 1.0; to: 0.0; duration: 5000 } 21 | NumberAnimation { from: 0.0; to: 1.0; duration: 5000 } 22 | } 23 | 24 | ShapePath { 25 | id: shapePath 26 | strokeWidth: 3 27 | strokeColor: "black" 28 | fillColor: "white" 29 | 30 | property real r: 40 31 | startX: circ.width / 2 - r 32 | startY: circ.height / 2 - r 33 | PathArc { 34 | x: circ.width / 2 + shapePath.r 35 | y: circ.height / 2 + shapePath.r 36 | radiusX: shapePath.r; radiusY: shapePath.r 37 | useLargeArc: true 38 | } 39 | PathArc { 40 | x: circ.width / 2 - shapePath.r 41 | y: circ.height / 2 - shapePath.r 42 | radiusX: shapePath.r; radiusY: shapePath.r 43 | useLargeArc: true 44 | } 45 | } 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/ShapeGallery/ShapeEllipse.qml: -------------------------------------------------------------------------------- 1 | import QtQml 2.12 2 | import QtQuick 2.12 3 | import QtQuick.Controls 2.12 4 | import QtQuick.Shapes 1.12 5 | 6 | 7 | Rectangle { 8 | width: 120 9 | height: 120 10 | color: th.pressed ? "steelBlue" : "lightGray" 11 | 12 | TapHandler { id: th } 13 | 14 | Shape { 15 | id: shape 16 | anchors.fill: parent 17 | 18 | ShapePath { 19 | id: p 20 | strokeWidth: 3 21 | strokeColor: "black" 22 | fillColor: "white" 23 | 24 | property real xr: 70 25 | property real yr: 30 26 | startX: shape.width / 2 - xr 27 | startY: shape.height / 2 - yr 28 | PathArc { 29 | x: shape.width / 2 + p.xr 30 | y: shape.height / 2 + p.yr 31 | radiusX: p.xr; radiusY: p.yr 32 | useLargeArc: true 33 | } 34 | PathArc { 35 | x: shape.width / 2 - p.xr 36 | y: shape.height / 2 - p.yr 37 | radiusX: p.xr; radiusY: p.yr 38 | useLargeArc: true 39 | } 40 | } 41 | } 42 | } 43 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/ShapeGallery/ShapeEllipticalArc.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.12 2 | import QtQuick.Shapes 1.12 3 | 4 | 5 | Rectangle { 6 | color: "lightGray" 7 | Shape { 8 | id: shape 9 | width: 220 10 | height: 200 11 | anchors.centerIn: parent 12 | 13 | ShapePath { 14 | startX: 0; startY: 100 15 | fillColor: "white" 16 | strokeColor: "black" 17 | PathArc { 18 | relativeX: 50; relativeY: 0 // === x:50; y:100 19 | radiusX: 25; radiusY: 25 20 | } 21 | PathArc { 22 | relativeX: 50; relativeY: 0 23 | radiusX: 25; radiusY: 35 24 | } 25 | PathArc { 26 | x: 150; y: 100 // === relativeX: 50; y: 100 27 | radiusX: 25; radiusY: 60 28 | } 29 | PathArc { 30 | relativeX: 50; y: 100 31 | radiusX: 25; radiusY: 25 32 | } 33 | } 34 | } 35 | 36 | Shape { 37 | width: 220 38 | height: 100 39 | 40 | anchors.left: parent.left 41 | anchors.bottom: parent.bottom 42 | anchors.bottomMargin: 10 43 | 44 | scale: 0.5 45 | 46 | ShapePath { 47 | fillColor: "white" 48 | strokeColor: "black" 49 | strokeWidth: 10 50 | 51 | // Defines an arc with the given radii and center 52 | PathAngleArc { 53 | centerX: 110; centerY: 95 54 | radiusX: 45; radiusY: 45 55 | sweepAngle:360 56 | } 57 | } 58 | } 59 | } 60 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/ShapeGallery/ShapeJoinStyles.qml: -------------------------------------------------------------------------------- 1 | import QtQml 2.12 2 | import QtQuick 2.12 3 | import QtQuick.Controls 2.12 4 | import QtQuick.Shapes 1.12 5 | 6 | 7 | Rectangle { 8 | color: "lightGray" 9 | 10 | Shape { 11 | width: 120 12 | height: 120 13 | anchors.centerIn: parent 14 | 15 | ShapePath { 16 | id: rootPath 17 | 18 | strokeColor: "black" 19 | strokeWidth: 20 20 | capStyle: ShapePath.RoundCap 21 | 22 | property int index: 0 23 | property variant styles: [ ShapePath.BevelJoin, ShapePath.MiterJoin, ShapePath.RoundJoin ] 24 | property variant styleText: [ "BevelJoin", "MiterJoin", "RoundJoin" ] 25 | 26 | joinStyle: styles[index] 27 | 28 | startX: 30 29 | startY: 30 30 | PathLine { x: 100; y: 30 } 31 | PathLine { x: 100; y: 100 } 32 | PathLine { x: 30; y: 100 } 33 | PathLine { x: 30; y: 30 } 34 | } 35 | } 36 | 37 | Timer { 38 | interval: 1000 39 | repeat: true 40 | running: true 41 | onTriggered: rootPath.index = (rootPath.index + 1) % 3 42 | } 43 | 44 | Text { 45 | anchors.left: parent.left 46 | text: rootPath.styleText[rootPath.index] 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/ShapeGallery/ShapeQuadraticBezier.qml: -------------------------------------------------------------------------------- 1 | import QtQml 2.12 2 | import QtQuick 2.12 3 | import QtQuick.Controls 2.12 4 | import QtQuick.Shapes 1.12 5 | 6 | 7 | Rectangle { 8 | color: "lightGray" 9 | 10 | Item { 11 | width: 200 12 | height: 100 13 | anchors.centerIn: parent 14 | 15 | Shape { 16 | id: shape 17 | anchors.fill: parent 18 | 19 | ShapePath { 20 | strokeWidth: 4 21 | strokeColor: "black" 22 | 23 | startX: 30 24 | startY: 60 25 | // Defines a quadratic Bezier curve with a control point 26 | PathQuad { 27 | x: 170; y: 60 28 | controlX: circle.x; controlY: circle.y 29 | } 30 | } 31 | } 32 | 33 | Rectangle { 34 | id: circle 35 | color: "blue" 36 | width: 10 37 | height: 10 38 | radius: 5 39 | SequentialAnimation on x { 40 | // the animation will continuously repeat until it is explicitly stopped 41 | loops: Animation.Infinite 42 | NumberAnimation { 43 | from: 0 44 | to: 200 45 | duration: 5000 46 | } 47 | } 48 | } 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/ShapeGallery/ShapeRectrangle.qml: -------------------------------------------------------------------------------- 1 | import QtQml 2.12 2 | import QtQuick 2.12 3 | import QtQuick.Controls 2.12 4 | import QtQuick.Shapes 1.12 5 | 6 | 7 | Rectangle { 8 | id:root 9 | width: 120 10 | height: 120 11 | color: th.pressed ? "steelBlue" : "lightGray" 12 | containmentMask: ctr 13 | 14 | TapHandler { id: th } 15 | 16 | Shape { 17 | id: ctr 18 | anchors.fill: parent 19 | containsMode: Shape.FillContains 20 | 21 | ShapePath { 22 | strokeColor: "white" 23 | fillColor: "white" 24 | strokeWidth: 3 25 | 26 | startX: 90; startY: 90 27 | PathLine { x: 180; y: 90 } 28 | PathLine { x: 180; y: 180} 29 | PathLine { x: 90; y: 180 } 30 | PathLine { x: 90; y: 90 } 31 | } 32 | 33 | NumberAnimation on rotation { 34 | from: 0 35 | to: 360 36 | duration: 5000 37 | loops: Animation.Infinite 38 | } 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Contents/ShapeGallery/ShapeTriangle.qml: -------------------------------------------------------------------------------- 1 | import QtQml 2.12 2 | import QtQuick 2.12 3 | import QtQuick.Controls 2.12 4 | import QtQuick.Shapes 1.12 5 | 6 | 7 | Rectangle { 8 | width: 120 9 | height: 120 10 | color: th.pressed ? "steelBlue" : "lightGray" 11 | containmentMask: ctr 12 | 13 | TapHandler { id: th } 14 | 15 | Shape { 16 | id: ctr 17 | anchors.fill: parent 18 | containsMode: Shape.FillContains 19 | 20 | ShapePath { 21 | strokeColor: "black" 22 | fillColor: "white" 23 | strokeWidth: 3 24 | 25 | SequentialAnimation on strokeColor { 26 | loops: Animation.Infinite 27 | ColorAnimation { 28 | from: "black" 29 | to: "green" 30 | duration: 5000 31 | } 32 | ColorAnimation { 33 | from: "green" 34 | to: "yellow" 35 | duration: 5000 36 | } 37 | ColorAnimation { 38 | from: "yellow" 39 | to: "black" 40 | duration: 5000 41 | } 42 | } 43 | 44 | startX: ctr.width/2; startY: 80 45 | PathLine { x: ctr.width/2 + 50; y: 80 + 100 } 46 | PathLine { x: ctr.width/2 - 50; y: 80 + 100 } 47 | PathLine { x: ctr.width/2; y: 80 } 48 | } 49 | } 50 | } 51 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Button/download_black.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Button/download_black.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Button/download_blue.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Button/download_blue.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Button/download_gray.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Button/download_gray.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Button/download_red.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Button/download_red.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Button/download_white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Button/download_white.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Button/expand.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Button/expand.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Common/left.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Common/left.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Common/left_hovered.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Common/left_hovered.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Common/menu.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Common/menu.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Common/right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Common/right.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Common/right_hovered.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Common/right_hovered.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Common/view.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Common/view.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Common/windmill.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Common/windmill.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Common/wizard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Common/wizard.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Dissolve_1.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Dissolve_1.jpg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Dissolve_2.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Dissolve_2.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl1.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl1.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl10.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl10.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl11.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl11.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl12.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl12.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl14.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl14.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl15.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl15.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl2.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl2.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl3.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl3.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl4.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl4.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl5.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl5.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl6.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl6.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl7.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl7.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl8.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl8.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/Girls/girl9.jpeg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/Girls/girl9.jpeg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/arrow.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/astronomy.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/astronomy.jpg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/baby.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/baby.jpg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/girl.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/girl.jpg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Effect/soundRect.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Effect/soundRect.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Tao/weixin.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Tao/weixin.jpg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Tao/zhifubao.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Tao/zhifubao.jpg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/about_gray.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/about_gray.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/about_white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/about_white.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/close_gray.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/close_gray.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/close_white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/close_white.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/flower.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/flower.jpg -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/lang_gray.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/lang_gray.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/lang_white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/lang_white.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/max_gray.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/max_gray.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/max_white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/max_white.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/minimal_gray.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/minimal_gray.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/minimal_white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/minimal_white.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/normal_gray.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/normal_gray.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/normal_white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/normal_white.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/settings_gray.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/settings_gray.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/settings_white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/settings_white.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/skin_gray.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/skin_gray.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/Window/skin_white.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/Window/skin_white.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/logo/milk.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/logo/milk.ico -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/logo/milk.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/logo/milk.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/logo/milk_32.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/logo/milk_32.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Image/logo/milk_48.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Image/logo/milk_48.png -------------------------------------------------------------------------------- /examples/TaoQuickShow/Qml.qrc: -------------------------------------------------------------------------------- 1 | 2 | 3 | Qml/main.qml 4 | Qml/Biz/CircleText.qml 5 | Qml/Biz/CloseBtn.qml 6 | Qml/Biz/LangBtn.qml 7 | Qml/Biz/SkinBtn.qml 8 | Qml/Page/ControlsShow.qml 9 | Qml/Pane/LeftPane.qml 10 | Qml/Pane/RightPane.qml 11 | Qml/Pane/TitlePane.qml 12 | Qml/Page/Home.qml 13 | Qml/Pane/ContentModel.qml 14 | Qml/Dialog/AboutDialog.qml 15 | Qml/Dialog/SettingsDialog.qml 16 | Qml/Biz/ExpandBtn.qml 17 | 18 | 19 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Qml/Biz/CircleText.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.0 2 | import QtQuick.Controls 2.0 3 | import TaoQuick 1.0 4 | 5 | Rectangle { 6 | width: 28 7 | height: width 8 | radius: width / 2 9 | color: CusConfig.themeColor 10 | border.width: CusConfig.controlBorderRadius 11 | border.color: CusConfig.controlBorderColor 12 | property alias text: t.text 13 | property alias textItem: t 14 | 15 | BasicText { 16 | id: t 17 | anchors.centerIn: parent 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Qml/Biz/CloseBtn.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | 3 | import TaoQuick 1.0 4 | 5 | CusButton_Image { 6 | implicitWidth: 24 7 | implicitHeight: 24 8 | tipText: qsTr("Close") + trans.transString 9 | btnImgUrl: imgPath + (hovered || pressed ? "Window/close_white.png" : "Window/close_gray.png") 10 | } 11 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Qml/Biz/ExpandBtn.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.0 2 | import QtQuick.Controls 2.0 3 | import TaoQuick 1.0 4 | 5 | CusButton { 6 | id: expandBtn 7 | property bool isOpened: true 8 | contentItem: BasicText { 9 | x: 0 10 | text: expandBtn.text 11 | color: expandBtn.textColor 12 | horizontalAlignment: Text.AlignLeft 13 | } 14 | background: Rectangle { 15 | width: expandBtn.width 16 | height: expandBtn.height 17 | color: expandBtn.pressed ? CusConfig.controlBorderColor_pressed : (expandBtn.hovered ? CusConfig.controlBorderColor_hovered : CusConfig.controlColor) 18 | radius: 2 19 | CusImage { 20 | source: imgPath + "Button/expand.png" 21 | anchors { 22 | right: parent.right 23 | rightMargin: 14 24 | } 25 | rotation: expandBtn.isOpened ? 180 : 0 26 | Behavior on rotation { 27 | NumberAnimation { 28 | duration: 200 29 | } 30 | } 31 | } 32 | } 33 | } 34 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Qml/Biz/LangBtn.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | CusButton_Image { 6 | btnImgUrl: imgPath + (hovered 7 | || pressed ? "Window/lang_white.png" : "Window/lang_gray.png") 8 | tipText: qsTr("Language") + trans.transString 9 | onClicked: { 10 | pop.show() 11 | } 12 | CusPopup { 13 | id: pop 14 | barColor: CusConfig.controlColor 15 | backgroundWidth: 100 16 | backgroundHeight: langListView.contentHeight > 500 ? 500 : langListView.contentHeight + 2 17 | contentItem: ListView { 18 | id: langListView 19 | anchors.fill: parent 20 | anchors.margins: 2 21 | model: trans.languages 22 | interactive: false 23 | clip: true 24 | delegate: Item { 25 | width: langListView.width 26 | height: 36 27 | CusButton { 28 | id: dBtn 29 | anchors { 30 | fill: parent 31 | margins: 4 32 | } 33 | text: modelData 34 | backgroundColor: trans.currentLang === modelData ? CusConfig.controlColor_pressed : (hovered || pressed ? CusConfig.controlColor_hovered : pop.barColor) 35 | textColor: CusConfig.textColor 36 | borderWidth: 0 37 | radius: 4 38 | onClicked: { 39 | trans.setCurrentLang(modelData) 40 | } 41 | } 42 | } 43 | } 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Qml/Dialog/SettingsDialog.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import QtQuick.Window 2.9 4 | import TaoQuick 1.0 5 | 6 | Popup { 7 | id: root 8 | width: 600 9 | height: 340 10 | 11 | 12 | function showParentCenter() { 13 | x = (parent.width - width) / 2 14 | y = (parent.height - height) / 2 15 | open() 16 | } 17 | 18 | function showScreenCenter() { 19 | var globalX = (Screen.desktopAvailableWidth - width) / 2 20 | var globalY = (Screen.desktopAvailableHeight - height) / 2 21 | var pos = parent.mapFromGlobal(globalX, globalY) 22 | x = pos.x 23 | y = pos.y 24 | open() 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Qml/Page/ControlsShow.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import TaoQuick 1.0 4 | 5 | Column { 6 | anchors.centerIn: parent 7 | spacing: 10 8 | Row { 9 | spacing: 10 10 | CusButton { 11 | width: 80 12 | height: 30 13 | text: "Hello With Tip" 14 | tipText: "Hello Button" 15 | } 16 | CusButton { 17 | width: 80 18 | height: 30 19 | text: "Hello Disable" 20 | enabled: false 21 | } 22 | CusButton_Gradient { 23 | width: 80 24 | height: 30 25 | text: "Hello Gradient" 26 | tipText: "Hello Gradient" 27 | } 28 | } 29 | Row { 30 | spacing: 10 31 | CusSwitch {} 32 | CusSwitch { 33 | checked: true 34 | } 35 | } 36 | Row { 37 | spacing: 10 38 | CusCheckBox { 39 | text: "unchecked" 40 | } 41 | CusCheckBox { 42 | checked: true 43 | text: "checked" 44 | } 45 | CusCheckBox { 46 | enabled: false 47 | text: "disable" 48 | } 49 | CusCheckBox { 50 | enabled: false 51 | checked: true 52 | text: "disable & checked" 53 | } 54 | } 55 | CusComboBox { 56 | model: 10 57 | width: 120 58 | } 59 | CusSlider { 60 | width: 200 61 | from: 0 62 | to: 200 63 | } 64 | CusSlider_Spin { 65 | width: 200 66 | from: 0 67 | to: 100 68 | } 69 | CusSpinBox_HourMinute { 70 | width: 200 71 | } 72 | CusTextField { 73 | width: 200 74 | } 75 | CusTextField_Search { 76 | width: 200 77 | } 78 | } 79 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Src/AppInfo.cpp: -------------------------------------------------------------------------------- 1 | #include "AppInfo.h" 2 | #include "Ver-u8.h" 3 | 4 | #ifdef USE_VISUAL_STUDIO 5 | #include "taoVersionInfo.h" 6 | #endif 7 | 8 | #include 9 | #include 10 | AppInfo::AppInfo(QObject* parent) 11 | : QObject(parent) 12 | { 13 | m_appName = VER_PRODUCTNAME_STR; 14 | m_appVersion = TaoVer; 15 | m_latestVersion = TaoVer; 16 | m_buildDateTime = TaoDATETIME; 17 | m_buildRevision = TaoREVISIONSTR; 18 | m_copyRight = VER_LEGALCOPYRIGHT_STR; 19 | m_descript = QString::fromLocal8Bit(VER_FILEDESCRIPTION_STR); 20 | m_compilerVendor = QString("%1(%2 %3)").arg(QT_VERSION_STR).arg(CXX_COMPILER_ID).arg(QSysInfo::buildCpuArchitecture()); 21 | } 22 | 23 | void AppInfo::beforeUiReady(QQmlContext* ctx) 24 | { 25 | ctx->setContextProperty("appInfo", this); 26 | } 27 | 28 | void AppInfo::afterUiReady() 29 | { 30 | 31 | // auto json = QJsonDocument(*this).toJson(QJsonDocument::Indented); 32 | // json.replace("\\n\\r","\\\n"); 33 | // qWarning() << json; 34 | } 35 | 36 | AppInfo::~AppInfo() { } 37 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Src/AppInfo.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include "Common/JsonSerialize.h" 4 | #include "Common/PropertyHelper.h" 5 | #include 6 | #include 7 | #include 8 | class AppInfo : public QObject 9 | { 10 | Q_OBJECT 11 | 12 | AUTO_PROPERTY(QString, appName, "") 13 | AUTO_PROPERTY(QString, appVersion, "") 14 | AUTO_PROPERTY(QString, latestVersion, "") 15 | AUTO_PROPERTY(QString, buildDateTime, "") 16 | AUTO_PROPERTY(QString, buildRevision, "") 17 | AUTO_PROPERTY(QString, copyRight, "") 18 | AUTO_PROPERTY(QString, descript, "") 19 | AUTO_PROPERTY(QString, compilerVendor, "") 20 | AUTO_PROPERTY(bool, splashShow, false) 21 | AUTO_PROPERTY(float, scale, 1.0f) 22 | AUTO_PROPERTY(double, ratio, 14.0 / 9.0) 23 | AUTO_PROPERTY(QStringList, customs, {}) 24 | 25 | public: 26 | explicit AppInfo(QObject* parent = nullptr); 27 | virtual ~AppInfo() override; 28 | 29 | public: 30 | void beforeUiReady(QQmlContext* ctx); 31 | 32 | void afterUiReady(); 33 | }; 34 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Src/DeviceAddTable/DeviceAddItem.cpp: -------------------------------------------------------------------------------- 1 | #include "DeviceAddItem.h" 2 | #include 3 | DeviceAddItem::DeviceAddItem(QObject* parent) 4 | : QuickListItemBase(parent) 5 | { 6 | connect(this, &DeviceAddItem::addressChanged, this, [this]() { m_ipv4Address = QHostAddress(address()).toIPv4Address(); }); 7 | } 8 | 9 | DeviceAddItem::~DeviceAddItem() { } 10 | bool DeviceAddItem::match(const QString& key) 11 | { 12 | if (key.isEmpty()) 13 | { 14 | return true; 15 | } 16 | if (m_name.contains(key, Qt::CaseInsensitive)) 17 | { 18 | return true; 19 | } 20 | if (m_address.contains(key, Qt::CaseInsensitive)) 21 | { 22 | return true; 23 | } 24 | if (m_modelString.contains(key, Qt::CaseInsensitive)) 25 | { 26 | return true; 27 | } 28 | return false; 29 | } -------------------------------------------------------------------------------- /examples/TaoQuickShow/Src/DeviceAddTable/DeviceAddItem.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include "Common/PropertyHelper.h" 4 | #include "QuickModel/QuickListItemBase.h" 5 | #include 6 | class DeviceAddItem : public QuickListItemBase 7 | { 8 | Q_OBJECT 9 | 10 | AUTO_PROPERTY(QString, name, "") 11 | AUTO_PROPERTY(QString, address, "") 12 | AUTO_PROPERTY(QString, modelString, "") 13 | AUTO_PROPERTY(bool, online, false) 14 | 15 | public: 16 | explicit DeviceAddItem(QObject* parent = nullptr); 17 | virtual ~DeviceAddItem() override; 18 | 19 | bool match(const QString& key) override; 20 | quint32 toIPv4Address() const 21 | { 22 | return m_ipv4Address; 23 | } 24 | 25 | private: 26 | quint32 m_ipv4Address = 0; 27 | }; 28 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Src/DeviceAddTable/DeviceAddModel.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #include "QuickModel/QuickListModel.h" 4 | #include 5 | class DeviceAddModelPrivate; 6 | class DeviceAddItem; 7 | class DeviceAddModel : public QuickListModel 8 | { 9 | Q_OBJECT 10 | using Super = QuickListModel; 11 | 12 | public: 13 | explicit DeviceAddModel(QObject* parent = nullptr); 14 | virtual ~DeviceAddModel() override; 15 | public slots: 16 | void doUpdateName(int row, const QString& name); 17 | 18 | void initData(); 19 | 20 | void addOne(); 21 | void addMulti(int count); 22 | 23 | void insertBeforeSelected(); 24 | void insertBeforeRow(int row); 25 | 26 | void clearAll(); 27 | 28 | void removeSelected(); 29 | void removeChecked(); 30 | void removeRow(int row); 31 | 32 | private: 33 | DeviceAddItem* genOne(uint32_t value); 34 | 35 | private: 36 | DeviceAddModelPrivate* d; 37 | }; 38 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Src/stdafx.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | /* Add C includes here */ 3 | 4 | /* Add C++ includes here */ 5 | #if defined __cplusplus 6 | #include 7 | #include 8 | #include 9 | #include 10 | #include 11 | #include 12 | #include 13 | #include 14 | #include 15 | #include 16 | #include 17 | #include 18 | #include 19 | #include 20 | #include 21 | #include 22 | #include 23 | 24 | #include 25 | #include 26 | #include 27 | #include 28 | #include 29 | 30 | #endif 31 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/TaoQuickShow.pri: -------------------------------------------------------------------------------- 1 | #一部分头文件加入编译预处理,提高编译速度 2 | PRECOMPILED_HEADER = $$PWD/Src/stdafx.h 3 | 4 | HEADERS += \ 5 | $$PWD/Src/AppInfo.h \ 6 | $$PWD/Src/DeviceAddTable/DeviceAddItem.h \ 7 | $$PWD/Src/DeviceAddTable/DeviceAddModel.h 8 | 9 | SOURCES += \ 10 | $$PWD/Src/AppInfo.cpp \ 11 | $$PWD/Src/DeviceAddTable/DeviceAddItem.cpp \ 12 | $$PWD/Src/DeviceAddTable/DeviceAddModel.cpp \ 13 | $$PWD/Src/main.cpp 14 | 15 | CONFIG(debug, debug|release) { 16 | #debug模式直接用本地qml文件,不要qrc资源文件。这样调试快一些。 17 | win32{ 18 | path=$$system("cd") 19 | path ~=s,\\\\,/,g 20 | } else { 21 | path=$$system("pwd") 22 | } 23 | DEFINES +=TaoQuickShowPath=\\\"file:///$${path}/\\\" 24 | 25 | OTHER_FILES += $$files($$path/Qml/*.qml, true) 26 | OTHER_FILES += $$files($$path/Contents/*.qml, true) 27 | 28 | } else { 29 | #release模式用qrc、走资源文件。这样发布不会携带源码。 30 | RESOURCES += \ 31 | $$PWD/Qml.qrc \ 32 | $$PWD/Image.qrc \ 33 | $$PWD/Contents.qrc 34 | DEFINES +=TaoQuickShowPath=\\\"qrc:/\\\" 35 | } 36 | 37 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/TaoQuickShow.pro: -------------------------------------------------------------------------------- 1 | TEMPLATE = app 2 | TARGET = TaoQuickShow 3 | 4 | QT += core gui qml quick 5 | 6 | CONFIG += c++17 qtquickcompiler utf8_source 7 | win32:mingw { 8 | LIBS += -lDwmapi 9 | } 10 | 11 | load(taoVersion) 12 | setTaoVersion() 13 | 14 | load(taoBundle) 15 | BundlePath = $$getBundlePath("TaoQuickShow") 16 | 17 | #load(taoBuildPath) 18 | #setBuildPath($${TaoQuick_BUILD_TREE}/$${TARGET}) 19 | 20 | CONFIG(debug,debug|release) { 21 | DESTDIR = $${TaoQuick_RUN_TREE}/debug 22 | DEFINES += TAODEBUG 23 | } else { 24 | DESTDIR = $${TaoQuick_RUN_TREE}/release 25 | } 26 | #!exists($${TaoQuick_3RDPARTY_TREE}/TaoCommon/src/TaoCommon/TaoCommon.pri) { 27 | # error("3rdparty library TaoCommon missing, please update by command: git submodule update --init") 28 | #} 29 | include($${TaoQuick_3RDPARTY_TREE}/TaoCommon/src/TaoCommon/TaoCommon.pri) 30 | include($${TaoQuick_SOURCE_TREE}/src/TaoQuick.pri) 31 | include(TaoQuickShow.pri) 32 | 33 | win32:!mingw { 34 | RC_FILE = App.rc 35 | } 36 | macos { 37 | ICON = milk.icns 38 | } 39 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/Ver-u16.h: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/Ver-u16.h -------------------------------------------------------------------------------- /examples/TaoQuickShow/Ver-u8.h: -------------------------------------------------------------------------------- 1 | #pragma once 2 | 3 | #define RELEASE_VER 1 // 0: beta version; 1: release version 4 | #define RELEASE_DATE __DATE__ // yyyy-mm-dd; only used for RELEASE_VER=1 5 | 6 | #define RELEASE_TIME __TIME__ // hh:mm:ss 7 | 8 | #define RELEASE_VER_MAIN TaoMAJ 9 | #define RELEASE_VER_MAIN2 TaoMIN 10 | #define RELEASE_VER_SUB TaoPAT 11 | 12 | #define FILE_VER_STR TaoREVISIONSTR 13 | 14 | #define VER_COMPANYNAME_STR "JaredTao\0" 15 | 16 | #define VER_FILEDESCRIPTION_STR "TaoQuickShow\0" 17 | #define VER_INTERNALNAME_STR "jaredtao.github.io\0" 18 | #define VER_LEGALCOPYRIGHT_STR "Copyright(C)2019-2029 JaredTao\0" 19 | #define VER_LEGALTRADEMARKS_STR "JaredTao\0" 20 | #define VER_ORIGINALFILENAME_STR "TaoQuickShow.exe\0" 21 | #define VER_PRODUCTNAME_STR "TaoQuickShow\0" 22 | 23 | // version number (string) 24 | #define TOSTRING2(arg) #arg 25 | 26 | #define TOSTRING(arg) TOSTRING2(arg) 27 | #define RELEASE_VER_STR TOSTRING(RELEASE_VER_MAIN) "." TOSTRING(RELEASE_VER_MAIN2) "." TOSTRING(RELEASE_VER_SUB) 28 | -------------------------------------------------------------------------------- /examples/TaoQuickShow/milk.icns: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/milk.icns -------------------------------------------------------------------------------- /examples/TaoQuickShow/milk.ico: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/examples/TaoQuickShow/milk.ico -------------------------------------------------------------------------------- /examples/examples.pro: -------------------------------------------------------------------------------- 1 | TEMPLATE = subdirs 2 | 3 | SUBDIRS += \ 4 | TaoQuickShow 5 | -------------------------------------------------------------------------------- /mkspecs/features/taoBuildPath.prf: -------------------------------------------------------------------------------- 1 | defineTest(setBuildPath) { 2 | buildPath = $$1 3 | CONFIG(debug,debug|release){ 4 | MOC_DIR = $${buildPath}/debug/moc 5 | RCC_DIR = $${buildPath}/debug/rcc 6 | UI_DIR = $${buildPath}/debug/ui 7 | OBJECTS_DIR = $${buildPath}/debug/obj 8 | QMLCACHE_DIR = $${buildPath}/debug/qmlcache 9 | } else { 10 | MOC_DIR = $${buildPath}/release/moc 11 | RCC_DIR = $${buildPath}/release/rcc 12 | UI_DIR = $${buildPath}/release/ui 13 | OBJECTS_DIR = $${buildPath}/release/obj 14 | QMLCACHE_DIR = $${buildPath}/release/qmlcache 15 | } 16 | export(MOC_DIR) 17 | export(RCC_DIR) 18 | export(UI_DIR) 19 | export(OBJECTS_DIR) 20 | export(QMLCACHE_DIR) 21 | } 22 | -------------------------------------------------------------------------------- /mkspecs/features/taoBundle.prf: -------------------------------------------------------------------------------- 1 | defineReplace(getBundlePath) { 2 | appName = $$1 3 | BundlePath = 4 | macos{ 5 | CONFIG(debug, debug|release){ 6 | CONFIG -=app_bundle 7 | } else { 8 | BundlePath=$${appName}.app/Contents/MacOS/ 9 | } 10 | } 11 | export(CONFIG) 12 | return ($$BundlePath) 13 | } 14 | -------------------------------------------------------------------------------- /mkspecs/features/taoVersion.prf: -------------------------------------------------------------------------------- 1 | defineTest(setTaoVersion) { 2 | TAO_VERSION_TAG = 1.0 3 | 4 | # current commit hash 5 | REVISION=$$system("git rev-parse HEAD") 6 | REVISION=$$str_member($${REVISION}, 0, $$num_add(10, -1)) 7 | isEmpty(REVISION) { 8 | REVISION = 0000000000 9 | } 10 | 11 | # last tag 12 | Ver=$$system("git describe --abbrev=0 --tags") 13 | isEmpty(Ver) { 14 | Ver=0.0.0 15 | } 16 | VerList =$$split(Ver, .) 17 | MAJ = $$take_first(VerList) 18 | MIN = $$take_first(VerList) 19 | PAT = $$take_first(VerList) 20 | equals(TEMPLATE, lib) { 21 | CONFIG += skip_target_version_ext 22 | VER_MAJ = $${MAJ} 23 | VER_MIN = $${MIN} 24 | VER_PAT = $${PAT} 25 | VERSION = $${Ver} 26 | } 27 | 28 | DEFINES *= TaoREVISION=$${REVISION} 29 | DEFINES *= TaoREVISIONSTR=\"\\\"$${REVISION}\\\"\" 30 | DEFINES *= TaoVer=\"\\\"$${Ver}\\\"\" 31 | DEFINES *= TaoMAJ=$${MAJ} 32 | DEFINES *= TaoMIN=$${MIN} 33 | DEFINES *= TaoPAT=$${PAT} 34 | DEFINES *= TaoDATETIME=\"\\\"$${_DATE_}\\\"\" 35 | DEFINES *= CXX_COMPILER_ID=\"\\\"$${QMAKE_COMPILER}\\\"\" 36 | 37 | export(CONFIG) 38 | export(VER_MAJ) 39 | export(VER_MIN) 40 | export(VER_PAT) 41 | export(VERSION) 42 | export(DEFINES) 43 | } 44 | 45 | -------------------------------------------------------------------------------- /preview/Arrow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/Arrow.png -------------------------------------------------------------------------------- /preview/AtomJoggle.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/AtomJoggle.gif -------------------------------------------------------------------------------- /preview/Buttons-en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/Buttons-en.png -------------------------------------------------------------------------------- /preview/Buttons.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/Buttons.png -------------------------------------------------------------------------------- /preview/ClickShow.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/ClickShow.gif -------------------------------------------------------------------------------- /preview/Data-en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/Data-en.png -------------------------------------------------------------------------------- /preview/Data.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/Data.png -------------------------------------------------------------------------------- /preview/EdgeTab.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/EdgeTab.gif -------------------------------------------------------------------------------- /preview/I18n-en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/I18n-en.png -------------------------------------------------------------------------------- /preview/I18n.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/I18n.png -------------------------------------------------------------------------------- /preview/ListViewWithTab.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/ListViewWithTab.gif -------------------------------------------------------------------------------- /preview/SuperMario.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/SuperMario.png -------------------------------------------------------------------------------- /preview/Table-en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/Table-en.png -------------------------------------------------------------------------------- /preview/Table.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/Table.png -------------------------------------------------------------------------------- /preview/byte.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/byte.png -------------------------------------------------------------------------------- /preview/designer.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/designer.png -------------------------------------------------------------------------------- /preview/main-en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/main-en.png -------------------------------------------------------------------------------- /preview/main.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/main.png -------------------------------------------------------------------------------- /preview/rect-en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/rect-en.png -------------------------------------------------------------------------------- /preview/rect.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/rect.png -------------------------------------------------------------------------------- /preview/skin-en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/skin-en.png -------------------------------------------------------------------------------- /preview/skin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/skin.png -------------------------------------------------------------------------------- /preview/snail.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/snail.png -------------------------------------------------------------------------------- /preview/wizard-en.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/wizard-en.png -------------------------------------------------------------------------------- /preview/wizard.gif: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/wizard.gif -------------------------------------------------------------------------------- /preview/wizard.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/preview/wizard.png -------------------------------------------------------------------------------- /scripts/manulaDeployment.bat: -------------------------------------------------------------------------------- 1 | @echo off 2 | cd .. 3 | call "D:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC\Auxiliary\Build\vcvars64.bat" 4 | set VCINSTALLDIR="C:\Program Files (x86)\Microsoft Visual Studio\2019\Enterprise\VC" 5 | set winSdkDir=%WindowsSdkDir% 6 | set winSdkVer=%WindowsSdkVersion% 7 | set vcToolsInstallDir=%VCToolsInstallDir% 8 | set vcToolsRedistDir=%VCToolsRedistDir% 9 | set msvcArch=x64 10 | set QTDIR=D:\Qt\5.15.2\msvc2019_64 11 | set PATH=%PATH%;%QTDIR%\bin 12 | powershell.exe -NoProfile -ExecutionPolicy Bypass -File scripts\windows-publish.ps1 TaoQuickShow TaoQuickShow.exe 13 | 14 | cd scripts -------------------------------------------------------------------------------- /src/TaoQuick.pri: -------------------------------------------------------------------------------- 1 | CONFIG(debug,debug|release){ 2 | # debug mode use local file 3 | win32{ 4 | path=$$system("cd") 5 | path ~=s,\\\\,/,g 6 | } else { 7 | path=$$system("pwd") 8 | } 9 | DEFINES += TaoQuickImportPath=\\\"file:///$${path}/\\\" 10 | 11 | OTHER_FILES += $$files($$path/TaoQuick/Qml/*.qml, true) 12 | 13 | } else { 14 | # release mode use qrc file 15 | RESOURCES += $$PWD/TaoQuick/TaoQuick.qrc 16 | # release mode set importPath with 'qrc:///' 17 | DEFINES += TaoQuickImportPath=\\\"qrc:///\\\" 18 | } 19 | 20 | # Additional import path used to resolve QML modules in Qt Creator's code model 21 | QML_IMPORT_PATH = $$PWD 22 | QML2_IMPORT_PATH = $$PWD 23 | 24 | # Additional import path used to resolve QML modules just for Qt Quick Designer 25 | QML_DESIGNER_IMPORT_PATH = $$PWD 26 | 27 | 28 | -------------------------------------------------------------------------------- /src/TaoQuick/Images/Check.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/Check.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/ComboBox_Down.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/ComboBox_Down.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/Expanded.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/Expanded.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/Icon_Camera_Offline.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/Icon_Camera_Offline.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/Icon_Camera_Online.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/Icon_Camera_Online.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/Search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/Search.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/Search_Clear.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/Search_Clear.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/Table_Asc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/Table_Asc.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/Table_Asc_Hovered.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/Table_Asc_Hovered.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/Table_Desc.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/Table_Desc.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/Table_Desc_Hovered.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/Table_Desc_Hovered.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/arrow-down.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/arrow-down.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/arrow-left.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/arrow-left.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/arrow-right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/arrow-right.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/arrow-up.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/arrow-up.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/ellipsis.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/ellipsis.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/last.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/last.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/left.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/left.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/next.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/next.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/particle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/particle.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/radio-checked-disabled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/radio-checked-disabled.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/radio-checked-hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/radio-checked-hover.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/radio-checked-normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/radio-checked-normal.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/radio-unchecked-disabled.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/radio-unchecked-disabled.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/radio-unchecked-hover.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/radio-unchecked-hover.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/radio-unchecked-normal.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/radio-unchecked-normal.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/right.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/right.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/rotate.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/rotate.png -------------------------------------------------------------------------------- /src/TaoQuick/Images/spinner.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/Images/spinner.png -------------------------------------------------------------------------------- /src/TaoQuick/Qml/Basic/BasicText.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | 6 | Text { 7 | verticalAlignment: Text.AlignVCenter 8 | horizontalAlignment: Text.AlignHCenter 9 | font.family: CusConfig.fontFamily 10 | font.pixelSize: CusConfig.fontPixel 11 | elide: Text.ElideRight 12 | color: CusConfig.textColor 13 | // renderType: Text.NativeRendering 14 | } 15 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/Basic/BasicTooltip.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | ToolTip { 6 | id: basicTooltip 7 | contentItem: BasicText { 8 | text: basicTooltip.text 9 | } 10 | background: Rectangle { 11 | color: CusConfig.tipBackgroundColor 12 | border.color: CusConfig.tipBorderColor 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/Basic/CusCallLater.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.12 2 | import QtQuick.Controls 2.12 3 | Item { 4 | Component { 5 | id: timerComp 6 | Timer { 7 | id: timer 8 | repeat: false 9 | property var _cb: function() {} 10 | onTriggered: { 11 | _cb() 12 | destroy(parent) 13 | } 14 | function setTimeout(callback, delayTime) { 15 | _cb = callback; 16 | interval = delayTime; 17 | start(); 18 | } 19 | } 20 | } 21 | function callLate(callback, delayTime) { 22 | var timerObj = timerComp.createObject() 23 | timerObj.setTimeout(callback, delayTime) 24 | } 25 | 26 | } 27 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/Basic/MoveArea.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | 4 | MouseArea { 5 | id: moveArea 6 | 7 | property int lastX: 0 8 | property int lastY: 0 9 | property var control: parent //导出一个control属性,指定要拖动的目标, 默认就用parent好了。注意目标要有x和y属性并且可修改 10 | signal move(real xOffset, real yOffset) 11 | onContainsPressChanged: { 12 | if (containsPress) { 13 | cursorShape = Qt.SizeAllCursor 14 | lastX = mouseX 15 | lastY = mouseY 16 | } else { 17 | cursorShape = Qt.ArrowCursor 18 | } 19 | } 20 | onPositionChanged: { 21 | if (pressed && control) { 22 | if ((mouseX - lastX) !== 0 || (mouseY - lastY) !== 0) 23 | moveArea.move(mouseX - lastX, mouseY - lastY) 24 | } 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/Basic/TransArea.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | //鼠标事件透传 4 | MouseArea { 5 | anchors.fill: parent 6 | hoverEnabled: true 7 | // propagateComposedEvents: true 8 | //鼠标图标, hovered 或者 pressed时显示此图标 9 | cursorShape: Qt.PointingHandCursor 10 | onDoubleClicked: { mouse.accepted = false;} 11 | onPositionChanged: { mouse.accepted = false;} 12 | onPressed: { mouse.accepted = false; } 13 | onPressAndHold: { mouse.accepted = false; } 14 | onClicked: { mouse.accepted = false;} 15 | onReleased: { mouse.accepted = false;} 16 | onWheel: { wheel.accepted = false; } 17 | } 18 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusBackground/CusBackground.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | Rectangle { 6 | color: CusConfig.backgroundColor 7 | MouseArea { 8 | id: backgroundArea 9 | anchors.fill: parent 10 | onClicked: { 11 | focus = true 12 | } 13 | } 14 | } 15 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusButton/CusButton_Blue.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | 4 | CusButton { 5 | backgroundColorNormal: "#38a9e4" 6 | backgroundColorHovered: "#47c0ff" 7 | backgroundColorPressed: "#108bcd" 8 | backgroundColorDisable: "#b6bdc5" 9 | 10 | borderColor: "#579ee5" 11 | textColor: "#ffffff" 12 | } 13 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusButton/CusButton_Gradient.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | CusButton { 6 | id: cusButton 7 | background: Rectangle { 8 | radius: cusButton.radius 9 | color: cusButton.backgroundColor 10 | border.color: cusButton.borderColor 11 | border.width: cusButton.borderWidth 12 | clip: true 13 | Rectangle { 14 | id: pressRect 15 | radius: 0 16 | smooth: true 17 | property int startX: cusButton.width / 2 18 | property int startY: cusButton.height / 2 19 | x: startX - radius 20 | y: startY - radius 21 | width: radius * 2 22 | height: radius * 2 23 | visible: radius > 0 24 | color: backgroundColorPressed 25 | 26 | SequentialAnimation { 27 | id: pressAnimation 28 | NumberAnimation { 29 | target: pressRect 30 | property: "radius" 31 | from: 0 32 | to: Math.max(pressRect.startX, 33 | cusButton.width - pressRect.startX) 34 | duration: 500 35 | } 36 | ScriptAction { 37 | script: { 38 | pressRect.radius = 0 39 | } 40 | } 41 | } 42 | } 43 | } 44 | 45 | TransArea { 46 | anchors.fill: parent 47 | onPressed: { 48 | pressRect.startX = mouseX 49 | pressRect.startY = mouseY 50 | pressAnimation.start() 51 | } 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusButton/CusButton_Image.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | 6 | Button { 7 | id: cusButtonImage 8 | implicitWidth: 24 9 | implicitHeight: 24 10 | 11 | property alias tipText: toolTip.text 12 | property alias tipItem: toolTip 13 | property alias tipVisible: toolTip.visible 14 | property alias tipDelay: toolTip.delay 15 | property alias tipTimeout: toolTip.timeout 16 | property bool selected: false 17 | property string btnImgNormal 18 | property string btnImgHovered 19 | property string btnImgPressed 20 | property string btnImgDisbaled 21 | 22 | property string btnImgUrl: { 23 | if (!cusButtonImage.enabled) { 24 | return btnImgDisbaled 25 | } else if (cusButtonImage.pressed || selected) { 26 | return btnImgPressed 27 | } else if (cusButtonImage.hovered) { 28 | return btnImgHovered 29 | } else { 30 | return btnImgNormal 31 | } 32 | } 33 | background: Item { 34 | width: cusButtonImage.width 35 | height: cusButtonImage.height 36 | CusImage { 37 | id: backImage 38 | source: btnImgUrl 39 | anchors.centerIn: parent 40 | } 41 | } 42 | BasicTooltip { 43 | id: toolTip 44 | visible: cusButtonImage.hovered && String(text).length 45 | delay: 500 46 | } 47 | TransArea { 48 | } 49 | } 50 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusButton/CusButton_ImageBackground.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.10 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | Button { 6 | id: cusButtonImage 7 | 8 | property alias tipText: toolTip.text 9 | property alias tipItem: toolTip 10 | property alias tipVisible: toolTip.visible 11 | property alias tipDelay: toolTip.delay 12 | property alias tipTimeout: toolTip.timeout 13 | 14 | property string btnImgUr 15 | property color backgroundColor: "transparent" 16 | property color backgroundColor_pressed 17 | property color backgroundColor_hovered 18 | 19 | BasicTooltip { 20 | id: toolTip 21 | visible: cusButtonImage.hovered && String(text).length 22 | } 23 | background: Rectangle { 24 | width: cusButtonImage.width 25 | height: cusButtonImage.height 26 | color: cusButtonImage.pressed ? backgroundColor_pressed : ( cusButtonImage.hovered ? backgroundColor_hovered : backgroundColor) 27 | CusImage { 28 | anchors.centerIn: parent 29 | width: cusButtonImage.width 30 | height: cusButtonImage.height 31 | source: btnImgUr 32 | } 33 | } 34 | TransArea {} 35 | } 36 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusButton/CusButton_Red.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | 4 | CusButton { 5 | backgroundColorNormal: "#f14958" 6 | backgroundColorHovered: "#f25a68" 7 | backgroundColorPressed: "#e43e4d" 8 | backgroundColorDisable: "#b6bdc5" 9 | 10 | borderColor: backgroundColor 11 | textColor: "#ffffff" 12 | } 13 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusButton/CusButton_White.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | 4 | CusButton { 5 | backgroundColorNormal: "#ffffff" 6 | backgroundColorHovered: "#eaf6fd" 7 | backgroundColorPressed: "#d7ebfa" 8 | backgroundColorDisable: "#b6bdc5" 9 | 10 | borderColor: enabled ? "#38a9e4" : "#b6bdc5" 11 | borderWidth: 1 12 | 13 | textColor: enabled ? "#38a9e4" : "#ffffff" 14 | } 15 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusImage/CusImage.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | 4 | Image { 5 | width: sourceSize.width 6 | height: sourceSize.height 7 | } 8 | 9 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusImage/CusImageOverlay.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import QtGraphicalEffects 1.0 4 | Item { 5 | property alias source: srcImg.source 6 | property alias color: overlayImg.color 7 | 8 | Image { 9 | id: srcImg 10 | anchors.fill: parent 11 | visible: false 12 | } 13 | ColorOverlay { 14 | id: overlayImg 15 | source: srcImg 16 | anchors.fill: srcImg 17 | width: srcImg.width 18 | height: srcImg.height 19 | 20 | } 21 | } 22 | 23 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusImage/CusImage_Tip.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | CusImage { 6 | id: cusImageTip 7 | 8 | property alias tipItem: toolTip 9 | property alias tipText: toolTip.text 10 | property alias tipVisible: toolTip.visible 11 | property alias tipDelay: toolTip.delay 12 | property alias tipTimeout: toolTip.timeout 13 | 14 | property alias containsMouse: hoverArea.containsMouse 15 | property alias containsPress: hoverArea.containsPress 16 | BasicTooltip { 17 | id: toolTip 18 | visible: cusImageTip.enabled && String(text).length && hoverArea.containsMouse 19 | } 20 | TransArea { 21 | id: hoverArea 22 | anchors.fill: parent 23 | hoverEnabled: true 24 | } 25 | } 26 | 27 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusInput/CusTextField.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | TextField { 6 | id: cusTextField 7 | height: CusConfig.fixedHeight 8 | hoverEnabled: enabled 9 | selectByMouse: true 10 | color: CusConfig.textColor 11 | maximumLength: CusConfig.maximumLength 12 | selectionColor: CusConfig.controlColor_pressed 13 | selectedTextColor: CusConfig.textColor_pressed 14 | font.pixelSize: CusConfig.fontPixel 15 | background: Rectangle { 16 | color: (cusTextField.enabled && !cusTextField.readOnly) ? CusConfig.controlColor : CusConfig.controlColor_disabled 17 | radius: CusConfig.controlBorderRadius 18 | border.width: 1 19 | border.color: (cusTextField.enabled && !cusTextField.readOnly && (cusTextField.hovered || cusTextField.focus)) ? CusConfig.controlBorderColor_hovered : CusConfig.controlBorderColor 20 | } 21 | } 22 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusInput/CusTextField_Btn.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | CusTextField { 6 | id: cusTextFieldBtn 7 | 8 | property Component rightBtn: nullptr 9 | 10 | background: Rectangle { 11 | color: (cusTextFieldBtn.enabled && !cusTextFieldBtn.readOnly) ? CusConfig.controlColor : CusConfig.controlColor_disabled 12 | radius: CusConfig.controlBorderRadius 13 | border.width: 1 14 | border.color: (cusTextFieldBtn.enabled && !cusTextFieldBtn.readOnly && (cusTextFieldBtn.hovered || cusTextFieldBtn.focus)) ? CusConfig.controlBorderColor_hovered : CusConfig.controlBorderColor 15 | 16 | Loader { 17 | sourceComponent: rightBtn 18 | anchors { 19 | right: parent.right 20 | rightMargin: 4 21 | verticalCenter: parent.verticalCenter 22 | } 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusInput/CusTextField_Valid.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | 6 | TextField { 7 | id: cusTextField 8 | height: CusConfig.fixedHeight 9 | hoverEnabled: enabled 10 | selectByMouse: true 11 | color: CusConfig.textColor 12 | maximumLength: CusConfig.maximumLength 13 | selectionColor: CusConfig.controlColor_pressed 14 | selectedTextColor: CusConfig.textColor_pressed 15 | property bool invalid: false 16 | onTextChanged: { 17 | invalid = false 18 | } 19 | background: Rectangle { 20 | color: (cusTextField.enabled 21 | && !cusTextField.readOnly) ? CusConfig.controlColor : CusConfig.controlColor_disabled 22 | radius: CusConfig.controlBorderRadius 23 | border.width: 1 24 | border.color: { 25 | if (cusTextField.enabled) { 26 | if (cusTextField.readOnly) { 27 | return CusConfig.controlBorderColor 28 | } else { 29 | if (cusTextField.invalid) { 30 | return CusConfig.invalidColor 31 | } else { 32 | if (cusTextField.hovered || cusTextField.focus) { 33 | return CusConfig.controlBorderColor_hovered 34 | } else { 35 | return CusConfig.controlBorderColor 36 | } 37 | } 38 | } 39 | } else { 40 | return CusConfig.controlBorderColor 41 | } 42 | } 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusInput/CusTextInput.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | TextInput { 6 | id: cusTextField 7 | height: CusConfig.fixedHeight 8 | font.pixelSize: CusConfig.fontPixel 9 | verticalAlignment: Text.AlignVCenter 10 | horizontalAlignment: Text.AlignHCenter 11 | selectByMouse: true 12 | color: CusConfig.textColor 13 | maximumLength: CusConfig.maximumLength 14 | selectionColor: CusConfig.controlColor_pressed 15 | selectedTextColor: CusConfig.textColor_pressed 16 | // renderType: Text.NativeRendering 17 | } 18 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusLabel/CusLabel.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | 6 | Label { 7 | font.family: CusConfig.fontFamily 8 | font.pixelSize: CusConfig.fontPixel 9 | color: CusConfig.textColor 10 | elide: Text.ElideRight 11 | // renderType: Text.NativeRendering 12 | verticalAlignment: Text.AlignVCenter 13 | horizontalAlignment: Text.AlignLeft 14 | } 15 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusLabel/CusLabel_Center.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.10 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | Label { 6 | font.pixelSize: Config.fontSize_default 7 | color: Config.textColor 8 | height: Config.fixedHeight 9 | elide: Text.ElideRight 10 | verticalAlignment: Text.AlignVCenter 11 | horizontalAlignment: Text.AlignHCenter 12 | // renderType: Text.NativeRendering 13 | } 14 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusLabel/CusLabel_Left.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.10 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | Label { 6 | font.pixelSize: Config.fontSize_default 7 | color: Config.textColor 8 | height: Config.fixedHeight 9 | elide: Text.ElideRight 10 | verticalAlignment: Text.AlignVCenter 11 | horizontalAlignment: Text.AlignLeft 12 | // renderType: Text.NativeRendering 13 | } 14 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusPopup/CusPopup.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | Item { 6 | id: root 7 | anchors.fill: parent 8 | property alias popupVisible: popup.visible 9 | property alias contentItem: popup.contentItem 10 | property color barColor: CusConfig.tipBackgroundColor 11 | property alias backgroundItem: background 12 | property real backgroundWidth: 200 13 | property real backgroundHeight: 160 14 | property color borderColor: barColor 15 | property real borderWidth: 0 16 | 17 | property real verticalOffset: 24 18 | //矩形旋转45度,一半被toolTip遮住(重合),另一半三角形和ToolTip组成一个带箭头的ToolTip 19 | Rectangle { 20 | id: bar 21 | visible: popup.visible 22 | rotation: 45 23 | width: verticalOffset 24 | height: width 25 | color: barColor 26 | border.color: borderColor 27 | //水平居中 28 | anchors.horizontalCenter: parent.horizontalCenter 29 | //垂直方向上,由ToolTip的y值,决定位置 30 | anchors.verticalCenter: parent.bottom 31 | anchors.verticalCenterOffset: verticalOffset 32 | } 33 | Popup { 34 | id: popup 35 | width: backgroundWidth 36 | height: backgroundHeight 37 | background: Rectangle { 38 | id: background 39 | color: barColor 40 | radius: 8 41 | border.color:borderColor 42 | border.width: borderWidth 43 | } 44 | } 45 | function show() { 46 | popup.x = (root.width - popup.width) / 2 47 | popup.y = root.height + verticalOffset 48 | popupVisible = true 49 | } 50 | function hide() { 51 | popupVisible = false 52 | } 53 | } 54 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusPopup/CusToolTip_Triangle.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | 6 | Item { 7 | id: root 8 | anchors.fill: parent 9 | property alias text: toolTip.text 10 | property alias tipVisible: toolTip.visible 11 | property alias delay: toolTip.delay 12 | property alias timeout: toolTip.timeout 13 | property color barColor: CusConfig.tipBackgroundColor 14 | //矩形旋转45度,一半被toolTip遮住(重合),另一半三角形和ToolTip组成一个带箭头的ToolTip 15 | Rectangle { 16 | id: bar 17 | visible: toolTip.visible 18 | rotation: 45 19 | width: 10 20 | height: 10 21 | color: barColor 22 | //水平居中 23 | anchors.horizontalCenter: parent.horizontalCenter 24 | //垂直方向上,由ToolTip的y值,决定位置 25 | anchors.verticalCenter: toolTip.y > 0 ? parent.bottom : parent.top 26 | anchors.verticalCenterOffset: toolTip.y > 0 ? 5 : -5 27 | } 28 | BasicTooltip { 29 | id: toolTip 30 | delay: 500 31 | background: Rectangle { 32 | color: barColor 33 | radius: CusConfig.controlBorderRadius 34 | } 35 | } 36 | } 37 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusScroll/CusScrollBar.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | ScrollBar { 6 | id: cusTirangleTipBorder 7 | property bool isSmaller: true 8 | // minimumSize: 0.1 9 | // size: Math.max(height / content.height, 0.1) 10 | contentItem: Rectangle { 11 | implicitWidth: isSmaller ? CusConfig.scrollBarSize_Smaller : CusConfig.scrollBarSize 12 | implicitHeight: isSmaller ? CusConfig.scrollBarSize_Smaller : CusConfig.scrollBarSize 13 | radius: CusConfig.scrollBarRadius 14 | color: isSmaller ? CusConfig.scrollBarBackgroundColor : CusConfig.scrollBarBackgroundColor_hovered 15 | TransArea{ 16 | id: t 17 | onEntered: { 18 | isSmaller = false 19 | } 20 | onExited: { 21 | isSmaller = true 22 | } 23 | } 24 | } 25 | } 26 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusSlider/CusSlider_Spin.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | Row { 6 | height: CusConfig.fixedHeight 7 | spacing: 0 8 | property alias value: slider.value 9 | property alias from: slider.from 10 | property alias to: slider.to 11 | property alias stepSize: slider.stepSize 12 | CusSlider { 13 | id: slider 14 | height: CusConfig.fixedHeight 15 | width: parent.width * 0.8 16 | onValueChanged: { 17 | spinBox.value = value 18 | } 19 | } 20 | CusSpinBox { 21 | id: spinBox 22 | height: CusConfig.fixedHeight 23 | width: parent.width * 0.2 24 | value: slider.value 25 | from: slider.from 26 | to: slider.to 27 | onValueChanged: { 28 | slider.value = value 29 | } 30 | } 31 | } 32 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusSpinBox/CusSpinBox_HourMinute.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | 6 | Row { 7 | id: cusSpinBoxHourMinute 8 | property int hour: 0 9 | property int minute: 0 10 | property int defaultSpinWidth: 60 11 | width: childrenRect.width 12 | spacing: 2 13 | 14 | onHourChanged: { 15 | hourSpin.value = hour 16 | } 17 | onMinuteChanged: { 18 | minuteSpin.value = minute 19 | } 20 | function prefixZero(value, locale) { 21 | return String((value < 10 ? "0" : "") + String(value)) 22 | } 23 | CusSpinBox { 24 | id: hourSpin 25 | from: 0 26 | to: 23 27 | enabled: cusSpinBoxHourMinute.enabled 28 | onValueChanged: { 29 | cusSpinBoxHourMinute.hour = value 30 | } 31 | implicitWidth: defaultSpinWidth 32 | textFromValue: prefixZero 33 | } 34 | CusLabel { 35 | text: ":" 36 | horizontalAlignment: Text.AlignLeft 37 | verticalAlignment: Text.AlignVCenter 38 | width: 4 39 | } 40 | CusSpinBox { 41 | id: minuteSpin 42 | from: 0 43 | to: 59 44 | onValueChanged: { 45 | cusSpinBoxHourMinute.minute = value 46 | } 47 | enabled: cusSpinBoxHourMinute.enabled 48 | implicitWidth: defaultSpinWidth 49 | textFromValue: prefixZero 50 | } 51 | } 52 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusTable/CusTableConstant.qml: -------------------------------------------------------------------------------- 1 | pragma Singleton 2 | 3 | import QtQuick 2.9 4 | 5 | QtObject { 6 | readonly property int column0Width: 50 7 | readonly property int minWidth: 40 8 | readonly property int maxWidth: 400 9 | function bound(minValue, midValue, maxValue) { 10 | return Math.max(minValue, Math.min(midValue, maxValue)) 11 | } 12 | } 13 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/CusWizard/CusWizard.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | 6 | Item { 7 | id: cusWizardItem 8 | signal wizardFinished 9 | property string totlaString: qsTr("Wizard %1/%2 >").arg(currentIndex + 1).arg(count) + CusConfig.transString 10 | property string operatorString: qsTr("Click any area to show next") + CusConfig.transString 11 | MouseArea { 12 | anchors.fill: parent 13 | hoverEnabled: true 14 | onClicked: { 15 | currentIndex++ 16 | if (currentIndex >= count) { 17 | wizardFinished() 18 | } 19 | } 20 | } 21 | property var model 22 | property int count: model.count 23 | property int currentIndex: 0 24 | Repeater { 25 | model: cusWizardItem.model 26 | delegate: CusWizardPage { 27 | anchors.fill: parent 28 | visible: index === currentIndex 29 | wizardName: model.name 30 | wizardDescript: model.descript 31 | targetObjectName: model.targetObjectName 32 | pageType: model.arrowType 33 | } 34 | } 35 | CusLabel { 36 | z: 999 37 | id: centerLabel 38 | anchors { 39 | centerIn: parent 40 | horizontalCenterOffset: 300 41 | verticalCenterOffset: 150 42 | } 43 | text: totlaString 44 | font.pixelSize: 22 45 | color: "white" 46 | } 47 | CusLabel { 48 | z: 999 49 | anchors { 50 | centerIn: parent 51 | horizontalCenterOffset: 300 52 | verticalCenterOffset: 150 + centerLabel.height 53 | } 54 | text: operatorString 55 | color: "white" 56 | } 57 | } 58 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/Effect/Animation/ADissolve.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | 4 | import ".." 5 | import "../.." 6 | 7 | ShaderEffect { 8 | id: r 9 | property int duration: 1000 10 | property ShaderEffectSource effectSource: ShaderEffectSource { 11 | hideSource: true 12 | } 13 | property ShaderEffectSource dissolveSource: ShaderEffectSource { 14 | hideSource: true 15 | } 16 | property int percent 17 | opacity: percent > 0 ? 1 : 0 18 | NumberAnimation { 19 | id: animation 20 | target: r 21 | property: "percent" 22 | from: 0 23 | to: 100 24 | alwaysRunToEnd: true 25 | loops: 1 26 | duration: r.duration 27 | } 28 | 29 | fragmentShader: CusEffectCommon.fragmentShaderCommon + " 30 | varying vec2 qt_TexCoord0; 31 | uniform float qt_Opacity; 32 | uniform sampler2D effectSource; 33 | uniform sampler2D dissolveSource; 34 | uniform int percent; 35 | void main() 36 | { 37 | vec4 color = texture2D(effectSource, qt_TexCoord0); 38 | vec4 dcolor = texture2D(dissolveSource, qt_TexCoord0); 39 | float alpha = 1.0 - step(float(percent) / 100.0, dcolor.r); 40 | alpha *= qt_Opacity; 41 | gl_FragColor = vec4(color.rgb * alpha, alpha); 42 | } 43 | " 44 | function restart() { 45 | animation.restart() 46 | } 47 | } 48 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/Effect/Animation/ASector.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | 6 | ShaderEffect { 7 | id: r 8 | 9 | property int duration: 1000 10 | property ShaderEffectSource effectSource: ShaderEffectSource { 11 | hideSource: true 12 | } 13 | property int percent 14 | opacity: percent > 0 ? 1 : 0 15 | NumberAnimation { 16 | id: animation 17 | target: r 18 | property: "percent" 19 | from: 0 20 | to: 100 21 | alwaysRunToEnd: true 22 | loops: 1 23 | duration: r.duration 24 | } 25 | fragmentShader: CusEffectCommon.fragmentShaderCommon + " 26 | varying vec2 qt_TexCoord0; 27 | uniform float qt_Opacity; 28 | uniform sampler2D effectSource; 29 | uniform int percent; 30 | void main() 31 | { 32 | vec4 color = texture2D(effectSource, qt_TexCoord0); 33 | float per = float(percent) / 100.0 * 180; 34 | const vec2 origin = vec2(0.5, 0.5); 35 | const vec2 a = vec2(0.5, 0.0); 36 | vec2 c = qt_TexCoord0 - origin; 37 | float alpha = 0.0; 38 | if (cos(radians(per))* length(c) * length(a) < dot(c, a)) { 39 | alpha = 1.0; 40 | } 41 | alpha *= qt_Opacity; 42 | gl_FragColor = vec4(color.rgb * alpha, alpha); 43 | } 44 | " 45 | function restart() { 46 | animation.restart() 47 | } 48 | } 49 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/Effect/Animation/ASlowEnter.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import ".." 4 | import "../.." 5 | 6 | Item { 7 | id: r 8 | property int targetX: 0 9 | property int targetY: 0 10 | property alias animation: animation 11 | 12 | readonly property int directFromLeft: 0 13 | readonly property int directFromRight: 1 14 | readonly property int directFromTop: 2 15 | readonly property int directFromBottom: 3 16 | 17 | property int dir: directFromBottom 18 | property int duration: 2000 19 | property int extDistance: 10 20 | property var __propList: ["x", "x", "y", "y"] 21 | property var __fromList: [-r.parent.width - r.width 22 | - extDistance, r.parent.width + r.width + extDistance, -r.parent.height 23 | - r.height - extDistance, r.parent.height + r.height + extDistance] 24 | property var __toList: [targetX, targetX, targetY, targetY] 25 | NumberAnimation { 26 | id: animation 27 | target: r 28 | property: __propList[dir] 29 | from: __fromList[dir] 30 | to: __toList[dir] 31 | duration: r.duration 32 | loops: 1 33 | alwaysRunToEnd: true 34 | } 35 | } 36 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/Effect/CusEffectCommon.qml: -------------------------------------------------------------------------------- 1 | pragma Singleton 2 | import QtQuick 2.9 3 | QtObject { 4 | property string versionString: GraphicsInfo.renderableType === GraphicsInfo.SurfaceFormatOpenGLES ? 5 | "#version 100 es" : "#version 130" 6 | property string fragmentShaderCommon: versionString + " 7 | #ifdef GL_ES 8 | precision mediump float; 9 | #else 10 | # define lowp 11 | # define mediump 12 | # define highp 13 | #endif // GL_ES 14 | " 15 | 16 | } 17 | 18 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/Misc/CusDragItem.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | Item { 4 | id: root 5 | property alias containsMouse: mouseArea.containsMouse 6 | signal posChange(int xOffset, int yOffset) 7 | implicitWidth: 12 8 | implicitHeight: 12 9 | property int posType: Qt.ArrowCursor 10 | 11 | //5.10之前, qml是不能定义枚举的,用只读的int属性代替一下。 12 | readonly property int posLeftTop: Qt.SizeFDiagCursor 13 | readonly property int posLeft: Qt.SizeHorCursor 14 | readonly property int posLeftBottom: Qt.SizeBDiagCursor 15 | readonly property int posTop: Qt.SizeVerCursor 16 | readonly property int posBottom: Qt.SizeVerCursor 17 | readonly property int posRightTop: Qt.SizeBDiagCursor 18 | readonly property int posRight: Qt.SizeHorCursor 19 | readonly property int posRightBottom: Qt.SizeFDiagCursor 20 | MouseArea { 21 | id: mouseArea 22 | anchors.fill: parent 23 | hoverEnabled: true 24 | property int lastX: 0 25 | property int lastY: 0 26 | onContainsMouseChanged: { 27 | if (containsMouse) { 28 | cursorShape = posType; 29 | } else { 30 | cursorShape = Qt.ArrowCursor; 31 | } 32 | } 33 | onPressedChanged: { 34 | if (containsPress) { 35 | lastX = mouseX; 36 | lastY = mouseY; 37 | } 38 | } 39 | onPositionChanged: { 40 | if (pressed) { 41 | posChange(mouseX - lastX, mouseY - lastY) 42 | } 43 | } 44 | } 45 | } 46 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/Misc/CusFPS.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import "../.." 4 | Item { 5 | property int fps: 60 6 | 7 | property int frameCount: 0 8 | property color textColor: "#f7e08c" 9 | implicitWidth: 100 10 | implicitHeight: 36 11 | Image { 12 | id: spinner 13 | source: CusConfig.imagePathPrefix + "spinner.png" 14 | width: 32 15 | height: 32 16 | anchors.verticalCenter: parent.verticalCenter 17 | anchors.left: parent.left 18 | RotationAnimation on rotation { 19 | from: 0 20 | to: 360 21 | running: true 22 | loops: Animation.Infinite 23 | duration: 1000 24 | } 25 | onRotationChanged: frameCount++ 26 | } 27 | BasicText { 28 | anchors.left: spinner.right 29 | anchors.verticalCenter: parent.verticalCenter 30 | text: "FPS " + fps 31 | font.pixelSize: 18 32 | style: Text.Outline 33 | styleColor: "#606060" 34 | 35 | color: textColor 36 | } 37 | Timer { 38 | interval: 1000 39 | repeat: true 40 | running: true 41 | onTriggered: { 42 | fps = frameCount 43 | frameCount = 0 44 | } 45 | } 46 | } 47 | -------------------------------------------------------------------------------- /src/TaoQuick/Qml/Misc/CusShortCutKeys.qml: -------------------------------------------------------------------------------- 1 | import QtQuick 2.9 2 | import QtQuick.Controls 2.2 3 | import QtQml 2.0 4 | QtObject { 5 | id: shortCutKeys 6 | property bool shiftPressed: false 7 | property bool ctrlPressed: false 8 | signal selectAllPressed() 9 | signal selectAllReleased() 10 | signal escPressed() 11 | signal escReleased() 12 | } 13 | -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/BasicText.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/BasicText.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/BasicTooltip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/BasicTooltip.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusBackground.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusBackground.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusBusyIndicator.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusBusyIndicator.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusButton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusButton.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusButton_Blue.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusButton_Blue.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusButton_Gradient.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusButton_Gradient.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusButton_Image.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusButton_Image.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusButton_ImageColorOverlay.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusButton_ImageColorOverlay.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusButton_Red.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusButton_Red.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusButton_White.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusButton_White.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusCheckBox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusCheckBox.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusComboBox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusComboBox.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusDialog.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusDialog.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusDragItem.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusDragItem.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusFPS.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusFPS.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusImage.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusImage.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusImage_Tip.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusImage_Tip.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusLabel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusLabel.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusListView.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusListView.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusPopup.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusPopup.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusRectDraw.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusRectDraw.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusResizeBorder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusResizeBorder.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusScrollBar.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusScrollBar.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusShortCutKeys.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusShortCutKeys.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusSlider.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusSlider.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusSlider_Spin.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusSlider_Spin.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusSpinBox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusSpinBox.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusSpinBox_HourMinute.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusSpinBox_HourMinute.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusSwitch.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusSwitch.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusTableHeader.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusTableHeader.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusTableRow.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusTableRow.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusTableView.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusTableView.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusTemplateDragBorder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusTemplateDragBorder.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusTextButton.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusTextButton.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusTextField.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusTextField.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusTextField_Btn.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusTextField_Btn.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusTextField_Search.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusTextField_Search.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusTextField_Valid.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusTextField_Valid.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusTextInput.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusTextInput.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusToolTip_Triangle.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusToolTip_Triangle.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/CusTriangleTipBorder.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/CusTriangleTipBorder.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/MoveArea.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/MoveArea.png -------------------------------------------------------------------------------- /src/TaoQuick/designer/images/TransArea.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/jaredtao/TaoQuick/d1e8f51756bacd23eaaf96dcb54465cd61deaf92/src/TaoQuick/designer/images/TransArea.png -------------------------------------------------------------------------------- /src/taoQuick.cmake: -------------------------------------------------------------------------------- 1 | set(TaoQuickPath ${CMAKE_CURRENT_LIST_DIR}) 2 | 3 | if (CMAKE_BUILD_TYPE MATCHES "Release") 4 | set(TaoQuickRes ${TaoQuickPath}/TaoQuick/TaoQuick.qrc CACHE STRING "tao quick res path") 5 | set(TaoQuickImportPath "qrc:///" CACHE STRING "tao quick import path") 6 | else() 7 | set(TaoQuickImportPath "file:///${TaoQuickPath}/" CACHE STRING "tao quick import path") 8 | endif() 9 | 10 | add_compile_definitions(TaoQuickImportPath="${TaoQuickImportPath}") 11 | 12 | #add_compile_definitions(QML_IMPORT_PATH="${TaoQuickPath}") 13 | #add_compile_definitions(QML2_IMPORT_PATH="${TaoQuickPath}") 14 | #add_compile_definitions(QML_DESIGNER_IMPORT_PATH="${TaoQuickPath}") 15 | 16 | set(QML_IMPORT_PATH ${TaoQuickPath} CACHE STRING "") 17 | set(QML2_IMPORT_PATH ${TaoQuickPath} CACHE STRING "") 18 | set(QML_DESIGNER_IMPORT_PATH ${TaoQuickPath} CACHE STRING "") 19 | 20 | -------------------------------------------------------------------------------- /src/taoQuick.props: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | TaoQuickImportPath=R"(file:///$(ProjectDir))";%(PreprocessorDefinitions) 8 | 9 | 10 | 11 | 12 | TaoQuickImportPath="qrc:/";%(PreprocessorDefinitions) 13 | 14 | 15 | 16 | 17 | 18 | -------------------------------------------------------------------------------- /taoVersionInfo.h: -------------------------------------------------------------------------------- 1 | #ifndef TAO_VERSION_INFO_H 2 | #define TAO_VERSION_INFO_H 3 | 4 | #define TaoREVISIONSTR "rev" 5 | #define TaoVer "1.2.0" 6 | #define TaoMAJ 1 7 | #define TaoMIN 2 8 | #define TaoPAT 0 9 | #define TaoDATETIME "0" 10 | #define CXX_COMPILER_ID "vc143" 11 | 12 | #endif //TAO_VERSION_INFO_H 13 | --------------------------------------------------------------------------------