June 23, 200619 yr I got panel light functional using the basic structure:MAKE_ICON( ... BMP_LIGHT_OFF, // Off bmp, followed by on bmp IMAGE_USE_ERASE, // Set bright or not bright in callback ... 2, // Number of icons)MAKE_STATIC // LUMINUOUSTo get the on bmp BRIGHT without the off bmp looking bright I set it in the callback: // Make BRIGHT pelement_icon->image_flags = pelement_icon->image_flags | IMAGE_USE_BRIGHT;and: // Make !BRIGHT pelement_icon->image_flags = pelement_icon->image_flags & ~IMAGE_USE_BRIGHT;which works fine. Since the background can be the off condition, I thought perhaps I should just use 1 icon, and set it to bright, but then I realized that it would always be on, haha.So, seems that only other way to do this would be to just use a BMP_LIGHT_OFF which is just pure RGB(0, 0, 0) black and then turn on the USE_IMAGE_TRANSPARENCY.Opinions?Seems this approach would improve performance by eliminating the need to programatically change the image flags.Patrick
June 23, 200619 yr You can either paint BMP_LIGHT_OFF in RGB(0,0,0), or use BMP_LIGHT_ON in the macro and mace sure the callback returns -1 in off state. For MAKE_ICONs it's the same as hide the image.
Create an account or sign in to comment