Uploaded image for project: 'Core ReactOS'
  1. Core ReactOS
  2. CORE-13182

Improvements for the console props dlg "Font" tab

    XMLWordPrintable

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Fix Version/s: 0.4.6
    • Component/s: Win32SS
    • Labels:
      None

      Description

      Rewrite the way we deal with console font samples in the console properties dialog:

      • Remove the font helper functions that were already moved into concfg/font.c in r74462, and use the latter instead.
      • Use a double list for listing the available font sizes for a given face:
      • a ListBox for raster fonts;
      • a ComboBox for TrueType fonts, allowing the user to specify a custom size.
        The raster ListBox is wrapped using the LIST_CTL structure so that we can use
        the bisection functions on it.
      • Allow the user to specify TrueType font size either in pixels or in points. Raster font sizes however are always in pixels.
      • Try to remember the nearest font size across different selected face changes.
      • Try to support custom-sized TrueType fonts (using the ComboBox's edit field). May need more improvements!
      • Retrieve the correct character cell height & width size in pixels when selecting a font (especially when it's a TrueType one).
      • We now support bold console fonts too, see CORE-13122 (thanks Katayama Hirofumi MZ!).
      • Remove the commented-out "temporary code for future reference".
      • Use a global cached font "hCurrentFont" that gets initialized when the console properties applet is created,
        so that we now can have a correct font in the screen samples when one directly views e.g. the "Color" tab,
        without going first in the "Font" tab. This current font is of course updated whenever one changes the font settings.

      Tested with success on Windows 2003, Windows 7 and on ReactOS.

      NOTE: On ReactOS however, some fonts (e.g. TrueType Fixedsys) do not report correct metrics values (via GetTextMetrics),
      giving a wrong (off-by-one) computed character cell height & width size. They however work OK on Windows.
      Cc Katayama Hirofumi MZ for this problem (this needs a new bug report).

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                hbelusca hbelusca
                Reporter:
                hbelusca hbelusca
              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: