Peek: Add setting to disable file metadata tooltip#46624
Open
Peek: Add setting to disable file metadata tooltip#46624
Conversation
Agent-Logs-Url: https://github.com/microsoft/PowerToys/sessions/11d9fbe6-847a-407c-8648-c8b4d53cbb6d Co-authored-by: niels9001 <9866362+niels9001@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add option to disable tooltip on Peek window
Peek: Add setting to disable file metadata tooltip
Mar 29, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a "Show file preview tooltip" toggle to Peek's Behavior settings, letting users disable the metadata tooltip (filename, type, date modified, size) shown on hover over the preview.
Changes
PeekProperties— newShowFilePreviewTooltip: BoolProperty(defaulttrue)IUserSettings/UserSettings— expose the setting; updated by the existing file watcher on settings changeFilePreview— newShowFilePreviewTooltipDependencyProperty; setsInfoTooltip = nullwhen disabled (WinUI suppresses tooltip on null content); re-triggersUpdateTooltipAsyncwhen re-enabled with a file loaded;infoTooltipfield changed tostring?MainWindow.xaml.cs— reads setting fromIUserSettingsand pushes it toFilePreviewer.ShowFilePreviewTooltipon eachInitialize()call, picking up the latest user preference each time Peek activatesPeekViewModel—ShowFilePreviewTooltipproperty for two-way Settings UI bindingPeekPage.xaml— toggle in the Behavior group, consistent with existing togglesResources.resw— localizable strings for header and descriptionPR Checklist
Detailed Description of the Pull Request / Additional comments
Setting defaults to
true— no behavior change for existing users. The tooltip suppression works by settingInfoTooltiptonull; WinUI'sToolTipdoes not open whenContentis null, so no empty popup appears. The custom tooltip placement logic (top/bottom based on cursor Y) is unaffected.Validation Steps Performed
truepreserves existing behavior✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.