mirror of
https://github.com/gryf/wmaker.git
synced 2026-01-01 03:22:30 +01:00
The RGB panel of the WINGs color panel lists the red, green, and blue values as base 10 numbers. However, hexadecimal numbers are very common when dealing with RGB colors. This patch adds two radio buttons at the bottom of the RGB panel to allow users to choose their preferred number system. For version 2 of the patch: Based on Cristophe's suggestions regarding the new decimal/hexadecimal RGB color feature introduced in commit 83d8ad6, this patch changes rgbState from an int to an enum, converts some if statements to switches, and changes from atoi to strtol for the base 10 string conversion. In addition, the "hexadecimal" text was too wide for the default size of its radio button for some fonts, so both radio buttons are now resized to fit the width of the panel.
106 KiB
106 KiB