Bug 383191

Summary: Mismatch of default font settings and default kcm_fonts selection
Product: [Plasma] plasma-integration Reporter: Fabian Vogt <fabian>
Component: generalAssignee: Martin Flöser <mgraesslin>
Status: RESOLVED FIXED    
Severity: normal CC: bugseforuns
Priority: NOR    
Version: master   
Target Milestone: ---   
Platform: openSUSE   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description Fabian Vogt 2017-08-06 09:54:03 UTC
Found by openQA: https://openqa.opensuse.org/tests/462041#step/start_wayland_plasma5/12

The font of the polkit authentication dialog is slightly bolder before saving (without changes!) in kcm_fonts. The culprit seems to be the:

[General]
font=Noto Sans,10,-1,5,50,0,0,0,0,0,Regular

line in .config/kdeglobals. Removing "Regular" makes it bolder again.

AFAICS this is due to a missing default QFont::setStyleName in plasma-integration.
Comment 1 Fabian Vogt 2017-08-06 09:57:46 UTC
(In reply to Fabian Vogt from comment #0)
> AFAICS this is due to a missing default QFont::setStyleName in
> plasma-integration.

I was able to confirm this and created https://phabricator.kde.org/D7160
Comment 2 Fabian Vogt 2017-08-11 09:14:34 UTC
Git commit 1b21b5977c2068c5bd30c9f9f641f60bdba9ea8e by Fabian Vogt.
Committed on 11/08/2017 at 09:14.
Pushed by fvogt into branch 'master'.

Also specify a default StyleName for fonts

Summary:
When saving, kcm_fonts adds the default selected StyleName,
so it needs to specified here as well to avoid mismatches.

Test Plan:
Ran pkcon install with no kdeglobals.
Without this change: Bold title in the auth dialog
With this change:  Normal title in the auth dialog

Reviewers: #plasma

Subscribers: plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D7160

M  +8    -7    src/platformtheme/kfontsettingsdata.cpp
M  +1    -0    src/platformtheme/kfontsettingsdata.h

https://commits.kde.org/plasma-integration/1b21b5977c2068c5bd30c9f9f641f60bdba9ea8e
Comment 3 RJVB 2017-11-29 22:19:37 UTC
Git commit 8ed5863a2664a3635381d58893704824eeac83d4 by R.J.V. Bertin.
Committed on 29/11/2017 at 21:53.
Pushed by rjvbb into branch 'qt590'.

Also specify a default StyleName for fonts

Summary:
When saving, kcm_fonts adds the default selected StyleName,
so it needs to specified here as well to avoid mismatches.

Test Plan:
Ran pkcon install with no kdeglobals.
Without this change: Bold title in the auth dialog
With this change:  Normal title in the auth dialog

Reviewers: #plasma

Subscribers: plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D7160

Cherry-picked from plasma-integration:1b21b5977c2068c5bd30c9f9f641f60bdba9ea8e
and slightly adapted for OS X

Committed from host : Portia.local

M  +8    -7    src/platformtheme/kfontsettingsdata.cpp
M  +1    -0    src/platformtheme/kfontsettingsdata.h
M  +9    -8    src/platformtheme/kfontsettingsdatamac.mm
M  +1    -0    src/platformtheme/plintegration-cumpatch1.diff

https://commits.kde.org/osx-integration/8ed5863a2664a3635381d58893704824eeac83d4