decent icon size
svn path=/trunk/KDE/kdelibs/; revision=1016957
This commit is contained in:
parent
37f65858dc
commit
9ee071c5e3
@ -366,7 +366,8 @@ void PushButton::paint(QPainter *painter,
|
|||||||
QRectF rect = contentsRect();
|
QRectF rect = contentsRect();
|
||||||
|
|
||||||
if (!nativeWidget()->icon().isNull()) {
|
if (!nativeWidget()->icon().isNull()) {
|
||||||
QPixmap iconPix = nativeWidget()->icon().pixmap(rect.height(), rect.height());
|
const iconSize = qMin(rect.width(), rect.height());
|
||||||
|
QPixmap iconPix = nativeWidget()->icon().pixmap(iconSize);
|
||||||
if (!isEnabled()) {
|
if (!isEnabled()) {
|
||||||
KIconEffect *effect = KIconLoader::global()->iconEffect();
|
KIconEffect *effect = KIconLoader::global()->iconEffect();
|
||||||
iconPix = effect->apply(iconPix, KIconLoader::Toolbar, KIconLoader::DisabledState);
|
iconPix = effect->apply(iconPix, KIconLoader::Toolbar, KIconLoader::DisabledState);
|
||||||
|
Loading…
Reference in New Issue
Block a user