[Scummvm-git-logs] scummvm master -> 5122be339f2b50521a55c324c6f1a71c7b14a6bd

digitall noreply at scummvm.org
Sat Oct 4 15:16:34 UTC 2025


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://api.github.com/repos/scummvm/scummvm .

Summary:
5122be339f GUI: Change Rich Text Widget Used For Help To Use TTF For Non-English Only


Commit: 5122be339f2b50521a55c324c6f1a71c7b14a6bd
    https://github.com/scummvm/scummvm/commit/5122be339f2b50521a55c324c6f1a71c7b14a6bd
Author: D G Turner (digitall at scummvm.org)
Date: 2025-10-04T16:15:29+01:00

Commit Message:
GUI: Change Rich Text Widget Used For Help To Use TTF For Non-English Only

Changed paths:
    gui/widgets/richtext.cpp


diff --git a/gui/widgets/richtext.cpp b/gui/widgets/richtext.cpp
index 575540f9c09..821fbacf77e 100644
--- a/gui/widgets/richtext.cpp
+++ b/gui/widgets/richtext.cpp
@@ -21,6 +21,7 @@
 
 #include "common/system.h"
 #include "common/unicode-bidi.h"
+#include "common/translation.h"
 
 #include "graphics/macgui/mactext.h"
 
@@ -197,7 +198,11 @@ void RichTextWidget::createWidget() {
 
 	const int fontHeight = g_gui.xmlEval()->getVar("Globals.Font.Height", 25);
 
-	int newId = wm->_fontMan->registerTTFFont(ttfFamily);
+	int newId;
+	if (TransMan.currentIsBuiltinLanguage())
+		newId = Graphics::kMacFontNewYork;
+	else // MacFONTs do not contain diacritic marks or non-English characters, so we have to use TTF instead
+		newId = wm->_fontMan->registerTTFFont(ttfFamily);
 	Graphics::MacFont macFont(newId, fontHeight, Graphics::kMacFontRegular);
 
 	_txtWnd = new Graphics::MacText(Common::U32String(), wm, &macFont, fg, bg, _textWidth, Graphics::kTextAlignLeft);




More information about the Scummvm-git-logs mailing list