Re: onPaint Ficker
Posted: 04/28/2003 12:48:57
Yes, this method is not double buffered. There are some reasons for it (the
same reasons prevent implementation of Prepaint=True mode).
Will be fixed in one of next updates, but not very soon.
> I am using the following code to draw a dark square after the MaxTextWidth
> area to show that the area is not editable. It works great except the
> square flickers a some while the user scrolls and flickers alot while the
> user selects text. It seems the onPaint method is not double buffered.
> can the flicker be avoided?
> Stephen Davenport
> procedure Tform1.rvePaint(Sender: TCustomRichView;
> Canvas: TCanvas; Prepaint: Boolean);
> var r: TRect;
> Canvas.Pen.Style := psSolid;
> Canvas.Pen.Color := cl3DDKShadow;
> Canvas.Brush.Style := bsSolid;
> Canvas.Brush.Color := clBtnShadow;
> r := Rect(Sender.MaxTextWidth+Sender.RightMargin, 0, Sender.Width,
> // drawing
Powered by ABC Amber Outlook Express Converter