2

I'm trying to add my custom ContainerView to an usual ViewController using StoryBoard (iOS7). I only have a TableView Controller on this view. If I move the ContainerView inside the TableView it is displayed (but moved with the table items), but if I place it directly on view it is not displayed any more! Any ideas?

Arnie Schwarzvogel
  • 955
  • 1
  • 13
  • 25

1 Answers1

0

There appears to be a bug in Xcode/iOS where if the container view is the first child of self.view in storyboard, it doesn't show. For example when I have:

enter image description here

my container doesn't show.

But if I move the label above the container view in the outline:

enter image description here

Then my container view and the label will show.

UPDATE: Upon further investigation it appears the container view does still show if it is the first child, just much lower than you would expect it to appear. Placing another element above the container view allows the container to appear in the position you would expect (the position shown in storyboard).

Adam Johns
  • 35,397
  • 25
  • 123
  • 176