go-astilectron icon indicating copy to clipboard operation
go-astilectron copied to clipboard

MenuItemOptions Icon not sizing properly

Open packet-sent opened this issue 3 years ago • 2 comments

Hi, I got the following issue with the sizing of the MenuItemOptions Icon: image image

I have tried with different sized icons and different formats (png/ico) and couldn't figure out how to fix it, also tried looking at the documentation (https://pkg.go.dev/github.com/asticode/[email protected]#MenuItemOptions) but couldn't see anything pointing me in the right direction, if anybody could help I would appreciate it.

packet-sent avatar Dec 26 '21 02:12 packet-sent

Have you tried using a .png or event better a .svg instead of a .ico ?

asticode avatar Dec 26 '21 09:12 asticode

So with different sizes of .ico files, it didn't respect the sizes it had (tried many from 8x8 to 128x128) and for the .svg file it gave me the following error (building gave 0 errors) and the menu wasn't present in the tray. image

However with .png it worked fine with a smaller resolution of 16x16. image

I think something could be done about this as for the tray icon I just used a .ico file and it worked perfectly to size, as I am pretty sure nobody is intentionally going for something that large in the MenuItem, or maybe we can customize the size.

packet-sent avatar Dec 26 '21 20:12 packet-sent