I have a very simple UIViewController subclass. I've set an image view as its view. It takes the entire window.When I create a label and add it like this
UILabel *titleLabel=[self labelWithText:@"Some text"];
[self.imageView addSubview: titleLabel];
the label does not appear. But if I add it like this
[self.view addSubview: titleLabel];
it works, I see the label added to the view. A UIImageView is a subclass of UIView and it responds to the selector addSubview:. Then why does not this work?