Drag and drop the “doesnt_work.png” into the red rectangle --> it is not displayed.
Drag and drop the “works.png” into the red rectangle --> it is displayed.
[quote=404464:@Stefan Adelsberger]I also tried it with the latest alpha without success.
Maybe related to my screen configuration (1 x HiDPI and 1 x normal resolution)?[/quote]
This seems to be the issue.
If I turn off “Supports HiDPI” then it works.
Any ideas if this is a bug or am I missing something?
[quote=404465:@Stefan Adelsberger]This seems to be the issue.
If I turn off “Supports HiDPI” then it works.
Any ideas if this is a bug or am I missing something?[/quote]
The one you provided works.
I’m using Windows 10 with Xojo 2018r2 (and r3a24).
So this is regarding to the dpi?
Shouldn’t the picture always be drawn no matter which dpi?
[quote=405165:@Stefan Adelsberger]The one you provided works.
I’m using Windows 10 with Xojo 2018r2 (and r3a24).
So this is regarding to the dpi?
Shouldn’t the picture always be drawn no matter which dpi?[/quote]
Some how the PPX and PPY of the image that doesn’t work has been saved as 113 which make the DPI 2.87 where as the working image has PPX and PPY of 2834 which is 72DPI.
If you break the code after reading the image you can see it loads fine as its in the Contents of mIcon, however the mIcon.VerticalResolution and mIcon.HorizontalResolution vars are shown as 3 (rounded up from 2.87).
The image is there, but its really really big and you are only seeing the top left few pixels of the image. If you set the above two lines to something like 30 you can see it getting bigger, at 6 it will only just be shown, when you get to 3 it “vanishes” as its drawing off the size of the controls.
Setting the PPX and PPY in the image should fix this problem, try a different paint package?