Bug 344185

Summary: Selected image gets pixelated instead of smooth when scaling is necessary
Product: [Applications] systemsettings Reporter: Martin Häggström <cjmhaggstrom>
Component: kcm_useraccountAssignee: Unassigned bugs mailing-list <unassigned-bugs>
Status: RESOLVED FIXED    
Severity: normal    
Priority: NOR    
Version: 5.2.0   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
URL: https://i.imgur.com/x7S5Pe7.jpg
Latest Commit: Version Fixed In: 5.2.1
Sentry Crash Report:

Description Martin Häggström 2015-02-15 09:44:52 UTC
It seems that the module is not using Qt::SmoothTransformation when scaling the image down to 64x64 pixels.

Proposed change:
Line 122 in kdepasswd/kcm/chfacedlg.cpp ought to be changed to 
pix = pix.scaled( KCFGUserAccount::faceSize(), KCFGUserAccount::faceSize(), Qt::KeepAspectRatio, Qt::SmoothTransformation );

Reproducible: Always

Steps to Reproduce:
1. Open user account kcm module ("kcmshell kcm_useraccount")
2. Click on face icon to change it
3. Click "Custom Image" and select an image larger than 64x64 px (default size)

Actual Results:  
The displayed image in the grid is very pixelated / hard to distinguish.

Expected Results:  
The displayed image in the grid should be a smoothly scaled down version of the selected image.
Comment 1 Kai Uwe Broulik 2015-02-16 15:46:57 UTC
Git commit 1d4eb597c573caa7bf28dca7ec1b9c0f046548a6 by Kai Uwe Broulik.
Committed on 16/02/2015 at 15:44.
Pushed by broulik into branch 'Plasma/5.2'.

Use smooth transformation for scaling down the user picture

Thanks to Martin Häggström for the patch
FIXED-IN: 5.2.1

M  +1    -1    kcms/useraccount/chfacedlg.cpp

http://commits.kde.org/plasma-desktop/1d4eb597c573caa7bf28dca7ec1b9c0f046548a6