Win11: get screen pixel color without Taskbar flash?
Craig Newman
craig at starfirelighting.com
Thu Jul 9 09:18:05 EDT 2026
No such issue on Mac, but then again Mac has no taskbar.
On a different note, I made a standard button and field on a new card and placed this in the button script:
on mouseUp
put the mouseColor into fld 1
end mouseUp
Clicking around various parts of the “main” body of that button, that is, in the blue area as opposed to the white name of the button itself, I get different RGB values. They are all close, but I would have bet that they were all the same. Nope. The white area that is the name itself is always 255,255,255.
No issue, but why?
Craig
> On Jul 9, 2026, at 2:46 AM, ambassador--- via use-livecode <use-livecode at lists.runrev.com> wrote:
>
> I know of two ways to obtain the RGB of a specified pixel on the screen:
>
> 1. mouseColor - set the screenMouseLoc, get the mouseColor, set the loc back
>
> 2. export snapshot - grab a single-pixel image
>
> Both methods have a UI side effect that makes them non-starters for the app I'm working on: the Taskbar flashes momentarily while the screen pixel is being obtained.
>
> This appears to be a momentary addition to the far-right of the Taskbar of the icon that's present when using the Win sceen shot tool. I'm guessing the API LC is using triggers that with both methods.
>
> Does anyone know of another way to obtain the color of a specific location on screen which is outside of an LC windows?
>
> If not, is there some clever way to avoid the momentary flash of the snapshot icon in the Taskbar?
>
> TIA -
>
> --
> Richard Gaskin
> Fourth World Systems
>
>
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode
More information about the use-livecode
mailing list