View Issue Details

IDProjectCategoryView StatusLast Update
0036383LazarusLCLpublic2020-03-31 13:56
Reporterjamie philbrook Assigned To 
Status newResolutionopen 
Product Version2.0.6 
Summary0036383: 32 bit bitmaps will not draw transparently due to incomplete code.
DescriptionI guess there was some work put in for Alpha blend 32 bit images using the alpha channel however, its not complete and thus is not useable. However, an option flag was included to use it thus disabling the abilities to use 32 bit images for transparencies.

In file CustomBitmap.Inc

Procedure TCustomBitmap.RawImageNeeded(…

Line 0000225 in 2.0.6 Laz release.

pf32bit: flags := [riqRGB, riqfMask, riqAlpha];

comment out riqAlpha and recompile...

It now works but I think a property should be inplace to select this in the future if they ever do get the Alpha blend functional.

At least for now we can use it.

Steps To Reproduceprocedure TForm1.Button1Click(Sender: TObject);
  B := TBitMap.Create;
  B.PixelFormat := pf32bit;
  B.Transparent := True;
  B.TransparentMode := tmFixed;
  B.TransparentColor:= clblack;
  B.Canvas.Brush.Color := clblack;
  B.Canvas.Brush.Style := bsClear;
  B.Canvas.Font.Color := clRed;

The above will fail to draw a transparent image until you do the fix.
Fixed in Revision
Attached Files


related to 0024241 new TBitBtn do not display bitmap correctly 


jamie philbrook

2019-11-30 04:03

reporter   ~0119555

I wanted to add that this fix actually creates a 24 bit bitmap so it's not really a fix but if anyone can see it in their heart to figure a way to make it stay 32 bit and work as a transparency I would be grateful.

Issue History

Date Modified Username Field Change
2019-11-30 03:43 jamie philbrook New Issue
2019-11-30 04:03 jamie philbrook Note Added: 0119555
2020-03-31 10:02 Juha Manninen Relationship added related to 0024241
2020-03-31 13:56 Juha Manninen Tag Attached: transparent