buttonimage is ok in vis. designer but when i run it messed

Windows specific forum
sartic
Enthusiast
Enthusiast
Posts: 143
Joined: Thu Aug 26, 2010 8:26 am

buttonimage is ok in vis. designer but when i run it messed

Post by sartic »

I thought i made mistake when i copy same object but i checked all id and they are ok.
What can it be? All images are PNG 8bit. Using PB 4.50

Now i am designing GUI for my 1st serious project after my control test app (irc server/client) and it is not working at 1st step ;)
Registered user of PB (on Linux Mint 21.1 & Win 10 64bit)
User avatar
ts-soft
Always Here
Always Here
Posts: 5756
Joined: Thu Jun 24, 2004 2:44 pm
Location: Berlin - Germany

Re: buttonimage is ok in vis. designer but when i run it mes

Post by ts-soft »

How could we help you. No source, no zodiac signs :wink:
sartic
Enthusiast
Enthusiast
Posts: 143
Joined: Thu Aug 26, 2010 8:26 am

Re: buttonimage is ok in vis. designer but when i run it mes

Post by sartic »

it works always when u disable "include binary bitmaps"
Registered user of PB (on Linux Mint 21.1 & Win 10 64bit)
LuCiFeR[SD]
666
666
Posts: 1033
Joined: Mon Sep 01, 2003 2:33 pm

Re: buttonimage is ok in vis. designer but when i run it mes

Post by LuCiFeR[SD] »

sartic wrote:it works always when u disable "include binary bitmaps"
Without the code which shows the problem we cannot help you, as we are not mind readers :P
sartic
Enthusiast
Enthusiast
Posts: 143
Joined: Thu Aug 26, 2010 8:26 am

Re: buttonimage is ok in vis. designer but when i run it mes

Post by sartic »

I did it and erased it. Problem _is_ in code which designer generates wrong. I don't know when and why. I am using designer using widthout "include".
Registered user of PB (on Linux Mint 21.1 & Win 10 64bit)
IdeasVacuum
Always Here
Always Here
Posts: 6426
Joined: Fri Oct 23, 2009 2:33 am
Location: Wales, UK
Contact:

Re: buttonimage is ok in vis. designer but when i run it mes

Post by IdeasVacuum »

...Never had a problem like that caused by Visual Designer, very likely that you have something odd in the code - PNG 8bit is unusual, that might have something to do with it. Is there any specific reason why 8bit is used?
IdeasVacuum
If it sounds simple, you have not grasped the complexity.
sartic
Enthusiast
Enthusiast
Posts: 143
Joined: Thu Aug 26, 2010 8:26 am

Re: buttonimage is ok in vis. designer but when i run it mes

Post by sartic »

IdeasVacuum wrote:...Never had a problem like that caused by Visual Designer, very likely that you have something odd in the code - PNG 8bit is unusual, that might have something to do with it. Is there any specific reason why 8bit is used?
at least 3x smaller size and for icons 256 color is enough :)
Registered user of PB (on Linux Mint 21.1 & Win 10 64bit)
PureLust
Enthusiast
Enthusiast
Posts: 478
Joined: Mon Apr 16, 2007 3:57 am
Location: Germany, NRW

Re: buttonimage is ok in vis. designer but when i run it mes

Post by PureLust »

Are you sure, you have "UsePNGDecoder()" in your Code?
[Dynamic-Dialogs] - create complex GUIs the easy way
[DeFlicker] - easily deflicker your resizeable Windows
[WinFX] - Window Effects (incl. 'click-through' Window)
IdeasVacuum
Always Here
Always Here
Posts: 6426
Joined: Fri Oct 23, 2009 2:33 am
Location: Wales, UK
Contact:

Re: buttonimage is ok in vis. designer but when i run it mes

Post by IdeasVacuum »

at least 3x smaller size and for icons 256 color is enough
Well, unless your app is running on a mobile platform or you have thousands of images buttons, the file size saving means very little. However, if you are confident that your code is correct then I would check the validity of the image files with Irfan View (simply open them and re-save them).

http://www.irfanview.net/
IdeasVacuum
If it sounds simple, you have not grasped the complexity.
Post Reply