make button icons follow a reasonable size and layout
Needs ReviewPublic

Authored by camiloh on Thu, Aug 22, 3:40 PM.

Details

Summary

with the Plasma style buttons which have an icon look wrong. The icon size is too big and in consecuence the whole button is drawn way too big.
With this patch the icon is set to a standard size and drawn in the button layout, in a way it looks consistent with other button with no icons.

example:

Before path:

With patch:

BUG: 399952
FIXED-IN: 5.62

Diff Detail

Repository
R242 Plasma Framework (Library)
Branch
arcpatch-D23352_2
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 15749
Build 15767: arc lint + arc unit
camiloh created this revision.Thu, Aug 22, 3:40 PM
Restricted Application added a project: Frameworks. · View Herald TranscriptThu, Aug 22, 3:40 PM
Restricted Application added a subscriber: kde-frameworks-devel. · View Herald Transcript
camiloh requested review of this revision.Thu, Aug 22, 3:40 PM
camiloh updated this revision to Diff 64317.Thu, Aug 22, 3:41 PM

correct import line

camiloh edited the summary of this revision. (Show Details)Thu, Aug 22, 3:43 PM
camiloh edited the summary of this revision. (Show Details)
ngraham edited the summary of this revision. (Show Details)Thu, Aug 22, 4:34 PM
ngraham accepted this revision.Thu, Aug 22, 4:38 PM
ngraham added a subscriber: ngraham.

LGTM, just fix the whitespace issue

src/declarativeimports/plasmacomponents3/Button.qml
68

unnecessary whitespace change

This revision is now accepted and ready to land.Thu, Aug 22, 4:38 PM
camiloh updated this revision to Diff 64365.Thu, Aug 22, 10:24 PM

remove white line

camiloh marked an inline comment as done.Thu, Aug 22, 10:24 PM
This revision was automatically updated to reflect the committed changes.
mart reopened this revision.Wed, Aug 28, 8:41 AM

Same problem as the toolbutton one, button icons need to scale unless icon size fixed from client side

This revision is now accepted and ready to land.Wed, Aug 28, 8:41 AM
mart requested changes to this revision.Wed, Aug 28, 8:42 AM
This revision now requires changes to proceed.Wed, Aug 28, 8:42 AM
mart added inline comments.Wed, Aug 28, 9:02 AM
src/declarativeimports/plasmacomponents3/Button.qml
51

no anchors and no enclosing Item.

This was ok as it was, including fillwidth/fillheight (perhaps)
but with the line:
Layout.preferredWidth: control.icon.width > 0 ? control.icon.width : -1
same for preferredHeight

This revision was not accepted when it landed; it landed in state Needs Revision.Wed, Aug 28, 9:10 AM
This revision was automatically updated to reflect the committed changes.
mart reopened this revision.Wed, Aug 28, 1:29 PM
camiloh updated this revision to Diff 64850.Wed, Aug 28, 2:13 PM

suggested changes. use preferred width and height when the icon group height and width props are set

camiloh updated this revision to Diff 64851.Wed, Aug 28, 2:15 PM

correct slip from toolbutton