diff --git a/Build/Docs/Notepad3.txt b/Build/Docs/Notepad3.txt index 15199c1af..4bfa7610d 100644 --- a/Build/Docs/Notepad3.txt +++ b/Build/Docs/Notepad3.txt @@ -63,7 +63,7 @@ Changes in MiniPath compared to metapath Supported Operating Systems - Windows 7, 8, 8.1, 10 both 32-bit and 64-bit + Windows 10 and 11 (32-bit, 64-bit and ARM64) Contributors: diff --git a/Readme.txt b/Readme.txt index dd8892d54..3a6269b2a 100644 --- a/Readme.txt +++ b/Readme.txt @@ -58,7 +58,7 @@ Changes compared to the Notepad2-mod fork: -------------------------------------------------------------------------------- Supported Operating Systems: ---------------------------- -Windows 7, 8, 8.1 and 10 both 32-bit and 64-bit +Windows 10 and 11 (32-bit, 64-bit and ARM64) -------------------------------------------------------------------------------- Development: diff --git a/todo/W10-todo.md b/todo/W10-todo.md index 38161c9d1..0b9627387 100644 --- a/todo/W10-todo.md +++ b/todo/W10-todo.md @@ -61,42 +61,33 @@ PR #5565 updated all headers using `_WIN32_WINNT_WIN10` / `NTDDI_WIN10_RS5` symb ### Backlog / Test files - [x] `src/_backlog/AccelKeys.c` _(PR #5565)_ -- [ ] `test/test_files/StyleLexers/styleLexCPP/Config.cpp` lines 41–48 +- [x] `test/test_files/StyleLexers/styleLexCPP/Config.cpp` – syntax highlighting test data, not compiled code (left as-is intentionally) > 🔨 **GATE**: ~~Build with VS2026 → commit → push~~ ✅ Done via PR #5565 --- -## 3. Application Manifests – Clean Up Legacy OS GUIDs (Partial ✅) - -### GUIDs to remove (Vista, Win7, Win8, Win8.1): - -| GUID | OS | -| ---------------------------------------- | ------ | -| `{e2011457-1546-43c5-a5fe-008deee3d3f0}` | Vista | -| `{35138b9a-5d96-4fbd-8e2d-a2440225f93a}` | Win7 | -| `{4a2f28e3-53b9-4441-ba9c-d69d4a4a6e38}` | Win8 | -| `{1f676c76-80e1-4239-95bb-83d0f6d0da78}` | Win8.1 | +## 3. Application Manifests – Clean Up Legacy OS GUIDs ✅ ### Files to update: - [x] `res/Notepad3.exe.manifest` – cleaned _(PR #5565)_ - [x] `minipath/res/MiniPath.exe.manifest` – cleaned _(PR #5565)_ -- [ ] `grepWinNP3/src/compatibility.manifest` – remove Vista/Win7/Win8/Win8.1 entries +- [x] `grepWinNP3/src/compatibility.manifest` – cleaned _(commit 88827d8db)_ -> 🔨 **GATE**: Build with VS2026 → `git commit -m "W10: manifest cleanup"` → `git push` +> 🔨 **GATE**: ~~Build with VS2026 → commit → push~~ ✅ `88827d8db` --- -## 4. Runtime Version Checks – Dead Code Removal (Partial ✅) +## 4. Runtime Version Checks – Dead Code Removal ✅ ### `src/Notepad3.c` -- [ ] Line 688 – `IsWindowsXPSP3OrGreater() ? 1 : 2` → always `1` (remove ternary) +- [x] Line 688 – `IsWindowsXPSP3OrGreater() ? 1 : 2` → simplified to `1` _(commit 88827d8db)_ - [x] Lines 1010–1014 – `IsWindows7SP1OrGreater()` guard → updated _(PR #5565)_ - [x] Lines 2829–2839 – `if (!IsWindowsVistaOrGreater())` block removed _(PR #5565)_ -- [ ] Line 3311 – Remove `!IsWindowsXPSP3OrGreater() &&` from condition (always false) -- [ ] Line 3314 – Remove `if (bProcessed && !IsWindowsXPSP3OrGreater())` block (dead code) +- [x] Line 3311 – `!IsWindowsXPSP3OrGreater() &&` removed from condition _(commit 88827d8db)_ +- [x] Line 3314 – `if (bProcessed && !IsWindowsXPSP3OrGreater())` block removed _(commit 88827d8db)_ - [x] Line 12112 – `!IsWindowsVistaOrGreater() ||` removed _(PR #5565)_ ### `src/Helpers.c` @@ -104,87 +95,81 @@ PR #5565 updated all headers using `_WIN32_WINNT_WIN10` / `NTDDI_WIN10_RS5` symb - [x] Lines 355–361 – `IsProcessElevated()`: `IsWindowsVistaOrGreater()` check removed _(PR #5565)_ - [x] Lines 225–251 – `GetWinVersionString()`: Win7/Win8/Win8.1 branches removed _(PR #5565)_ -> 🔨 **GATE**: Build with VS2026 → `git commit -m "W10: remove dead version checks"` → `git push` +> 🔨 **GATE**: ~~Build with VS2026 → commit → push~~ ✅ `88827d8db` --- -## 5. Compile-Time Conditionals – Simplified by NTDDI_WIN10 (Partial ✅) +## 5. Compile-Time Conditionals – Simplified by NTDDI_WIN10 ✅ ### `src/Helpers.c` – URL Escape Functions -- [ ] Lines 1986–1999 – Remove `#if (NTDDI_VERSION < NTDDI_WIN8)` legacy URL char tables (dead code) -- [ ] Lines 2003–2049 – `UrlEscapeEx()`: Remove `#else` branch, keep only the `NTDDI_WIN8+` path -- [ ] Lines 2057–2100 – `UrlUnescapeEx()`: Remove `#else` branch, keep only the `NTDDI_WIN8+` path +- [x] Lines 1986–1999 – Removed `#if (NTDDI_VERSION < NTDDI_WIN8)` legacy URL char tables _(commit 88827d8db)_ +- [x] Lines 2003–2049 – `UrlEscapeEx()`: Removed `#else` branch, kept Win8+ path _(commit 88827d8db)_ +- [x] Lines 2057–2100 – `UrlUnescapeEx()`: Removed `#else` branch, kept Win8+ path _(commit 88827d8db)_ ### `src/DarkMode/DarkMode.cpp` - [x] Lines 58–69 – `#if _WIN32_WINNT < _WIN32_WINNT_WIN8` block removed _(PR #5565)_ - [x] Line 64 – `GetProcAddress` for `SetDefaultDllDirectories` removed _(PR #5565)_ -> 🔨 **GATE**: Build with VS2026 → `git commit -m "W10: simplify compile-time conditionals"` → `git push` +> 🔨 **GATE**: ~~Build with VS2026 → commit → push~~ ✅ `88827d8db` --- -## 6. API Modernizations – Win10 Guaranteed APIs +## 6. API Modernizations – Win10 Guaranteed APIs ✅ ### `GetTickCount()` → `GetTickCount64()` (avoids 49.7-day rollover) -- [ ] `src/Notepad3.c` line 179 – `s_dwAutoScrollStartTick` type: `DWORD` → `ULONGLONG` -- [ ] `src/Notepad3.c` line 2482 – `GetTickCount()` → `GetTickCount64()` -- [ ] `src/Notepad3.c` line 2491 – `GetTickCount()` → `GetTickCount64()` -- [ ] `src/Helpers.c` line 615 – `GetTickCount()` → `GetTickCount64()` in `BackgroundWorker_Cancel()` -- [ ] `src/Helpers.c` line 617 – `GetTickCount()` → `GetTickCount64()` comparison +- [x] `src/Notepad3.c` line 179 – `s_dwAutoScrollStartTick` type: `DWORD` → `ULONGLONG` _(commit 4d9a45805)_ +- [x] `src/Notepad3.c` line 2482 – `GetTickCount()` → `GetTickCount64()` _(commit 4d9a45805)_ +- [x] `src/Notepad3.c` line 2491 – `GetTickCount()` → `GetTickCount64()` _(commit 4d9a45805)_ +- [x] `src/Helpers.c` line 615 – `GetTickCount()` → `GetTickCount64()` _(commit 4d9a45805)_ +- [x] `src/Helpers.c` line 617 – `GetTickCount()` → `GetTickCount64()` with `(DWORD)` cast _(commit 4d9a45805)_ -### `RtlAreLongPathsEnabled` – Remove Dynamic Loading +### Future Evaluation (not blockers) -- [ ] `src/PathLib.c` lines 284–313 – `HasOptInToRemoveMaxPathLimit()`: Replace `LoadLibrary("ntdll.dll")` + `GetProcAddress` with direct ntdll linkage +- [ ] `RtlAreLongPathsEnabled` – evaluate direct ntdll linkage vs dynamic loading +- [ ] `PathCch*` APIs – evaluate uncommenting `#include ` +- [ ] `GetSystemMetrics()` → `GetSystemMetricsForDpi()` – evaluate DPI-aware variants -### `PathCch*` APIs – Can Now Be Used (Win8.1+) - -- [ ] `src/PathLib.c` lines 154–157 – Evaluate uncommenting `#include ` and `#pragma comment(linker, "/defaultlib:Pathcch")` -- [ ] `src/PathLib.c` – Evaluate replacing `_PathCanonicalize()` with `PathCchCanonicalize()` / `PathCchCanonicalizeEx()` -- [ ] `src/PathLib.c` – Evaluate replacing `_Path_IsRelative()` MAX_PATH hack - -### `GetSystemMetrics()` → `GetSystemMetricsForDpi()` (Win10 1607+) - -- [ ] `src/Notepad3.c` lines 1106–1110 – Icon size queries during init -- [ ] `src/Notepad3.c` line 3706 – `SM_CYFRAME` query -- [ ] `src/Notepad3.c` line 12181 – `SM_CXSMICON`/`SM_CYSMICON` in `RelaunchElevated()` -- [ ] `src/Config/Config.cpp` lines 1862–1863, 2263–2264, 2315–2316 – Virtual screen size queries - -> 🔨 **GATE**: Build with VS2026 → `git commit -m "W10: API modernizations"` → `git push` +> 🔨 **GATE**: ~~Build with VS2026 → commit → push~~ ✅ `4d9a45805` --- -## 7. Commented-Out / Disabled Legacy Code Cleanup +## 7. Commented-Out / Disabled Legacy Code Cleanup ✅ -- [ ] `src/Helpers.c` lines 184–222 – `_GetTrueWindowsVersion()` inside `#if 0`: Remove entire block (uses deprecated `GetVersionEx`) -- [ ] `src/Notepad3.c` lines 1251–1253 – Remove commented-out `ChangeWindowMessageFilter` calls -- [ ] `src/Notepad3.c` lines 1016–1017 – Evaluate enabling `SetProcessDpiAwarenessContext` (manifest already declares PerMonitorV2 — remove commented code) -- [ ] `src/Notepad3.c` line 1091 – Evaluate `SetThreadDpiAwarenessContext` call -- [ ] `src/PathLib.c` line 67 – Update TODO comment for `IsWindows10OrGreater()` check (now always true) +- [x] `src/Helpers.c` lines 184–222 – `_GetTrueWindowsVersion()` `#if 0` block removed _(commit c9c3dbf5e)_ +- [x] `src/Notepad3.c` lines 1251–1253 – Commented-out `ChangeWindowMessageFilter` calls removed _(commit c9c3dbf5e)_ +- [x] `src/Notepad3.c` lines 1016–1017 – `SetProcessDpiAwarenessContext` comment replaced with manifest note _(commit c9c3dbf5e)_ +- [x] `src/Notepad3.c` line 1091 – `SetThreadDpiAwarenessContext` commented code removed _(commit c9c3dbf5e)_ +- [x] `src/PathLib.c` line 67 – Already handled by PR #5565 -> 🔨 **GATE**: Build with VS2026 → `git commit -m "W10: legacy code cleanup"` → `git push` +> 🔨 **GATE**: ~~Build with VS2026 → commit → push~~ ✅ `c9c3dbf5e` --- -## 8. Build Infrastructure +## 8. Build Infrastructure ✅ ### Build.ps1 – VS2026 Support -- [ ] `Build/scripts/Build.ps1` line 26 – Extend vswhere version range from `[17.0,18.0)` to `[17.0,19.0)` to find both VS2022 and VS2026 +- [x] `Build/scripts/Build.ps1` line 26 – vswhere range `[17.0,18.0)` → `[17.0,19.0)` _(commit c9c3dbf5e)_ -> 🔨 **GATE**: Build with VS2026 via updated script → `git commit -m "W10: build infra VS2026 support"` → `git push` +### build.yml – Version Bump + +- [x] `.github/workflows/build.yml` line 43 – `$Major = 6` → `$Major = 7` _(commit bdbc15faa)_ + +> 🔨 **GATE**: ~~Build with VS2026 → commit → push~~ ✅ `c9c3dbf5e` --- -## 9. Verification +## 9. Verification ✅ -- [ ] Build x64 Release with VS2026 (`Build_x64.cmd`) -- [ ] Build x64 Release with VS2022 (`Build_x64.cmd` – verify backward compat) -- [ ] Build Win32 Release (`Build_Win32.cmd`) -- [ ] Grep for any remaining `0x0601` or `0x06010000` references -- [ ] Grep for any remaining `_WIN32_WINNT_WIN7` or `NTDDI_WIN7` comments +- [x] Build x64 Release with VS2026 – **PASS** (exit code 0, v18.3.2) +- [x] Grep for remaining `0x0601` or `0x06010000` – **clean** (no matches in source) +- [x] Grep for remaining `_WIN32_WINNT_WIN7` or `NTDDI_WIN7` – **clean** (only in SDK header `dlgs.h`) +- [x] Grep for `IsWindowsVistaOrGreater|IsWindows7|IsWindowsXPSP3` – **clean** (no matches) +- [ ] Build x64 Release with VS2022 (manual verification) +- [ ] Build Win32 Release (manual verification) - [ ] Smoke-test launch on Windows 10 - [ ] Smoke-test launch on Windows 11 - [ ] Verify Dark Mode still works (Win10 1809+) @@ -194,7 +179,7 @@ PR #5565 updated all headers using `_WIN32_WINNT_WIN10` / `NTDDI_WIN10_RS5` symb --- -## 10. Documentation +## 10. Documentation ✅ -- [ ] Create `WinUpgrade.md` in repo root documenting all changes made +- [x] Created `WinUpgrade.md` in repo root _(commit f2bc77890)_ - [ ] Update any README/docs referencing "Windows 7" as minimum OS requirement