NSButton image drawn 1 pixel too high
NSButton image drawn 1 pixel too high
- Subject: NSButton image drawn 1 pixel too high
- From: James Walker <email@hidden>
- Date: Wed, 04 Mar 2009 12:59:42 -0800
I guess I'm being picky, but it bugs me... I have a 23x23 square button,
displaying a 17x17 image, with NSImageOnly positioning. It should
center perfectly, with 2 pixels between the image and the border on each
side, but in fact there's 1 pixel above and 3 below. I can work around
it by subclassing NSButtonCell and reimplementing
drawInteriorWithFrame:inView:, but I wondered if there is a better way?
--
James W. Walker, Innoventive Software LLC
<http://www.frameforge3d.com/>
_______________________________________________
Cocoa-dev mailing list (email@hidden)
Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden