mirror of
https://github.com/unshackle-dl/unshackle.git
synced 2026-11-13 12:35:05 +00:00
fix(console): count a virama conjunct as one cell
A Hindi conjunct such as न्द in हिन्दी drew the --list border one cell short.
This commit is contained in:
@@ -22,3 +22,8 @@ def test_panel_pads_an_indic_label_to_the_border() -> None:
|
||||
Console(file=out, width=20, color_system=None).print(Panel("हिंदी"))
|
||||
|
||||
assert out.getvalue().splitlines()[1] == "│ हिंदी" + " " * 12 + " │"
|
||||
|
||||
|
||||
def test_a_virama_conjunct_shares_one_cell() -> None:
|
||||
assert cell_len("हिन्दी") == 4 # न्द is one conjunct
|
||||
assert cell_len("ಕನ್ನಡ") == 4 # a Kannada virama does not join, so ನ್ನ keeps two cells
|
||||
|
||||
Reference in New Issue
Block a user