A window is opened and displayed by a call to one of the OpenWindow() functions: openwindow(), openwindowtaglist() or openwindowtags(). struct Window *OpenWindowTagList( struct NewWindow *newWindow, struct TagItem *tagList ); struct Window *OpenWindowTags( struct NewWindow *newWindow, unsigned long tag1Type, ... ); struct Window *OpenWindow( struct NewWindow *newWindow ); The type of window and its attributes are specified in newwindow or tagitem structures depending on which function is used. these functions all return a pointer to a new window structure if they succeed. a null return indicates failure. openwindowtaglist() and openwindowtags() are available only in release 2 (V36) and later versions of the OS. For these functions, window attributes are specified in tagitem structures which are paired data items specifying an attribute and its setting. (See the `utility library' chapter for more information on TagItems.) openwindow() is available in all versions of the os. window attributes can be specified using a newwindow structure but only a limited set of window attributes are available this way. To support both the new window features of Release 2 and compatibility with older versions of the OS, use OpenWindow() with an extended version of the newwindow structure named extnewwindow. see the wflg_nw_extended flag description in the "window Attributes" section below for more information on using OpenWindow() with the extended NewWindow structure. Further references to OpenWindow() in this chapter will apply to all three functions. These calls are the only proper method for allocating a window structure. The tag based versions are recommended for V36 and later versions of the OS. Use the extnewwindow structure with openwindow() to provide backward compatibility. openwindowtaglist() example setting window attributes