From kde-commits Fri Sep 30 21:36:26 2016 From: David Edmundson Date: Fri, 30 Sep 2016 21:36:26 +0000 To: kde-commits Subject: [plasma-desktop] applets/kickoff/package/contents/ui: Constrain kickoff config button label size Message-Id: X-MARC-Message: https://marc.info/?l=kde-commits&m=147527139502717 Git commit 77dad58290769e2e1223c1275b8e074c8e8ff3bd by David Edmundson. Committed on 30/09/2016 at 21:26. Pushed by davidedmundson into branch 'master'. Constrain kickoff config button label size Summary: A better way to achieve center aligning is to use the alignment property of QtQuick.Text. This looks the same but because we now have left and right anchors text gets elided properly rather than overflowing out the box. Test Plan: Opened, looks identical Reviewers: #plasma Subscribers: jsalatas, plasma-devel Tags: #plasma Differential Revision: https://phabricator.kde.org/D2901 M +4 -1 applets/kickoff/package/contents/ui/KickoffConfigurationButt= on.qml http://commits.kde.org/plasma-desktop/77dad58290769e2e1223c1275b8e074c8e8ff= 3bd diff --git a/applets/kickoff/package/contents/ui/KickoffConfigurationButton= .qml b/applets/kickoff/package/contents/ui/KickoffConfigurationButton.qml index ef95dec..31bf05f 100644 --- a/applets/kickoff/package/contents/ui/KickoffConfigurationButton.qml +++ b/applets/kickoff/package/contents/ui/KickoffConfigurationButton.qml @@ -48,8 +48,11 @@ PlasmaCore.FrameSvgItem { id: textElement anchors { top: iconElement.bottom - horizontalCenter: parent.horizontalCenter + left: parent.left + right: parent.right } + horizontalAlignment: Text.AlignHCenter + elide: Text.ElideRight color: PlasmaCore.ColorScope.textColor font.pointSize: theme.smallestFont.pointSize }