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

Feature request: option to not insert empty line when wrapping line that exactly hits limit #3235

Open
Tachytaenius opened this issue Apr 7, 2024 · 2 comments

Comments

@Tachytaenius
Copy link

With word wrap on, if a line has the exact minimum length to be wrapped, an empty line is displayed between it and the next line in the file (which isn't what modern GUI editors tend to do).
My suggestion is for an option to disable this behaviour so that the line that has the exact minimum length is not wrapped.

Empty lines being displayed where they shouldn't be breaks structure and grouping made with empty lines. Worse when writing prose in the style of a book (intended paragraphs with only one line break between them, not two).

I tried to edit a clone of micro to do this, but nothing I tried actually removed said blank lines. If it's not a change that fits in micro then some direction on how to do it, plugin or source edit, would be appreciated!

@Tachytaenius Tachytaenius changed the title Feture request: option to not insert empty line when wrapping line that exactly hits limit Feature request: option to not insert empty line when wrapping line that exactly hits limit Apr 7, 2024
@dmaluka
Copy link
Collaborator

dmaluka commented Apr 7, 2024

But where will we display the cursor at the end of this line?

which isn't what modern GUI editors tend to do

That's because they are GUI editors, so they usually display the cursor as a thin vertical line "between" characters. Micro is a terminal editor, and terminals usually display the cursor as a thick bar occupying the entire character, and micro has no control over that. So if we want both the line itself and the cursor at the end of it to be visible, and the line itself occupies the entire window width, there is no room for the cursor in that line, so we need an empty line below it, to display the cursor there.

@Tachytaenius
Copy link
Author

Setting the word wrap limit to be one to the left so that there is a vertical strip for the cursor to sit in would be an acceptable compromise IMHO.

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

2 participants