Hi @ayrtbh This is a nice idea. However, unfortunately I can confirm that your Macro does not pick the correct RGB values as you can confirm by using the inbuilt eyedropper in the Apple Color Picker.
The correct RGB values for the blue square above are 146,179,242 but the your Macro shows them as 162.194,245
Like you say the error maybe is in the maths - maybe a rounding error?
But this got me thinking that since the Apple Color Picker itself has an eyedropper tool to select colors (as I used above) why not just make a hot key with Keyboard Maestro to invoke the Color Picker and then use its accurate eye dropper?
After a bit of Googling I found the System Shortcut for the Color Picker is ⇧⌘C
But it doesn't work in all Apps. The AppleScript to invoke the Color Picker is:
So, the below Keyboard Maestro Macro works to make ⇧⌘C open the Color Picker in all Apps. Maybe there is a way to select the eye dropper tool itself using AppleScript?).