Re: Problem moving subview within superview
Re: Problem moving subview within superview
- Subject: Re: Problem moving subview within superview
- From: Scott Anguish <email@hidden>
- Date: Sun, 12 Feb 2006 00:16:43 -0500
sigh, well that's embarassing.
I did think we were discussing Views though (rather than that
specific subclass)
On Feb 11, 2006, at 8:19 PM, Camillo Lugaresi wrote:
On 12/feb/06, at 00:12, Scott Anguish wrote:
On Feb 10, 2006, at 1:50 PM, Camillo Lugaresi wrote:
Also, is that the right way to do what I was trying to? I
couldn't think of anything more elegant but I'd love to hear if
there is a better approach.
NSRect oldFrame = [button frame];
[button setFrame:NSMakeRect(0,0,35,35)];
[[button superview] setNeedsDisplayInRect:oldFrame];
[button setNeedsDisplay];
camillo shoes the correct way (although with a small syntax
error.. setNeedsDisplay requires a boolean value)
Actually, NSControl has an argumentless setNeedsDisplay method.
<http://developer.apple.com/documentation/Cocoa/Reference/
ApplicationKit/ObjC_classic/Classes/NSControl.html#//apple_ref/occ/
instm/NSControl/setNeedsDisplay>
Camillo
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Cocoa-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden