mirror of
https://github.com/fankes/termux-app.git
synced 2025-09-04 17:55:36 +08:00
There is currently a bug where selection rendering is broken if the active cursor shape is anything other than the default solid box. Selected text is normally highlighted by effectively rendering a cursor over all of the characters in the selection region, but if the cursor is a bar, the resulting selection highlight is too narrow to cover the full width of the selection. Similarly, if the cursor is an underline, all of the selected text will be underlined instead of highlighted. To fix this issue, treat selections different from cursors in the rendering logic and force the renderer to always use the block cursor style for rendering selections. That way, we get correct behavior regardless of what the current cursor shape is.