Museum

Home

Lab Overview

Retrotechnology Articles

Online Manuals

⇒ xwcreate(1) — HP-UX 9.10

Media Vault

Software Library

Restoration Projects

Artifacts Sought

Related Articles

X(1)

XOpenDisplay(3x)

xwdestroy(1)

XWCREATE(1)  —  X Version 11

Release 5

NAME

xwcreate − create a new X window

SYNOPSIS

xwcreate [options] name

DESCRIPTION

This command creates a new X window and assigns it the name name. 

This program will also create a device file of the same name as the window in the indicated directory.  After the window has been created, the device file may be used to specify the window that an application should use when utilizing a graphics library (e.g., Starbase or HP-GKS). 

A window created by xwcreate can be destroyed by xwdestroy(1). 

OPTIONS

-display display
Specifies the server to connect to; See X(1) for details.  A limitation in xwcreate requires that the display name must be no more than 115 characters long. 

-parent parent
Name of the window which is to be the parent of name.  If named, the parent window must have been created by a previous invocation of xwcreate and must not have been destroyed by xwdestroy(1); otherwise an error message will be generated.  If parent window is not named, the RootWindow of the display and screen will be used as the parent.  If specified, parent window’s name must be no more than 12 characters long. 

-geometry geometry
This option specifies the preferred size and position of the window; See X(1) for details. 

-r Requests the X server to create backing store for the window.  By default, windows are not created with backing store. 

-bg color
This option specifies the background color.  By default, background color of the window will be black.

-bw pixels
This option specifies the width in pixels of the window border.  By default, border of the window will be 3 pixels wide.

-bd color
This option specifies the border color.  By default, the window border will be white.

-depth depth
This option specifies the visual depth of the window.  By default, the window will have the same depth as its parent.  If the specified depth is not supported by the display, an error will be generated and the window will not be created.

-visual visualclass
This option specifies the visual class of the window when multiple visual classes are supported by the display at the specified depth. visualclass can be "PseudoColor", "StaticColor", "GrayScale", "StaticGray", "DirectColor" or "TrueColor" (case is not significant).  For most displays, which support only one visual class at each depth, this option need not be specified. 

-overlay
This option specifies that an overlay plane visual should be used.  This option is only in effect for servers that are in the combined mode with the root window property, SERVER_OVERLAY_VISUALS set. For such a server, specifying this option will cause only overlay visuals to be considered;  when this option is not specified, image plane based visuals will be favored.

-wmdir directory
is the name of the directory where the device file is to be created. See DEPENDENCIES, below, for details.

-title name
is the name to be used to reference the window.  The name must be no more than 12 characters long. 

X DEFAULTS

xwcreate uses the Xlib routine XGetDefault(3X) to read its Xdefaults, so its resource names are all capitalized. 

Background
Specifies the window’s background color.

BorderColor
Specifies the border color. This option is useful only on color displays.

BorderWidth
Specifies the border width.

Depth
Specifies the visual depth of the created window.

VisualClass
Specifies the visual class of the created window.

Retained
If ’on’, requests the X server to create backing store for the window.

Wmdir
Specifies the default directory where the device file will be created. See -wmdir above for details. 

Geometry
Specifies the default positioning and/or sizing for the created window. See X(1) for details. 

EXAMPLES

xwcreate FullView
Create a window named "FullView". Since no other argument is provided, the default geometry, border color, etc. of FullView will be taken from the RootWindow of the window’s display and screen.

xwcreate HalfView  -display remote_host:1.2 -parent FullView
-geometry 400x200+5+10 -r -bw 10
Create a window named "HalfView" on the display "remote_host:1.2". HalfView will be a child of the window "FullView". The upper left hand corner of HalfView  will be located at coordinate 5,10 of FullView  and will be 400 pixels wide and 200 pixels high. The border of HalfView will be 10 pixels wide and the border colors  will be the same as FullView.

DEPENDENCIES

HP-UX Systems
Windows are actually created, maintained, and destroyed by the gwind daemon; xwcreate does its job by requesting window creation from the daemon.  If gwind is not running, xwcreate will start it. 
 
The device file created by xwcreate/gwind is a pty, through which graphics applications (such as the Starbase library) communicate with gwind. 
 
The location of the device file is determined by the use of the -wmdir command line option and the WMDIR environment variable. 
 
If the -wmdir option is not used, then the directory name will be computed as follows:  first, the environment of the process will be searched for the variable $WMDIR.  If the variable $WMDIR is defined in the environment, then it will be used as the desired directory.  If the the variable $WMDIR is not defined in the environment, then the device file will be created in the /dev/screen directory. 
 
If the -wmdir option is used in the command line, the directory name will be obtained as follows:  If the directory argument implies an absolute pathname, then it will be taken to be the desired directory.  Otherwise, the directory name will be taken to be relative to the value of the environment variable $WMDIR.  If $WMDIR is not defined in the environment, the directory name will be taken to be relative to the /dev/screen directory.  Note:  if $WMDIR is defined in the environment, it must represent an absolute pathname.  If -wmdir is defined in the command line, then the implied directory must have already been created.  Otherwise, an error ("Invalid directory") will be generated. 
 
If -wmdir is used or WMDIR environment variable is set to other than the default, the directory used must exist on the same physical device as "/dev". 
 
If XKillClient is used (used by some window managers) on one of the windows created by xwcreate, all windows created by xwcreate (started with the same “-display” argument) are also be destroyed. 

ENVIRONMENT

   DISPLAY - the default host and display number. 
   WMDIR - the window manager directory.
   /dev/screen - the default window manager directory on HP-UX systems.

DIAGNOSTICS

If the window is created successfully, xwcreate will remain silent.  Otherwise xwcreate prints one or more error messages to standard output.  For example:

No such display.
Named window exists.
Named parent window does not exist.
Couldn’t communicate with gwind.

NOTES

The WM_CLASS of an xwcreate’ed window is Xwcreate. 

ORIGIN

HP

SEE ALSO

X(1), XOpenDisplay(3x), xwdestroy(1). 

  —  HP-UX 9.0 August 1992

Typewritten Software • bear@typewritten.org • Edmonds, WA 98026