[PR #14107] [MERGED] Allow for exe/dll paths for the Icon setting #29938

Open
opened 2026-01-31 09:37:43 +00:00 by claunia · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/microsoft/terminal/pull/14107
Author: @PankajBhojwani
Created: 9/30/2022
Status: Merged
Merged: 10/26/2022
Merged by: @undefined

Base: mainHead: dev/migrie/1504-prototype-2


📝 Commits (10+)

  • 4b4d794 this is the code from the experiment brnach, in a more reasonable place
  • cfc15f1 Parse out the index from the string
  • a5b82ce I don't think this works at all
  • 56fc572 it doesn't crash instantaneously anymore
  • f349d99 everything works except cmdpal
  • 0e30565 format
  • 1b28a93 remove artifact
  • 200d48d switch to content presenter, switch to not async
  • 6e22de6 nits
  • aa21a6f format

📊 Changes

11 files changed (+198 additions, -32 deletions)

View changed files

📝 src/cascadia/LocalTests_SettingsModel/pch.h (+2 -0)
📝 src/cascadia/TerminalApp/CommandPalette.xaml (+12 -12)
📝 src/cascadia/TerminalApp/PaletteItem.cpp (+7 -0)
📝 src/cascadia/TerminalApp/PaletteItem.h (+2 -0)
📝 src/cascadia/TerminalApp/PaletteItem.idl (+1 -0)
📝 src/cascadia/TerminalApp/TerminalPage.cpp (+3 -6)
📝 src/cascadia/TerminalSettingsEditor/MainPage.cpp (+2 -9)
📝 src/cascadia/TerminalSettingsModel/IconPathConverter.cpp (+162 -2)
📝 src/cascadia/TerminalSettingsModel/IconPathConverter.h (+2 -2)
📝 src/cascadia/TerminalSettingsModel/IconPathConverter.idl (+1 -1)
📝 src/cascadia/TerminalSettingsModel/pch.h (+4 -0)

📄 Description

Summary of the Pull Request

Allow exe/dll paths for the Icon setting

The exe/dll icon needs to work in all the following areas:

  • The tab
  • The navigation view item in the SUI
  • The new tab flyout
  • The command palette

PR Checklist

  • Closes Switch from ConhostConnection to the official ConPTY API (#1504)
  • CLA signed. If not, go over here and sign the CLA
  • Tests added/passed
  • Documentation updated. If checked, please file a pull request on our docs repo and link it here: #xxx
  • Schema updated.
  • I've discussed this with core contributors already. If not checked, I'm ready to accept this work might be rejected in favor of a different grand plan. Issue number where discussion took place: #xxx

Detailed Description of the Pull Request / Additional comments

For the command palette, we had to switch to using ContentPresenter because IconSourceElement cannot take in every type of icon we need to provide

Validation Steps Performed

Setting "%SystemRoot%\System32\shell32.dll,214" as the icon for a profile works in all the cases listed above.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/microsoft/terminal/pull/14107 **Author:** [@PankajBhojwani](https://github.com/PankajBhojwani) **Created:** 9/30/2022 **Status:** ✅ Merged **Merged:** 10/26/2022 **Merged by:** [@undefined](undefined) **Base:** `main` ← **Head:** `dev/migrie/1504-prototype-2` --- ### 📝 Commits (10+) - [`4b4d794`](https://github.com/microsoft/terminal/commit/4b4d794956c1078f182fd5dc5af06661161e1ee8) this is the code from the experiment brnach, in a more reasonable place - [`cfc15f1`](https://github.com/microsoft/terminal/commit/cfc15f193f7a652cc13a5c0b12ddcb6b142cd7c5) Parse out the index from the string - [`a5b82ce`](https://github.com/microsoft/terminal/commit/a5b82cebab56d80f9fb244af89927fb6f1aaceb0) I don't think this works at all - [`56fc572`](https://github.com/microsoft/terminal/commit/56fc5720290cef2f57bea368084e2995f160feca) it doesn't crash instantaneously anymore - [`f349d99`](https://github.com/microsoft/terminal/commit/f349d99012195655ef5ca573c99729d2fddac570) everything works except cmdpal - [`0e30565`](https://github.com/microsoft/terminal/commit/0e30565f947b06fa4cd481055540e1b20643df9f) format - [`1b28a93`](https://github.com/microsoft/terminal/commit/1b28a93146508c1f1637aec24e1aa211c0a6ab22) remove artifact - [`200d48d`](https://github.com/microsoft/terminal/commit/200d48d80174fe0a5b6ab63b2bf143e43e7d69be) switch to content presenter, switch to not async - [`6e22de6`](https://github.com/microsoft/terminal/commit/6e22de6504800483277cdd0f2c18f609e52b2e5a) nits - [`aa21a6f`](https://github.com/microsoft/terminal/commit/aa21a6f2d9c8b62f1c589dcdc51ce4e481bdb21c) format ### 📊 Changes **11 files changed** (+198 additions, -32 deletions) <details> <summary>View changed files</summary> 📝 `src/cascadia/LocalTests_SettingsModel/pch.h` (+2 -0) 📝 `src/cascadia/TerminalApp/CommandPalette.xaml` (+12 -12) 📝 `src/cascadia/TerminalApp/PaletteItem.cpp` (+7 -0) 📝 `src/cascadia/TerminalApp/PaletteItem.h` (+2 -0) 📝 `src/cascadia/TerminalApp/PaletteItem.idl` (+1 -0) 📝 `src/cascadia/TerminalApp/TerminalPage.cpp` (+3 -6) 📝 `src/cascadia/TerminalSettingsEditor/MainPage.cpp` (+2 -9) 📝 `src/cascadia/TerminalSettingsModel/IconPathConverter.cpp` (+162 -2) 📝 `src/cascadia/TerminalSettingsModel/IconPathConverter.h` (+2 -2) 📝 `src/cascadia/TerminalSettingsModel/IconPathConverter.idl` (+1 -1) 📝 `src/cascadia/TerminalSettingsModel/pch.h` (+4 -0) </details> ### 📄 Description ## Summary of the Pull Request Allow exe/dll paths for the `Icon` setting The exe/dll icon needs to work in all the following areas: * [x] The tab * [x] The navigation view item in the SUI * [x] The new tab flyout * [x] The command palette ## PR Checklist * [x] Closes #1504 * [x] CLA signed. If not, go over [here](https://cla.opensource.microsoft.com/microsoft/Terminal) and sign the CLA * [ ] Tests added/passed * [ ] Documentation updated. If checked, please file a pull request on [our docs repo](https://github.com/MicrosoftDocs/terminal) and link it here: #xxx * [ ] Schema updated. * [x] I've discussed this with core contributors already. If not checked, I'm ready to accept this work might be rejected in favor of a different grand plan. Issue number where discussion took place: #xxx ## Detailed Description of the Pull Request / Additional comments For the command palette, we had to switch to using `ContentPresenter` because `IconSourceElement` cannot take in every type of icon we need to provide ## Validation Steps Performed Setting "%SystemRoot%\System32\shell32.dll,214" as the icon for a profile works in all the cases listed above. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
claunia added the pull-request label 2026-01-31 09:37:43 +00:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/terminal#29938