The GUI-fication Continues #

icon mangler: added a close box to the window (before I just had a close command in the menu) and the appropriate calls in my event handling code to handle it properly. My next step is to add a grow box to the window, thus letting the user resize it. Then I would draw the icon at the size the user has chosen. I want to be able to restrict the resizing so that it's only in a 1:1 ratio (because icons are 32x32). Even better, I want to limit the resizing to multiples of 32, so that the icon will be enlarged evenly. I know this is possible (Resourcerer does it for example) but hopefully it doesn't require too much custom code. All of this will be useful later on, because then the resize box can act as a way to magnify the icon (since icons are so small they don't require a magnifying glass tool for zooming in to a specific area, since there are no scrollbars and the whole icon is visible at the same time). I think I'll also provide a display in the status bar, where the percentage magnification will be displayed (and perhaps when the user clicks on it a popup menu will show up, allowing one to choose values from 100% to 800%). However that will have to wait until I implement controls within windows, but the grow box is a good step towards that too.

(later)

I've got the windows to resize (no size constraints yet tho), but I can't get it to refresh properly. I'm setting the update region to the whole window, and yet it only draws the new icon in the newly revealed area. I have no idea why this is happening, but like most problems this will probably be rather clear to me tomorrow :p

Post a Comment