Since I use Excel VBA way too often, I found I needed the String.Format() function from .NET. I looked around the internet for one but only found a limited version on EliasZone (String.Format Equivalent for VBA). The limits weren't that bad, only five replacement arguments, it was more the thought of having to make changes if I suddenly needed more. Thus, I put together my own version.

As of the first revision, it has only been tested on exactly what I needed it for, it includes very little error handling, and could do with some love. Therefore you should feel free to fork and update as needed.

Usage:

StringFormat( _
    "If I had a {0} dollars, I would buy you a {1}. I know you always wanted a {1}!", _
    "million", _
    "monkey" _
)

The script:

I've been wanting to try out a standup desk for a little while now so when I happened to be running early for work today, I decided to throw one together to fill up my time. Thus, the standup desk prototype was born.

standup-desk-prototype1.jpg

As you can see, it's not the most beautiful thing in the world but it functions fairly well. I've spent 80% of my day standing without any problems except sore feet. I found that I was able to concentrate in my meetings much better and it was easy to grab a couple weights and swing those around for a bit. Unfortunately my day hasn't included any programming so I'm not sure how effective I will be yet.

The change I need to make most to the prototype is keyboard height. For me, that is definitely a game changer. At first I was using the keyboard at the height of the first drawer, about six or seven inches lower, and I found it very uncomfortable. At its current height, I've found the keyboard to be pretty close but a little too high so I touchtype but with fewer fingers.

All in all, for a day that has been filled with meetings and creating slide decks, I think this has been the first time that I haven't nearly fallen asleep. I would suggest that if you have some time and a bit of styrofoam you put a prototype together.

I was in a programming rut recently and my manager suggested I write a program that counts to ten for a quick win. I was rather insulted because writing some script to count to ten isn't terribly difficult and wouldn't make me feel much better. Then I took a step back, put some thought into the idea, and then decided to learn Brainfuck and write a script that would count to ten.

It turns out Brainfuck is pretty easy to pick-up. I learned the language and wrote my script over my 30 minute lunch break!

I was pretty hungry afterwards.

The Code

The code is fairly simple. There are some variables (cells 3, 4, and 5) and a couple loops. I commented the code and spaced it out to make it a bit easier to read.

While I was looking for a code highlighting library, for this site, I came across a post on the highlight.js project page where the author was excited that someone had ported the Solarized theme to the project. Out of interest I decided to see what Solarized was about and I fell in love. The colours seemed to fit really well and the screenshots of Python code looked excellent. Unfortunately, there was no StyleScheme for Gedit so I decided to set about creating one.

And now here we are. :)

Light theme
solarized_light.png

Dark theme
solarized_dark.png

Both screenshots are using the Ubuntu Mono font at size 13

It’s still a work in progress but if you’d like to help you can clone the git repository at

git clone https://github.com/mattcan/solarized-gedit.git

I plan to forwarded this to Ethan Schoonover to see if it gets included in the main repo as a git-subtree.

UPDATE

My code was submoduled into the official repo so you can download from me above or from the official repo.

more