[Lazarus] RE : RE : gtk2 TCustomControl.Paint, InvalidateRect
zeljko
zeljko at holobit.net
Sat Jul 9 18:06:09 CEST 2011
On Saturday 09 of July 2011 16:25:58 Armin Diehl wrote:
> Hi Ludo,
>
> have tried setting the parent of the scrollbar to panal1 and this
> works fine.
>
> Many thanks for the solution.
>
> > The scrollbar invalidates indeed the whole region, even if it is located
> > outside the customcontrol (and thus invisible). If nobody else has
> > another idea I would suggest to create a bug report.
> >
> > In the mean time, a workaround is to parent the scrollbox to the parent
> > of TPaintTest. The constructor becomes then
OK, let's stop a bit here.
It invalidates some area (parent in this case), and part of that area isn't
exposed (visible) then gtk2 will not paint that part. if it's opposite then
it's an ugly gtk2 bug.
Let me see one more time what's exact problem:
Any visible scrollbar in TCustomControl sends update for whole parent (eg.
form) ? IMO, it's fixable under gtk2lcl by intercepting expose event in
scrollbar and reduce area which is marked as exposed, but then another
question raises , what if I move scrollbar by mouse (and I have already cutted
exposed area to the size of scrollbar) ? My TCustomControl will get an update
since it's viewport is moved ?
zeljko
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.lazarus-ide.org/pipermail/lazarus/attachments/20110709/0e2e7f8e/attachment-0003.html>
More information about the Lazarus
mailing list