Ok, I've had time to try this and it works :).

Thank you very much Filipe

Felipe Monteiro de Carvalho wrote:
On 8/9/06, Andreas Berger <[EMAIL PROTECTED]> wrote:
Can someone tell me how to load transparent glyphs for a TSpeedButton at
run time?

You are forgetting that bitmaps contain no information about
transparency at all. You must provide the transparency information
yourself. In this case it will be a color. All pixels with that color
will be transparent.

Try:

    bmp := TBitmap.Create;
    bmp.LoadFromFile('x.bmp');
    bmp.Transparent := True;
    bmp.TransparentColor := clFuchsia; // Insert color here
    glyph.Assign(bmp);


_________________________________________________________________
    To unsubscribe: mail [EMAIL PROTECTED] with
               "unsubscribe" as the Subject
  archives at http://www.lazarus.freepascal.org/mailarchives

Reply via email to