[vtk-developers] vtkCocoaRenderWindow qq

clinton at elemtech.com clinton at elemtech.com
Wed Oct 1 14:22:38 EDT 2008


On Wednesday 01 October 2008 11:34:24 am Sean McBride wrote:
> On 10/1/08 11:29 AM, clinton at elemtech.com said:
> >To add Carbon to your table:
> >vtkWindow concept       Cocoa concept       Carbon concept
> >DisplayId               NSView                 -na-
> >WindowId                NSWindow            HIView
> >ParentId                unimplemented       HIView
> >RootWindow           -na-                        Window
>
> Thanks.
>
> >However, I assume the Cocoa support was there before HIViews were
> >supported by
> >vtkCarbonRenderWindow.
>
> Could be.
>
> >What I would have expected was something like
> >vtkWindow concept       Cocoa concept       Carbon concept
> >DisplayId               -na-                    -na-
> >WindowId                NSView            HIView
> >ParentId                 NSView            HIView
> >RootWindow           NSWindow             Window
>
> I'm not trying to be difficult :), but why would you expect this?  Is
> there some documentation I'm missing?  vtkWindow seems to give no
> guidance.  Do you know what these refer to on X11 and Win32?

I don't think you're missing any documentation, maybe what you're looking for 
just isn't there.

Here's my view of things.
Programmers on Win32 and X11 use a "Window" handle.  That Window can be a 
child or not.  You can draw content in that Window.  I consider that mapping 
to Cocoa's NSView.

On X11, a Window that is not a child is managed by the window manager.  The 
window manager addes the minimize button, maximize buttons, window border, 
window title, etc...  I consider that roughly mapping to Mac's NSWindow.

Also, when I consider the typical use cases on X11 and Win32, SetWindowId is 
called with a child Window.

Clint



More information about the vtk-developers mailing list