nixpkgs/pkgs/by-name/fr/freecad/0003-FreeCad-fix-font-load-crash.patch
julian1 f1c4f54fb0 Freecad: fix cursor.pcf font load crash
update

update

update
2025-06-02 20:58:17 +10:00

27 lines
1.3 KiB
Diff

diff --git a/src/Gui/PreferencePages/DlgSettingsEditor.cpp b/src/Gui/PreferencePages/DlgSettingsEditor.cpp
index 0dda987..01568f1 100755
--- a/src/Gui/PreferencePages/DlgSettingsEditor.cpp
+++ b/src/Gui/PreferencePages/DlgSettingsEditor.cpp
@@ -288,7 +288,9 @@ void DlgSettingsEditor::loadSettings()
QStringList fixedFamilyNames;
for (const auto& name : familyNames) {
if (QFontDatabase().isFixedPitch(name)) {
- if (name.compare(QLatin1String("8514oem"), Qt::CaseInsensitive) != 0) {
+ if (name.compare(QLatin1String("8514oem"), Qt::CaseInsensitive) != 0
+ && name.compare(QLatin1String("cursor.pcf"), Qt::CaseInsensitive) != 0)
+ {
fixedFamilyNames.append(name);
}
}
@@ -298,7 +300,9 @@ void DlgSettingsEditor::loadSettings()
QStringList fixedFamilyNames;
for (const auto& name : familyNames) {
if (QFontDatabase::isFixedPitch(name)) {
- if (name.compare(QLatin1String("8514oem"), Qt::CaseInsensitive) != 0) {
+ if (name.compare(QLatin1String("8514oem"), Qt::CaseInsensitive) != 0
+ && name.compare(QLatin1String("cursor.pcf"), Qt::CaseInsensitive) != 0)
+ {
fixedFamilyNames.append(name);
}
}