Blurred file icons in panels under Windows 10 22H2

The behaviour described in the bug report is either by design, or would be far too complex/time-consuming to be changed

Moderators: white, Hacker, petermad, Stefan2

Post Reply
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Blurred file icons in panels under Windows 10 22H2

Post by *MVV »

I have a new machine with Windows 10 22H2 installed, and all TC versions (up to 11.03 RC6, x86 and x64) show blurred system icons for files. Explorer shows same small icons properly.

Sample (compare standard and nonstandard icons, standard ones look blurred): https://i.ibb.co/YLCbJHq/tcblricn.png
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Blurred file icons in panels under Windows 10 22H2

Post by *ghisler(Author) »

Some Windows functions to extract icons return blurred icons when the small icon size (e.g. in the system tray) isn't 16x16 pixels. For example, if the size is 20x20, then Windows will resize the icon to 20x20 and then resize it back to 16x16. Unfortunately there is nothing I can do myself, you will have to find the right settings and change them yourself.

Moderator message

Moved to will not be changed
Author of Total Commander
https://www.ghisler.com
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Re: Blurred file icons in panels under Windows 10 22H2

Post by *MVV »

I have 16x16 icons in taskbar and system tray...
And Explorer does extract proper icons somehow...
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Blurred file icons in panels under Windows 10 22H2

Post by *ghisler(Author) »

Explorer uses a different function which I also use for EXE files. However, this function returns a tiny program icon on a white sheet for most file types instead of the normal app icon, so I will not switch to that function for most types. In your screenshot, the exe icons are not blurry. Strangely the CHM icon is fine too, it probably also uses a different function. I'm 100% sure that you have the problem described above. Is your screen scaling set to a higher value than 100%?
Author of Total Commander
https://www.ghisler.com
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Re: Blurred file icons in panels under Windows 10 22H2

Post by *MVV »

No, I use 100%, don't like how old good programs look on higher scaling.

Good that you've got many details from the screenshot.
ghisler(Author) wrote: 2024-02-19, 08:00 UTCSome Windows functions to extract icons return blurred icons when the small icon size (e.g. in the system tray) isn't 16x16 pixels.
Is there a setting for that except scaling settings? I would like to test if it helps. But my tray icons look like 16x16, as I said.
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Blurred file icons in panels under Windows 10 22H2

Post by *ghisler(Author) »

You could use my registry tool to find out what icon is used. Does Windows 10 use the notepad universal app now like Windows 11 instead of the regular notepad.exe? These apps often have png icons.

https://www.totalcommander.ch/win/tools/registryinfo.zip
Author of Total Commander
https://www.ghisler.com
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Re: Blurred file icons in panels under Windows 10 22H2

Post by *MVV »

Well, Notepad in Windows 10 is still native (unlike Calculator).

I've checked some file types:
.CHM type is "chm.file", default icon is "%SystemRoot%\hh.exe,0"
.DLL type is "dllfile", default icon is "C:\Windows\system32\imageres.dll,-67"
.INI type is "inifile", default icon is "%SystemRoot%\system32\imageres.dll,-69"
.TXT type is "txtfile", default icon is "%SystemRoot%\system32\imageres.dll,-102"
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Blurred file icons in panels under Windows 10 22H2

Post by *ghisler(Author) »

These exe files should all contain 16x16 icons, so it shouldn't blur them unless what I explained above. Something is still wrong with your system.
Author of Total Commander
https://www.ghisler.com
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Re: Blurred file icons in panels under Windows 10 22H2

Post by *MVV »

Well, it is a fresh 22H2 installation, and I don't know where to look...

I have a VM with 22H2, icons are normal in TC there...
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Re: Blurred file icons in panels under Windows 10 22H2

Post by *MVV »

I've tried to run TC with clean INI, same problem.

BTW small icons in 7-Zip file manager are normal: https://i.ibb.co/0qZpMyr/11.png
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Blurred file icons in panels under Windows 10 22H2

Post by *ghisler(Author) »

I do not have this problem in Windows 11.
Please post the output of registryinfo for at least one affected file type.
Author of Total Commander
https://www.ghisler.com
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Re: Blurred file icons in panels under Windows 10 22H2

Post by *MVV »

Registryinfo output for TXT:

Code: Select all

[HKEY_CLASSES_ROOT\.txt]
"Content Type"="text/plain"
"PerceivedType"="text"
@="txtfile"
[HKEY_CLASSES_ROOT\.txt\PersistentHandler]
@="{5e941d80-bf96-11cd-b579-08002b30bfeb}"
[HKEY_CLASSES_ROOT\.txt\ShellNew]
"ItemName"="@%SystemRoot%\system32\notepad.exe,-470"
"NullFile"=""
=============================
[HKEY_CLASSES_ROOT\txtfile]
@="Text Document"
"EditFlags"=dword:00210000
[HKEY_CLASSES_ROOT\txtfile\DefaultIcon]
@="%SystemRoot%\system32\imageres.dll,-102"
[HKEY_CLASSES_ROOT\txtfile\shell]
[HKEY_CLASSES_ROOT\txtfile\shell\open]
[HKEY_CLASSES_ROOT\txtfile\shell\open\command]
@="%SystemRoot%\system32\NOTEPAD.EXE %1"
[HKEY_CLASSES_ROOT\txtfile\shell\print]
[HKEY_CLASSES_ROOT\txtfile\shell\print\command]
@="%SystemRoot%\system32\NOTEPAD.EXE /p %1"
[HKEY_CLASSES_ROOT\txtfile\shell\printto]
[HKEY_CLASSES_ROOT\txtfile\shell\printto\command]
@="%SystemRoot%\system32\notepad.exe /pt "%1" "%2" "%3" "%4""
==========================================================
[Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.txt]
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.txt\OpenWithList]
"a"="EmEditor.exe"
"MRUList"="ab"
"b"="NOTEPAD.EXE"
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.txt\OpenWithProgids]
"txtfile"=hex(0):
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.txt\UserChoice]
"ProgId"="txtfile"
"Hash"="ELWmGYeUhOo="
=============================
Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.txt\UserChoice="txtfile"
=============================
FileExts\OpenWithList(0)="a"=EmEditor.exe
not found: [HKEY_CLASSES_ROOT\Applications\EmEditor.exe]
=============================
FileExts\OpenWithList(2)="b"=NOTEPAD.EXE
[HKEY_CLASSES_ROOT\Applications\NOTEPAD.EXE]
[HKEY_CLASSES_ROOT\Applications\NOTEPAD.EXE\shell]
[HKEY_CLASSES_ROOT\Applications\NOTEPAD.EXE\shell\edit]
[HKEY_CLASSES_ROOT\Applications\NOTEPAD.EXE\shell\edit\command]
@="%SystemRoot%\system32\NOTEPAD.EXE %1"
[HKEY_CLASSES_ROOT\Applications\NOTEPAD.EXE\shell\open]
[HKEY_CLASSES_ROOT\Applications\NOTEPAD.EXE\shell\open\command]
@="%SystemRoot%\system32\NOTEPAD.EXE %1"
=============================
FileExts\OpenWithProgIDs(0)="txtfile"
[HKEY_CLASSES_ROOT\txtfile]
@="Text Document"
"EditFlags"=dword:00210000
[HKEY_CLASSES_ROOT\txtfile\DefaultIcon]
@="%SystemRoot%\system32\imageres.dll,-102"
[HKEY_CLASSES_ROOT\txtfile\shell]
[HKEY_CLASSES_ROOT\txtfile\shell\open]
[HKEY_CLASSES_ROOT\txtfile\shell\open\command]
@="%SystemRoot%\system32\NOTEPAD.EXE %1"
[HKEY_CLASSES_ROOT\txtfile\shell\print]
[HKEY_CLASSES_ROOT\txtfile\shell\print\command]
@="%SystemRoot%\system32\NOTEPAD.EXE /p %1"
[HKEY_CLASSES_ROOT\txtfile\shell\printto]
[HKEY_CLASSES_ROOT\txtfile\shell\printto\command]
@="%SystemRoot%\system32\notepad.exe /pt "%1" "%2" "%3" "%4""
Registryinfo output for DLL:

Code: Select all

[HKEY_CLASSES_ROOT\.dll]
@="dllfile"
"Content Type"="application/x-msdownload"
[HKEY_CLASSES_ROOT\.dll\PersistentHandler]
@="{098f2470-bae0-11cd-b579-08002b30bfeb}"
=============================
[HKEY_CLASSES_ROOT\dllfile]
@="Application Extension"
"AlwaysShowExt"=""
EditFlags=type(3)
"FriendlyTypeName"="@shell32.dll,-10146"
"NoOpen"=""
[HKEY_CLASSES_ROOT\dllfile\DefaultIcon]
@="C:\Windows\system32\imageres.dll,-67"
==========================================================
[Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.dll]
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.dll\OpenWithList]
"a"="ResHacker.exe"
"MRUList"="a"
[HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts\.dll\OpenWithProgids]
"dllfile"=hex(0):
=============================
FileExts\OpenWithList(0)="a"=ResHacker.exe
not found: [HKEY_CLASSES_ROOT\Applications\ResHacker.exe]
=============================
FileExts\OpenWithProgIDs(0)="dllfile"
[HKEY_CLASSES_ROOT\dllfile]
@="Application Extension"
"AlwaysShowExt"=""
EditFlags=type(3)
"FriendlyTypeName"="@shell32.dll,-10146"
"NoOpen"=""
[HKEY_CLASSES_ROOT\dllfile\DefaultIcon]
@="C:\Windows\system32\imageres.dll,-67"
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 48088
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: Blurred file icons in panels under Windows 10 22H2

Post by *ghisler(Author) »

Could you check with the plugin iclview whether the file
%SystemRoot%\system32\imageres.dll
contains 16x16 icons, especially icon Nr. 102 (second number)? That would be 0097.

Edit: I have checked my code, TC calls ExtractIconExW, which gets a small icon with the system default size. Normally this is 16x16, but on higher DPI screens it can be something like 22x22, which results in blurry icons. I will try calling LoadImage instead.
Author of Total Commander
https://www.ghisler.com
User avatar
MVV
Power Member
Power Member
Posts: 8702
Joined: 2008-08-03, 12:51 UTC
Location: Russian Federation

Re: Blurred file icons in panels under Windows 10 22H2

Post by *MVV »

Well, imageres.dll file itself is a dummy DLL with size 2560 bytes, its imageres.dll.mui is also dummy, all resources are in C:\Windows\SystemResources\imageres.dll.mun file with size 20705792 bytes, Resource Hacker shows that its icon group 102 contains many icons: 16x16, 20x20, 24x24, 32x32, 48x48, 64x64 and 256x256, all in 24-bit colors:

Code: Select all

256 x 256 (16.8mil colors) - Ordinal name: 986
64 x 64 (16.8mil colors) - Ordinal name: 987
48 x 48 (16.8mil colors) - Ordinal name: 988
40 x 40 (16.8mil colors) - Ordinal name: 989
32 x 32 (16.8mil colors) - Ordinal name: 990
24 x 24 (16.8mil colors) - Ordinal name: 991
20 x 20 (16.8mil colors) - Ordinal name: 992
16 x 16 (16.8mil colors) - Ordinal name: 993
Post Reply