I am designing a custom widget, and it flickers when I scroll. Prima::Edit
and Prima::PodView don't do this, so I know it's me and not the toolkit.
I am hoping this is a problem that others have encountered before, and that
someone will have suggestions. If not, I can work up a small example script
and send it.
The data I am parsing is SGML, and I process it each time through
on_paint. The processing algorithm is quite speedy when tested alone, but
perhaps within the context of Prima, it is not fast enough. If this is the case,
I can try using TextView as my base (instead of Widget) class and
processing the SGML into TextView blocks when it is set.
The problem with that is that I generate hotspots to pass an event when the
user clicks on certain portions of the text, and I have to generate these
hotspots within on_paint. I suppose I could also format my text chunks as
arefs as follows:
[ text, size, color, font_style, sub_or_super, hotspot_boolean ]
Or something similar, which would be somewhat faster than processing the
SGML each time through. But I need to know whether the flicker really is
caused by a slow on_paint, or by something else (perhaps a bad
VScroll_Change algorithm, something to do with setting my offsets for
scrolling).
Any advice would be appreciated.
Received on Fri 06 Aug 2004 - 07:08:52 CEST
This archive was generated by hypermail 2.2.0 : Sat 19 Mar 2011 - 18:35:05 CET