Ok almost solved by me ... will still grant 500 points to the one solving problem with TBitBtn and TSpeedButton.
See picture below ...
Solution for:
1. TimageList runtime add PNG with alpha:
---
ImageList.ColorDepth:=cd32
...
aPNG:=TPNGImage.Create;
try
aPNG.loadfromfile('test.pn
aBMP:=TBitmap.Create;
try
aBMP.Assign(aPNG);
ImageList.Add(aBMP, nil);
finally
aBMP.Free;
end;
finally
aPNG.Free;
end;
---
Works with TMainMenu ---
the same stuf does not work with
tbitbutton and tspeedbutton
i tried:
SpeedButton1.Glyph:=TBitma
SpeedButton1.Glyph.PixelFo
and assign aPNG like above but result is in folowing picture ...
Please solve this ...
Main Topics
Browse All Topics





by: DKropf3Posted on 2009-05-03 at 05:41:44ID: 24289727
Ok, one step forward i made ... (still can't add png at runtime) but if i add png at design time and set TImageList's ColorDepth to cd32Bit it works with mainmenu ... but not with speedbutton.
Example .PNG ok on mainmenu ... speedbuton not.