Jul 19th 2013

A Very Simple Plugin

Posted on Jul 19, 2013

Something I have a habit of doing when I write CSS is to put a little comment up at the top of the file that contains a color palette list.

I wanted to play around with writing plugins for Sublime Text (My editor of choice). I decided to build a simple plugin to generate my pallete comment in conjunction with the Color Lovers API. If you are using LESS variables will be created for you as well.

To use it all you have to do is hit (Command + C + L) and then enter in the ID of the pallete you want. The plugin will then fetch from the Color Lovers API and inject the comment into your file at the cursor position.

If you use Sublime Text and want to give it a try or expand on it here is the plugin.

Dec 31st 2012

Tetris Clone Using Javascript and Canvas

Posted on Dec 31, 2012

Years ago when I used to write Actionscript for a living I coded up a little tetris app to get myself used to using Actionscript 2. Recently just for the heck of it I decided to create a port of that app using Javascript with canvas. I changed some things around but for the most part all the core logic is unchanged. Obviously the rendering code is all new. Have fun!

Controls

  • Up Arrow Rotate
  • Down Arrow Move down quikly
  • Left Arrow Move to the left
  • Right Arrow Move to the right
  • Spacebar Instant drop

Dec 15th 2012

Palette Browser + Nine Patch Generator

Posted on Dec 15, 2012

Dec 7th 2012

COLOURlovers Palette Browser

Posted on Dec 07, 2012

I'm not entirely sure what I plan to do with this (I have a couple ideas) but out of boredom today I built a javascript based palette browser that pulls data from the COLOURlovers API.

Fell free to use and abuse the source any way you like.

Apr 28th 2011

Nine Patch Canvas Experiment

Posted on Apr 28, 2011

Nine patch quilting has been around since before the American Civil War. It is a simple technique for creating a seemingly infinite number of patterns using a 3 x 3 grid of of simple shapes.

Below is a nine patch generator I built using JavaScript and canvas as a learning exercise. It's been tested in Firefox and Chrome for Mac, and in theory should work in any modern browser with canvas support. Feel free to download the source code and chop it up however you'd like.

The Shapes to Be Drawn Into Our Grid

The lighter shapes are only allowed in the center.

A Single Nine Patch Pattern

Click the pattern to re-draw.

A 3 x 3 Grid of Nine Patch Patterns

Click the pattern to re-draw.

A 9 x 9 Grid of Nine Patch Patterns

Click the pattern to re-draw.

Apr 25th 2011

Lorem ipsum in TextMate

Posted on Apr 25, 2011

Nothing shocking here. I just needed a quick topic for my first post so I'm sharing my new favorite shortcut in TextMate. It's probably old news but I don't care. I love it.

Type lorem + tab into TextMate and it will generate a block of lorem ipsum for you. Awesome!