Fixing icon paths

This commit is contained in:
Ad5001 2022-01-30 01:37:46 +01:00
parent 7a8b35c83b
commit 12fb88cab9
Signed by: Ad5001
GPG key ID: EF45F9C6AFE20160
2 changed files with 8 additions and 5 deletions

View file

@ -74,9 +74,12 @@ def run():
print("Loaded dependencies in " + str((dep_time - start_time)*1000) + "ms.")
icon_fallbacks = QIcon.fallbackSearchPaths();
icon_fallbacks.append(path.realpath(path.join(getcwd(), "qml", "eu", "ad5001", "LogarithmPlotter", "icons")))
icon_fallbacks.append(path.realpath(path.join(getcwd(), "qml", "eu", "ad5001", "LogarithmPlotter", "icons", "settings")))
icon_fallbacks.append(path.realpath(path.join(getcwd(), "qml", "eu", "ad5001", "LogarithmPlotter", "icons", "settings", "custom")))
base_icon_path = path.join(getcwd(), "qml", "eu", "ad5001", "LogarithmPlotter", "icons")
icon_fallbacks.append(path.realpath(path.join(base_icon_path, "common")))
icon_fallbacks.append(path.realpath(path.join(base_icon_path, "objects")))
icon_fallbacks.append(path.realpath(path.join(base_icon_path, "history")))
icon_fallbacks.append(path.realpath(path.join(base_icon_path, "settings")))
icon_fallbacks.append(path.realpath(path.join(base_icon_path, "settings", "custom")))
QIcon.setFallbackSearchPaths(icon_fallbacks);
app = QApplication(argv)

View file

@ -78,7 +78,7 @@ D.Dialog {
id: nameProperty
height: 30
label: qsTr("Name")
icon: "icons/settings/custom/label.svg"
icon: "icons/common/label.svg"
min: 1
width: dlgProperties.width
value: objEditor.obj.name
@ -105,7 +105,7 @@ D.Dialog {
label: qsTr("Label content")
model: [qsTr("null"), qsTr("name"), qsTr("name + value")]
property var idModel: ["null", "name", "name + value"]
icon: "icons/settings/custom/label.svg"
icon: "icons/common/label.svg"
currentIndex: idModel.indexOf(objEditor.obj.labelContent)
onActivated: function(newIndex) {
if(idModel[newIndex] != objEditor.obj.labelContent) {