SetGadgetColor for OptionGadget and CheckBoxGadget

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
User avatar
stefanpape
User
User
Posts: 14
Joined: Sun Aug 04, 2013 11:12 am

SetGadgetColor for OptionGadget and CheckBoxGadget

Post by stefanpape »

Hello,

it would be very cool, if it's possible to set the background- and front-color for option-gadgets and checkbox-gadgets. Currently the look is different in Windows and Mac. In Windows, the gadget is always filled with the system background, that's not very beautiful in a colored window. In Mac the background is transparent, but the font-color is always the system-color.
User avatar
jacdelad
Addict
Addict
Posts: 1993
Joined: Wed Feb 03, 2021 12:46 pm
Location: Riesa

Re: SetGadgetColor for OptionGadget and CheckBoxGadget

Post by jacdelad »

Setting colours is limited differently by different OSes. On Windows you can use callbacks, but you'd have to take care for repainting. Search for ChrisD's ObjectTheme in the forum, this should fulfill your needs.
Good morning, that's a nice tnetennba!

PureBasic 6.21/Windows 11 x64/Ryzen 7900X/32GB RAM/3TB SSD
Synology DS1821+/DX517, 130.9TB+50.8TB+2TB SSD
User avatar
blueb
Addict
Addict
Posts: 1111
Joined: Sat Apr 26, 2003 2:15 pm
Location: Cuernavaca, Mexico

Re: SetGadgetColor for OptionGadget and CheckBoxGadget

Post by blueb »

jacdelad wrote: Sat May 17, 2025 10:19 am Setting colours is limited differently by different OSes. On Windows you can use callbacks, but you'd have to take care for repainting. Search for ChrisD's ObjectTheme in the forum, this should fulfill your needs.
ChrisR

viewtopic.php?t=82890
- It was too lonely at the top.

System : PB 6.21(x64) and Win 11 Pro (x64)
Hardware: AMD Ryzen 9 5900X w/64 gigs Ram, AMD RX 6950 XT Graphics w/16gigs Mem
User avatar
jacdelad
Addict
Addict
Posts: 1993
Joined: Wed Feb 03, 2021 12:46 pm
Location: Riesa

Re: SetGadgetColor for OptionGadget and CheckBoxGadget

Post by jacdelad »

Yes, ChrisR, not ChrisD. :mrgreen:
Good morning, that's a nice tnetennba!

PureBasic 6.21/Windows 11 x64/Ryzen 7900X/32GB RAM/3TB SSD
Synology DS1821+/DX517, 130.9TB+50.8TB+2TB SSD
Post Reply