Quirk: GUI button's active area doesn't resize.

Started by RickJ, Thu 17/04/2003 03:53:08

Previous topic - Next topic

RickJ

The GUI button's active area doesn't resize when the button is resized using SetButtonPic().

If SetButtonPic() is used to change a button's appearance and if the new graphic is of a different size the mouse-over and click events still use the original button size and not the new one.   It would seem more intuitive, to me, if this area were determined by the graphic used for the "normal" view.  

Would it be possible in some future version to have the SetButtonPic() function, calculate and update the button size parameters, whenever it is used to change the "normal" grahic?


 

Pumaman

Sounds sensible to me - would anyone have a problem if SetButtonPic did this automatically?

Scorpiorus

#2
Suggestion is handy as well as there are maybe a particular situation when autosizing isn't preferable(trying to figure out when  ::)) . maybe an option then? :P

EDIT: or maybe the option is useless in case if the button's bounds do not cut the image(I can't remember now).

-Cheers

Pumaman

The button's bounds don't clip the image - they just decide the rectangle in which the mouse click will register.

Thinking about it, I can't see a situation where resizing automatically would be a problem. At the moment, virtually all SetButtonPic calls are used to change it to another image of the same size anyway.

Scorpiorus

oh, as it's a button (and it doesn't clip the image) then consequently the whole image area should be clickable. Autoresizing! :P

-Cheers

SMF spam blocked by CleanTalk