Peace For All

May 30, 2006

Ranting about Web Design and WP templates

Filed under: technology — Devlin Bentley @ 2:47 pm

I take issue to people who use fixed size, well, anything. Fixed sized fonts are my biggest complaint (especially when they are set at 2 pixels or so…).

Now I realize that XHTML and CSS are not the best tools to work with. Indeed, just trying to get any two elements to line up <i>and</i> have the same height can be a daunting task, but widths…

Widths people, are easy. Instead of going <tt>width: 800px;</tt> and then centering the page, you go <tt>margin-left: 25%; margin-right: 25%;</tt> and be done with it.

Yes I know that then you have to size everything else relative, but honestly, is making your make both usable AND future-proof(ish) really that bad? (yes it is that /hard/, but the end result is something that you can be proud of)

Either most WP themes use absolute widths, or they just set the margins to something stupid like 40% on each side. I have yet to figure out which bit of stupidity it is exactly.

Oh, kudos[1] to the web designers from taking a page out of the programmer’s handbook and instead of making configuration options, just saying “edit the source”.


My UPS died.

Filed under: technology — Devlin Bentley @ 2:16 pm

Granted I've had it for 5+ years, so it is time for it to go.  The sad thing is, I haven't used the battery but a few times, but apparently the way it is setup, the entire thing just goes ploomp, none of the devices run at all.  That likely means it is an active UPS (which is a good thing, it cleans up the electricity going through it), but also means it is now useless.  *sigh*  More lead in a landfill.

May 28, 2006

Every Pop Machine is also a Quarter Machine

Filed under: Life in general, technology — Devlin Bentley @ 4:48 pm

One of the disadvantages of living in an apartment is the constant need for quarters in order to do the laundry every week. Typically this means either going down to the bank to get a roll of quarters, or trying to find a kindly cashier at the grocery store who is willing to part with one of their precious quarter rolls.

Needless to say, this gets inconvenient, especially since I never really, you know, plan my day around getting a pack of quarters. When Saturday comes, I do laundry, end of story. Having to drop what I am doing to run out to the store or bank in order to pick up a pack of quarters is not very convenient.

There is also a pop machine right outside my apartment room. I don't drink pop (except for the 4 liters of diet coke that I got for free two days ago, but that is a separate story!) so I never had cause to even think about the machine. At least, not until I had an epiphany.

Who ever programmed that pop machine was trained as either a software or a hardware engineer. They are my brethren, no?

A ordinary person would expect that if they put in 65 cents of coins into the machine, that when they pressed "coin return" that they would be given back the same coins that they put in. That makes sense, they put in some money, now they want it back, so they get back the money that they put in.

But I thought about if for a bit, how would I go about and program the pop machine to give back money after the user had hit "coin return"? It is rather foolish to just return the money that was put in, since I also need to give change when the user pays to much (such as putting in a dollar for a 65 cent can of pop). Thus a path from the change box in the machine to the coin chute is needed. It is therefore redundant, and an unnecessary cost, to also build a path from the coin entrance to the coin return chute. It makes more sense to just call the giveChange(int val) function and pass in for val how much money the user has already inserted.

Now how would I compute the types of coins to give back to the user to add up to val? Naturally, I would use the change giving algorithm, known to every computer scientist, engineer, and anybody who has ever worked a cash register.

The algorithm is easy to understand. You always give back the most coins of the highest denomination that you can.

As an example, lets say you need to give back 65 cents.

The highest denomination coin you can return is (in America), a quarter worth 25 cents. So you return 2 of those, adding up to 50 cents given back to the user so far. You cannot return any more quarters, since then you would be over 65 cents.

Now you have 15 cents left to return to the user, so the highest denomination coin you can give back is a dime. You give one dime back to the user, so you have returned 60 cents so far.

Now you have 5 cents left to return to the user, so the highest denomination coin you can give back is a nickel. You give a single nickel back to the user, and you now have returned a total of 65 cents.

How does this relate to my laundry woes?

I pop in 5 dimes, I get out two quarters. I pop in another 5 times, out comes another two quarters, I go off to put my laundry in the wash.

(This only works if you have a multitude of spare change lying around!)

The key to my success was not expecting what an ordinary user expects, but rather in using my understanding and training in the mathematics and engineering[1] disciplines to achieve an understanding of how to manipulate the world around me.

[1]I originally was intending on becoming a Computer Engineer and trained as such, even though I have switched over to Computer Science, I still retain much of my earlier learned behaviors and thinking patterns from Engineering, although those skills lie at an early stage of development.

May 27, 2006

Hello world!

Filed under: Uncategorized — Devlin Bentley @ 8:34 pm

Heya, I switched over from Blogspot (which my GF deleted… again…).

Pluses about Blogspot:  Able to edit template directly, insert JS code.

Pluses about  I don't have to edit the template directly and insert JS/HTML code to get simple features (trackback, RSS feeds…) working. 

Eww, what happened to Outlook in Office 12 Beta 2?

Filed under: technology — Devlin Bentley @ 4:32 pm

The stained glass look is gone, now it looks like crud. Word still looks good. Way to be inconsistent. I know I know, upgrade to Vista, get the pretty effects.

Unless MS fixes some serious UI issues in Vista, I am not upgrading. Vista has…. issues as of yet. Maybe they've been fixed in the last three months (when I last was at MS campus playing with Vista), but I doubt it.

Create a free website or blog at