More knock off pocket tools (this time Victorinox) and a bit of customising ►
◄ Project Zebra: We build our computers the way we build our cities
I know, but despite having been using Linux full time since 2016 personally, Windows is still quite widely used and Microsoft still keep breaking the user experience by removing features and making things non-configurable. It's as if they looked longingly at the Gnome project and want to be them.
Windows 11 launched with a rewritten taskbar lacking simple expected features such as being able to move its position and being able to see your open windows on it. The only supported behaviour is a single icon per application with no window titles visible, so if you've got half a dozen spreadsheets open and one window maximised it's impossible to tell what other documents are open. Apparently nobody at Microsoft uses a computer for work, it's that mindbogglingly stupid a situation.
Before getting into workarounds I should note that Microsoft seems eventually to have realised that users are genuinely angry about and not upgrading because of it:
https://blogs.windows.com/windows-insider/2023/05/24/announcing-windows-11-insider-preview-build-23466/
"We’re excited to bring you an early version of one of our most requested features for Windows 11, never combined mode. In never combined mode, you’ll be able to see each window of your applications on the taskbar individually, as well as their corresponding labels."
That's two years of failing to implement a basic window management function, folks. And still no sign of official support for moving the taskbar, in fact MS seem very anti putting it to the right or left of the screen from official comments. Being selfish hopefully at least top positioning will return, or at least a registry hack will work and be reliable. They really seem to hate Fitt's Law, efforts to minimise mouse travel and people trying to avoid or minimise repetitive strain injuries. See also: the mess that is contrast and padding in modern Office UI design, or the fact there's no official way to hide the proliferation of additional folders in Outlook mailboxes without delving into VBA.
Whilst waiting for Microsoft to fix the taskbar, you can also see open windows with the task switcher (Alt+Tab or Alt+Shift+Tab in reverse) or task view (Win+Tab). Less well known is that you can use Ctrl+Alt+Tab and the task switcher waits for you to make a selection, which is better for accessibility.
Things that I find make these features more useful are switching off the setting that shows individual Edge tabs as separate windows, turning off distracting animations, and giving the persistent task switcher a less finger-cramping shortcut. The first two are easy:
https://www.howtogeek.com/696775/how-to-stop-alttab-from-showing-edge-browser-tabs/
https://superuser.com/questions/1058344/turn-off-windows-10-task-view-sliding-animation
Remapping keyboards shortcuts in this desktop environment is a bit trickier, with limited built in options. Windows keyboard remapping is key-for-key, not key-to-multiple-keys. There's an official Microsoft PowerToy called Keyboard Manager that does something like the latter, but which is stay-resident, requires far too high a task priority and can cause other software to misbehave. A workaround is to do it in two steps: map a key to a media key (whether your keyboard has them or not) which in turn can run something. Note that the remapping part is a per-machine setting in current Windows, not per-user like it was on XP.
It should be possible to send keys with VBScript such as the script below but in practice it's unreliable and doesn't always fire, or fires but the active window intercepts what needs to be a global shortcut.
Set WshShell = WScript.CreateObject("WScript.Shell")
WshShell.SendKeys "^%{TAB}"
Instead you could use either a swiss army knife type tool such as nircmd or a fuller compilable scripting language such AutoHotKey or AutoIt (and you could set global hotkeys with those too). However, nircmd is probably less likely to give anti-virus false positives.
https://superuser.com/questions/1055166/generic-way-to-remap-every-media-button
So to map F1 to media key 15 (mail) before logging off and back on:
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\Keyboard Layout]
"Scancode Map"=hex:00,00,00,00,00,00,00,00,02,00,00,00,6c,e0,3b,00,00,00,00,00
And to change what the "mail" key does for your user:
[HKEY_CURRENT_USER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\AppKey\15]
"ShellExecute"="notepad.exe"
For the task switcher it'd be: nircmd.exe sendkeypress "ctrl+alt+tab"
SendKeys does have uses. For instance, an apparently popular bit of VBScript if you need to make uninterrupted presentations or deal with Microsoft's video-conferencing app interpreting no keypresses as "away" after an unconfigurable five minutes (not helpful when you're reading a document or making notes and want people to know you're available) is:
Set wsc = CreateObject("WScript.Shell")
Do
WScript.Sleep(1000*60)
wsc.SendKeys("{F13}")
Loop
i.e. Each minute send an F13 key press which (not being a real key on standard keyboards these days) does nothing in most applications, unlike num lock and scroll lock which are also commonly used. It may have unforeseen consequences for "press any key" type scenarios with apps that read raw keyboard input, though.
If you just need to pause screen locking whilst in PowerPoint, playing a video silently in an application that prevents a screen saver kicking in should also work. PowerPoint could send that 'busy' signal, but doesn't.
If you have multiple video-conferencing apps that fight Windows to be the default and show presence information in Outlook, you can use RegEdit to set DefaultIMApp in "HKEY_CURRENT_USER\Software\IM Providers" to the relevant one and set the key itself to be owned by a different user, such as an admin account. Why Windows doesn't allow the user to configure this themselves in a way that can't be overridden by an application (like they do with Edge to make it harder for people to jump ship to another default browser) is another question. It's like the bad old days when things like RealPlayer would steal default file associations.