screenFetch icon indicating copy to clipboard operation
screenFetch copied to clipboard

Slightly broken layout on Windows 8.1 Pro

Open Jorge9811 opened this issue 4 years ago • 2 comments

As you can see right below, the WM Theme field seems to be a tad broken on Windows Embedded 8.1 Industry Pro x64. I am using a custom theme, if it matters. mintty-2019-08-29_12-58-30

EDIT: Could it be because it's trying to retrieve the visual theme from the wrong path? I'm honestly not sure, just throwing a guess. Themes are located in C:\Windows\Resources\Themes for what it's worth.

EDIT2: I might have fixed it, somewhat. notepad++-2019-08-29_13-16-15

Jorge9811 avatar Aug 30 '19 16:08 Jorge9811

Hey there @Jorge9811 would you mind sharing what you've changed? Line numbers would help.

KittyKatt avatar Oct 06 '19 16:10 KittyKatt

I just fixed this locally. On my machine (Win10), reg query outputs 3 lines: a blank line, key name, key value: reg query 'HKCU\Software\Microsoft\Windows\CurrentVersion\Themes' //v 'CurrentTheme' returns


HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Themes
    CurrentTheme    REG_SZ    C:\Users\foobar\AppData\Local\Microsoft\Windows\Themes\Custom.theme

which the line Win_theme=$(echo "$themeFile" | awk -F"\\" '{print $NF}' | sed 's|\.theme$||') shortens to


Themes
Custom

I fixed it by piping the reg query call through tail: themeFile="$(reg query 'HKCU\Software\Microsoft\Windows\CurrentVersion\Themes' //v 'CurrentTheme' | tail +3)" which starts with the 3rd line (key value). I don't know if there's a "better" way. The code is in detectwmtheme(), my detected distro is Msys (I'm using mintty), and my windowmanager is DWM/Explorer, so the relevant line for me is 2454.

almitydave avatar Feb 25 '21 20:02 almitydave