Live data from Hacker News

Writing my own text editor, and daily-driving it

blog.jsbarretto.com

101–110 of 124 posts

Re: Writing my own text editor, and daily-driving it

#101

This was so nice to read, I've been trying to encourage my friends to write their own editors, there's something really nice about the process of working within your own tool. I've used my own text editor(it's call Left) for nearly 10 years, it took time to get it just right, but I iterated over the years(using Left to edit Left) but that time I spent putting it together is paid back 20x by the joy it gives me openin…

What were the features that were most important to you in your text editor? Did you try to build it for multiple types of workflows?

Re: Writing my own text editor, and daily-driving it

#102

Would like to see someone make their own WYSIWYG editor.

I actually did this back in the late 90s! The editor was called "Scorpio"[1]. It was written for the classic MacOS in some version of C with objects, maybe Think C(?). I'm not 100% sure.

It's an amazing fun thing to do, but I probaby wouldn't wan't to do it again now. This thing didn't handle unicode (I had never heard of it), barely handled spell checking and didn't handle bi-directional input.

Text (1 byte per char) was stored in a big array on the heap. Styles were also an array (again on the heap) of fixed length structs. Font information, in the form of fixed-point width tables, was gathered from system calls and cached.

It did actually support inline pictures though, which was pretty challenging.

Writing an editor is a hugely fun project. Highly recommended.

[1] https://atpm.com/3.03/page11.shtml

Re: Writing my own text editor, and daily-driving it

#103

This was so nice to read, I've been trying to encourage my friends to write their own editors, there's something really nice about the process of working within your own tool. I've used my own text editor(it's call Left) for nearly 10 years, it took time to get it just right, but I iterated over the years(using Left to edit Left) but that time I spent putting it together is paid back 20x by the joy it gives me openin…

What were the features that were most important to you in your text editor? Did you try to build it for multiple types of workflows?

One of the first thing I added was Leap keys-type search, I didn't want modes.

- Leap keys: https://www.youtube.com/watch?v=o_TlE_U_X3c

The second was pragma-mark navigation, so I can always see a overview of the codebase.

- navbar: https://assets.merveilles.town/media_attachments/files/116/2...

I also wanted a local copy buffer specific to the project I work on, so I could easily manage multiple copies of the clipboard data(it's part of how I work).

Re: Writing my own text editor, and daily-driving it

#104

This was so nice to read, I've been trying to encourage my friends to write their own editors, there's something really nice about the process of working within your own tool. I've used my own text editor(it's call Left) for nearly 10 years, it took time to get it just right, but I iterated over the years(using Left to edit Left) but that time I spent putting it together is paid back 20x by the joy it gives me openin…

I'm 19 years into using my own ("aoeui"), and it's one of the best things I ever did for my own productivity.

hell yeah that's awesome, I wish I had that insight when I was your age so I didn't waste my time editor hoping for 5 years.

Re: Writing my own text editor, and daily-driving it

#106

Earlier quoted context omitted.

I'm 19 years into using my own ("aoeui"), and it's one of the best things I ever did for my own productivity.

hell yeah that's awesome, I wish I had that insight when I was your age so I didn't waste my time editor hoping for 5 years.

I'm curious, how old do you think I am?

Re: Writing my own text editor, and daily-driving it

#107

I laughed out loud when the author wrote 'it replaced nano'. So you are claiming to have tried dozens of editors, discarded them, only to land on nano as your daily driver? If that's true, this person must be a character.

No, the author used Howl for their normal work and Nano occasionally. I would guess when working in the terminal

Re: Writing my own text editor, and daily-driving it

#109

Earlier quoted context omitted.

hell yeah that's awesome, I wish I had that insight when I was your age so I didn't waste my time editor hoping for 5 years.

I'm curious, how old do you think I am?

Oh damn, I very much misread your message as "I'm 19 and using my own-"

Yeah, okay you have 10 years of dogfooding ahead of me X)

Sorry. Still, goals.

Re: Writing my own text editor, and daily-driving it

#110

One of the best kept secret and one that he should have tried is "Kate". Good old style editor that is a native app, not an electron app. All the features that you might want and more, but simple and efficient. And the most important for me, super snappy. I can't bear the latency that you get for typing code when using things like vscode. I don't know how people can appreciate that.

I know this is just one data point, but I don't notice any latency when typing code in VS Code. It takes a while to start up, and that is annoying especially for quick short editing jobs, but other than that I never notice any sluggishness. Is this something many people experience?

I'll get into WSL2 situations where it seems like intellisense activity delays the display of characters I type. Feels like the old dynamic dropdown problem.
Post reply on HN