addSubView: [NSView subviews] doesn't show any subviews, after adding subviews.
addSubView: [NSView subviews] doesn't show any subviews, after adding subviews.
- Subject: addSubView: [NSView subviews] doesn't show any subviews, after adding subviews.
- From: "Frederick C. Lee" <email@hidden>
- Date: Fri, 18 Nov 2005 15:14:15 -0800
Greetings:
I just wanted to add subviews to a container view: eventually having
n-rows and n-columns of subviews within a container view. I want to
manage those views via the container view's subviews array. But as
you can see, the container array doesn't get populated by new subviews.
What am I missing?
Regards,
Ric.
Before Adding Subview:
(gdb) po [gvContainerView subviews]
<NSCFArray 0x394890>(
<NSView: 0x394ba0>
)
After Adding Subview:
(gdb) po [gvContainerView subviews]
<NSCFArray 0x394890>(
<NSView: 0x394ba0>
)
- (IBAction)addSubView:(id)sender {
NSLog(@"{GVDocument.m: addSubView}");
[gvContainerView addSubview:ricImageView];
NSRect myRect;
myRect.origin.x = 10; myRect.origin.y = 10;
myRect.size.width = 60; myRect.size.height = 60;
[ricImageView setFrame:myRect];
[gvContainerView setNeedsDisplay:YES];
return;
}
_______________________________________________
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