Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weโ€™ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Right one eight block character rendering incorrectly #3097

akinsho opened this issue Nov 13, 2020 · 1 comment

Right one eight block character rendering incorrectly #3097

akinsho opened this issue Nov 13, 2020 · 1 comment


Copy link

akinsho commented Nov 13, 2020

Describe the bug
Hi, firstly thank you for all your hard work on this project, it's very much appreciated ๐Ÿ™๐Ÿฟ .

The issue:

When rendering the right one eight block character (U+2595, โ–• ) in Kitty it seems to render an incorrect block character instead. I noticed #3025 but rather than not appearing the character is just not the right one.

The image is of the left one eight block beside the right one eight block.



To Reproduce
Steps to reproduce the behavior:

  1. Open kitty
  2. paste in โ–•
  3. See error

Expected behavior
Up till 0.19.0 this behaviour was correct and I have only seen this since. Ideally this character would be rendered correctly as it was previously

If applicable, add screenshots to help explain your problem.

Environment details
OS: Name and version of operating system(s)
Ubuntu 20.10

Output of kitty --debug-config

kitty 0.19.2 (e06ef732d8) created by Kovid Goyal
Linux pyrelight 5.8.0-28-generic #30-Ubuntu SMP Thu Nov 5 13:24:33 UTC 2020 x86_64
Ubuntu 20.10 \n \l
Loaded config files: /etc/xdg/kitty/kitty.conf, /home/akin/.config/kitty/kitty.conf
[318 09:17:36.457074] Could not find included config file: /home/akin/akin.conf, ignoring
Running under: X11

Config options different from defaults:
active_border_color                Color(red=153, green=153, blue=153)
background                         Color(red=40, green=44, blue=52)
bold_font                          Operator Mono Bold Nerd Font Complete
bold_italic_font                   Operator Mono Bold Italic Nerd Font Complete
color0                             Color(red=40, green=44, blue=52)
color1                             Color(red=224, green=108, blue=117)
color10                            Color(red=86, green=182, blue=194)
color11                            Color(red=229, green=192, blue=123)
color12                            Color(red=97, green=175, blue=239)
color13                            Color(red=190, green=80, blue=70)
color14                            Color(red=86, green=182, blue=194)
color15                            Color(red=171, green=178, blue=191)
color2                             Color(red=152, green=195, blue=121)
color3                             Color(red=229, green=192, blue=123)
color4                             Color(red=97, green=175, blue=239)
color5                             Color(red=190, green=80, blue=70)
color6                             Color(red=86, green=182, blue=194)
color7                             Color(red=151, green=158, blue=171)
color8                             Color(red=57, green=62, blue=72)
color9                             Color(red=209, green=154, blue=102)
confirm_os_window_close            2
copy_on_select                     clipboard
enable_audio_bell                  False
enabled_layouts                    ['tall:bias=55;full_size=1', 'stack', 'fat', 'horizontal']
focus_follows_mouse                True
font_family                        FiraCode Nerd Font
font_size                          13.5
foreground                         Color(red=151, green=158, blue=171)
hide_window_decorations            1
inactive_border_color              Color(red=118, green=118, blue=118)
inactive_text_alpha                0.6
italic_font                        Operator Mono Book Italic
macos_quit_when_last_window_closed True
mouse_hide_wait                    0.0
placement_strategy                 top-left
scrollback_lines                   10000
selection_background               Color(red=151, green=158, blue=171)
selection_foreground               Color(red=40, green=44, blue=52)
tab_separator                      |
update_check_interval              0.0
window_border_width                (1.0, 'pt')
Added shortcuts:
         control+right KeyAction(func='move_window', args=['right'])
         control+left KeyAction(func='neighboring_window', args=['left'])
         control+down KeyAction(func='neighboring_window', args=['bottom'])
         control+up KeyAction(func='move_window', args=['top'])
         shift+control+a KeyAction(func='kitty_shell', args=['window'])
         shift+control+e > c KeyAction(func='edit_config_file', args=())
         shift+control+g KeyAction(func='kitten', args=['hints', '--type=linenum --linenum-action=tab nvim +{line} +{path}'])
         shift+control+z KeyAction(func='kitten', args=[''])
         shift+control+backslash KeyAction(func='toggle_fullscreen', args=())
Removed shortcuts:
         shift+control+a > 1 KeyAction(func='set_background_opacity', args=['1'])
         shift+control+a > d KeyAction(func='set_background_opacity', args=['default'])
         shift+control+a > l KeyAction(func='set_background_opacity', args=['-0.1'])
         shift+control+a > m KeyAction(func='set_background_opacity', args=['+0.1'])
         shift+control+e KeyAction(func='kitten', args=['hints'])
Changed shortcuts:
         shift+control+minus KeyAction(func='decrease_font_size', args=())
         shift+control+period KeyAction(func='next_layout', args=())
         shift+control+equal KeyAction(func='increase_font_size', args=())
         shift+control+c KeyAction(func='close_window', args=())
         shift+control+h KeyAction(func='previous_tab', args=())
         shift+control+l KeyAction(func='next_tab', args=())
         shift+control+n KeyAction(func='new_tab', args=())

Additional context
This problem persists despite running kitty --config NONE as I don't believe it to be related to my font as I have tried switching between different ones

Please let me know if you need anymore information.

@akinsho akinsho added the bug label Nov 13, 2020
Copy link

kovidgoyal commented Nov 13, 2020

Well, it's somewhat of a conundrum. The problem is your cell width is not a multiple of eight. So the question becomes what to do with the extra pixels. Currently what kitty does is simply draw the last eight bar extra thick. So if you draw all eight blocks the entire cell gets filled. There are various alternative approaches, you could instead fix the thickness of every eight bar and distribute the extra pixels either before, after or both. It's not clear to me which strategy is the "correct" one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
None yet

No branches or pull requests

2 participants