Action lineMoveDown will jump to arbitrary position in the attempt to make the cursor visible
@MegatronKing is already working on this.
Since Jan 6, 2025.
Assessment
This issue has not been assessed yet.
Description
Pressing key down and reaching the end of the page will not scroll by one line, but by an arbitrary amount of lines in the attempt to make the caret visible on the screen.
Expected behavior
I would expect the screen in this case to scroll by one line - same behavior as if I scroll up, which will also always scroll the screen by one line, when we reach the top of the screen.
Device:
- all platforms
Additional context
This behavior is caused by method _CodeField.makePositionVisible line 550. In my opinion this line should be corrected from:
Current code:
if (position.index > last.index) {
_verticalViewport.jumpTo(max(0, last.bottom - size.height + _preferredLineHeight * (position.index - first.index)));
}
Correct code (replace first.index by last.index):
if (position.index > last.index) {
_verticalViewport.jumpTo(max(0, last.bottom - size.height + _preferredLineHeight * (position.index - last.index)));
}
- Dominant language
- Dart
- Stars
- 761
- Forks
- 102
- PR merge metrics
- No merged PRs in 30d
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from reqable/re-editor
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
-
enhancement
-
enhancement
-
bug
All issues in reqable/re-editor
Similar issues
-
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
code quality good first issue
Difficulty 2/5 1-3 hours Newbie friendliness 90/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 78/100
Suwayomi/Suwayomi-Tsumiru#479 ·
-
Build Failure: agora_rtc_engine compiled against android-31 while dependencies require android-34+ Open
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
-
Difficulty 2/5 1-3 hours Newbie friendliness 92/100
conceptadev/noir#95 ·