Till Schneidereit

Partly, yes

Introducing SwiftSuspenders

| Comments

Working with RobotLegs

Recently, I started working with the awesome MVCS framework RobotLegs by Shaun Smith.

As I’m not a big fan of the configuration overhead that the Spring framework for Dependency Injection brings with it, I immediately fell in love with the metadata based SmartyPants IOC framework. While I really like the approach and everything worked great, I quickly realized that SmartyPants has two problems: It’s somewhat slow and, due to some dependencies on the Flex framework, rather big.

SwiftSuspenders: A fast, lightweight DI solution

That’s why I started implementing an ultra lightweight DI framework (which hardly even deserves being called a framework) which then became SwiftSuspenders.

SwiftSuspenders implements exactly the functionality needed by RobotLegs, nothing more, but, crucially, nothing less - and it does so as fast and as lean as possible. By focusing on these needs, I was able to implement a solution that’s about an order of magnitude faster and weighs only 10% of SmartyPants file size-wise. And yes: Both of these values are SWAGs and shouldn’t be relied on for, well, anything.

Right after I published SwiftSuspenders on GitHub - as you should do with everything you build that might be of help to your esteemed colleagues - awesome stuff happened: Shaun Smith immediately forked to project, started fixing bugs and embarrasing mistakes in the documentation and switched most of the examples for RobotLegs to using SwiftSuspenders and hinted at creating unit tests - which I shamefully neglected. Yesterday, he followed up on that and pushed a range of unit tests to a new GitHub project!

What now?

Apart from you reading the introductory documentation, starting to use SwiftSuspenders and forking it on GitHub? I’m not sure.

I think that maybe, SwiftSuspenders is pretty much done as it is. SmartyPants still has some features that SwiftSuspenders doesn’t, but for now, I don’t think that those are really essential. Then again, I might implement Provider Binding and Rule Binding sometimes later - whereas I can almost guarantee that I won’t implement live bindings.

On finding Unicode ranges

| Comments

Most people don’t think in code points - which seems like a pretty good state of the world to me.

The only downside is that dealing with fonts for Flash applications and sooner or later the whole web is far more complicated than it would otherwise be. Let me explain.

Each time your client requests you use their corporate typface or your designer decides that he absolutely, positively can’t use a web-safe font for some other reason, you have to somehow get font glyphs to the user that he doesn’t already have installed on his machine. In html, this is mostly done using png’s, increasing the download time and the complexity of changing the content. But at least for Flash you can instead embed the glyphs and keep your content as text. How do you do that? You embed the font in your swf and let the Flash player use it to render the content.

Now what you don’t want to do is embed the whole font, because that’ll add between several dozen kb and several mb (no kidding!) to your swf. Instead, you’ll want to embed only the glyphs you need to display your content. And this is where Unicode code points come into the picture: You need to use those to tell the compiler which glyphs to embed.

To make a long story short, you’ll have to find out which Unicode ranges to use to make the compiler embed the glyphs you need. And for that, I’ve written a small JavaScript tool, which allows you to enter ranges of characters or just a bunch of text, which it then converts into an optimally reduced set of Unicode ranges.

You can find this tool here, I hope you find it useful and not too ugly.

Introduction

| Comments

To the world at large and you who is reading this in particular: Hello!

As seems pertinent for an introductory blog post, let me tell you a little bit about myself and what you can expect to read here in the future.

Update: This is oh so very much outdated that you shouldn’t even read it. Really.

I am a web developer mostly concentrated on solving highly technical, rather abstract problems using ActionScript and other front end web development technologies. That is to say: I’m a Flash developer, but in contrast to many of my peers, I’m not too interested in fancy animations and gratuitous effects. Thus, I’m drawn not the quickly built, glossy high end projects that dominate the Flash world but to the invisible technical challenges that lie behind each well-built site or application.

I constantly re-evaluate my views on what is a good balance between pragmatism and theoretical soundness in my daily work, trying to stay on the right side of the boundary between writing maintainable code and becoming an architecture astronaut.

For the last two and a half years, I’ve lead the Flash development team at Fork unstable media. Before that, I worked as a freelancer for about seven years and studied philosophy and an ever-changing assortment of minor fields.

As of July 2009, I will be a co-founder of a yet-to-be-named startup located in Hamburg, Germany. What are we going to do? Mostly two things:

  1. Work as a technical sub-contractor for for internet agencies, concentrating on websites, applications and presentations mostly done in Adobe Flash.
  2. Try to cross the chasm that lies between the proprietary world of Flash and the standards-based rest of the web-universe.

Should you decide to return, I’ll tell you a lot more about this second aspect of what we’re going to do and about why I think that we’re going to fill an important niche.