Hacker News new | past | comments | ask | show | jobs | submit login

I don't see why this is so. I like auto removal of trailing space, I don't see why you can't combine that feature and virtual space. Virtual space just means the cursor/caret moves strictly vertically as you press the up/down keys even as you visit lines that are shorter than the current offset from the left margin. If you alight at such a line and start typing text, the editor simply inserts sufficient spaces to extend the shorter line to the current offset before it inserts the text you are entering. If you are entering only spaces, that's fine too but unless you enter something else at some point all the excess space can be trimmed when you leave the line.



You're misinterpreting the problem.

Auto-removal of trailing space is only possible if the trailing space is meaningless. Many programming languages have meaningful trailing spaces which cannot be removed. The most common example is inside multi-line strings.


Fair enough, I agree that virtual space is not useful or even possible if you can't or don't want auto trimmed trailing space as well. Fortunately there are many workflows and languages where auto-trimmed trailing space is a plus, and these overlap with my areas of interest.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: