Skip to content

Highlight parenthesis character only and not the entire block #118

@joelostblom

Description

@joelostblom

Originally from jupyterlab/jupyterlab#15196 where it was suggested that this is a better fit for jupyterlab-vim

Problem

Currently, matching parenthesis are indicated by highlighting the entire block the parenthesis is in, rather than just the parenthesis character itself. This makes it difficult to tell apart the cursor from the highlighted parenthesis as they melt into each other as you can see in this short clip:

jlab-cursor-2023-10-01_14.45.47.mp4

a block cursor from a highlight parenthesis and is confusing when moving through text quickly.

Proposed Solution

I think it is much easier to keep track of the cursor position if just the parenthesis character is highlighted, rather than the entire block. This is how things look in vim for me:

vim-cursor-2023-10-01_14.46.52.mp4

Additional context

I believe this is a recent change, possibly new in 4.0, because I recently upgraded from 3.6 and immediately reacted to how hard it was to tell where my cursor is. Note that I do use vim mode for the cursor to be a block, but I believe this is a general issue for any block cursor.

Any CSS workaround that can be applied right away until there is a fix forthis would be much appreciated. I think this also affect non-block cursors to a lesser extent because the block highlight generally introduces more visual noise

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions