Network Working Group Robert W. Scheifler Request for Comments: 1013 June 1987X WINDOW SYSTEM PROTOCOL, VERSION 11 Alpha Update April 1987
M.I.T. [Page 1]
RFC 1013 June 1987
Author: Robert W. Scheifler
M.I.T. [Page 2]
RFC 1013 June 1987
This document does not attempt to define precise formats or bit encodings.
-------------------------------------------------------------------
M.I.T. [Page 3]
RFC 1013 June 1987
SECTION 1. TERMINOLOGY
M.I.T. [Page 4]
RFC 1013 June 1987
Client
M.I.T. [Page 5]
RFC 1013 June 1987
Cursor
M.I.T. [Page 6]
RFC 1013 June 1987
Event propagation
M.I.T. [Page 7]
RFC 1013 June 1987
Inferiors
M.I.T. [Page 8]
RFC 1013 June 1987
Occludes
M.I.T. [Page 9]
RFC 1013 June 1987
Pointing device
M.I.T. [Page 10]
RFC 1013 June 1987
Root window
M.I.T. [Page 11]
RFC 1013 June 1987
Tile
M.I.T. [Page 12]
RFC 1013 June 1987
ZFormat
M.I.T. [Page 13]
RFC 1013 June 1987
SECTION 3. SYNTAX
M.I.T. [Page 14]
RFC 1013 June 1987
LISTofFOO
M.I.T. [Page 15]
RFC 1013 June 1987
WINGRAVITY: {Unmap, Static,
M.I.T. [Page 16]
RFC 1013 June 1987
The length, format, and interpretation of a HOST address are specific to the family.
M.I.T. [Page 17]
RFC 1013 June 1987
Atom
M.I.T. [Page 18]
RFC 1013 June 1987
Pixmap
M.I.T. [Page 19]
RFC 1013 June 1987
BITMAP ICON_SIZE RGB_GREEN_MAP COMMAND ITALIC_ANGLE RGB_RED_MAP
COPYRIGHT MAX_SPACE SECONDARY
CUT_BUFFER0 MIN_SPACE SIZE_HINTS
CUT_BUFFER1 NAME STRIKEOUT_ASCENT
CUT_BUFFER2 NORMAL_HINTS STRIKEOUT_DESCENT
CUT_BUFFER3 NORM_SPACE STRING
CUT_BUFFER4 PIXMAP SUBSCRIPT_X
CUT_BUFFER5 POINT_SIZE SUBSCRIPT_Y
CUT_BUFFER6 PRIMARY SUPERSCRIPT_X
CUT_BUFFER7 QUAD_WIDTH SUPERSCRIPT_Y
DEFAULT_CHAR RECTANGLE UNDERLINE_POSITION
END_SPACE RESIZE_HINT UNDERLINE_THICKNESS
FACE_NAME RESOLUTION WEIGHT
FAMILY_NAME RGB_BEST_MAP WINDOW
FONT_ASCENT RGB_BLUE_MAP WM_HINTS
FONT_DESCENT RGB_COLOR_MAP X_HEIGHT
ICON RGB_DEFAULT_MAP ZOOM_HINTS ICON_NAME
M.I.T. [Page 20]
RFC 1013 June 1987
Received by the client at connection setup:
M.I.T. [Page 21]
RFC 1013 June 1987
bits-per-pixel: {4, 8, 16, 24, 32} scanline-pad: {8, 16, 32}]
M.I.T. [Page 22]
RFC 1013 June 1987
For each pixmap depth supported by some screen, pixmap-formats lists the ZFormat used to represent images of that depth. In ZFormat, the pixels are in scanline order, left to right within a scanline. The number of bits used to hold each pixel is given by bits-per-pixel, and may be larger than strictly required by the depth. When the bits-per-pixel is 4, the order of nibbles in the byte is the same as the image byte-order. Each scanline is padded to a multiple of bits as given by scanline-pad.
M.I.T. [Page 23]
RFC 1013 June 1987
Black-pixel and white-pixel can be used in implementing a "monochrome" application. These pixel values are for permanently allocated entries in the default-colormap; the actual RGB values may be settable on some screens.
M.I.T. [Page 24]
RFC 1013 June 1987
The red-mask, green-mask, and blue-mask are only defined for DirectColor and TrueColor; each has one contiguous set of bits, with no intersections.
M.I.T. [Page 25]
RFC 1013 June 1987
The window is placed on top in the stacking order with respect to siblings. The x and y coordinates are relative to the parent's origin, and specify the position of the upper left outer corner of the window (not the origin). The width and height specify the inside size, not including the border, and must be non-zero. The border-width for an InputOnly window must be zero (else a Match error).
M.I.T. [Page 26]
RFC 1013 June 1987
If background-pixmap is given, it overrides the default background-pixel. The background pixmap and the window must have the same root and the same depth (else a Match error). Any size pixmap can be used, although some sizes may be faster than others. If background None is specifed, the window has no defined background. If background ParentRelative is specified, the parent's background is used, but the window must have the same depth as the parent (else a Match error); if the parent has background None, then the window will also have background None. A copy of the parent's background is not made; the parent's background is reexamined each time the window background is required. If background-pixel is given, it overrides the default and any background-pixmap given, and a pixmap of undefined size filled with background-pixel is used for the background. For a ParentRelative background, the background tile origin always aligns with the parent's background tile origin; otherwise the background tile origin is always the window origin.
M.I.T. [Page 27]
RFC 1013 June 1987
A backing-store of WhenMapped advises the server that maintaining contents of obscured regions when the window is mapped would be beneficial. A backing-store of Always advises the server that maintaining contents even when the window is unmapped would be beneficial. Note that, even if the window is larger than its parent, the server should maintain complete contents, not just the region within the parent boundaries. If the server maintains contents, Exposure events will not be generated, but the server may stop maintaining contents at any time. A value of NotUseful advises the server that maintaining contents is unnecessary, although a server may still choose to maintain contents.
M.I.T. [Page 28]
RFC 1013 June 1987
This request generates a CreateNotify event.
M.I.T. [Page 29]
RFC 1013 June 1987
Changing the cursor of a root window to None restores the default cursor.
M.I.T. [Page 30]
RFC 1013 June 1987
DestroySubwindows
M.I.T. [Page 31]
RFC 1013 June 1987
MapWindow
M.I.T. [Page 32]
RFC 1013 June 1987
ConfigureWindow
M.I.T. [Page 33]
RFC 1013 June 1987
NorthWest: [0, 0] North: [W/2, 0] NorthEast: [W, 0] West: [0, H/2] Center: [W/2, H/2] East: [W, H/2] SouthWest: [0, H] South: [W/2, H] SouthEast: [W, H]
M.I.T. [Page 34]
RFC 1013 June 1987
placed at the bottom of the stack
M.I.T. [Page 35]
RFC 1013 June 1987
Errors: Drawable
M.I.T. [Page 36]
RFC 1013 June 1987
ChangeProperty
M.I.T. [Page 37]
RFC 1013 June 1987
type: ATOM format: {8, 16, 32} bytes-after: CARD32 value: LISTofINT8 or LISTofINT16 or LISTofINT32
M.I.T. [Page 38]
RFC 1013 June 1987
ListProperties
M.I.T. [Page 39]
RFC 1013 June 1987
Error: Atom, Window
M.I.T. [Page 40]
RFC 1013 June 1987
GrabPointer
M.I.T. [Page 41]
RFC 1013 June 1987
This request generates EnterNotify and LeaveNotify events.
M.I.T. [Page 42]
RFC 1013 June 1987
This request establishes a passive grab. In the future, if the specified button is pressed when the specified modifier keys are down (and no other buttons or modifier keys are down), and grab-window contains the pointer, and the confine-to window (if any) is viewable, and these constraints are not satisfied for any ancestor, then the pointer is actively grabbed as described in GrabPointer, the last-pointer-grab time is set to the time at which the button was pressed (as transmitted in the ButtonPress event), and the ButtonPress event is reported. The interpretation of the remaining arguments is as for GrabPointer. The active grab is terminated automatically when all buttons are released (independent of the state of modifier keys).
M.I.T. [Page 43]
RFC 1013 June 1987
GrabKeyboard
M.I.T. [Page 44]
RFC 1013 June 1987
UngrabKeyboard
M.I.T. [Page 45]
RFC 1013 June 1987
An Access error is generated if some other client has issued a GrabKey with the same key combination on the same window. When using AnyModifier or AnyNonModifier, the request fails completely (no grabs are established) if there is a conflicting grab for any combination.
M.I.T. [Page 46]
RFC 1013 June 1987
For ReplayPointer, if the pointer is actively grabbed by the client and is frozen as the result of an event having been sent to the client (either from the activation of a GrabButton, or from a previous AllowEvents with mode SyncPointer, but not from a GrabPointer), then the pointer grab is released and that event is completely reprocessed, but this time ignoring any passive grabs at or above (towards the root) the grab-window of the grab just released. The request has no effect if the pointer is not grabbed by the client, or if the pointer is not frozen as the result of an event.
M.I.T. [Page 47]
RFC 1013 June 1987
GrabServer
M.I.T. [Page 48]
RFC 1013 June 1987
TranslateCoordinates
M.I.T. [Page 49]
RFC 1013 June 1987
SetInputFocus
M.I.T. [Page 50]
RFC 1013 June 1987
OpenFont
M.I.T. [Page 51]
RFC 1013 June 1987
Returns logical information about a font.
M.I.T. [Page 52]
RFC 1013 June 1987
[x + min-bounds.left-side-bearing, y - max-bounds.
M.I.T. [Page 53]
RFC 1013 June 1987
X_HEIGHT: INT32
M.I.T. [Page 54]
RFC 1013 June 1987
draw-direction: {LeftToRight, RightToLeft} font-ascent: INT16 font-descent: INT16 overall-ascent: INT16 overall-descent: INT16 overall-width: INT32 overall-left: INT32 overall-right: INT32
M.I.T. [Page 55]
RFC 1013 June 1987
ListFontsWithInfo
M.I.T. [Page 56]
RFC 1013 June 1987
It is legal to pass an InputOnly window as a drawable to this request.
M.I.T. [Page 57]
RFC 1013 June 1987
In graphics operations, given a source and destination pixel, the result is computed bitwise on corresponding bits of the pixels. That is, a boolean operation is performed in each bit plane. The plane-mask restricts the operation to a subset of planes. That is, the result is
And src AND dst
AndReverse src AND (NOT dst)
Copy src
AndInverted (NOT src) AND dst NoOp dst Xor src XOR dst Or src OR dst Nor (NOT src) AND (NOT dst) Equiv (NOT src) XOR dst Invert NOT dst OrReverse src OR (NOT dst)
CopyInverted NOT src
OrInverted (NOT src) OR dst
NAnd (NOT src) OR (NOT dst)
Set 1
M.I.T. [Page 58]
RFC 1013 June 1987
Thin lines (zero line-width) are "one pixel wide" lines drawn using an unspecified, device dependent algorithm (for example, Bresenham). There are only two constraints on this algorithm. First, if a line is drawn unclipped from [x1,y1] to [x2,y2] and another line is drawn unclipped from [x1+dx, y1+dy] to [x2+dx,y2+dy], then a point [x,y] is touched by drawing the first line if and only if the point [x+dx,y+dy] is touched by drawing the second line. Second, the effective set of points comprising a line cannot be affected by clipping; that is, a point is touched in a clipped line if and only if the point lies inside the clipping region and the point would be touched by the line when drawn unclipped.
M.I.T. [Page 59]
RFC 1013 June 1987
The cap-style defines how the endpoints of a path are drawn:
M.I.T. [Page 60]
RFC 1013 June 1987
For the odd dashes for line requests with line-style DoubleDash: Solid: background Tiled: same as for even dashes OpaqueStippled: same as for even dashes Stippled: background masked by stipple
M.I.T. [Page 61]
RFC 1013 June 1987
The default component values are: function: Copy plane-mask: all ones foreground: 0 background: 1 line-width: 0 line-style: Solid cap-style: Butt join-style: Miter fill-style: Solid full-rule: EvenOdd arc-mode: PieSlice tile: pixmap of unspecified size filled with forground pixell (i.e., client specified pixel if any, else 0) stipple: pixmap of unspecified size filled with ones tile-stipple-x-origin: 0 tile-stipple-y-origin: 0 font: <implementation dependent> subwindow-mode: ClipByChildren graphics-exposures: True clip-x-origin: 0 clip-y-origin: 0 clip-mask: None dash-offset: 0 dash-list: 4 (i.e., the list [4, 4])
M.I.T. [Page 62]
RFC 1013 June 1987
Changes components in gc. The value-mask and value-list specify which components are to be changed. The values and restrictions are the same as for CreateGC.
M.I.T. [Page 63]
RFC 1013 June 1987
If known by the client, ordering relations on the rectangles can be specified with the ordering argument; this may provide faster operation by the server. If an incorrect ordering is specified, the server may generate a Match error, but is not required to do so; if no error is generated, the graphics results are undefined. UnSorted means the rectangles are in arbitrary order. YSorted means that the rectangles are non-decreasing in their Y origin. YXSorted additionally constrains YSorted order in that all rectangles with an equal Y origin are non-decreasing in their X origin. YXBanded additionally constrains YXSorted by requiring that for every possible Y scanline, all rectangles that include that scanline have identical Y origins and Y extents.
M.I.T. [Page 64]
RFC 1013 June 1987
CopyArea
M.I.T. [Page 65]
RFC 1013 June 1987
GC components: alu-function, plan-mask, foreground, background, subwindow-mode, graphics-exposures, clip-x-origin, clip-y-origin, clip-mask
M.I.T. [Page 66]
RFC 1013 June 1987
GC mode-dependent components: foreground, background, tile, stipple, tile-stipple-x-origin, tile-stipple-y-origin, dash-offset,dash-list
M.I.T. [Page 67]
RFC 1013 June 1987
PolyArc
M.I.T. [Page 68]
RFC 1013 June 1987
FillPoly
M.I.T. [Page 69]
RFC 1013 June 1987
GC components: alu-function, plane-mask, fill-style, fill-rule, subwindow-mode, clip-x-origin, clip-y-origin, clip-mask
M.I.T. [Page 70]
RFC 1013 June 1987
For XYPixmap and ZPixmap, depth must match the depth of drawable (else a Match error). For XYPixmap, the image must be sent in XYFormat. For ZPixmap, the image must be sent in the ZFormat defined for the given depth.
M.I.T. [Page 71]
RFC 1013 June 1987
PolyText8
M.I.T. [Page 72]
RFC 1013 June 1987
where TEXTITEM16: TEXTELT16 or FONT TEXTELT16: [delta-x: INT8
M.I.T. [Page 73]
RFC 1013 June 1987
ImageText16
M.I.T. [Page 74]
RFC 1013 June 1987
Has no effect on a default colormap for a screen.
M.I.T. [Page 75]
RFC 1013 June 1987
If cmap is an installed map, a ColormapNotify event is generated on every window having this colormap as an attribute. If a colormap is installed as a result of the uninstall, a ColormapNotify event is generated on every window having that colormap as an attribute.
M.I.T. [Page 76]
RFC 1013 June 1987
AllocColorCells
M.I.T. [Page 77]
RFC 1013 June 1987
FreeColors
M.I.T. [Page 78]
RFC 1013 June 1987
Errors: Colormap, Name, Access, Value
M.I.T. [Page 79]
RFC 1013 June 1987
Creates a cursor and associates identifier cid with it. Foreground and background RGB values must be specified, even if the server only has a monochrome screen. The foreground is used for the one bits in the source, and the background is used for the zero bits. Both source and mask (if specified) must have depth one (else a Match error), but can have any root. The mask pixmap defines the shape of the cursor; that is, the one bits in the mask define which source pixels will be displayed. If no mask is given, all pixels of the source are displayed. The mask, if present, must be the same size as source (else a Match error). The x and y coordinates define the hotspot, relative to the source's origin, and must be a point within the source (else a Match error).
M.I.T. [Page 80]
RFC 1013 June 1987
Deletes the association between the resource id and the cursor. The cursor storage will be freed when no other resource references it.
M.I.T. [Page 81]
RFC 1013 June 1987
The extension name should be in the ASCII encoding, and upper/lower case matters.
M.I.T. [Page 82]
RFC 1013 June 1987
Returns the current mapping of the keyboard. Elements of the list are indexed starting from one. The length of the list is 255.
M.I.T. [Page 83]
RFC 1013 June 1987
If both auto-repeat-mode and key are specified, then the auto-repeat mode of that key is changed, if possible. If only auto-repeat-mode is specified, then the global auto-repeat mode for the entire keyboard is changed, if possible, without affecting the per-key settings. It is a Match error if a key is specified without an auto-repeat-mode.
M.I.T. [Page 84]
RFC 1013 June 1987
SetPointerMapping
M.I.T. [Page 85]
RFC 1013 June 1987
GetPointerControl
M.I.T. [Page 86]
RFC 1013 June 1987
ChangeHosts
M.I.T. [Page 87]
RFC 1013 June 1987
Defines what will happen to the client's resources at connection close. A connection starts in Destroy mode. The meaning of the close-down mode is described in Section 11.
M.I.T. [Page 88]
RFC 1013 June 1987
What happens when the last connection to a server closes:
M.I.T. [Page 89]
RFC 1013 June 1987
ButtonPress
M.I.T. [Page 90]
RFC 1013 June 1987
EnterNotify
M.I.T. [Page 91]
RFC 1013 June 1987
between A and B exclusive (in that order)
M.I.T. [Page 92]
RFC 1013 June 1987
NonlinearVirtual, Pointer, PointerRoot, None}
M.I.T. [Page 93]
RFC 1013 June 1987
If P is an inferior of A, FocusOut with detail Pointer is
M.I.T. [Page 94]
RFC 1013 June 1987
KeymapNotify
M.I.T. [Page 95]
RFC 1013 June 1987
NoExposure
M.I.T. [Page 96]
RFC 1013 June 1987
DestroyNotify
M.I.T. [Page 97]
RFC 1013 June 1987
ConfigureNotify
M.I.T. [Page 98]
RFC 1013 June 1987
CirculateNotify
M.I.T. [Page 99]
RFC 1013 June 1987
Reported to the owner of a selection. Generated when a client issues a ConvertSelection request. The arguments are as in the request.
M.I.T. [Page 100]
RFC 1013 June 1987
SECTION 13. FLOW CONTROL AND CONCURRENCY