Last night I finished writing a ray tracer for class. Super basic, no antialiasing, only a couple primitives, but still fun.
It was also my first real project in Rust. Overall, great experience. The borrow checker was mystifying at first (and admittedly still is to some degree), but it wasn’t as bad as I’d expected. And the language itself is lovely to code in. Great ergonomics, even if the syntax is occasionally intimidating. I’m excited to do more with it. (I’ve been thinking about possibly rewriting md2epub in either Rust or Go at some point.)
Tectonic is an intriguing modern TeX engine written in Rust and powered by XeTeX.
What exactly that last bit means, I’m not entirely sure. But what I do know is that Tectonic is a much smaller install than MacTeX, and my initial tests came out with no problems whatsoever. Also, by default it doesn’t write out those intermediate .aux/.log files. I’m planning to use it instead of MacTeX going forward.
Switched from Chrome to Firefox yesterday. (I don’t really trust Google anymore and figured it was finally time to make the move.) Other perks: multi-account containers, theming via userChrome.css, supporting Rust. Happy so far, though it’s admittedly only been a day.
As mentioned on Twitter, I’ve decided to write my own typesetting engine, called Ink. Apparently I’m crazy.
The details are still very much in the air, but here are some quick notes:
Written in Rust (for speed)
Programmatic (sort of like TeX)
Intended for use in typesetting book interiors, covers, and charts
Possibly some kind of template/data division
Full OpenType feature support (shaping via HarfBuzz)
Custom PDF generation library (inkpdf)
Reasons for doing this insane thing:
PlotDevice only runs on OS X and I want the source of my language charts to be usable on other platforms.
I’d like to open source the books I typeset, so InDesign isn’t a great solution.
TeX is powerful and well-seasoned and all, but it’s not exactly pleasant or easy to work with, especially for the kind of stuff I do.
I’ll learn a lot and have fun while I’m at it.
The initial roadmap, not necessarily in order:
Write inkpdf in Python (which I think will be a better fit for the charts anyway)
Get familiar with HarfBuzz
Port inkpdf to Rust
Plan out the Ink language (I’ve started on this and it’s looking promising)
Figure out how scripting is going to work and embed the interpreter
I’ll document the process on this blog, of course. First steps: reading the PDF spec and figuring out how to make PDFs by hand.
(For those who’ve been reading for a while, Ink was also the name of my static blog engine. That’s now ink-static, and at some point I’ll either retire it completely or change the name to something unrelated.)