Add support for saving icons at higher resolutions #7
Labels
No labels
CLI
GUI
bug
duplicate
feature
in development
invalid
non-priority
optimisation
prioritised
wontfix
No project
No assignees
1 participant
Due date
No due date set.
Dependencies
No dependencies set.
Reference: Ruben/iconiic#7
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Right now icons are only saved as 32x32 bitmaps for any selected folder / icon. Larger icons can be fetched with the Windows API function already being used up to 256x256 so it should not be hard to add.
As mentioned on stackoverflow (https://stackoverflow.com/questions/28012229/what-is-the-maximum-size-of-an-icon-returned-from-shgetfileinfo), SHGetFileInfoW cannot directly retrieve "jumbo icons" (256x256). The system image index of said icon needs to be retrieved, the image from the system image list converted to an icon, then the bitmap can be built from the icon handle.
See the following links:
SHGetImageList can help get the jumbo image list as explained here (https://stackoverflow.com/questions/30495641/using-shgetimagelist-how-to-use-himagelist), then the index from SHGetFileInfoW can be used to build the jumbo icon from the specified index in the jumbo image list.
Fixed by commit
1a3d97044f
All icons now saved in 256x256 or max resolution.