diff --git a/contents/ui/main.qml b/contents/ui/main.qml index 5e7ee74..3e3c98e 100644 --- a/contents/ui/main.qml +++ b/contents/ui/main.qml @@ -115,33 +115,49 @@ Item { Plasmoid.compactRepresentation: RowLayout { id: mainItem spacing: 0 - PlasmaComponents.Label { - id: commandNameLabel - text: commandName - } - Item { + Item{ + id: labelContainer + Layout.fillHeight: true Layout.fillWidth: true + Text { + width: parent.width-parent.height + height: parent.height + id: commandNameLabel + text: commandName + color: PlasmaCore.ColorScope.textColor + minimumPointSize: 5 + font.pointSize: 100 + fontSizeMode: Text.Fit + anchors.centerIn: parent + horizontalAlignment: Text.AlignHCenter + verticalAlignment: Text.AlignVCenter + elide: Text.ElideRight + } } - PlasmaCore.IconItem { - id: icon + Item{ + id :iconContainer Layout.fillHeight: true - Layout.fillWidth: true - source: checked ? plasmoid.configuration.iconOn : plasmoid.configuration.iconOff - MouseArea { - id: mouseArea - anchors.fill: parent - hoverEnabled: true - onClicked: { - if ((checked && offScriptEnabled) || (!checked && onScriptEnabled)) { - checked = checked == true ? false : true - toggleAction(); + Layout.minimumWidth: height + PlasmaCore.IconItem { + id: icon + anchors.fill:parent + source: checked ? plasmoid.configuration.iconOn : plasmoid.configuration.iconOff + MouseArea { + id: mouseArea + anchors.fill: parent + hoverEnabled: true + onClicked: { + if ((checked && offScriptEnabled) || (!checked && onScriptEnabled)) { + checked = checked == true ? false : true + toggleAction(); + } } } - } - BusyIndicator { - id: busy - anchors.fill:parent - visible: scriptRunning + BusyIndicator { + id: busy + anchors.fill:parent + visible: scriptRunning + } } } }