Font style name 'Normal' and 'Regular' have the same meaning
Some popular fonts on linux systems follow a naming convention, where font styles are named 'Regular', 'Italic', 'Bold' and 'Bold Italic'. Qt so far only accepts the words Italic and Oblique interchangably, but not with Regular and Normal. This change will make sure that Regular is interpreted the same as the Normal font style. Fixes: QTBUG-90396 Pick-to: 6.0 6.1 5.15 Change-Id: Ibbaf086de742c91f4d380c937ca80e846aa32a2e Reviewed-by: Volker Hilsheimer <volker.hilsheimer@qt.io>
This commit is contained in:
parent
101581484b
commit
426b363761
@ -591,6 +591,14 @@ void QFontDialogPrivate::updateStyles()
|
||||
cstyle.replace(QLatin1String("Oblique"), QLatin1String("Italic"));
|
||||
first = false;
|
||||
goto redo;
|
||||
} else if (cstyle.contains(QLatin1String("Regular"))) {
|
||||
cstyle.replace(QLatin1String("Regular"), QLatin1String("Normal"));
|
||||
first = false;
|
||||
goto redo;
|
||||
} else if (cstyle.contains(QLatin1String("Normal"))) {
|
||||
cstyle.replace(QLatin1String("Normal"), QLatin1String("Regular"));
|
||||
first = false;
|
||||
goto redo;
|
||||
}
|
||||
}
|
||||
if (!found)
|
||||
|
Loading…
x
Reference in New Issue
Block a user