Fine, I'll build my own text editor

(dbushell.com)

38 points | by Alephinitesimal 12 hours ago

8 comments

  • stillpointlab 1 minute ago
    I literally just got Fable to write me a text editor. Well, I'll be honest, I got it to wrap the KDE KTextEditor library which is like 90% of a text editor.

    I had been using Kate which was what an LLM suggested was the closest to something like Sublime Text on Fedora. But even Kate, which was great, had too much going on.

    So I asked Fable to take the text editor part (KTextEditor) and wrap it using Rust with an LSP server. It took about 2 days but I have a tiny, super fast little editor. I use Sway to manage things like tabs, fuzzel stands in for fuzzy file search, broot stands in for an explorer view. I've already added Markdown preview support. I might get around to some basic git integration.

    Then I got it to turn that little editor into a note-taking interface that I have bound to a Mod-m key binding to keep notes in ~/Notes.

    We live in wild times. I hope everyone is taking advantage while they can.

  • akersten 7 minutes ago
    Yes, who would have guessed that the <textarea> element, designed specifically for this use case and built into browsers for 3 decades, would be the most performant and behaviorally consistent way to implement editable text.

    I'm kind of sad the author stopped shedding unneeded complexity there though... we're not really building a text editor yet, we're building a website with a fancy input field. If we want to build a proper text editor we must eschew the bloat that is the web browser too.

  • pmkary 1 hour ago
    Text editors are like mechanical watches or fountain pens. There is just so much beauty in the machinery that makes them. For me, there are hardly any other modules that are this satisfying to watch being made. Each time I find a new one (a good one like this), with everything on ropes and rendering and I-beam placement computations and ... it feels like a Christmas gift.
    • pmkary 1 hour ago
      Just what part of this comment deserved to get a -1 point leaves a whole universe of imagination to me and no answer :/
      • ameminator 35 minutes ago
        Sometimes people down vote for no reason. Unfortunately, when one complains about it, they look like a whiner.
      • pmkary 59 minutes ago
        Literally I only praised and wrote how much I love something and how beautiful text editors are. And there are people who cannot stand this :))) oh wow!
      • roarcher 53 minutes ago
        A word of unsolicited advice: HNers are a prickly lot and will downvote without explanation because you stepped on some unknowable pet peeve of theirs that probably nobody else in the world shares. This happens all the time but you likely only notice when you happen to get downvoted before any upvotes and end up at 0 or -1. If your comment is reasonable, it will usually come back up.

        But complaining about downvotes will certainly earn more of them.

        • jasonkester 7 minutes ago
          Don’t forget the old “downvote the other comments so mine goes to the top “ trick.

          All your best stuff will get downvoted by at least somebody eventually. For some reason, that somebody always gets in early enough that you notice.

      • fsckboy 7 minutes ago
        i didn't downvote it but I thought it was pretty empty. "how do i love thee, let me count the ways" has been done before, and his love was more interesting than that you like text editors generically, and you don't mention anything you like. I'm not in favor of more poesy in tech circles.

        i like text editors but I feel they contain "everything but the kitchen sink" (if you know you know) and that makes them somewhat impenetrable and difficult to modify and bend to new purposes even though they contain so much capability and potential, and the people who do understand them think it's a good idea to drag and drop an URL and have that do a web transaction and download a buttload of text, when what I wanted was just the text... of the url. I'm sure there's some way to turn it off, but instead there should be some way to turn it on. Oh yeah, worse when it's a jpg url, guess what they do with that.

        in another direction, the point of markdown was to be editable and readable in source form, not to be a replacement for rendered HTML, but the same people who ruined HTML by overloading it are now fully engaged in ruining markdown by overloading it and making it unreadable in source form.

  • dang 2 hours ago
    Recent and related:

    They don't make 'em like Sublime Text anymore - https://news.ycombinator.com/item?id=49209354 - Aug 2026 (13 comments)

    • asabla 31 minutes ago
      I used sublime text over so many years. Still find it to be a marvel when it comes to large text files, and how well it still handles them
      • cwnyth 9 minutes ago
        I still don't see a point in switching from Sublime to VS Code. If I need to SSH in to my server, I have options there. But Sublime does everything I need it to do and it does it faster and cleaner and just better than the alternatives.
  • nottorp 31 minutes ago
    There really is a fps counter on there.

    Is the experiment seriously rendering continuously in a loop?

  • samus 33 minutes ago
    Every time someone has that idea they discover that text editing is hard! Kudos to the author that they considered accessibility as well.
  • anon291 1 hour ago
    I am being pushed to use vs code right now by my team, but we already have a fully programmable and scriptable editor called emacs that is 100000x better. I don't understand why everyone just switches to these random tools. Text editing is a solved problem. Most of the supposed advantages of these tools is just a configuration of vim or emacs.
    • xedrac 39 minutes ago
      I use emacs daily (with vim keybindings of course), but I completely understand why vscode is so popular. It's extremely easy to get started with, has features galore, and sane defaults. Emacs takes much more effort to get productive with, although this is improving with each release.
    • nxc18 30 minutes ago
      If you work on web tech (and who doesn’t these days?) VS Code has the advantage of using the same tech stack you’re already familiar with. If you need to debug a problem, just open devtools. If you want to run a performance profile, do the same. If you want to fix a bug in the extension you’re using, just open a PR and fix it.

      It is a very flexible system and still quite fast and easy to configure. I’ve been trying Zed and WebStorm looking for better alternatives, but it turns out they have their own problems. Zed isn’t nearly as configurable, WebStorm’s config system is an absolute nightmare (xml for days - and constantly changing, mingling actual config with transient state).

      People complain that VS Code is slow; perhaps on some metrics and perhaps it is slower than a much less featured system like sublime. But I don’t think it is meaningfully slower in practice than Zed, and they make a lot of compromises to get that edge.

      • jotato 21 minutes ago
        I’m trying to phrase this to not be “that guy” but have you used Code on large code bases? Vscode on my m2 Mac routinely crashed when doing file search. That is why I switched to zed.

        I do miss the configurablity though

    • muppetman 27 minutes ago
      That’s easy. Because if they accept that emacs is good enough, they have to then accept that probably whatever thing they’re building is almost certainly worthless.

      26 different browsers all based on Chromium, 127 different “observability platforms” etc.

      So so much redundant rehashed stuff. We can’t accept that though, THIS TIME it’s going to be great and amazing and we’ll get a huge investment and sold to a huge company for millions.

      I’m not suggesting that it hasn’t been a huge leap in computing and software in the last 40 years.

      But we need to have faith in new being better to keep going. That’s why the new hotness is always so popular.

  • self_awareness 1 hour ago
    Text editing is a solved problem.

    It's not about the style of cursor, or if rope is used or not. We already have answers to that.

    It's about remote editing, LSP support.