-
Notifications
You must be signed in to change notification settings - Fork 5.3k
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
Hard wrap support #2865
Comments
The one from codemirror interferes with undo/redo in a rather bad way. Do you know of any other editors implementing this feature? |
For JS-based editors I know that Atom editor have the autoflow plugin, it does not "live" hard wrap, but at least a keyboard shortcut to wrap selected text or current paragraph. For others, I believe that vim have this nicely handled. It wraps text as you type, but only at the point of cursor. This way it handles the most common situation easly and hopefully in a way that could be implemented in JS without performance problems. But if you start typing inside an already written paragraph it will not "reflow" the whole paragraph, but just wrap when your new text will pass the maximum column. Also if you start typing in the middle of an already written line it will wrap where you enter new text, and the already written text on the right will overlap. Also there are shortcuts to force re-wrap. It also preserves indentation, so if you start paragraph indented wrapping will preserve it. This is really. Vim wraps pasted text, if you do not want it you must temporary disable wrapping. Also the Eclipse dialog for entering Git commit messages wraps text automatically, including pasted text, additionally "reflowing" if writing inside other line. I do not even know if it can be disabled,2 |
Also GitHub Desktop does hardwrap at 72 char, with "reflow" and wrapping pasted text. |
Could someone comment on the plans of this feature? |
Ditto, would love to hard warp in overleaf with uses Ace editor. I'm not used to vim keyboard shortcuts for end of visual line etc. :'( Now I just skip vim mode when writing which is most of the time |
#4545 adds initial support for vim |
@nightwing I also came here looking for a fix for overleaf. It's awkward to be used to hit j or k and skip over the text you want cause it's soft-wrapped. gq would be useful. Your fix seems to solve my simple use case, which is just selecting a long line and hard wrapping it. So, seems useful to me, for whatever that's worth. |
We understand that hard wrapping feature would be nice for some people to have. This could come a new 'extension' under Ace. However, compared to all the other bugs and feature requests, this feature request would have low priority. Feel free to create a PR though. |
Ah, I did not notice, but we have a hardwrap.js in
|
ACE already have soft wrap support, but please add hard wrap also.
CodeMirror already have it: https://codemirror.net/demo/hardwrap.html
The text was updated successfully, but these errors were encountered: