microsoft / PowerToys

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

[Screen Ruler] Multiple Measurements on Screen at a time (more than bounds) #22825

Open michael-hawker opened 1 year ago

michael-hawker commented 1 year ago

Description of the new feature / enhancement

Often times when I'm measuring something in the UI, I'm trying to compare values of things (like margins).

For instance in this case with a control we're building in the Windows Community Toolkit:

image

image

I had to do a bijillion different steps to get these images...

  1. Ctrl+Shift+M to bring up Screen Ruler
  2. Select the horizontal tool
  3. Get my measurement
  4. Ctrl+Shift+S to grab a screenshot
  5. Click close on Screen Ruler
  6. Paste screenshot
  7. Repeat steps 1-6

It'd be nice to be able to click the left-mouse button when the Screen Ruler is active to 'save' that measurement and keep it visible on the screen. Then I can go and measure something else to compare, switch tools to get a vertical measurement, etc... and keep clicking and placing them on the snapshot of the screen.

When I'm done I can get a screenshot (or PowerToys should just save off the buffer it has to the clipboard anyway for me) so that I can just paste it into my issue/document etc... with a whole annotated image of my various measurements.

Scenario when this would be used?

This would let me easily annotate an entire interface for comparison, critique, or review without having to do a lot of back-and-forth steps.

Supporting information

If measurements can be 'pasted' on to the image, then there should probably be a way to clear them, either right-clicking near a pasted measurement, or a clear option on the toolbar. Depends on how this works and if it's drawing to an image or actively drawing them on top of the screen.

That last part does factor into the option of continuously refreshing the image of the desktop vs. a static snapshot. Probably either make these mutually exclusive or involves a bit more work to implement this?

ENCRYPTEDFOREVER commented 1 year ago

Well, multiple measurements feature is available, but only for "Bounds" mode, it would be really nice to see it available for all measurement modes

crutkas commented 1 year ago

wondering how much effort this is, seems maybe low cost, adding to .71

DracoClaw commented 7 months ago

is this still planned?

ENCRYPTEDFOREVER commented 5 months ago

How many more times this is planned to be postponed? 🫠

drawbyperpetual commented 2 months ago

I have a working change for this. Now I'd like to get some feedback before opening a PR.

A GIF says a thousand words, so here it is:

screen_ruler_measurements_multiple

Essentially, I've made it work like multiple measurements for the Bounds tool - holding the SHIFT key while releasing the primary mouse button will keep the current measurement displayed instead of hiding it.

As for clipboard handling, as demonstrated in the GIF, I've made it such that all the active measurements are copied to the clipboard when there are multiple measurements. As a bonus, I've also updated clipboard handling for the Bounds tool to work in this way (it currently only copies the latest measurement even when in multiple measurement mode).

What do you all think?

jaimecbernardo commented 2 months ago

@michael-hawker @ENCRYPTEDFOREVER @DracoClaw . Any thoughts on the above? Thank you :)