Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[New PowerToy] Add Screen Ruler module for measuring screen contents #19701

Merged
merged 117 commits into from
Aug 26, 2022

Conversation

yuyoyuppe
Copy link
Collaborator

@yuyoyuppe yuyoyuppe commented Aug 2, 2022

Summary of the Pull Request

Bounds tool and measure tool is implemented.

Fixes
  • Change the horizontal+vertical icon to be more in line with the other icons. Example:
    image
  • Make having feet in the ticker an option. (Not working on continuous mode, though).
  • Multimonitor is not working.
  • Interaction seems to reversed for select vs scan mode. (left-click vs right-click to copy)
  • Changing tolerance in Settings seems to do nothing.
  • Add an ability to quickly change sensitivity while scanning with a mouse wheel
  • Verify on VM: initializing overlay UI shouldn't fail in GetClientRect with "Invalid window handle".
  • After finishing using a scan option, the toggle shouldn't keep being on.
  • Verify if the measurements are OK.
  • Pressing the activation shortcut again should close the measure tool UI.
  • Measure tool OOBE screen is not correctly wired up yet.
  • Disable measurement whenever the cursor is within the overlay toolbar? Therefore, controls can still be selected by mouse without using the ESC key first. This is also important for a11y I can imagine.
  • Measure tool UI doesn't exit when stopping runner in the Visual Studio debugger.
  • OOBE and Settings imagery (cc @niels9001) (src/settings-ui/Settings.UI/Assets/Modules/OOBE/ScreenRuler.png, src/settings-ui/Settings.UI/Assets/Modules/ScreenRuler.png)
  • Add a shadow to the tooltip (optional)
  • In settings say it's inspired by Roolr.
  • Telemetry.

PR Checklist

  • Closes: Screen measuring tool #863
  • Communication: I've discussed this with core contributors already. If work hasn't been agreed, this work might be rejected
  • Tests: Added/updated and all pass
  • Localization: All end user facing strings can be localized
  • Dev docs: Added/updated
  • New binaries: Added on the required places
  • Documentation updated: If checked, please file a pull request on our docs repo and link it here: #xxx

ScreenRuler

image

@github-actions

This comment was marked as outdated.

@github-actions

This comment was marked as resolved.

@github-actions

This comment was marked as resolved.

@niels9001
Copy link
Contributor

@jaimecbernardo @yuyoyuppe

Love this tool already😊!

One quirk: should we disable measurement whenever the cursor is within the overlay toolbar? Therefore, controls can still be selected by mouse without using the ESC key first. This is also important for a11y I can imagine.

@jaimecbernardo
Copy link
Collaborator

Thanks for the feedback @niels9001 , I've added it to the checklist in the PRs description so we can keep track of the changes still needed.

@htcfreek
Copy link
Collaborator

Make having feet in the ticker an option. (Not working on continuous mode, though).

  • Does this mean the distance is shown in feed unity? Then we should add pixel, centimeter, millimeter and maybe zoll as option too.
  • We should have an info bar on the settings page about all these restrictions in continues mode.

@github-actions

This comment was marked as resolved.

@htcfreek
Copy link
Collaborator

htcfreek commented Aug 12, 2022

I saw the gifs in the description now. And I love yet until try it by myself.

As I wrote somewhere it would be nice to have the ability of choosing the unit (mm, cm, px, zoll) and it would be great to have the unit abbreviation in the tooltip.

Regarding the toolbar I suggest to change the cross capture icon in the toolbar to a cross to make it more clear. maybe the symbol f164 (explore content single).

We could use symbol eb3c (design) as toy icon.

@crutkas
Copy link
Member

crutkas commented Aug 25, 2022

Sent via email screenshots, i think for the horizontal bar is off by one. It is 1 px too high. I'm at 100% scale. Using it to measure the minimize button / maximize button as hit points, you can see it stops 1 px above minimize

@github-actions

This comment was marked as outdated.

@yuyoyuppe
Copy link
Collaborator Author

@niels9001 are you ok with merging this? :) I believe AutomationPeer changes are now addressed.

# Conflicts:
#	.github/actions/spell-check/expect.txt
#	installer/PowerToysSetup/Product.wxs
#	src/runner/main.cpp
#	src/settings-ui/Settings.UI/OOBE/Views/OobeShellPage.xaml
#	src/settings-ui/Settings.UI/Views/ShellPage.xaml
Copy link
Contributor

@niels9001 niels9001 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Aaaawwwweeeesssssooooommmmmeeee 😄👍

@crutkas
Copy link
Member

crutkas commented Aug 26, 2022

when appropriate, (hoping today 😊), we can get this in so. I want to kick off a signed test build with all the new stuff and just be hyper critical of all the new stuff and what could be adjusted / should be adjusted before we release.

@jaimecbernardo
Copy link
Collaborator

when appropriate, (hoping today 😊), we can get this in so. I want to kick off a signed test build with all the new stuff and just be hyper critical of all the new stuff and what could be adjusted / should be adjusted before we release.

Figuring out those last build CI errors and we'll be merging it afterwards 😉

@github-actions

This comment was marked as outdated.

@yuyoyuppe yuyoyuppe merged commit 78d65a8 into microsoft:main Aug 26, 2022
@yuyoyuppe yuyoyuppe deleted the measure_tool branch August 26, 2022 23:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Idea-New PowerToy Suggestion for a PowerToy Needs-Review This Pull Request awaits the review of a maintainer.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants
  翻译: