At 7:27 PM +0100 9-03-00, Stephen Bentley wrote:
>Okay, perhaps I should be a little more specific.  I draw a bitmap image
>and assign it to a graphic button on a form.  In Constructor's form
>layout appearance window, it looks just like I drew it.  Once I load
>the app and run it on POSE, I get a series of messages saying my
>app has just read from memory manager data structures (even though
>I simply added the bitmap and made no other changes) and instead of
>my bitmap I see the "funky" character associated with decimal 128
>in the standard font.

Hmm.  Try it on a debug ROM?

Also, are you sure you're running on Palm OS 3.5?  If you try a graphic
button on an older release of the OS, you'll probably get this sort of
behavior.  Graphic buttons only work on 3.5 and later.

The graphic button type puts one or two resource IDs in the same space in
the control structure where the text pointer used to exist.  (That's why
they break this way on old OS releases.  The old OS attempts to follow the
'pointer' that's really a resource ID, and this is rarely readable memory!)

The new control code knows when a button is a graphic button (an attribute
bit is set), and correctly interprets the structure elements as resource
IDs in this case.  Of course, it then has to call DmGetResource to get the
real image... so you have to make sure there's a real bitmap with the
proper ID in your application.  (I think Constructor does a lot of this for
you.)  If there is no bitmap with the right ID, then I'm pretty sure the
ROM puts up an error message (the debug ROM should, at least.)

Sorry I can't be more helpful here.  The constructor that supports this
stuff didn't exist when I was working on our own apps, so I've never used
it!

                                        --Bob

________________________________________________________________________
Bob Ebert, Consulting Engineer, Palm Computing Europe V: +33 4 9952.4354
77 rue Samuel Morse, 34935 Montpellier Cedex 9 France F: +33 4 9952.4397



-- 
For information on using the Palm Developer Forums, or to unsubscribe, please see 
http://www.palm.com/devzone/mailinglists.html

Reply via email to