resizing subwindow

I have an existing subwindow that is to be replaced by a different one.
Should I destroy the original and then create a new one, or merely change the size of the existing one?
How do I change the size of a subwindow? glViewport(…) does not seem to affect the existing window.

What windowing system do you use?
The function glViewport(…) is used for the transformation of normalized device coordinates to window coordinates (see MSGN for further info).

The window was created with
subWindow = glutCreateSubWindow(mainWindow, margin, margin, width, height);
glViewport(0, 0, (GLsizei) width, (GLsizei) height);

Basically, I want to change width & height.

[QUOTE=Lighttec;1259441]What windowing system do you use?
The function glViewport(…) is used for the transformation of normalized device coordinates to window coordinates (see MSGN for further info).[/QUOTE]

This is a GLUT question not an OpenGL question.

After you have created a subwindow you can use glutSetWindow and glutPositionWindow and glutReshapeWindow on the subwindow to adjust what you need.