microsoft / PowerToys

Windows system utilities to maximize productivity
MIT License
109.46k stars 6.45k forks source link

Color Picker - Include X, Y Coordinates of picked color. #33482

Open Serfrost opened 2 months ago

Serfrost commented 2 months ago

Description of the new feature / enhancement

Ideally, from the Color Picker > Color Formats > Custom Format, this could be included as %Xp and %Yp variables.

Different methods of obtaining said coordinate may be helpful, that being:

As such, after selecting a color in Hex, you could then paste down ID:0D1117, X:1873, Y:1011 or similar.

Scenario when this would be used?

Picking a color is great and all, but when it comes to scripting with color values and pixels on-screen for automated tasks, it would really help if this would show + copy the X and Y coordinates associated with the chosen color. This would greatly help with my own personal productivity, and perhaps others would appreciate it as well.

Supporting information

No response

crutkas commented 2 months ago

can you go into more details here. As is, I don't understand the use case to correlate the X/Y for the pointer and the color.

Is the ask actually just asking for "I'd like the X&Y coordinate of the pointer"

/needinfo

Serfrost commented 2 months ago

Is the ask actually just asking for "I'd like the X&Y coordinate of the pointer"

This is more or less correct, yes.

As for going into detail - certain automation tools such as AutoHotkey enlist the use of PixelSearch or whichever derivatives they decide to use, which rely on the script author to input the X/Y values of the color they intend to search for in addition to the hex value of the color. There are other use cases, but this is personally what I'd be using it for.

https://www.autohotkey.com/docs/v1/lib/PixelSearch.htm

If X/Y was optionally included with Color Picker, this would streamline the process and removes the need for yet another external tool.