If that's what you're doing, then don't you have all the information you need? You've got the pointer to the bitmap! That's got the width and height in it. -- Keith James Tu <[EMAIL PROTECTED]> on 11/05/2000 07:00:05 PM Please respond to "Palm Developer Forum" <[EMAIL PROTECTED]> Sent by: James Tu <[EMAIL PROTECTED]> To: "Palm Developer Forum" <[EMAIL PROTECTED]> cc: (Keith Rollin/US/PALM) Subject: Re: Easier way of finding width and height of an attribute Keith: I'm basically a newbie trying to make a program that allows you to drag a big (larger than 160x160) bitmap around. Initially I used a form bitmap and tried to move it and it didn't work. (I got a handle to the form obj and tried to set the obj to a new location.) So I decided to go the "draw the bitmap" way. It's working and now I'm fine tuning the interactiong. I'm just using : resH = DmGetResource (bitmapRsc, myBitmap); bitmap = MemHandleLock (resH); WinDrawBitmap(bitmap, current_x, current_y); MemHandleUnlock (resH); to draw the bitmap. I want to use the width and the height of the bitmap to calculate my current_x and _y. [EMAIL PROTECTED] wrote: > > Can you tell us more about how you're handling this bitmap? I mean, if it's part > of the current form (that is, you have a bitmap object in the form), you can > just call FrmGetObjectBounds to get the bounds. > > -- Keith > > I'm trying to develop my first few palm apps and I have a question for > the almight list... > > Is there an easier way to find out information about resources? > From what I've been reading, it seems that one would have to open up > the application's resource database, the the resource ID of the > bitmap, and then accessing it's attributes. > > I'm basically dragging a bitmap around the screen and want to contrain > it to the boundaries of the screen. I need to find out the width and > height of my bitmap. > > Any sample code would be great! > > Thanks! -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/tech/support/forums/ -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/tech/support/forums/
