Open vassudanagunta opened 3 years ago
For reference: #2187.
If this change doesn't add performance overhead to the case when it is not enabled, it will be very welcome.
This issue has not received any attention in 1 year. If you want to keep this issue open, please leave a comment below and auto-close will be canceled.
I still plan on fixing this with a PR when I get the chance.
This issue has not received any attention in 1 year. If you want to keep this issue open, please leave a comment below and auto-close will be canceled.
Sorry, I still plan on working on this once I get through some higher priority projects, which, btw, would make use of the proposed custom wrap indent functionality.
This issue has not received any attention in 1 year. If you want to keep this issue open, please leave a comment below and auto-close will be canceled.
Still plan to do this.
Currently Ace supports three wrapping behaviors:
wrap indent disabled:
text mode, wrap indent enabled:
code mode, wrap indent enabled
These behaviors are hard-coded, without any way for a Mode to hook in custom behavior to suit the particular conventions of its file type, nor a means to add configuration options.
Some desirable alternate behaviors:
In plain text, wrap indentation that aligns with the content on the first line gives the most legibilty. I fact, CommonMark specifies this for hard wrapping of list content because
In code, some prefer semantic indentation, such as wrapping wherein arguments are aligned
I propose that
getWrapIndent()
be customizable by Mode. I'm even willing to do the implementation. But first, would such changes be approved by the project maintainers?