>
>I've got some code that will hide/show one control (a list) and
>dynamically resize another control (a form) based on user input.
>
>The problem I have is that when I resize the form, I need to
>reposition the insertion point, both to keep Gremlins from whining at
>me and so that the user sees the same text, but in order to do this I
>put the insertion point at the beginning and once the control is
>resized, back where it needs to be.
>
>Unfortunately this causes some really horrible scrolling of the field
>as I go through these gyrations.
>
>I tried hiding and un-hiding the field but it won't actually go away
>until after my routine has exited.
>
>Am I overdoing things?  I modified my code so that gremlins wouldn't
>complain when I resized the field and caused an "invalid insertion
>point".  I'd like to make it so my program will make it through a
>gremlins run completely clean.  Is that an unreasonable goal?
>
 It turns out that one way to reduce the flicker was for me to use
FldSetInsertionPoint when I set it to the beginning of the field
rather than FldSetInsPtPosition.  The latter call causes the insertion
point to be scrolled into view and the former call does not.

Since I then call FldSetInsPtPosition once done resizing, the
insertion point is scrolled into view with a minimum of flicker.

I'd still like to know what I could do to remove all the flicker (IE,
do all my resizing with drawing turned off and then cause the entire
form to be drawn when I'm done).


  Michael S. Harrison
  michaelh.dragonseye@com
  (reverse the dot and at to send email)

* The opinions expressed here are those of my iguana
* and I never know what he's going to say next.

-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palmos.com/dev/support/forums/

Reply via email to