Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Is there a modern text editor that only supports ASCII, so I can take my plain text notes and store pages and pages of them in one or two KB?


Maybe, but there's no reason to use an ASCII-only text editor. (Almost) all modern text editors use UTF-8. And UTF-8 stores all the characters in the 7 bit ASCII table the same way ASCII does.

The result of that is, so long as you don't add any emoji or anything to your documents, a 2022 version of VS Code will store your text files in the same format as vi did in 1976.


Until you copy and paste from a website that is using em dash, en dash or smart quotes...


Even if your editor "supports" other encodings than ASCII -- i e. it can save text in other formats -- many (most?) of them can be set to save in some particular encoding by default (so set it to save as ASCII), and usually they save previously-existing files in the same encoding the files already had.

And, as someone already mentioned, all the first 127 characters of the UTF-8 encoding are the same as the ASCII ones, so a UTF-8-encoded file containing only those characters is identical to -- is -- an ASCII-encoded file.


Numerous modern editors support ASCII. There's no reason to want one to only support ASCII, and it certainly isn't required to deal with plain text notes.

Where do you store them now?

And 2 KB is 2 thousand characters ... "pages and pages" of notes sounds like more than that.


One nice alternative is a clipboard widget for your OS that strips formatting and other stuff out. I use "PureText" on windows to remove formatting and it works great for me for many things, though it only strips rich text formatting.


Most of them should have an ANSI setting. It might be stashed as an option in the save dialog. If space is really an issue, zip them. Plain text always compresses wonderfully.




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

Search: