On Interface and Software Design

October 19, 2010

First, designing a user interface has almost nothing to do with writing software. There are software limitations that affect the design but other than that, the underlying code and data structures should not be considered until after the user interface is fully designed.

I ran into this issue when working with the linkage program. I have an interface that works much like the interface of drawing and painting programs. You can create an object in the document and click and drag it, rotate it, etc…, just like in a drawing program. You can select multiple items and act on them as a group and you can cut and paste things in the same way you would cut and paste text in a text editing program. Then I realized that I could expand my functionality by making a simple change to remove a restriction on the types of connectors can be inputs.

An input rotates at a specific RPM and anything attached rotates around it. Well, my change to let any connector be an input exposed a flaw in my program. I designed the code before designing the user interface. The whole things broke in a non-obvious way. How can any connector that is not an anchor rotate all of the things connected to it? It can’t. An input anchor works because there is the assumption that the “ground” doesn’t rotate around the anchor and only non-grounded links and connectors actually rotate. This assumption was part of the original design but is not very visible because the “ground” link is not really displayed.

This is what led me to the first sentence of this post. I didn’t design the user interface, I changed the code to provide a feature that wasn’t designed at all. To be honest, much of the linkage program was built by adding features int he code before considering the user interface issues.

Design the user interface with a paint program and a text editor and don’t write code until the design is done.

It’s acceptable to write some code to test design theories and to make a prototype when needed but any code written before the user interface design is finished will end up affecting the design more than you might think.

At this point, I’ve added so many features that don’t quite work that I’m inclined to work on the interface and then make the code fit that design. I’ll start by getting rid of the “any connector can be an input” feature and then consider redesigning the way sliding connectors are represented and manipulated. Are they even sliding connectors if they have not been “attached” to a link? Not really.