For a long time, I’d run to the same problem with projects that included a window containing a full-window NSOpenGLView and a toolbar. In the Interface Builder, the NSToolbar controls open behind the OpenGL view and are unusable.
There is a simple, although kludgy, way around this:
Set the NSOpenGLView hidden in the View settings of the control. Then, add a line to your window controller’s awakeFromNib method:
[[self glview] setHidden:NO]; // glview is the NSOpenGLView control
Result: You can still control the view inside the window normally in Interface Builder, but NSToolbar opens on top, the OpenGLView still opens up normally, and everybody is happy.
- Click to share on Twitter (Opens in new window)
- Share on Facebook (Opens in new window) Click to share on Google+ (Opens in new window)
Leave a Reply Cancel reply