Windows system utilities to maximize productivity
Go to file
Randy 81c09685e9
Registry Preview: complete feature with integration with Settings and the Launcher UX (#23709)
* Initial src for Registry Preview

Initial collection of files

* Update MainWindow.Utilities.cs

fixing a few spelling items

* Update expect.txt

* Update App.xaml.cs

* Update MainWindow.Events.cs

* Update MainWindow.Utilities.cs

* Update MainWindow.xaml.cs

* Update expect.txt

* Update MainWindow.Events.cs

* Rename AddPreviewtoRegfile.reg to AddPreviewToRegfile.reg

* Rename RemovePreviewtoRegfile.reg to RemovePreviewToRegfile.reg

* Update Resources.resw

* Update MainWindow.xaml

* Turns on self-contained mode

Updates the csproj file to compile the app as self-contained .
Includes fixes for code that expected the app to be in an ApplicationContainer.
Updates WindowsAppSDK from 1.1.5 to 1.2.230118.102.

* Updated to align with StyleCop errors

Multiple changes across the codebase that now aligns with StyleCop guidelines.

Tested again after the changes, to make sure no new bugs crept in.

* Added comments for spell-checker

Unclear if this side step should be done or not, but the kxz comes from a GUID and the other three names are constants.

* Adding code-custom.dic

Comments didn't work; trying a dic file

* Added four new terms to expects.txt file

Cleaning up attempt to update the spell-checker with dic file and moved it to expects.txt file

* Adding one more string

Adding one more string for Spell-Check

* Adding back egfile

Seems this is needed.

* Correcting a variable name

Seems one of the variable names that changed globally got missed in a XAML file.

* Update project to be more PowerToys friendly

Tweaking names and output file name to fit better with PowerToys.

* First pass at integration into Settings and Launcher

This PR is not as large as it seems:
- RegistryPreview's source moved around to a "better" directory that makes it look like the whole app changed.  It didn't.  In fact, I opened it in Beyond Compare and there's not much difference in the RegistryPreview app.
- Added RegistryPreviewExt that produces a DLL that the Launcher can run the EXE
- Changes to Runner calls the Ext DLL rather than the app
- Settings UI got a bunch of changes to enable the Settings page for enable/disable across ViewModels, Views, and string tables.

Still todo:
- Add "Preview" to .REG files, when the app is enable (and remove it when disabled)
- Update the thumbnail-screenshot in the Settings page
- Add support for OOBE

* Update expect.txt

Added REGISTRYPREVIEWEXT for recent changes and corrected an alphabetic sorting error.

* Updating project file for Release mode

Build failed due to a bad Includes path in Release mode.

* Adds REG registration but breaks settings

This update will update the HKCU branch of the Registry for REG files: if the app in PowerToys is enabled, it adds a Preview item to the context menu of REG files and disabling in PowerToys removes the menu item.

While working on this, I noticed that the application settings were broken, after moving to a self-contained EXE: there must have been old settings from past builds, when it was still using containers and family names.

Added TODO's to add a new way to save settings, likely as JSON.

* Re-enabled app settings

Moved from using ApplicationDataContainer for app settings and now use simple JSON.

Also cleaned up handling the scenario where the Launcher send in the PID from PowerToys' main thread.

Fixed past spelling errors as well.

* Update RegistryPreview.png

Captured new screenshot.

* Integration into OOBE

Integrates new page for Registry Preview into OOBE process.

* Removing old comment and unneeded calls

Two bits of source removed as they aren't needed any longer

Removing a chunk of old commented out code that doesn't make sense anymore.

* Merging file from upstream

Updating some files due to three merge conflicts from upstream changes and a couple of other changes to keep up.

* Update .gitignore

Adding two vcxproj files that have local updates for atls.lib locations.

* Update Resources.resw

Fixing a typo that involved a missing closing tag.

* Fix analyzer warnings

* Fix CI build

* Fix ARM64 build
Project file cleanup

* Add to installer

* expect.txt

* Remove unneeded dll

* Update MainWindow.xaml.cs

Added check for current Theme and adjust TextBox Foreground accordingly.

* Update expect.txt

Cleaning up merge cruft.

* Revert wrong .gitignore changes

* Fix ARM installer

* Update Brushes for textBox to use Theme based versions

Finally figured out how to use the built-in, Theme-aware Brushes for the font colors in the onscreen textBox.  Also have it aligning the font color for the hover state.

* Align configuration in PowerToys.sln

* [installer] Add missing files

* Fix bad merge

* Fixes for stefansjfw's review

Includes:
- two new strings for UX localization
- adds compatibility section for Windows 10
- fix to only track successful activations
- Removes two REG files that were there for examples

* Fixes from review from htcfreek

Updates:
- Fixed an issue where TextBox_TextChanged was firing when you simply opened a file.
- Added clamp to prevent files larger than 10MB from being opened.
- Added support in the UX to show Keys and Values that are deleted via the file
- Added support to specially handle Keys that start with - and Values that have =- in them (delete scenario)
- Changed AppBarButton icon for Edit from Rename to NewWindow

* Create deleted-folder32.png

* Added Registry Preview to GPO

* Update expect.txt

Updating spellchecker works

* Updating Size/Move code for better results

- Moved the size/move to the MainWindow layer
- Cleaned up the JSON settings handling to avoid an access denied on first run

* Improving text handling

Changed how special characters are parse, which helps with live entry.

* Updates to parsing and other fixes

- Renamed the value PNG for parity
- Added new error image
- Added check that values have " at start and finish.
- Added support for a new "ERROR" type for Values
- Fixed support for @ versus "@" in values
- Fixed bug where Save wasn't activating in all scernarios

* Fix signing and versioning

* Update src/settings-ui/Settings.UI/ViewModels/RegistryPreviewViewModel.cs

Co-authored-by: Heiko <61519853+htcfreek@users.noreply.github.com>

* Apply suggestions from code review

Adds Launch button to the settings page.

Co-authored-by: Heiko <61519853+htcfreek@users.noreply.github.com>

* Update Resources.resw

Adding strings for new launch button

* Adding new version for GPO

Moving to 0.69.0

* More parsing bug fixes

- Changes to look for [- instead of -[ for syntax deleting keys (fix for developer's mental hiccup)
- Moved [- to top of the decision making stack, as it needs to come before [
- Added new StripEscapedCharacters function for both sides of a Value line
- Fixed crashing bug for scenario where no Keys are parsed before a Value

* Bug fixes from most recent review.

- Dictionary will now be case insensitive when searching for keys
- Added tool tips (and strings) to the images of the Keys and Values
- Updated delete handling for Keys, so that only the leaf-most node gets marked as deleted; also stops the top most roots from being marked deleted.

* Tweaking for @=-

Forces the UX to take @=- and treat it as @="" since that's what Registry Editor would do.

* Removing unused usings

* Updates app description

* Update src/gpo/assets/PowerToys.admx

Co-authored-by: Heiko <61519853+htcfreek@users.noreply.github.com>

* cleanup proj file
launch process only if module is enabled
add process to bugreport process list

* Add context menu icon

* Update src/modules/registrypreview/RegistryPreviewUI/MainWindow.Utilities.cs

Co-authored-by: Heiko <61519853+htcfreek@users.noreply.github.com>

* Use modulesRegistry.h to apply/unapply registry changes

* Tweaked window settings

Moved the loading of the settings a little later in the initialization code, which gives more time for things to initialize.

* Update registry.h

Moving the definition out of the detail namespace to the registry name space to fix a compilation issue in RegistryPreviewExt.

* Unapply on creation

If module is disabled in settings.json, on startup reg entries should be unnaplied.
TODO: read m_enabled from settings file on creation

* Removing size/move main window

Added a TODO comment that responds to the size/position settings that are being saved out in the JSON blob on close as it doesn't always work on every PC, as the MainWindow initializes at different times.

* Change to always keep Save As active

No reason for this to be disabled, honestly.

---------

Co-authored-by: Clint Rutkas <clint@rutkas.com>
Co-authored-by: Stefan Markovic <stefan@janeasystems.com>
Co-authored-by: Heiko <61519853+htcfreek@users.noreply.github.com>
Co-authored-by: Stefan Markovic <57057282+stefansjfw@users.noreply.github.com>
2023-03-27 15:21:46 +02:00
.config Fail build when nugets aren't consolidated (#22233) 2022-11-24 20:45:51 +01:00
.github Registry Preview: complete feature with integration with Settings and the Launcher UX (#23709) 2023-03-27 15:21:46 +02:00
.pipelines Registry Preview: complete feature with integration with Settings and the Launcher UX (#23709) 2023-03-27 15:21:46 +02:00
deps Update cziplib to 0.25 (#21198) 2022-10-13 00:12:17 +03:00
doc Add devdocs for tools (#24903) 2023-03-24 11:38:42 +01:00
installer Registry Preview: complete feature with integration with Settings and the Launcher UX (#23709) 2023-03-27 15:21:46 +02:00
src Registry Preview: complete feature with integration with Settings and the Launcher UX (#23709) 2023-03-27 15:21:46 +02:00
tools Registry Preview: complete feature with integration with Settings and the Launcher UX (#23709) 2023-03-27 15:21:46 +02:00
.gitattributes Update .gitattributes 2022-07-19 13:06:16 -07:00
.gitignore [ARM64] Installer Bootstrapper (#18241) 2022-05-13 16:55:39 +01:00
.gitmodules Delete cxxopts (#21197) 2022-10-13 00:09:47 +03:00
.vsconfig [Dev]Update .vsconfig (#21786) 2022-11-17 12:43:27 +00:00
CODE_OF_CONDUCT.md adding in a Code of Conduct 2020-03-05 10:11:27 -08:00
COMMUNITY.md Update COMMUNITY.md (#22378) 2022-12-06 07:25:28 +01:00
CONTRIBUTING.md Add information about localisation in contributing.md (#23685) 2023-03-14 18:14:52 +01:00
Cpp.Build.props [ARM64][Build] Prefer Arm64 Build Tools when building from Arm64 devices (#22792) 2022-12-15 18:40:29 -05:00
CppRuleSet.ruleset [Analyzers][CPP] Turn on warning 26493 (#23990) 2023-02-13 16:37:26 +00:00
Directory.Build.props [General]Update copyright year to 2023 (#24310) 2023-02-27 11:29:25 +00:00
Directory.Packages.props [Settings] Bump settingscontrols version number (#24874) 2023-03-20 14:27:29 +01:00
LICENSE Fix license file (#2626) 2020-05-02 15:59:18 -07:00
NOTICE.md [Settings] Bump settingscontrols version number (#24874) 2023-03-20 14:27:29 +01:00
nuget.config [Build]Centralize .NET NuGet Package Versions (#23727) 2023-02-13 17:10:33 +00:00
PowerToys.sln Registry Preview: complete feature with integration with Settings and the Launcher UX (#23709) 2023-03-27 15:21:46 +02:00
README.md 0.68 changelog (#24355) 2023-03-01 21:39:34 -08:00
SECURITY.md Create SECURITY.md 2020-07-17 14:45:18 -07:00
Solution.props [PowerRename] Fluent UX (#13678) 2021-10-25 14:40:19 +01:00
SUPPORT.md [Docs]Replace docs.micrososft.com with learn.microsoft.com (#20662) 2022-09-28 17:18:55 +01:00

Microsoft PowerToys

Hero image for Microsoft PowerToys

How to use PowerToys | Downloads & Release notes | Contributing to PowerToys | What's Happening | Roadmap

Build status

Architecture Solution (Main) Solution (Stable) Installer (Main)
x64 Build Status for Main Build Status for Stable Build Status Installer pipeline
ARM64 Build Status for Main Build Status for Main Build Status Installer pipeline

About

Microsoft PowerToys is a set of utilities for power users to tune and streamline their Windows experience for greater productivity. For more info on PowerToys overviews and how to use the utilities, or any other tools and resources for Windows development environments, head over to learn.microsoft.com!

Current utilities:
Always on Top PowerToys Awake Color Picker
FancyZones File Explorer Add-ons File Locksmith
Hosts File Editor Image Resizer Keyboard Manager
Mouse utilities Paste as Plain Text PowerRename
PowerToys Run Quick Accent Screen Ruler
Shortcut Guide Text Extractor Video Conference Mute

Installing and running Microsoft PowerToys

Requirements

  • Windows 11 or Windows 10 version 2004 (code name 20H1 / build number 19041) or newer.
  • Our installer will install the following items:

Go to Microsoft PowerToys GitHub releases page, click on Assets at the bottom to show the files available in the release. Please use the appropriate PowerToys installer that matches your machine's architecture. For most, it is x64.

This is our preferred method.

Via Microsoft Store

Install from the Microsoft Store's PowerToys page. You must be using the new Microsoft Store which is available for both Windows 11 and Windows 10.

Via WinGet

Download PowerToys from WinGet. To install PowerToys, run the following command from the command line / PowerShell:

winget install Microsoft.PowerToys -s winget

Other install methods

There are community driven install methods such as Chocolatey and Scoop. If these are your preferred install solutions, you can find the install instructions there.

Contributing

This project welcomes contributions of all types. Help spec'ing, design, documentation, finding bugs are ways everyone can help on top of coding features / bug fixes. We are excited to work with the power user community to build a set of tools for helping you get the most out of Windows.

We ask that before you start work on a feature that you would like to contribute, please read our Contributor's Guide. We will be happy to work with you to figure out the best approach, provide guidance and mentorship throughout feature development, and help avoid any wasted or duplicate effort.

Most contributions require you to agree to a Contributor License Agreement (CLA) declaring that you have the right to, and actually do, grant us the rights to use your contribution.

For guidance on developing for PowerToys, please read the developer docs for a detailed breakdown. This includes how to setup your computer to compile.

What's Happening

PowerToys Roadmap

Our prioritized roadmap of features and utilities that the core team is focusing on.

0.68 - February 2023 Update

In this release, we focused on releasing new features, stability and improvements.

Highlights

  • New utility: Paste as Plain Text allows pasting the text contents of your clipboard without formatting. Note: the formatted text in the clipboard is replaced with the unformatted text. Thanks @carlos-zamora!
  • New utility: Mouse Jump allows to quickly move the mouse pointer long distances on a single screen or across multiple screens. Thanks @mikeclayton!
  • Add new GPO policies for automatic update downloads and update toast notifications. Thanks @htcfreek!
  • Support MSC and CPL files in "Run command" results of PowerToys Run Program plugin. Thanks @htcfreek!
  • Add support for log2 and log10 in PowerToys Run Calculator plugin. Thanks @RickLuiken!
  • Added experimentation to PowerToys first run experience. There are current page which says "welcome" and a variant with direct instructions on how to use some of the utilities. We want to see if directly showing how to use PowerToys leads to more people using the features :)

General

  • Improve metered network detection in runner. Thanks @davidegiacometti!
  • Update PowerToys logo used by installer. Thanks @ChaseKnowlden!
  • Add new GPO policies for automatic update downloads and update toast notifications. Thanks @htcfreek!
  • Update copyright year to 2023. Thanks @ChaseKnowlden!

FancyZones

  • Refactored and improved code quality.
  • Fix crashing on moving window between monitors with Win + arrows. (This was a hotfix for 0.67)
  • Fix issue causing window attributes to not be reset properly. (This was a hotfix for 0.67)
  • Fix issue causing window to not be adjusted when layout is changed. (This was a hotfix for 0.67)
  • Fix issue causing window not to be unsnapped on drag started. (This was a hotfix for 0.67)
  • Fix issue causing layouts not to be applied to new virtual desktops. (This was a hotfix for 0.67)
  • Fix issues causing windows not to be restored correctly to their last known zone.

File explorer add-ons

  • Add Developer files previewer option to set max file size and fix styling issue. Thanks @Aaron-Junker!
  • Improve Developer files previewer exception handling and printing of error messages.
  • Fix crash when generating PDF and Gcode file thumbnails. (This was a hotfix for 0.67)

Hosts file editor

Keyboard Manager

Mouse Utils

  • Resolve grammatical error in Mouse Highlighter description. Thanks @WordlessSafe1!
  • New utility: Mouse Jump allows to quickly move the mouse pointer long distances on single or across screens. Thanks @mikeclayton!

Paste as Plain Text

  • New utility: Paste as Plain Text allows pasting the text contents of your clipboard without formatting. Note: the formatted text in the clipboard is replaced with the unformatted text. Thanks @carlos-zamora!

PowerToys Run

  • Show Steam (steam://open/) shortcuts in the Program plugin.
  • Localize paths of Program plugin results. Thanks @htcfreek!
  • Improved stability of the code used to get the localized names and paths. Thanks @htcfreek!
  • Support MSC and CPL files in "Run command" results of Program plugin. Thanks @htcfreek!
  • Added missing MSC and CPL settings to the results of Windows Settings plugin. Thanks @htcfreek!
  • System plugin: Setting for separate "Open/Empty Recycle bin" results or single result with context menu. (This was implemented based on user feedback for a change in the last build.) Thanks @htcfreek!
  • Add support for log2 and log10 in Calculator plugin. Thanks @RickLuiken!
  • Removed the TimeZone plugin.
  • Fix the crash when loading thumbnail for PDF files. (This was a hotfix for 0.67)

Shortcut Guide

Quick Accent

Settings

  • Add missing flyout borders on Windows 10. Thanks @davidegiacometti!
  • Add experimentation for oobe landing page. Thanks @chenss3!
  • Show icons of user-installed PowerToys Run plugins. Thanks @al2me6!
  • Fixed crash when clicking Browse for backup and restore location while running elevated.
  • Respect taskbar position when showing system tray flyout. (This was a hotfix for 0.67)
  • Show correct Hosts module image. (This was a hotfix for 0.67)

Development

  • Turned on C++ code analysis and incrementally fixing warnings.
  • Centralize .NET NuGet packages versions. Thanks @snickler!
  • Separate PowerToys installer logs and MSI logs to different files.
  • Added new GPO rules to the reporting tool.
  • Move PowerToys registry entries back to HKLM to fix context menu entries not working on some configurations. (This was a hotfix for 0.67)

What is being planned for version 0.69

For v0.69, we'll work on below:

  • Allow installing without UAC.
  • New utility: PowerToys Peek
  • Stability / bug fixes

PowerToys Community

The PowerToys team is extremely grateful to have the support of an amazing active community. The work you do is incredibly important. PowerToys wouldnt be nearly what it is today without your help filing bugs, updating documentation, guiding the design, or writing features. We want to say thank you and take time to recognize your work. Month over month, you directly help make PowerToys a better piece of software.

Code of Conduct

This project has adopted the Microsoft Open Source Code of Conduct.

Privacy Statement

The application logs basic telemetry. Our Telemetry Data page (Coming Soon) has the trends from the telemetry. Please read the Microsoft privacy statement for more information.