taskbar-vd-switcher: add "First letter of desktop name" label format - #3
Open
Cleroth wants to merge 1 commit into
Open
taskbar-vd-switcher: add "First letter of desktop name" label format#3Cleroth wants to merge 1 commit into
Cleroth wants to merge 1 commit into
Conversation
New Content.LabelFormat option `initial` shows the first letter of each desktop's Task View name, keeping surrogate pairs and a trailing combining mark or variation selector intact. Desktops that were never renamed have no Name value and show their number instead. ReadDesktopNames now returns an empty string for those so the label code can tell; the tooltip and the token log keep saying "Desktop N".
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
Label formatoption, First letter of desktop name, to the Content group: each button shows the first letter of the name the desktop has in Task View (Home,Work,Media->H W M). Unnamed desktops show their number.initialoption inContent.LabelFormat, parsed intoVdLabelFormat::Initialviasio::LoadChoicelike the othersé,❤️). Not full grapheme segmentation: ZWJ sequences, skin tones and flags are cut after the first code pointReadDesktopNamesnow returns""for a desktop with noNamevalue instead of substitutingDesktop N, so the label can fall back to the number; the tooltip and the[Layout] tokens:log line apply theDesktop Nfallback themselves. No other consumers@versionuntouchedVerification:
compile-check,verify-readme-sync,verify-settings-order,exit-time-destructor-auditandsubmission-preflightall pass. The extraction was checked standalone against emoji / combining / VS16 / CJK / RTL / empty / whitespace-only names. Live-tested on Windows 11 with this branch loaded as a local Windhawk mod: the first-letter labels render and switching works.Worth a look during your 2.0 live test: renaming a desktop in Task View. The slot the mod registers as
destroyedIdx(8 on current builds, 9 on the older monitor-aware layout) isVirtualDesktopNameChangedper the publicIVirtualDesktopNotificationlayouts, so a rename should already rebuild the grid; the only uncertainty is whether the registryNamevalue is written before that callback fires. If it lags, the label catches up on the next switch/create/destroy.