Unicode Box Drawing characters not printed in Ruby

前端 未结 1 1600
失恋的感觉
失恋的感觉 2021-01-27 23:22

I work on a game in Ruby. It uses ncurses to draw window contents and refresh the screen. This all works fine on macOS, where I develop the stuff. But on Linux, I cannot get any

相关标签:
1条回答
  • 2021-01-27 23:51

    Actually this should be several questions, but the most recent one asks how the characters could be shown as double-width.

    The screenshot does not match the given example program. That only draws a few sample characters, while the screenshot shows boxes.

    However, the particular line-drawing characters can be the problem, versus the locale tables (and depending on the actual program used). That's because those codes are ambiguous width (see U+2550). The standard leaves it up to the implementer whether to treat them as single-width or double-width. Not everyone agrees on the actual width.

    If this were a bug report, I'd get the actual program source to test with, but suspect the problem lies in Ruby.

    0 讨论(0)
提交回复
热议问题