mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-25 01:38:02 +02:00
Add some more box-drawing characters from the "Geometric shapes" Unicode block
Fixes #7433
This commit is contained in:
@@ -80,6 +80,8 @@ Detailed list of changes
|
|||||||
|
|
||||||
- Allow more types of alignment for :opt:`placement_strategy` (:pull:`7419`)
|
- Allow more types of alignment for :opt:`placement_strategy` (:pull:`7419`)
|
||||||
|
|
||||||
|
- Add some more box-drawing characters from the "Geometric shapes" Unicode block (:iss:`7433`)
|
||||||
|
|
||||||
0.34.1 [2024-04-19]
|
0.34.1 [2024-04-19]
|
||||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||||
|
|
||||||
|
|||||||
@@ -575,6 +575,9 @@ START_ALLOW_CASE_RANGE
|
|||||||
return BLANK_FONT;
|
return BLANK_FONT;
|
||||||
case 0x2500 ... 0x2573:
|
case 0x2500 ... 0x2573:
|
||||||
case 0x2574 ... 0x259f:
|
case 0x2574 ... 0x259f:
|
||||||
|
case 0x25d6 ... 0x25d7:
|
||||||
|
case 0x25cb:
|
||||||
|
case 0x25dc ... 0x25e5:
|
||||||
case 0x2800 ... 0x28ff:
|
case 0x2800 ... 0x28ff:
|
||||||
case 0xe0b0 ... 0xe0bf: // powerline box drawing
|
case 0xe0b0 ... 0xe0bf: // powerline box drawing
|
||||||
case 0xee00 ... 0xee0b: // fira code progress bar/spinner
|
case 0xee00 ... 0xee0b: // fira code progress bar/spinner
|
||||||
@@ -611,14 +614,14 @@ static glyph_index
|
|||||||
box_glyph_id(char_type ch) {
|
box_glyph_id(char_type ch) {
|
||||||
START_ALLOW_CASE_RANGE
|
START_ALLOW_CASE_RANGE
|
||||||
switch(ch) {
|
switch(ch) {
|
||||||
case 0x2500 ... 0x259f:
|
case 0x2500 ... 0x25ff:
|
||||||
return ch - 0x2500; // IDs from 0x00 to 0x9f
|
return ch - 0x2500; // IDs from 0x00 to 0xff
|
||||||
case 0xe0b0 ... 0xee0b:
|
case 0xe0b0 ... 0xee0b:
|
||||||
return 0xa0 + ch - 0xe0b0; // IDs from 0xa0 to 0xd58
|
return 0x100 + ch - 0xe0b0; // IDs from 0x100 to 0xe5b
|
||||||
case 0x2800 ... 0x28ff:
|
case 0x2800 ... 0x28ff:
|
||||||
return 0xe00 + ch - 0x2800; // IDs from 0xe00 to 0xeff
|
return 0xf00 + ch - 0x2800; // IDs from 0xf00 to 0xfff
|
||||||
case 0x1fb00 ... 0x1fbae:
|
case 0x1fb00 ... 0x1fbae:
|
||||||
return 0xf00 + ch - 0x1fb00; // IDs from 0xf00 to 0xfae
|
return 0x1000 + ch - 0x1fb00; // IDs from 0x1000 to 0x10ae
|
||||||
default:
|
default:
|
||||||
return 0xffff;
|
return 0xffff;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1015,16 +1015,22 @@ box_chars: Dict[str, List[Callable[[BufType, int, int], Any]]] = {
|
|||||||
'': [p(triangle, left=False)],
|
'': [p(triangle, left=False)],
|
||||||
'': [p(half_cross_line, which='tr'), p(half_cross_line, which='br')],
|
'': [p(half_cross_line, which='tr'), p(half_cross_line, which='br')],
|
||||||
'': [D],
|
'': [D],
|
||||||
|
'◗': [D],
|
||||||
'': [rounded_separator],
|
'': [rounded_separator],
|
||||||
'': [p(D, left=False)],
|
'': [p(D, left=False)],
|
||||||
|
'◖': [p(D, left=False)],
|
||||||
'': [p(rounded_separator, left=False)],
|
'': [p(rounded_separator, left=False)],
|
||||||
'': [p(corner_triangle, corner='bottom-left')],
|
'': [p(corner_triangle, corner='bottom-left')],
|
||||||
|
'◣': [p(corner_triangle, corner='bottom-left')],
|
||||||
'': [cross_line],
|
'': [cross_line],
|
||||||
'': [p(corner_triangle, corner='bottom-right')],
|
'': [p(corner_triangle, corner='bottom-right')],
|
||||||
|
'◢': [p(corner_triangle, corner='bottom-right')],
|
||||||
'': [p(cross_line, left=False)],
|
'': [p(cross_line, left=False)],
|
||||||
'': [p(corner_triangle, corner='top-left')],
|
'': [p(corner_triangle, corner='top-left')],
|
||||||
|
'◤': [p(corner_triangle, corner='top-left')],
|
||||||
'': [p(cross_line, left=False)],
|
'': [p(cross_line, left=False)],
|
||||||
'': [p(corner_triangle, corner='top-right')],
|
'': [p(corner_triangle, corner='top-right')],
|
||||||
|
'◥': [p(corner_triangle, corner='top-right')],
|
||||||
'': [cross_line],
|
'': [cross_line],
|
||||||
'': [p(progress_bar, which='l')],
|
'': [p(progress_bar, which='l')],
|
||||||
'': [p(progress_bar, which='m')],
|
'': [p(progress_bar, which='m')],
|
||||||
@@ -1038,6 +1044,13 @@ box_chars: Dict[str, List[Callable[[BufType, int, int], Any]]] = {
|
|||||||
'': [p(spinner, start=360, end=540)],
|
'': [p(spinner, start=360, end=540)],
|
||||||
'': [p(spinner, start=80, end=220)],
|
'': [p(spinner, start=80, end=220)],
|
||||||
'': [p(spinner, start=170, end=270)],
|
'': [p(spinner, start=170, end=270)],
|
||||||
|
'○': [p(spinner, start=0, end=360)], # circle
|
||||||
|
'◜': [p(spinner, start=180, end=270)], # upper-left
|
||||||
|
'◝': [p(spinner, start=270, end=360)], # upper-right
|
||||||
|
'◞': [p(spinner, start=360, end=450)], # lower-right
|
||||||
|
'◟': [p(spinner, start=450, end=540)], # lower-left
|
||||||
|
'◠': [p(spinner, start=180, end=360)], # upper-half
|
||||||
|
'◡': [p(spinner, start=0, end=180)], # lower-half
|
||||||
'═': [dhline],
|
'═': [dhline],
|
||||||
'║': [dvline],
|
'║': [dvline],
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user