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

Merge upstream PT #7 #330

Merged
merged 73 commits into from
Jan 15, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
73 commits
Select commit Hold shift + click to select a range
89be43e
[Workspaces] implement the move feature (#35480)
donlaci Dec 4, 2024
e7f1749
[KeyboardManager]Fix mapping shift to numpad (#35890)
mantaionut Dec 4, 2024
eadcf4b
[Analyzers] Update .editorconfig with rules to relax IDE errors (#36095)
snickler Dec 4, 2024
e19590f
[Workspaces] PWA follow-up (#36217)
SeraphimaZykova Dec 5, 2024
f7c9c80
[PTRun][Calculator]Allow scientific notation with lowercase 'e' (#36187)
PesBandi Dec 5, 2024
a9123bf
[Workspaces] Add encoder parameter to bitmap.save() (#36228)
donlaci Dec 5, 2024
076461e
[Workspaces] Implement store of app window's size and position (#36086)
donlaci Dec 5, 2024
09ce610
[ScreenRuler]Add setting to show the measurement in an extra unit (#3…
Sophanatprime Dec 5, 2024
a6c5420
[Deps]Update MSTest from 3.5.0 to 3.6.3 (#36115)
Youssef1313 Dec 5, 2024
4df8a97
Adding Jerry to community.md (#36232)
crutkas Dec 5, 2024
1212ce2
[Workspaces] Arranger: smart timer (#36096)
donlaci Dec 6, 2024
74a1a6e
Upgrade to check-spelling v0.0.24 (#36235)
jsoref Dec 6, 2024
51586b4
Adjust to community.md, shifting jerry's github user name (#36242)
crutkas Dec 6, 2024
3aec0a0
[AOT compatible] Resolve AOT Build Error in Peek.UI (#36194)
lei9444 Dec 9, 2024
ef672b5
Awake Updates - `TILLSON_11272024` (#36049)
dend Dec 9, 2024
9591950
[Workspaces] detecting right app version (#36100)
donlaci Dec 9, 2024
474b0cf
Move the XamlStyler config to src/ (#36202)
crutkas Dec 10, 2024
bf3474b
[AdvancedPaste]Add Semantic Kernel opt-in to allow chaining of paste …
drawbyperpetual Dec 11, 2024
7c6af65
[Launcher]Port from WPF-UI to .NET 9 WPF (#36215)
mantaionut Dec 11, 2024
7a39f2f
[UX]Updating New+ and Settings icons (#36290)
niels9001 Dec 11, 2024
ce0e00f
[Settings][Dashboard] Accessibility fixes (#36280)
davidegiacometti Dec 11, 2024
c5dc93f
[ci]Sign OpenAI dll that's not signed (#36299)
jaimecbernardo Dec 11, 2024
7aba6e8
Update CODEOWNERS to include gordon, jerry and kayla (#36308)
crutkas Dec 11, 2024
05e5e92
Making the powertoys-code-owners team code owners (#36310)
crutkas Dec 11, 2024
f19a34d
[FZEditor]Fix Create new layout dialog radio buttons IsChecked values…
stefansjfw Dec 12, 2024
feeeec6
0.87 changelog (#36335)
jaimecbernardo Dec 16, 2024
6f23fb5
[PTRun]Fix WPF transparent border issue on Windows 10 (#36392)
mantaionut Dec 18, 2024
e77ea96
[PTRun]Fix .NET 9 crash in OneNote (#36417)
mantaionut Dec 18, 2024
799f739
[AdvancedPaste]Fix NullReferenceException on Dispose (#36428)
drawbyperpetual Dec 18, 2024
43bc811
[Fuzz] Add fuzz testing for AdvancedPaste and new pipeline for onboar…
lei9444 Dec 19, 2024
ea66066
Add New CI Pipeline for Latest WindowsAppSDK (#36282)
shuaiyuanxx Dec 19, 2024
86c6b4a
[AOT compatible] Make HostsUILib become AOT compatible (#36136)
moooyo Dec 19, 2024
20a5f67
[AOT compatible] Clean up some AOT build issue in FilePreviewCommon a…
moooyo Dec 19, 2024
342c616
Add new pipeline using the latest webview2 from Edge Canary (#36317)
shuaiyuanxx Dec 19, 2024
2a6dcb9
[Bug fix] Making the OpenAI key configuration page scrollable. (#36359)
shuaiyuanxx Dec 19, 2024
e2cd863
[Bug fix] Add a format validation step before format conversion. (#36…
shuaiyuanxx Dec 19, 2024
f727762
Add more STCA team members (#36438)
jamrobot Dec 20, 2024
ea23f1e
Remove "prerelease: true" (#36484)
denelon Dec 21, 2024
bb637c1
[Docs]Update README for 0.87.1 release (#36534)
jaimecbernardo Dec 23, 2024
fbd72cc
[CI] Enhance build Pipeline Reliability with Retry Logic and Improved…
lei9444 Dec 24, 2024
e4d2deb
Add team member (#36590)
vanzue Dec 27, 2024
a720dd5
[New+]Don't override New actions from Explorer on Windows 10 (#36467)
jaimecbernardo Dec 27, 2024
2ba5fb7
[PTRun][Calculator]Handle hexadecimal numbers to not return divide by…
plante-msft Jan 2, 2025
1eec678
[TextExtractor]Minor UI/Accessibility fixes in the overlay UI (#36356)
davidegiacometti Jan 2, 2025
94d7121
[PTRun][Calculator]Update mages to v3.0.0 and support for `randi(n)` …
htcfreek Jan 3, 2025
bd30da6
[QuickAccent]Added ć for Slovenian (#36336) (#36338)
dsoklic Jan 3, 2025
21391bb
Fix snapping Workspaces Editor to Fancy Zones (#36463)
donlaci Jan 6, 2025
deddce2
[PTRun]Fix drag on .NET 9 WPF (#36635)
davidegiacometti Jan 6, 2025
90e75a1
[CQ]Continued to move stuff out of root - Solution.props (#36244)
crutkas Jan 6, 2025
6ca02f0
[QuickAccent]Add Proto-Indo-European (#36408)
haoliuu Jan 6, 2025
5e9675e
[PTRun]Add context buttons for VSCodeWorkspaces plugin (#36517)
programming-with-ia Jan 6, 2025
809791d
[Settings][QuickAccent]Change 'character set' to plural form (#36565)
PesBandi Jan 6, 2025
308c4b8
[PTRun][Calculator]Fix unit tests on non-english systems (#36569)
htcfreek Jan 8, 2025
cd2a887
[PTRun][Calc]Improve handling of non-base 10 numbers (#36700)
PesBandi Jan 8, 2025
a29ff07
[Settings][PTRun]Show plugin version and website (#36580)
htcfreek Jan 8, 2025
0d71f11
[Monaco]Add support for .resx and .resw preview support. (#36499)
asif4318 Jan 8, 2025
084978c
[Settings] Add Workspaces' workspaces.json file to backup/restore lis…
donlaci Jan 9, 2025
5ef9187
[Localization] Fix loc pipeline to send downloaded localized files to…
lei9444 Jan 9, 2025
7d8e4a7
[AdvancedPaste]Fixed issues with Screen Reader integration (#36778)
drawbyperpetual Jan 10, 2025
3ae3659
Remove Advent calendar from README (#36777)
cinnamon-msft Jan 10, 2025
a665975
[AdvancedPaste]Add all BitmapDecoder supported image filetypes to Ima…
daverayment Jan 13, 2025
aa9f3bb
[AOT]Clean up some AOT build issues in PowerAccent.Core (#36264)
moooyo Jan 13, 2025
df48a33
[WinUI3]Fix Windows 10 title bar borders (#36429)
pingzing Jan 13, 2025
4951a63
[QuickAccent]Fix unstable language loading (#36721)
jaimecbernardo Jan 13, 2025
8896cf8
[Peek]Bring into foreground if previously minimized (#36506)
asif4318 Jan 13, 2025
f11c885
Update Run docs README (#36857)
cinnamon-msft Jan 13, 2025
80461c0
[Monaco]Make minimap toggleable (#33742)
PesBandi Jan 14, 2025
3a10fac
[Monaco]Fix Json format preview setting (#36867)
jaimecbernardo Jan 14, 2025
162096c
[KBM]Added option for exact match shortcut (#36000)
mantaionut Jan 15, 2025
5bb9855
[Deps][Security]Update .NET Packages from 9.0.0 to 9.0.1 (#36879)
snickler Jan 15, 2025
fb20c2d
Merge remote-tracking branch 'mainPT/main' into stefan/merte_pt_7
stefansjfw Jan 15, 2025
0052fe2
Fix bad merge
stefansjfw Jan 15, 2025
2471541
[check-spelling] Update metadata
stefansjfw Jan 15, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .github/actions/spell-check/allow/code.txt
Original file line number Diff line number Diff line change
Expand Up @@ -97,6 +97,7 @@ EXSEL
HOLDENTER
HOLDESC
HOLDSPACE
HOLDBACKSPACE
KBDLLHOOKSTRUCT
keyevent
LAlt
Expand Down
2 changes: 0 additions & 2 deletions .github/actions/spell-check/expect.txt
Original file line number Diff line number Diff line change
Expand Up @@ -661,7 +661,6 @@ iid
Iindex
Ijwhost
IKs
iljxck
IMAGEHLP
IMAGERESIZERCONTEXTMENU
IMAGERESIZEREXT
Expand Down Expand Up @@ -756,7 +755,6 @@ lastcodeanalysissucceeded
Lastdevice
LASTEXITCODE
LAYOUTRTL
lcb
LCIDTo
Lclean
Ldone
Expand Down
6 changes: 3 additions & 3 deletions .pipelines/loc/loc.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ steps:
TDBuildServiceConnection: $(TouchdownServiceConnection)
authType: SubjectNameIssuer
resourceFilePath: |
**\Resources.resx
**\Resource.resx
**\Resources.resw
src\**\Resources.resx
src\**\Resource.resx
src\**\Resources.resw
outputDirectoryRoot: LocOutput
appendRelativeDir: true
pseudoSetting: Included
Expand Down
42 changes: 21 additions & 21 deletions Directory.Packages.props
Original file line number Diff line number Diff line change
Expand Up @@ -33,21 +33,21 @@
<PackageVersion Include="MessagePack" Version="2.5.187" />
<PackageVersion Include="Microsoft.CmdPal.Extensions.SDK" Version="0.0.1" />
<PackageVersion Include="Microsoft.CodeAnalysis.NetAnalyzers" Version="9.0.0" />
<PackageVersion Include="Microsoft.Data.Sqlite" Version="9.0.0" />
<PackageVersion Include="Microsoft.Data.Sqlite" Version="9.0.1" />
<!-- Including Microsoft.Bcl.AsyncInterfaces to force version, since it's used by Microsoft.SemanticKernel. -->
<PackageVersion Include="Microsoft.Bcl.AsyncInterfaces" Version="9.0.0" />
<PackageVersion Include="Microsoft.Bcl.AsyncInterfaces" Version="9.0.1" />
<PackageVersion Include="Microsoft.Diagnostics.Tracing.TraceEvent" Version="3.1.16" />
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Logging" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Hosting" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.Hosting.WindowsServices" Version="9.0.0" />
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="9.0.1" />
<PackageVersion Include="Microsoft.Extensions.Logging" Version="9.0.1" />
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="9.0.1" />
<PackageVersion Include="Microsoft.Extensions.Hosting" Version="9.0.1" />
<PackageVersion Include="Microsoft.Extensions.Hosting.WindowsServices" Version="9.0.1" />
<PackageVersion Include="Microsoft.SemanticKernel" Version="1.15.0" />
<PackageVersion Include="Microsoft.Toolkit.Uwp.Notifications" Version="7.1.2" />
<PackageVersion Include="Microsoft.Web.WebView2" Version="1.0.2903.40" />
<!-- Package Microsoft.Win32.SystemEvents added as a hack for being able to exclude the runtime assets so they don't conflict with 8.0.1. This is a dependency of System.Drawing.Common but the 8.0.1 version wasn't published to nuget. -->
<PackageVersion Include="Microsoft.Win32.SystemEvents" Version="9.0.0" />
<PackageVersion Include="Microsoft.Windows.Compatibility" Version="9.0.0" />
<PackageVersion Include="Microsoft.Win32.SystemEvents" Version="9.0.1" />
<PackageVersion Include="Microsoft.Windows.Compatibility" Version="9.0.1" />
<PackageVersion Include="Microsoft.Windows.CsWin32" Version="0.2.46-beta" />
<!-- CsWinRT version needs to be set to have a WinRT.Runtime.dll at the same version contained inside the NET SDK we're currently building on CI. -->
<!--
Expand All @@ -73,26 +73,26 @@
<PackageVersion Include="StreamJsonRpc" Version="2.19.27" />
<PackageVersion Include="StyleCop.Analyzers" Version="1.2.0-beta.556" />
<!-- Package System.CodeDom added as a hack for being able to exclude the runtime assets so they don't conflict with 8.0.1. This is a dependency of System.Management but the 8.0.1 version wasn't published to nuget. -->
<PackageVersion Include="System.CodeDom" Version="9.0.0" />
<PackageVersion Include="System.CodeDom" Version="9.0.1" />
<PackageVersion Include="System.CommandLine" Version="2.0.0-beta4.22272.1" />
<PackageVersion Include="System.ComponentModel.Composition" Version="9.0.0" />
<PackageVersion Include="System.Configuration.ConfigurationManager" Version="9.0.0" />
<PackageVersion Include="System.Data.OleDb" Version="9.0.0" />
<PackageVersion Include="System.ComponentModel.Composition" Version="9.0.1" />
<PackageVersion Include="System.Configuration.ConfigurationManager" Version="9.0.1" />
<PackageVersion Include="System.Data.OleDb" Version="9.0.1" />
<!-- Package System.Data.SqlClient added to force it as a dependency of Microsoft.Windows.Compatibility to the latest version available at this time. -->
<PackageVersion Include="System.Data.SqlClient" Version="4.8.6" />
<!-- Package System.Diagnostics.EventLog added as a hack for being able to exclude the runtime assets so they don't conflict with 8.0.1. This is a dependency of System.Data.OleDb but the 8.0.1 version wasn't published to nuget. -->
<PackageVersion Include="System.Diagnostics.EventLog" Version="9.0.0" />
<PackageVersion Include="System.Diagnostics.EventLog" Version="9.0.1" />
<!-- Package System.Diagnostics.PerformanceCounter added as a hack for being able to exclude the runtime assets so they don't conflict with 8.0.11. -->
<PackageVersion Include="System.Diagnostics.PerformanceCounter" Version="9.0.0" />
<PackageVersion Include="System.Drawing.Common" Version="9.0.0" />
<PackageVersion Include="System.Diagnostics.PerformanceCounter" Version="9.0.1" />
<PackageVersion Include="System.Drawing.Common" Version="9.0.1" />
<PackageVersion Include="System.IO.Abstractions" Version="21.0.29" />
<PackageVersion Include="System.IO.Abstractions.TestingHelpers" Version="21.0.29" />
<PackageVersion Include="System.Management" Version="9.0.0" />
<PackageVersion Include="System.Management" Version="9.0.1" />
<PackageVersion Include="System.Reactive" Version="6.0.1" />
<PackageVersion Include="System.Runtime.Caching" Version="9.0.0" />
<PackageVersion Include="System.ServiceProcess.ServiceController" Version="9.0.0" />
<PackageVersion Include="System.Text.Encoding.CodePages" Version="9.0.0" />
<PackageVersion Include="System.Text.Json" Version="9.0.0" />
<PackageVersion Include="System.Runtime.Caching" Version="9.0.1" />
<PackageVersion Include="System.ServiceProcess.ServiceController" Version="9.0.1" />
<PackageVersion Include="System.Text.Encoding.CodePages" Version="9.0.1" />
<PackageVersion Include="System.Text.Json" Version="9.0.1" />
<PackageVersion Include="UnicodeInformation" Version="2.6.0" />
<PackageVersion Include="UnitsNet" Version="5.56.0" />
<PackageVersion Include="UTF.Unknown" Version="2.5.1" />
Expand Down
42 changes: 21 additions & 21 deletions NOTICE.md
Original file line number Diff line number Diff line change
Expand Up @@ -1324,21 +1324,21 @@ EXHIBIT A -Mozilla Public License.
- Mages 3.0.0
- Markdig.Signed 0.34.0
- MessagePack 2.5.187
- Microsoft.Bcl.AsyncInterfaces 9.0.0
- Microsoft.Bcl.AsyncInterfaces 9.0.1
- Microsoft.CodeAnalysis.NetAnalyzers 9.0.0
- Microsoft.Data.Sqlite 9.0.0
- Microsoft.Data.Sqlite 9.0.1
- Microsoft.Diagnostics.Tracing.TraceEvent 3.1.16
- Microsoft.Extensions.DependencyInjection 9.0.0
- Microsoft.Extensions.Hosting 9.0.0
- Microsoft.Extensions.Hosting.WindowsServices 9.0.0
- Microsoft.Extensions.Logging 9.0.0
- Microsoft.Extensions.Logging.Abstractions 9.0.0
- Microsoft.Extensions.DependencyInjection 9.0.1
- Microsoft.Extensions.Hosting 9.0.1
- Microsoft.Extensions.Hosting.WindowsServices 9.0.1
- Microsoft.Extensions.Logging 9.0.1
- Microsoft.Extensions.Logging.Abstractions 9.0.1
- Microsoft.NET.ILLink.Tasks (A)
- Microsoft.SemanticKernel 1.15.0
- Microsoft.Toolkit.Uwp.Notifications 7.1.2
- Microsoft.Web.WebView2 1.0.2903.40
- Microsoft.Win32.SystemEvents 9.0.0
- Microsoft.Windows.Compatibility 9.0.0
- Microsoft.Win32.SystemEvents 9.0.1
- Microsoft.Windows.Compatibility 9.0.1
- Microsoft.Windows.CsWin32 0.2.46-beta
- Microsoft.Windows.CsWinRT 2.1.5
- Microsoft.Windows.SDK.BuildTools 10.0.22621.2428
Expand All @@ -1356,25 +1356,25 @@ EXHIBIT A -Mozilla Public License.
- SharpCompress 0.37.2
- StreamJsonRpc 2.19.27
- StyleCop.Analyzers 1.2.0-beta.556
- System.CodeDom 9.0.0
- System.CodeDom 9.0.1
- System.CommandLine 2.0.0-beta4.22272.1
- System.ComponentModel.Composition 9.0.0
- System.Configuration.ConfigurationManager 9.0.0
- System.Data.OleDb 9.0.0
- System.ComponentModel.Composition 9.0.1
- System.Configuration.ConfigurationManager 9.0.1
- System.Data.OleDb 9.0.1
- System.Data.SqlClient 4.8.6
- System.Diagnostics.EventLog 9.0.0
- System.Diagnostics.PerformanceCounter 9.0.0
- System.Drawing.Common 9.0.0
- System.Diagnostics.EventLog 9.0.1
- System.Diagnostics.PerformanceCounter 9.0.1
- System.Drawing.Common 9.0.1
- System.IO.Abstractions 21.0.29
- System.IO.Abstractions.TestingHelpers 21.0.29
- System.Management 9.0.0
- System.Management 9.0.1
- System.Net.Http 4.3.4
- System.Private.Uri 4.3.2
- System.Reactive 6.0.1
- System.Runtime.Caching 9.0.0
- System.ServiceProcess.ServiceController 9.0.0
- System.Text.Encoding.CodePages 9.0.0
- System.Text.Json 9.0.0
- System.Runtime.Caching 9.0.1
- System.ServiceProcess.ServiceController 9.0.1
- System.Text.Encoding.CodePages 9.0.1
- System.Text.Json 9.0.1
- System.Text.RegularExpressions 4.3.1
- UnicodeInformation 2.6.0
- UnitsNet 5.56.0
Expand Down
8 changes: 1 addition & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Microsoft PowerToys

![Hero image for Microsoft PowerToys](doc/images/overview/PT_holiday_hero_image.png)
![Hero image for Microsoft PowerToys](doc/images/overview/PT_hero_image.png)

[How to use PowerToys][usingPowerToys-docs-link] | [Downloads & Release notes][github-release-link] | [Contributing to PowerToys](#contributing) | [What's Happening](#whats-happening) | [Roadmap](#powertoys-roadmap)

Expand All @@ -20,12 +20,6 @@ Microsoft PowerToys is a set of utilities for power users to tune and streamline
| [Registry Preview](https://aka.ms/PowerToysOverview_RegistryPreview) | [Screen Ruler](https://aka.ms/PowerToysOverview_ScreenRuler) | [Shortcut Guide](https://aka.ms/PowerToysOverview_ShortcutGuide) |
| [Text Extractor](https://aka.ms/PowerToysOverview_TextExtractor) | [Video Conference Mute](https://aka.ms/PowerToysOverview_VideoConference) | [Workspaces](https://aka.ms/PowerToysOverview_Workspaces) |

## 🎁⭐ PowerToys Advent calendar ⭐🎁

We will be highlighting a cool utility each day for 24 days in December! To follow along, check out these threads:
- https://bsky.app/profile/kaylacinnamon.bsky.social/post/3lcb7iljxck2o
- https://x.com/cinnamon_msft/status/1863284610773246257

## Installing and running Microsoft PowerToys

### Requirements
Expand Down
15 changes: 10 additions & 5 deletions doc/devdocs/modules/launcher/readme.md
Original file line number Diff line number Diff line change
@@ -1,19 +1,24 @@
# Table of Contents
1. [Architecture](/doc/devdocs/modules/launcher/architecture.md)
2. [Debugging](/doc/devdocs/modules/launcher/debugging.md)
3. [Project Structure](/doc/devdocs/modules/launcher/project_structure.md)
4. [Telemetry](/doc/devdocs/modules/launcher/telemetry.md)
5. Plugins
3. [New Plugin Checklist](/doc/devdocs/modules/launcher/new-plugin-checklist.md)
4. [Project Structure](/doc/devdocs/modules/launcher/project_structure.md)
5. [Telemetry](/doc/devdocs/modules/launcher/telemetry.md)
6. Plugins
- [Overview](/doc/devdocs/modules/launcher/plugins/overview.md)
- [Calculator](/doc/devdocs/modules/launcher/plugins/calculator.md)
- [Folder](/doc/devdocs/modules/launcher/plugins/folder.md)
- [History](/doc/devdocs/modules/launcher/plugins/history.md)
- [Indexer](/doc/devdocs/modules/launcher/plugins/indexer.md)
- [OneNote](/doc/devdocs/modules/launcher/plugins/onenote.md)
- [Program](/doc/devdocs/modules/launcher/plugins/program.md)
- [Registry](/doc/devdocs/modules/launcher/plugins/registry.md)
- [Shell](/doc/devdocs/modules/launcher/plugins/shell.md)
- [Time and Date](/doc/devdocs/modules/launcher/plugins/timedate.md)
- [Windows System Commands](/doc/devdocs/modules/launcher/plugins/system.md)
- [Unit Converter](/doc/devdocs/modules/launcher/plugins/community.unitconverter.md)
- [Uri](/doc/devdocs/modules/launcher/plugins/uri.md)
- [Window Walker](/doc/devdocs/modules/launcher/plugins/windowwalker.md)
- [Value Generator](/doc/devdocs/modules/launcher/plugins/community.valuegenerator.md)
- [Web Search](/doc/devdocs/modules/launcher/plugins/WebSearch.md)
- [Windows Settings](/doc/devdocs/modules/launcher/plugins/windowssettings.md)
- [Windows System Commands](/doc/devdocs/modules/launcher/plugins/system.md)
- [Window Walker](/doc/devdocs/modules/launcher/plugins/windowwalker.md)
Binary file removed doc/images/overview/PT_holiday_hero_image.png
Binary file not shown.
51 changes: 32 additions & 19 deletions src/Monaco/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,19 @@
// `theme` can be "vs" for light theme or "vs-dark" for dark theme
// `lang` is the language of the file
// `wrap` if the editor is wrapping or not
// `minimap` if the minimap is shown
// `contextMenu` whether to use the Monaco context menu. The built-in context menu
// doesn't work in Peek, so we set this to false and create a custom one

var theme = ("[[PT_THEME]]" == "dark") ? "vs-dark" : "vs";
var wrap = [[PT_WRAP]];
var minimap = [[PT_MINIMAP]];
var stickyScroll = [[PT_STICKY_SCROLL]];
var fontSize = [[PT_FONT_SIZE]];

var lang = "[[PT_LANG]]";
var wrap = ([[PT_WRAP]] == 1) ? true : false;

var base64code = "[[PT_CODE]]";

var stickyScroll = ([[PT_STICKY_SCROLL]] == 1) ? true : false;

var fontSize = [[PT_FONT_SIZE]];
var contextMenu = ([[PT_CONTEXTMENU]] == 1) ? true : false;
var contextMenu = [[PT_CONTEXTMENU]];

var editor;

Expand All @@ -29,12 +31,13 @@
}).join(''));

function runToggleTextWrapCommand() {
if (wrap) {
editor.updateOptions({ wordWrap: 'off' })
} else {
editor.updateOptions({ wordWrap: 'on' })
}
wrap = !wrap;
editor.updateOptions({ wordWrap: wrap ? 'on' : 'off' });
}

function runToggleMinimap() {
minimap = !minimap;
editor.updateOptions({minimap: {enabled: minimap}});
}

function runCopyCommand() {
Expand Down Expand Up @@ -99,8 +102,8 @@
language: lang, // Sets language of the code
readOnly: true, // Sets to readonly
theme: 'theme', // Sets editor theme
minimap: { enabled: false }, // Disables minimap
lineNumbersMinChars: '3', // Width of the line numbers
minimap: { enabled: minimap }, // Controls if minimap is shown
lineNumbersMinChars: 3, // Width of the line numbers
contextmenu: contextMenu,
scrollbar: {
// Deactivate shadows
Expand Down Expand Up @@ -135,10 +138,20 @@
contextMenuOrder: 100,

// Method that will be executed when the action is triggered.
// @param editor The editor instance is passed in as a convenience
run: function (ed) {
runToggleTextWrapCommand();
}
run: runToggleTextWrapCommand
});

editor.addAction({
id: 'toggle-minimap',

label: 'Toggle minimap',

contextMenuGroupId: 'cutcopypaste',

contextMenuOrder: 100,

// Method that will be executed when the action is triggered.
run: runToggleMinimap
});

onContextMenu();
Expand Down Expand Up @@ -166,4 +179,4 @@
}
</script>
</body>
</html>
</html>
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@

namespace Microsoft.PowerToys.FilePreviewCommon.Monaco.Formatters;

[JsonSourceGenerationOptions(WriteIndented = true)]
[JsonSerializable(typeof(JsonDocument))]
internal sealed partial class FilePreviewJsonSerializerContext : JsonSerializerContext
{
Expand Down
6 changes: 4 additions & 2 deletions src/common/FilePreviewCommon/Formatters/JsonFormatter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,12 @@ public class JsonFormatter : IFormatter

private static readonly JsonSerializerOptions _serializerOptions = new JsonSerializerOptions
{
WriteIndented = true,
Encoder = JavaScriptEncoder.UnsafeRelaxedJsonEscaping,
};

private static readonly FilePreviewJsonSerializerContext _filePreviewJsonSerializerContext = new(_serializerOptions);

/// <inheritdoc/>
public string Format(string value)
{
Expand All @@ -27,8 +30,7 @@ public string Format(string value)

using (var jDocument = JsonDocument.Parse(value, new JsonDocumentOptions { CommentHandling = JsonCommentHandling.Skip }))
{
FilePreviewJsonSerializerContext context = new(_serializerOptions);
return JsonSerializer.Serialize(jDocument, context.JsonDocument);
return JsonSerializer.Serialize(jDocument, _filePreviewJsonSerializerContext.JsonDocument);
}
}
}
Expand Down
12 changes: 12 additions & 0 deletions src/common/ManagedCommon/NativeMethods.cs
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ internal static class NativeMethods
[DllImport("user32.dll")]
internal static extern uint SendInput(uint nInputs, INPUT[] pInputs, int cbSize);

[DllImport("dwmapi")]
internal static extern IntPtr DwmExtendFrameIntoClientArea(IntPtr hWnd, ref MARGINS pMarInset);

[StructLayout(LayoutKind.Sequential)]
public struct INPUT
{
Expand Down Expand Up @@ -100,5 +103,14 @@ internal enum INPUTTYPE : uint
INPUT_KEYBOARD = 1,
INPUT_HARDWARE = 2,
}

[StructLayout(LayoutKind.Sequential)]
internal struct MARGINS
{
public int cxLeftWidth;
public int cxRightWidth;
public int cyTopHeight;
public int cyBottomHeight;
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -4,10 +4,15 @@

using System;

namespace Common.UI
namespace ManagedCommon
{
public static class OSVersionHelper
{
public static bool IsWindows10()
{
return Environment.OSVersion.Version.Major >= 10 && Environment.OSVersion.Version.Minor < 22000;
}

public static bool IsWindows11()
{
return Environment.OSVersion.Version.Major >= 10 && Environment.OSVersion.Version.Build >= 22000;
Expand Down
Loading