Author Topic: Bitmap Button Demo  (Read 290 times)

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 9726
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Bitmap Button Demo
« on: July 05, 2022, 07:45:56 PM »
This is a test piece for buttons that take an up and down button image to give some animation to the appearance of buttons. I tried many variations to simplify it but ran into the problem that there was no viable way to pass 2 image handles to a subclass.

I ended up having to use a more complicated technique where you had to individually subclass each button and use the normal global scope image handles so that you get the correct switching from the up to down button.

You have to create 2 images for each button and write some extra code but the BS_BITMAP style works well with a system defined button and it frees you at last from the default system button appearance.
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :skrewy:

caballero

  • Member
  • *****
  • Posts: 1969
  • Matrix - Noah
    • abre ojos ensamblador
Re: Bitmap Button Demo
« Reply #1 on: July 05, 2022, 10:42:35 PM »
It works ok  :thumbsup:

Here my little contribution to make buttons, from some years ago, 2015 if I'm not wrong 
The logic of the error is hidden among the most unexpected lines of the program

hutch--

  • Administrator
  • Member
  • ******
  • Posts: 9726
  • Mnemonic Driven API Grinder
    • The MASM32 SDK
Re: Bitmap Button Demo
« Reply #2 on: July 06, 2022, 06:59:44 AM »
These actually work well, the big one with an irregular shape is particularly impressive.  :thumbsup:
hutch at movsd dot com
http://www.masm32.com    :biggrin:  :skrewy: