heyman / heynote

A dedicated scratchpad for developers
https://heynote.com
Other
3.86k stars 194 forks source link

Keep initial indentation for wrapped lines #187

Open jacobcarpenter opened 7 months ago

jacobcarpenter commented 7 months ago

First off, heynote is awesome; thanks so much! Also, I totally respect your hard stance on scope creep, so no worries if this doesn't make the cut.

In VS Code, with word wrap on, the wrapping wraps to the column of the first non-whitespace character:

Screenshot 2024-02-05 at 11 00 19 AM

In heynote, the word wrap wraps to flush left:

Screenshot 2024-02-05 at 11 02 06 AM

I prefer VS Code's approach, especially for ad-hoc markdown style lists, and would love to see that behavior in heynote. Thanks for your consideration!

heyman commented 7 months ago

Hey!

I agree that keeping the indentation for the wrapped lines is nicer. The line wrapping in Heynote is currently handled by CodeMirror, and I don't think CodeMirror's line wrapping functionality supports this out-of-the-box, so it would have to be implemented as a CodeMirror extension.

At the moment, I don't have time to work on this, but I'd happily accept a well-implemented PR.