scripted-diff: Use Courier New as tabular figures font in Overview page #207

pull hebasto wants to merge 1 commits into bitcoin-core:master from hebasto:210201-mono changing 1 files +8 −8
  1. hebasto commented at 12:17 pm on February 1, 2021: member

    The https://github.com/bitcoin/bitcoin/pull/16432/commits/8d75115844baefe5cad4d82ec8dce001dd16eb9c (https://github.com/bitcoin/bitcoin/pull/16432) introduced a monospaced font for tabulated figures.

    But the Qt’s font matching algorithm does not guarantee that:

    This change suggests to use Courier New explicitly which is available on Windows and macOS by default. On Linux systems the Qt substitutes the missed Courier New font (in case it is not installed) quite well. For example, the Liberation Mono is used on my system.

    This is an alternative to #87. But personally I still lean to embedding font (#79).

  2. scripted-diff: Use Courier New as tabular figures font in Overview page
    -BEGIN VERIFY SCRIPT-
    sed -i 's/Monospace/Courier New/' src/qt/forms/overviewpage.ui
    -END VERIFY SCRIPT-
    f6a45c6327
  3. hebasto force-pushed on Feb 2, 2021
  4. luke-jr commented at 4:27 pm on February 2, 2021: member

    NACK forcing a specific font. We have GUIUtil::fixedPitchFont to workaround Qt limitations…

    Furthermore, numbers shouldn’t need a monospace font at all. Replacing the spaces with U+2007 and absent decimal point with U+2008 seems like the correct approach there.

  5. luke-jr commented at 5:55 pm on February 2, 2021: member

    Replacing the spaces with U+2007 and absent decimal point with U+2008 seems like the correct approach there.

    Problem with this approach is that we’re masking with ‘#’ which isn’t the same width as digits, and there doesn’t seem to be a good substitute. Best I could come up with was https://dpaste.com/2H7QFU9BZ

  6. laanwj commented at 6:01 pm on February 2, 2021: member
    Wouldn’t this just have to be chanaged all over again when we decide to embed the fonts? (#79)
  7. hebasto commented at 6:02 pm on February 2, 2021: member

    Wouldn’t this just have to be chanaged all over again when we decide to embed the fonts? (#79)

    I really hope we’ll move with #79 :)

  8. jarolrod commented at 1:59 am on February 8, 2021: member

    Concept 0 on this

    Embedding the font as proposed in #79 is the way to go. In embedding the font we can effectively eliminate the current issues surrounding the representation of monospace characters. This change will not directly address the issue where the font is not available, we assume that linux will choose an appropriate monospace font.

    My opinion is that we should focus on #79 instead of devoting review time to this

  9. luke-jr commented at 3:03 am on February 8, 2021: member
    @jarolrod #79 is NACK. And even if we embed a font for backward platforms like Windows/macOS, especially NACK on forcing it by neglecting support of non-embedded builds.
  10. hebasto commented at 7:12 pm on February 21, 2021: member

    @luke-jr

    @jarolrod #79 is NACK. And even if we embed a font for backward platforms like Windows/macOS, especially NACK on forcing it by neglecting support of non-embedded builds.

    Hopefully your comment is addressed in #79 (comment)

  11. hebasto commented at 7:12 pm on February 21, 2021: member
    Closing in favor of #79.
  12. hebasto closed this on Feb 21, 2021

  13. hebasto deleted the branch on Feb 22, 2021
  14. bitcoin-core locked this on Aug 16, 2022

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin-core/gui. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2024-10-23 06:20 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me