[ros-bugs] [Bug 1191] New: Precompiled font names problem ?

ReactOS.Bugzilla at reactos.org ReactOS.Bugzilla at reactos.org
Sat Dec 24 11:39:27 CET 2005


http://www.reactos.org/bugzilla/show_bug.cgi?id=1191

           Summary: Precompiled font names problem ?
           Product: ReactOS
           Version: 0.2.9
          Platform: x86 Hardware
        OS/Version: ReactOS
            Status: NEW
          Severity: minor
          Priority: P3
         Component: Shell
        AssignedTo: ros-bugs at reactos.org
        ReportedBy: temarez at yandex.ru
         QAContact: ros-bugs at reactos.org


I have posted a question in forum concerning fonts in ReactOS
(http://www.reactos.org/forum/viewtopic.php?t=1364). GreatLord asked to post a
bugzilla about it. So here it is. One of the problems is that changing default
fonts in HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontSubstitutes and
SysFontSubstitutes cannot help you to turn on international support. I have
copied DejaVu fonts (http://dejavu.sourceforge.net/) and made such changes in
registry to get support of cyrillic letters (ROS 0.2.9):

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\SysFontSubstitutes]
"Arial"="DejaVu Sans"
"Courier New"="DejaVu Sans Mono"
"Marlett"="TGMarlett"
"Times New Roman"="DejaVu Serif"
"MS Sans Serif"="DejaVu Sans"
"MS Shell Dlg"="DejaVu Sans"
"MS Shell Dlg 2"="DejaVu Sans"
"Helv"="DejaVu Sans"

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\FontSubstitutes]
"Arial"="DejaVu Sans,204"
"Courier New"="DejaVu Sans Mono,204"
"Marlett"="TGMarlett"
"Times New Roman"="DejaVu Serif,204"
"MS Sans Serif"="DejaVu Sans,204"
"MS Shell Dlg"="DejaVu Sans,204"
"MS Shell Dlg 2"="DejaVu Sans,204"
"Helv"="DejaVu Sans,204"


Note: "FontName,204" values must be written in Windows registry for correct
support of cyr letters.


But ROS continued using Bitstream Vera. When I deleted all standard fonts and
leaved only DejaVu I saw cyrillic letters but not everywhere where they must be.
Most dialogs with russian text displays with central-european symbols instead of
russian. This must be general problem of all non-latin alphabets.

Maybe problem is in precompiled font names in some sources? I found precompiled
font names in 0.2.9 source:

subsys\csrss\win32csr\guiconsole.c (function GuiConsoleHandleNcCreate):

  GuiData->Font = CreateFontW(12, 0, 0, TA_BASELINE, FW_NORMAL,
                              FALSE, FALSE, FALSE, OEM_CHARSET,
                              OUT_DEFAULT_PRECIS, CLIP_DEFAULT_PRECIS,
                              NONANTIALIASED_QUALITY, FIXED_PITCH | FF_DONTCARE,
                              L"Bitstream Vera Sans Mono");

subsys\win32k\ntuser\misc.c (function IntGetFontMetricSetting)

   static LOGFONTW DefaultFont = {
                                    -11, 0, 0, 0, FW_NORMAL, FALSE, FALSE,
FALSE, ANSI_CHARSET,
                                    0, 0, DEFAULT_QUALITY, VARIABLE_PITCH |
FF_SWISS,
                                    L"Bitstream Vera Sans"
                                 };

subsys\win32k\objects\stockobj.c (Declaration of GDI stock objects)


static LOGFONTW OEMFixedFont =
{ 11, 0, 0, 0, FW_NORMAL, FALSE, FALSE, FALSE, OEM_CHARSET,
  0, 0, DEFAULT_QUALITY, FIXED_PITCH | FF_MODERN, L"Bitstream Vera Sans Mono" };

static LOGFONTW AnsiFixedFont =
{ 11, 0, 0, 0, FW_NORMAL, FALSE, FALSE, FALSE, ANSI_CHARSET,
  0, 0, DEFAULT_QUALITY, FIXED_PITCH | FF_MODERN, L"Bitstream Vera Sans Mono" };

/*static LOGFONTW AnsiVarFont =
 *{ 10, 0, 0, 0, FW_NORMAL, FALSE, FALSE, FALSE, ANSI_CHARSET,
 *  0, 0, DEFAULT_QUALITY, VARIABLE_PITCH | FF_SWISS, L"MS Sans Serif" }; */

static LOGFONTW SystemFont =
{ 11, 0, 0, 0, FW_NORMAL, FALSE, FALSE, FALSE, ANSI_CHARSET,
  0, 0, DEFAULT_QUALITY, VARIABLE_PITCH | FF_SWISS, L"Bitstream Vera Sans" };

static LOGFONTW DeviceDefaultFont =
{ 11, 0, 0, 0, FW_NORMAL, FALSE, FALSE, FALSE, ANSI_CHARSET,
  0, 0, DEFAULT_QUALITY, VARIABLE_PITCH | FF_SWISS, L"Bitstream Vera Sans" };

static LOGFONTW SystemFixedFont =
{ 11, 0, 0, 0, FW_NORMAL, FALSE, FALSE, FALSE, ANSI_CHARSET,
  0, 0, DEFAULT_QUALITY, FIXED_PITCH | FF_MODERN, L"Bitstream Vera Sans Mono" };

/* FIXME: Is this correct? */
static LOGFONTW DefaultGuiFont =
{ 11, 0, 0, 0, FW_NORMAL, FALSE, FALSE, FALSE, ANSI_CHARSET,
  0, 0, DEFAULT_QUALITY, VARIABLE_PITCH | FF_SWISS, L"Bitstream Vera Sans" };

Shouldn't these values been read from registry? It don't seems to me that
precompiling font names is better decision.

-- 
Configure bugmail: http://www.reactos.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.
You are the QA contact for the bug, or are watching the QA contact.


More information about the Ros-bugs mailing list