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

Shift + up/down arrow key behavior is erratic when crossing code blocks, sometimes, selects inside them, sometimes jumps to document start/end #6061

Open
hsandt opened this issue May 27, 2024 · 0 comments

Comments

@hsandt
Copy link

hsandt commented May 27, 2024

Describe the bug
Generally speaking, it's not always easy to select code blocks, but at with if you drag across a code block with the mouse it's possible to highlight the whole code block + some lines above and below.

When using Shift + arrow keys for precise selection though, behavior is quite inconsistent, esp. down arrow.

Here, I'm trying hard to select further down but blocked by some invisible wall. I finally manage to select a few lines, but a visual glitch makes the line numbers flash (this also happens when selecting upward - it's not visible on the low FPS gif below though).

When trying to go back up, I am warped to document stop.

Sometimes, when I should enter the code block's first line, I also jump select until document end - but I couldn't repro on this shorter MWE.

Peek 2024-05-27 Typora shift down and up odd behavior

To Reproduce
Steps to reproduce the behavior:

  1. Write some text, then add a code block with some text below, then more text below. Here is a short sample:
SOME TEXT

SOME TEXT

SOME TEXT

```
some code
some code
some code
```

MORE TEXT

MORE TEXT

MORE TEXT
  1. Click above the code block
  2. Hold shift and press Down arrow multiple times
  3. ... then Up arrow multiple times
  4. Try the same, starting from below the code block
  5. Observe line numbers flashing, selection being stuck and sometimes warping to document start/end

Expected behavior
Shift+up/down should extend/shrink selection line by line as usual, reliably.

Desktop:

  • OS: Linux Ubuntu 22.04, Unity desktop

Typora Version
e.g: 1.7.6

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

No branches or pull requests

1 participant