Line numbers aren't displayed correctly with line wrapping disabled

Open
#2,349 1 comment 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 1 day

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
56/100
Issue type
Bug
Clarity
Mostly clear
Activity status
Active
Domain
frontend

Research direction

Start by reproducing the issue with the three supplied settings, then inspect the line-number display and cursor movement entry points in Lem. Compare the displayed relative line numbers as the cursor moves with wrapping disabled; done when they remain correct. The issue does not name specific files or tests.

Written by the indexing model from the issue text.

Description

https://github.com/user-attachments/assets/c28bc7ce-4c25-4334-a391-5a4d65c184b3

To reproduce use these config:

(setf (variable-value 'line-wrap :global) nil)
(lem/line-numbers:toggle-line-numbers)
(setf lem/line-numbers:*relative-line* t)

And try to move the cursor any amount of lines down.

Specs:
Lem: https://github.com/lem-project/lem/commit/db85cfb10f8506bf9a645937fd6abcd7e4564ea2
SBCL 2.6.9-1.fc44
Fedora 44, Linux 7.2.11-200.fc44.x86_64
Sway 1.11
SDL2_ttf 2.24.0, SDL2_image 2.8.12
SDL2 library: sdl2-compat-2.32.74-1.fc44.x86_64

Dominant language
Common Lisp
Stars
3.1k
Forks
261
Avg merge
1d 6h
Merged PRs (30d)
133

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from lem-project/lem

All issues in lem-project/lem

Similar issues

More Web Dev issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.