ensure the rounded rectangle of scrollbard stays round
ClosedPublic

Authored by mart on Jan 24 2018, 4:19 PM.

Details

Summary

with the new very slim scrollbars, the rounded rectangle could
go to have a radius more than half their width, making them look
"pointy", this ensures they stay properly round

Test Plan

slim scrollbars still round, bigger ones are unaltered

Diff Detail

Repository
R31 Breeze
Lint
Automatic diff as part of commit; lint not applicable.
Unit
Automatic diff as part of commit; unit tests not applicable.
mart created this revision.Jan 24 2018, 4:19 PM
Restricted Application added a project: Plasma. · View Herald TranscriptJan 24 2018, 4:19 PM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
mart requested review of this revision.Jan 24 2018, 4:19 PM
hein accepted this revision.Jan 24 2018, 4:25 PM
hein added a subscriber: hein.

Great Yaynessings

This revision is now accepted and ready to land.Jan 24 2018, 4:25 PM
kstyle/breezehelper.cpp
1262

std::min( { a, b, c } )
would look nicer than qMin( qMin)
Other than that ship it !

also, rather than (qreal)( rect.width() ) you can use directly baseRect.width(), which is a qRectF.

0.5*qMin( ... ) would also do the job. (as in 0.5*Metrics:: ... )
But in any case, std::min( ... )

This revision was automatically updated to reflect the committed changes.