Writing my own text editor, and daily-driving it

Posted by todsacerdoti 4 hours ago

Counter60Comment10OpenOriginal

Comments

Comment by bananaboy 20 minutes ago

I love this! The line “resist the urge to push the difficult bits off to a box of statistics” particularly resonated with me!

Comment by whynotmaybe 1 hour ago

Fond memory of when I wrote an editor in the 90's because we didn't want to use "ms edit" for COBOL and asm files.

Syntax coloring, fast buffering and even a screen saver.

You could even call the compiler directly from it.

All this running on a pentium 120 and it felt a thousands times faster than today's vscode.

But vscode can edit multiple files at the same time...

Comment by willrshansen 2 hours ago

This feels like two steps up from a highly customized vim config. But I want one step up.

I want to be able to piece together an editor from modular task specific executables. Different programs for file searching, input mapping, buffer modification and display, etc. Probably similar to how LSPs are already separated from most editors.

One step less hardcore than writing a whole editor.

Anyone know of any existing projects along these lines?

Comment by kalterdev 1 hour ago

Acme [1]

It steps back from the “customize everything” mantra, believing that approach leaves users with an underdeveloped essential system. But it still has two major APIs: one for window manipulation [2], the other for text-based integration with the surrounding system via plumber [3].

All textual CLI tools (that is, those without pseudographics) work by default and are the heart of its style.

I use Acme for everything except web browsing (although most links are still managed by Acme).

[1]: http://youtu.be/dP1xVpMPn8M

[2]: http://9p.io/magic/man2html/4/acme

[3]: http://9p.io/sys/doc/plumb.html

Comment by mudkipdev 1 hour ago

I would recommend using the ropey crate for easy performance gains. A string buffer is quick to implement but you will hit a wall as soon as you need to edit large files.

Comment by codazoda 2 hours ago

I use my own text editor too. Nobody else seems to get value from it. I’m still surprised by the value we get from home grown solutions.

Comment by altilunium 1 hour ago

I use my own text editor too.

Sometimes I get surprise questions from my friends whenever they see my screen. “What’s that?” “That’s my own text editor!”

Comment by willrshansen 2 hours ago

Didn't even link it. :(

Comment by mllev15 1 hour ago

Josh Barretto is the genius behind the Super Mario 64 GBA port. I would gladly use his editor.

Comment by abktowa 1 hour ago

Should make my own text editor. Would make for an interesting project at least.

Comment by zacklee-aud 2 hours ago

[dead]

Comment by shablulman 2 hours ago

[dead]