Monday 8 March 2010

The Little Things

I got hung up today on the stupidest thing. My buttons.

They work great, do exactly what they're supposed to do. But my buttons bug the bejeezus out of me. Why? Because they're huge. I just want a nice little square button with a plus sign on it, maybe a minus sign, maybe two. They just do "fill," "add," "subtract," or "empty" on the value they're editing.

It's the "little" and "square" requirements that are annoying me. For some reason or other, the button truncates the string to "..." when it's smaller than 40 pixels wide. The plus sign is THINNER than the ellipsis, by my approximation, but is apparently too large to display. If I want the "+ +" label to display I need to extend it to 60 pixels.

Simple math says each character is 10 pixels wide, and the string needs to be a minimum of 15 pixels from each side. That's what Java is deciding. I can't figure out how to change this. I've asked in some forums and will keep searching, but this is what is currently holding up my development. I hate being obsessive-compulsive sometimes.

Theoretically progress is proceeding nicely. I added the functionality of showing the current matcode in the text input, a small feature mostly useful for changing your mind and therefore leaving the input with an empty string when you decide to play with a different setting. It also prepares the link-up of the value-editing MatEditLines that I've created to the matcode being displayed.

Still, this little tiny problem has bugged me enough to cause me not to progress too far forward. It's really a shame. Oh well, there's always tomorrow.

No comments: