PDA

Click to See Complete Forum and Search --> : Bitmap - buttons won't fill entirely with BMP, border rests


PeerBr
May 31st, 2001, 06:46 PM
Hey,

If I want to make a button with my own graphics, I set style to "graphically" and give it a custom bmp. The button is 855x15 Twips, that's with me 57x21 Pixel. OK, I create a BMP that is exactly that size in pixels. Now, I set btn.caption to "" and throw in the Bitmap. All is fine except for that the BMP doesn't take up the whole space, the button still has a grey border and the BMP is slightly offset.

I can work around this using a picture box, but then I don't have options like DownPicture etc. or I'd have to do this manually :(

So is there a solution?

Thanks!!

KingDavid
May 31st, 2001, 11:52 PM
Try making your Image larger.

PsychoMark
Jun 1st, 2001, 02:06 AM
Never tried to do it that way, but you could look for something like a BorderStyle property. Or just make your own using a picturebox like you suggested, just use the MouseDown and MouseUp events to draw the picture...

PeerBr
Jun 1st, 2001, 04:48 AM
That BorderWidth-thing would be it, but there is no such property for anything else than lines.

If I simply enlarge the button, maybe the whole image would fit in, but with that ugly grey border which really makes colored images look like crap!!:mad:

Hmm if nothing else helps than I guess I'll have to stick to the image-field version :(