From 6f46e95ed7e02bc16aaf26393942383ce8667e13 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=EA=A6=8C=EA=A6=AB=EA=A6=B6=EA=A6=8F=EA=A7=80=EA=A6=A6?= =?UTF-8?q?=EA=A6=BF=EA=A6=A7=EA=A6=AE=EA=A6=91=EA=A6=A9=EA=A6=AD=EA=A7=80?= Date: Tue, 11 Apr 2023 16:07:10 +0800 Subject: Qeduport now relies on Qootstrap Qeduport should now be installed to the system too. When used from app, Qeduport will refer to libqootstrap installed in the system. When used from Designer / Design Studio, Qeduport will refer to the non attached property QML version instead. --- imports/Eduport/Eduport.qml | 27 ++++++++++++--------------- 1 file changed, 12 insertions(+), 15 deletions(-) (limited to 'imports/Eduport/Eduport.qml') diff --git a/imports/Eduport/Eduport.qml b/imports/Eduport/Eduport.qml index ba3f344..f5f4da8 100644 --- a/imports/Eduport/Eduport.qml +++ b/imports/Eduport/Eduport.qml @@ -1,12 +1,10 @@ pragma Singleton import QtQuick 2.15 +import Bootstrap 5.3 QtObject { - enum Mode { - Light, - Dark - } - property int mode: Eduport.Mode.Light + property int mode: Bootstrap.mode + onModeChanged: Bootstrap.mode = mode readonly property real leadFontSize: 18.75 readonly property real formControlFontSize: 16 @@ -44,10 +42,9 @@ QtObject { readonly property real bsBadgeFontSize: 13.6 - property color bsBodyColor: mode ? "#a1a1a8" : "#747579" - property color bsBodyBg: mode ? "#222529" : "#ffffff" - - property color bsBorderColor: mode ? "#12ffffff" : bsGray200 + property color bsBodyColor: Bootstrap.bodyColor + property color bsBodyBg: Bootstrap.bodyBg + property color bsBorderColor: Bootstrap.borderColor property real bsBorderRadius: 5.2 property real bsBoxShadowOffsetX: 0 @@ -145,21 +142,21 @@ QtObject { || Qt.platform.os === "unix" || Qt.platform.os === "windows" readonly property FontLoader robotoBold: FontLoader { - source: haveRoboto ? "" : "../../Roboto/Roboto-Bold.ttf" + source: haveRoboto ? "" : "Roboto-Bold.ttf" } readonly property FontLoader robotoMedium: FontLoader { - source: haveRoboto ? "" : "../../Roboto/Roboto-Medium.ttf" + source: haveRoboto ? "" : "Roboto-Medium.ttf" } readonly property FontLoader robotoRegular: FontLoader { - source: haveRoboto ? "" : "../../Roboto/Roboto-Regular.ttf" + source: haveRoboto ? "" : "Roboto-Regular.ttf" } readonly property FontLoader heeboBold: FontLoader { - source: "../../Heebo/Heebo-Bold.ttf" + source: "Heebo-Bold.ttf" } readonly property FontLoader heeboMedium: FontLoader { - source: "../../Heebo/Heebo-Medium.ttf" + source: "Heebo-Medium.ttf" } readonly property FontLoader heeboRegular: FontLoader { - source: "../../Heebo/Heebo-Regular.ttf" + source: "Heebo-Regular.ttf" } } -- cgit v1.2.3