[lazarus] Form repaintis when painting speedbuton glyph

Shane Miller SMiller1 at stvgb.org
Wed May 3 09:53:44 EDT 2000


It could be that after I did the paint I called repaint or invalidate or something.  Maybe that causes it.

Are you going to look further into it?  If not, I guess I can look at it to see if that's the case. Problem is I do my development under LINUX, not windows.
Shane

>>> vrs at dds.nl 05/02/00 04:53PM >>>
Hi,

I have been looking at the problem with the speedbuttons in win32. I haven't
found a solution but I know more or less what is hapening, not the reason
why.

The problem is in painting the glyph on the button face. This paint action
(a copyrect on a canvas) causes gtk to emit (is that the right word) an
expose-event on the form and the form get repainted, which includes
repainting the speedbutton etc, etc.

Commenting out
    TButtonGlyph(FGlyph).Draw(Canvas, PaintRect, Offset, Caption, FLayout,
FMargin,  FSpacing, FState, Transparent, (0));
in the Procedure TSpeedbutton.Paint stops the repainting.

The reason why I can't solve this problem is a huge lack of knowledge on
graphics (DC etc) and gtk's interface to the graphics.
You might take a look at the stretchBlt function in gtkwinapi.inc. The
problem might be solved there.

I hope this helps somebody.

Regards,
Vincent Snijders.

_________________________________________________________________
     To unsubscribe: mail lazarus-request at miraclec.com with
                "unsubscribe" as the Subject
    archives at http://www.miraclec.com/list_archives/lazarus






More information about the Lazarus mailing list