wctltya Posted October 4, 2016 Report Posted October 4, 2016 Hi Joel, I've read your post here where you said: Quote Important note: When you just want to show a different image for when the button is released and when the button is pressed to make a visual "Click" effect then that has already been done for you! The existing image rendering function for the button widget can take an image that's either one, two or three times the height of the actual button. This way you can stack the image for the 'released', the 'pressed', (and optionally the 'disabled') state on top of each other and use that as one image. The button widget will automatically render the correct one depending on its current state. You can find more information about this in the API documentation and by using the forum search. This is also already supported by the uGFX-Studio. If you select the image rendering function on a button then you can not only submit the image path but also specify how many images you have (1, 2 or 3). But I still don't understand how to provide 3 different images for button states "Released", "Pressed" and "Disabled"? How to "stack" 3 images? For me it is most important to have two different images for Enabled and Disabled sates. Anyway I've provided a single image and used gwinDisable() assuming, that it will stop rising the button's events. But was surprised that the image disappears as well. I know that I can change the image pointer and redraw it my self, but why to do it if it is already implemented in the library and can be achieved gwinDisable/Enable functions.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now