6 ms·
Why I Wrote a Programmer's Text Editor
- kanny96 16y agoInteresting tale of the development of Kod, the Mac OS X code editor.
- danielpal 16y agoThis is awesome, I recently switched to vim after Textmate just became too outdated, but the usability of VIM is just terrible. I love what I see in Kod, but I won't change just yet, when are you planning to start charging for it ? I'll change when I can pay for it.
- jjcm 16y agoLove the chromium backend of it - I'd love it even more if it were merged with vim in a macvim-esque sort of way.
- Derbasti 16y agoThis! Oh, this!
- xtacy 16y agoEmacs would be awesome too. :-)
- jjcm 16y agoI agree. Both are amazingly powerful editors and seeing a nice/powerful GUI on top of it might make me switch over from a CLI. Time to branch this project.
- dsadsa 16y agoI disagree. Don't mix it. Just make port for linux so normal people can use it.
- chc 16y agoPeople who use Linux on the desktop are, statistically speaking, not even close to normal.
- burgerbrain 16y agoThis is a programmers editor. From the population of people who use such editors, using Linux really isn't all that uncommon.
- apl 16y agoSure. But for the power user, for the full-time developer, there's no point in going for something like Kod. Learning vim or emacs is actually not that hard. As Rasmus points out in this blog post, he's aiming for a different crowd: people for whom programming is a secondary activity.
- burgerbrain 16y agoI would suggest that even among the population of simply "power users", Linux usage is not uncommon.
- dhyasama 16y agoI initially read this as "people who use Linux are odd" and had a much needed chuckle. After reading it's descendants I don't think that's how you meant it, but thanks, nonetheless.
- swah 16y agoThe description says its chromium-like, not that it used code from Chrome, unfortunately.
- rasmusfabbe 16y agoIt do uses some Chromium code. See https://github.com/rsms/chromium-tabs https://github.com/rsms/chromium-tabs
- swah 16y agoCool! Detaching a tab into its own window (process?) is kinda magic for me.
- GrooveStomp 16y agoLook really nice. Too bad it's just OSX and as jjcm and xtacy pointed out, too bad it doesn't support vim or emacs bindings/integration in some way. I really like your UI choices borrowing so heavily from Chrome, though. Really do... updates personal notes
- masklinn 16y ago> too bad it doesn't support vim or emacs bindings/integration in some way. Well the bindings could probably be added[0], it's OSS and probably rather small still. Emacs integration on the other hand, that would be rather harder. [0] actually, since it uses standard Cocoa (text) controls it already has some Emacs-type bindings (C-a, C-e, C-f, C-b, C-k, C-p, C-n, ...) and you can define more (or redefine existing stuff) via DefaultKeyBinding.dict, just about any NSResponder action message (and there are quite a bunch of them) should be available for binding [1] And it even allows you to bind multiple actions to a single keystroke or to bind key sequences (à la Emacs's C-x C-s) [1] http://xahlee.org/emacs/osx_keybinding.html http://xahlee.org/emacs/osx_keybinding.html
- GrooveStomp 16y agoCool. Thanks for the resource! I've never used OSX, so I didn't know you could rebind the window manager's controls. Good stuff.
- masklinn 16y agoYeah that's one of those weird things in OSX which likely come from its NeXT roots: you can extremely easily configure/customize things you would never expect being able to touch on a non-OSS product.
- Swizec 16y agoI can attest to the awesomeness of both Kod and Rasmus. Especially Rasmus, I coded up the whole indentation feature and he had to completely rewrite everything I made because of efficiency issues (I'm not that great with objC yet) and he didn't even complain. Great guy.
- wccrawford 16y agoDon't sell yourself short. Just having a working prototype can be a god-send, no matter how inefficient.
- Swizec 16y agoIt happened to be my second time ever coding in objC, so I'm fairly certain it was crap. My later patches (think I've made two or three so far) got accepted without change :) Hope I have time soon to make the automagic indentation feature that's possible with the new AST thingy. Also hope somebody hasn't beaten me to it yet :P
- compay 16y ago> It happened to be my second time ever coding in objC, so I'm fairly certain it was crap. Your intellectual honesty and ability to judge your work dispassionately, as well as the fact that he accepted your work, lead me to believe that it might not have been crap. See: Dunning Kruger effect. :) http://en.wikipedia.org/wiki/Dunning%E2%80%93Kruger_effect http://en.wikipedia.org/wiki/Dunning%E2%80%93Kruger_effect
- lukifer 16y ago"If you can do a half-assed job of anything, you're a one-eyed man in a kingdom of the blind." - Kurt Vonnegut
- adrianparsons 16y agoCan someone explain the relationship between Kod and node.js? The Kod website says it is "based on node.js", but I don't quite get that. I'm familiar with node.js as a server-side platform, but are we about to see a bunch of node.js desktop apps?
- Swizec 16y agoIt's scriptable via javascript (because people generally get how to script with that) and is using node.js internally to run said javascript.
- rasmusfabbe 16y agoExactly. Node.js is—just like Python, Ruby or LUA—an embed-able general-purpose JS runtime. You can simply link with libnode. Kod then uses a mix of libdispatch and libev constructs to perform inter-thread communication. The code for doing this is fairly orthogonally designed and can be found in the KNode* and node* source files.
- mahmud 16y agoI don't think anything is like Lua when it comes to embedding; I mean, it's what, 100k? Hard to top that.
- die_sekte 16y agoio[1] has 10k lines and is embeddable. It's somewhat similiar to Lua. [1]: http://www.iolanguage.com/ http://www.iolanguage.com/
- silentbicycle 16y agoLua's performance is dramatically better, and it has a more mature toolchain. I'm interested in io, too, but I've had trouble even getting it to build on BSD.
- 16y ago
- eob 16y agoI'm really looking forward to seeing this project develop. It has the potential to spawn a whole host of "webby" editing components.. As Rasmus aluded, in-browser editors aren't really tractable right now, but if everything about Kod but the runtime is written in JS, you could imagine all sorts of interesting browser ports or hosted options down the road.
- zyb09 16y agoNice, just found Kod yesterday while browsing around Github and gave it a try. Really like the dark syntax highlighting, looks very pleasing. I seem to have a font-rendering issue though, the text looks kinda blurry.
- swah 16y agoThis comment perfectly encapsulates the value proposition.
- w1ntermute 16y agoIs the font rendering on this guy's site screwed up for anyone else? The "t"'s have something wrong with them: http://ompldr.org/vNzVrZg/why_i_wrote_a_programmers_text_editor.png http://ompldr.org/vNzVrZg/why_i_wrote_a_programmers_text_edi... Firefox 3.6 on Linux.
- pkamb 16y agoCame in to say that his "t"s looked really weird. Chrome.
- brown9-2 16y agoChrome 8.0 on Windows 7, yes.
- roxstar 16y agoLooks okay on chrome 9 on ubuntu lts: His two font choices Georgia: http://i.imgur.com/Lp6QL.png http://i.imgur.com/Lp6QL.png Droid Serif: http://i.imgur.com/0Kja4.png http://i.imgur.com/0Kja4.png
- w1ntermute 16y agoYeah, it looks OK for me in Chromium (dev channel) & Opera as well.
- joakin 16y agoHe is using font face embedding of the 'Droid Serif'. Probably some issue with the typography conversion or with windows rendering the fonts badly (i get the weird t also in windows 7).
- naner 16y agoI think it is a bug in the font he's fetching.
- rasmusfabbe 16y agoSeems to be an issue with the Droid font files. I'll look into it.
- 16y ago
- btipling 16y agoPlan on putting it in the Mac App Store?
- rasmusfabbe 16y agoEventually. Kod is still a very young and a relatively immature product, but as it stabilizes (in several aspects) we will make it available in the Mac App Store.
- po 16y agoI was particularly surprised by the behavior of the tab key: https://github.com/rsms/kod/wiki/Indentation https://github.com/rsms/kod/wiki/Indentation In a nutshell, if you press tab while anywhere on a line, it indents. Shift-Tab de-dents the line. After thinking about it a bit, I think I could get used to it. I like that they're exploring ideas like this. I would like preferences "CMD ," to be bound to something though even if it's to opening the configuration file itself. It's a bit disconcerting to not be given an explanation of why there are no preferences. I didn't understand the reasoning until I read this blog posting.
- emef 16y agoI think you're describing the type of behavior that emacs uses when you press tab, except it indents the line according to the default tab style associated with the file type. It's great for programming; I never have to worry about indentation because it's handled automatically.
- krig 16y agoI use smart-tab.el in emacs, the completion/tab handling is the most intuitive I've found. http://www.emacswiki.org/emacs/TabCompletion#toc2 http://www.emacswiki.org/emacs/TabCompletion#toc2 It expands if at the end of a word, and indents otherwise.
- yesimahuman 16y agoDoes anyone know how the tabs are integrated into the system? Is it a library or did he just try to recreate the experience?
- terhechte 16y agoHe used the Chromium Tabs: https://github.com/rsms/chromium-tabs https://github.com/rsms/chromium-tabs
- yesimahuman 16y agoHey thanks! I wish github had search through code bases!
- rgbrgb 16y agoWhat about TextMate? Is this aimed at a different crowd?