--- Derek Kite <[EMAIL PROTECTED]> wrote:
> I have a form with a list, where I assign a draw
> function, iterating
> through the db to come up with a list. So far so
> good. Does the palm os
> handle the currently selected item, and highlight it
> by inversing, or
> does the draw function have to do that? Mine seems
> to not highlight the
> selection.
>
I think I figured out what is going on. In my listdrawfunc, I get a
datarecord, lock the handle, unpack it to a struct with pointers to the
various strings. Then as I draw, I do fntcharsinwidth, then
windrawchars in various ways to make it look good. Then I unlock the
handle,release the record.
If I use other strings, the list hilights properly. Is the
fntcharsinwidth, which truncates the string, the string which is in a
locked handle, messing something up?
I will try a strcopy on the strings I need, do the truncating with that
copy. A question though, do I need to release the memory of the strcopy
result? How?
Derek
_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com