Skip navigation.

Notes to self

Whatever I feel like writing

Posts tagged with "textjure"

Textjure

, ,

What have I been up to, code wise, in my spare time? I felt like talking about this because I think it has gotten mildly interesting lately.

It hasn't been Fabric. I started Fabric, not because I thought it would be a fun thing to do, but because I absolutely needed a tool that did exactly what Fabric does. And ever since Fabric got to the point where it more or less completely scratches my deployment itches, my time-investment in it has pretty much retreated to maintenance mode.

No, my spare time is now primarily spent on the Clojure programming language, in some form or another.

When it comes to programming languages, I learn by doing and I think most people feel the same way; you can't learn how to write code if you don't write code. I learned Python by writing a blogging engine (how original) in it using Django, and then Fabric.

Now, I'm learning Clojure. I started out with the Euler problems but ran out of steam; the math problems just wasn't my thing. Then I was mostly idling around the clojure.core source code and the Java code, looking for a cool idea to try out but nothing really jumped out at me. I proposed a number of what I thought would be language improvements - with patches'n'all, but each and every one of them was turned down. Oh well.

Then, drifting aimlessly around Github, I stubbed my toe on a tiny little thing that Chris Houser had done. I was a text editor, but hardly even complete enough to be called a prototype.

I downloaded it and fired it up. I was mildly surprised the thing actually started and showed a little window with two parts: and editor panel and a build-in Clojure REPL that actually worked.

The interface wasn't terribly exciting, though. The window was tiny and placed in the top-left corner, and the program could not be started without naming a file to open.

I dug into the code - what little there was of it - and fixed those things. Made the window chrome-less and full-screen, and pivoted the editor/repl-split to a left-right configuration to better utilize my wider-than-tall screen resolution. It actually worked ad wasn't terribly difficult.

Then I found out that the thing actually had no functionality in the way of opening and saving files. Also, the key-binding looked messy. I turned to these issues next.

One thing leads to the next, and textjure is now slowly shaping up to be a genuinely useful text editor, though it is still woefully underfeatured.

The code is in my fork of Chris Housers repository: http://github.com/karmazilla/textjure/tree/master

The feature that I'm currently working on is syntax coloring. Following this, is stuff like indenting, incremental search and REPL-history. Then I guess I'll properly announce my work on the Clojure Google Group.

I always knew that I would eventually find something fun to hack on with Clojure, but I would never have imagined it would be a text editor. :smile: