D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-25 Thread Ahmad Samir
ahmadsamir added a comment. I am not so sure about the QPlatform integration bit, it looks easier/cleaner to just use KFontChooserDialog; QFontDialog isn't widely used in KDE code, so porting to KFontChooserDialog is doable (though that sounds like going back in time to using KFontDialog in

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-25 Thread Méven Car
meven added a comment. With D28122 I think you can go ahead and port this code to it. Unless you want to take care of the QPlatform integration for it first. REPOSITORY R119 Plasma Desktop REVISION DETAIL https://phabricator.kde.org/D27808 To:

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-17 Thread Ahmad Samir
ahmadsamir added a comment. I spent some time looking (and hacking at a kdeplatformfontdialoghelper...) at the code in kdeplatformfiledialoghelper, KFontChooser and KFontDialog, and I am starting to think that moving KFontDialog to KWidgetAddons (where KFontChooser and KFontRequester live)

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-10 Thread Christoph Feck
cfeck added a comment. See https://bugreports.qt.io/browse/QTBUG-56547 REPOSITORY R119 Plasma Desktop REVISION DETAIL https://phabricator.kde.org/D27808 To: ahmadsamir, #plasma, davidedmundson, broulik, ervin, meven Cc: cfeck, bport, plasma-devel, Orage, LeGast00n, The-Feren-OS-Dev,

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-10 Thread Méven Car
meven added a comment. In D27808#625229 , @ahmadsamir wrote: > In D27808#625227 , @cfeck wrote: > > > We already lost fractional point sizes when porting from KFontDialog to QFontDialog. > >

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-10 Thread Ahmad Samir
ahmadsamir added a comment. In D27808#625227 , @cfeck wrote: > We already lost fractional point sizes when porting from KFontDialog to QFontDialog. Yeah, I never understood why they opted for integer values only (I will dig in upstream

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-10 Thread Christoph Feck
cfeck added a comment. We already lost fractional point sizes when porting from KFontDialog to QFontDialog. Best approach is to add the KFontDialog to the platform plugin (and also the old KColorDialog while you are at it), or upstream our features to Qt. Btw, I set Toolbar font to a

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-10 Thread Ahmad Samir
ahmadsamir added a comment. In D27808#625186 , @meven wrote: > In D27808#625181 , @ahmadsamir wrote: > > > And another question, "General", "Menu", "Toolbar", how many users actually set these

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-10 Thread Méven Car
meven added a comment. In D27808#625181 , @ahmadsamir wrote: > And another question, "General", "Menu", "Toolbar", how many users actually set these three to individual font families/styles/sizes? If anything this is just not relevant

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-10 Thread Ahmad Samir
ahmadsamir added a comment. And another question, "General", "Menu", "Toolbar", how many users actually set these three to individual font families/styles/sizes? REPOSITORY R119 Plasma Desktop REVISION DETAIL https://phabricator.kde.org/D27808 To: ahmadsamir, #plasma, davidedmundson,

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-09 Thread Ahmad Samir
ahmadsamir added a comment. In D27808#625052 , @meven wrote: > Porting with such feature regression is hard to justify. I honestly don't know how many users actually use that feature; if it's still widely used, then yeah, that would

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-09 Thread Ahmad Samir
ahmadsamir planned changes to this revision. ahmadsamir added a comment. It seems I messed up the branches stuff (or phabricator works in a way I don't understand), so I think it's best to work at one diff at a time, instead of wasting time trying to make sense of this situation :/ (I

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-09 Thread Méven Car
meven added a comment. Porting with such feature regression is hard to justify. Perhaps we should port KFontDialog (it is ~150 lines of cpp) to kwidgetsaddons instead, `KFontChooser` is already there. Or better perhaps implement here a simple QDialog embedding `KFontChooser` and

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-09 Thread Méven Car
meven added inline comments. INLINE COMMENTS > fonts.cpp:678 > > -QFont KFonts::applyFontDiff(const QFont , const QFont , int > fontDiffFlags) > -{ > -QFont font(fnt); > - > -if (fontDiffFlags & KFontChooser::FontDiffSize) { > -font.setPointSizeF(newFont.pointSizeF()); > -

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-09 Thread Ahmad Samir
ahmadsamir added a comment. In D27808#624506 , @bport wrote: > With your change, we are not allowed anymore to change for example only font and keeping different size, style for each kind of font (window, menu, toolbar...), right ?

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-09 Thread Benjamin Port
bport added a comment. With your change, we are not allowed anymore to change for example only font and keeping different size, style for each kind of font (window, menu, toolbar...), right ? REPOSITORY R119 Plasma Desktop REVISION DETAIL https://phabricator.kde.org/D27808 To:

D27808: [Fonts KCM] Port KFontDialog/KFontChooser to QFontDialog

2020-03-03 Thread Ahmad Samir
ahmadsamir created this revision. ahmadsamir added reviewers: Plasma, davidedmundson, broulik, ervin, meven. Herald added a project: Plasma. ahmadsamir requested review of this revision. REVISION SUMMARY When using ajustAllFonts(), try to set the fixed width/Monospace font from the font