cfeck added a reviewer: cfeck.
cfeck added a comment.

  The config would work with removed styleName() for the cases where the 
weight() and style() attributes are sufficient. The intention from Qt's side 
was to uniquely identify fonts that cannot be selected by those two attributes. 
Imagine a font that has these faces:
  
  - HandwriteRegular
  - HandwriteBold
  - HandwriteItalic
  - HandwriteBoldItalic
  - HandwriteCursive
  - HandwriteBoldCursive
  
  Now the user picks "HandwriteCursive", and unless we do not save the 
styleName(), the font matching would probably select "HandwriteItalic" based on 
the weight() and style() attributes. On the other hand, calling setBold(true) 
on a font called "HandwriteCursive" _should_ select "HandwriteBoldCursive", 
even if the styleName was intended to enforce a specific face. If Qt cannot fix 
this issue, then we have to clear the styleName() at least for those fonts, 
where a perfect match is possible using the attributes alone (by comparing with 
the database again).

REPOSITORY
  R135 Integration for Qt applications in Plasma

REVISION DETAIL
  https://phabricator.kde.org/D9070

To: rjvbb, #frameworks, davidedmundson, graesslin, cfeck
Cc: cfeck, fvogt, plasma-devel, ZrenBot, progwolff, lesliezhai, ali-mohamed, 
jensreuterberg, abetts, sebas, apol, mart

Reply via email to