X Window System C Library and Protocol Reference

Order Number: EY-6737E-DP

This document is a comprehensive technical reference for the X Window System, specifically detailing its C Library (Xlib) and its underlying Protocol (Version 11). Published in 1988, it serves as a foundational guide for developers working with this graphical display system.

Key characteristics of the X Window System, as described in the document:

  • Network-Transparent and Device-Independent: X allows multiple applications (clients) to run simultaneously across a network, displaying text and 2D graphics on a bitmap display as if they were local. It's designed to be device-independent, meaning applications do not need to be rewritten or recompiled for different display hardware.
  • Client-Server Architecture: Applications are "clients" that communicate with an "X server" (running on the machine with the display) via a defined communication protocol. The server manages display output and forwards user input.
  • Asynchronous and Event-Driven: The communication protocol is largely asynchronous, allowing clients to send requests without waiting for immediate execution. The system operates on an event-driven model, where clients register interest in specific events (e.g., user input, window changes), and the server sends these notifications asynchronously.
  • Mechanism, Not Policy: A core philosophy of X is to provide low-level mechanisms (like window creation, graphics drawing, and input handling) rather than dictating a specific user interface policy. Higher-level toolkits and window managers are expected to be built on top of Xlib to define diverse user experiences.
  • Window Hierarchy: Windows are organized in a strict hierarchical tree structure, with a "root window" at the top of each physical screen, containing nested subwindows.

The document is structured into two main parts:

  1. Part I: Xlib - C Library X Interface: This section serves as a reference manual for Xlib, the standard C language interface to the X protocol. It covers:

    • Introduction to Xlib, errors, naming conventions, and programming considerations.
    • Display functions (opening/closing displays, obtaining information).
    • Window functions (creating, destroying, mapping, configuring, attribute manipulation).
    • Graphics resource functions (colormaps, pixmaps, graphics contexts).
    • Graphics functions (drawing points, lines, rectangles, arcs, text, image transfers).
    • Window manager functions (pointer/keyboard grabbing, screen saver, host access control).
    • Events and event-handling functions (event types, structures, masks, processing).
    • Predefined property functions (communication with window managers, standard colormaps).
    • Application utility functions (keyboard utilities, environment defaults, geometry parsing, color parsing, region manipulation, cut and paste buffers, image/bitmap manipulation, resource management, context management).
  2. Part II: X Window System Protocol Version 11: This part provides a concise and precise specification of the underlying X protocol's semantics, independent of any specific programming language. It details:

    • Protocol formats for requests, replies, and errors.
    • Syntactic conventions and common data types (e.g., WINDOW, PIXMAP, CURSOR, FONT, BITMASK, TIMESTAMP, BITGRAVITY, WINGRAVITY).
    • Detailed descriptions of various requests clients can send to the server.
    • Information on connection close operations.
    • Detailed descriptions of event types and their components.
    • Flow control and concurrency considerations.

The book also includes several appendices for cross-referencing Xlib functions to protocol requests, predefined cursor shapes, Xlib extension details, version 10 compatibility, KEYSYM encoding, and comprehensive protocol encoding descriptions, along with a glossary and index.

Overall, this document is an essential resource for C programmers and system developers aiming for a deep understanding or low-level interaction with the X Window System, as it existed in the late 1980s.

EY-6737E-DP
1988
734 pages
Quality

Original
26MB

Site structure and layout ©2025 Majenko Technologies