Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

In this Discussion

LMD 2024 TLMDSpeedButton certain images are not displayed

If I assign certain images to the glyph via Objebtinspector or from an LMDBitmapList, the image remains empty.
It works with the old 2019 version.

bmp
bmp
FB3.bmp
1K

Comments

  • 1 Comment sorted by Votes Date Added
  • I have now found a solution myself:

    procedure TLMDGlyph.UpdateMaster;
    var
      done: Boolean;
      BMP: TBitmap;// BS 17.07.2025
    begin
      done := False;
      if Assigned(FOnGetBitmap) then
      begin
        FMaster.Assign(nil); // Clear for sure.
        FOnGetBitmap(Self, FMaster, done);
      end;
      if not done then
      begin
        if FGlyph.PixelFormat = pf32bit then // BS 17.07.2025
        begin
          BMP := TBitmap.Create(FGlyph.Width, FGlyph.Height);
          try
            Bmp.Canvas.Draw(0,0, FGlyph);
            FMaster.Assign(Bmp);
          finally
            Bmp.Free;
          end;
        end
        else
          FMaster.Assign(FGlyph);
        FMaster.AlphaFormat := afDefined;
      end;
    end;
Sign In or Register to comment.