Page 1 of 2

[solved] custom icon in menubar became pale

Posted: 04 Apr 2024 22:59
by lian00
Hello, since the last beta versions of XYplorer, (25.80.0202 and previous) my custom icons in menubar have their color "faded". See capture.
2024-04-04_22h51_15.png

Re: custom icon in menubar became pale

Posted: 04 Apr 2024 23:32
by admin
1) Fascinating.

2) Your whole shot looks somewhat pale. Why?

3) Post the returns of screen;

4) Post that icon in a ZIP.

Re: custom icon in menubar became pale

Posted: 05 Apr 2024 14:03
by lian00
admin wrote: 04 Apr 2024 23:32 1) Fascinating.
:biggrin:
2) Your whole shot looks somewhat pale. Why?
Same question.
3) Post the returns of screen;
Virtual Screen: (0, 0) - (5760x1440)

Screen.Width (screenW) = 2560 (2560)
Screen.Height (screenH) = 1440 (1440)
Current Monitor: 1 (Primary)
Current Work Area: (0, 0) - (2560, 1409)

Number of Monitors: 2
Monitor 1 Area: (0, 0) - (2560, 1440) = 2560x1440
Monitor 1 Area Work: (0, 0) - (2560, 1409)
Monitor 1 DPI: 96 (100%)
Monitor 2 Area: (3840, 0) - (5760, 1080) = 1920x1080
Monitor 2 Area Work: (3840, 0) - (5760, 1080)
Monitor 2 DPI: 96 (100%)

Startup Work Area: (0, 0) - (2560, 1409), Startup Values: (398, 144) - (1720x1070), Winstate=0
XY Main Window: (398, 144) - (2118, 1214) = 1720x1070, Scale: 1704x1011, Winstate=0
GetCursorPos = 678, 322

Monitor: 1/2 (Primary)
Screen: 2560x1440 Virtual: (0, 0) - (5760, 1440) Work: (0, 0) - (2560, 1409)
Screen DPI: 96 (100%) twX: 15 (15) Stretch: 1,00 sLF: 1,00 Toolbar Zoom: 0,75 (2;2)
Screen Color Depth: 32 Line Spacing: 2 (2,00)
DPI Awareness: Unaware Auto Scaling: Yes, Yes

UseDPIAwareIconSizes: No
Icon Size: Small=16, Large=32, Extra Large=48, Jumbo=256
Icon Size Controls: Small=16, Large=32, Extra Large=48, Jumbo=256
Icon Size Recommended: Small=16, Large=32, Extra Large=48, Jumbo=256
4) Post that icon in a ZIP.
Tama Icons PC.zip

Re: custom icon in menubar became pale

Posted: 05 Apr 2024 14:21
by admin
Thanks! These are weird icons. Look at this:
2024-04-05_141946.png
Try to find others. :)

Re: custom icon in menubar became pale

Posted: 05 Apr 2024 14:34
by lian00
Ooooh, I liked them so much. So it depends of the size and bit number. Too bad, they worked great before I tried to change the size.

Re: custom icon in menubar became pale

Posted: 05 Apr 2024 14:39
by admin
GDI chooses which icon to use from the resource. ATM I don't see how I can influence this :| This problem came up recently when I started using GDI for these icons. The drawing quality is much better, but now we see: there is a drawback.

Re: custom icon in menubar became pale

Posted: 05 Apr 2024 14:44
by admin
I'll add a tweak just for your funny icons :)

Code: Select all

ToolbarCTBNoGDI=1

Re: custom icon in menubar became pale

Posted: 05 Apr 2024 15:07
by lian00
admin wrote: 05 Apr 2024 14:44 I'll add a tweak just for your funny icons :)

Code: Select all

ToolbarCTBNoGDI=1
Cool. So it will implemented in next beta ? Do I need to change the config file manually ?

Re: custom icon in menubar became pale

Posted: 05 Apr 2024 15:08
by admin

Re: custom icon in menubar became pale

Posted: 05 Apr 2024 15:13
by lian00
admin wrote: 05 Apr 2024 15:08 Yes and yes.

See https://www.xyplorer.com/faq-topic.php?id=tweak
Thanks a lot for your reactivity. I will try the setting - I already changed the icons as it was so ugly to look at :mrgreen:

Re: custom icon in menubar became pale

Posted: 05 Apr 2024 16:30
by lian00
It works…but regular .ico files looks better with default option, so I will move to icons working in default mode. Thanks a lot for the work.

Re: [solved] custom icon in menubar became pale

Posted: 05 Apr 2024 17:37
by klownboy
What is/was the real issue here as to why he had the faded icons? Was it because XY scaled down from the faded 32x32 8-bit or faded 48x48 8-bit and not the 32x32 or 48x48 32-bit?

So as a lesson, if you are using large icons on the toolbar with no scaling, which I always assumed were 24x24, should we always at least attempt to use icon set that have 24x24 size in 32-bit? And with that large icon toolbar size, are we better off if 24x24 is not available scaling down from the 48x48 versus 32x32?

Re: [solved] custom icon in menubar became pale

Posted: 05 Apr 2024 17:44
by admin
Don't worry. All this only affects custom toolbar buttons, and only those that use an ICO file for the custom icon. If that ICO file does not contain an icon that fits the current button size, then stretching is required. This is now done with GDI, which does a better job than the previous way. However, GDI chooses which icon to use from the file, and for some reason in this case it chooses the wrong one, the 8-bit one. I would call this a bug. But it is not my bug, and I cannot fix it.

Re: [solved] custom icon in menubar became pale

Posted: 05 Apr 2024 18:21
by klownboy
admin wrote: 05 Apr 2024 17:44 All this only affects custom toolbar buttons, and only those that use an ICO file for the custom icon.
Yeah, and most of my CTBs use ICOs, but I do try to use icons that have a 24x24, 32-bit size. In general, are users better of using PNGs if available rather than ICOs and do PNGs have a little longer load time on startup due to size and quality?

Re: [solved] custom icon in menubar became pale

Posted: 05 Apr 2024 18:36
by admin
You tell me. :)