LINFO

X Server Definition



An X server is a program in the X Window System that runs on local machines (i.e., the computers used directly by users) and handles all access to the graphics cards, display screens and input devices (typically a keyboard and mouse) on those computers.

The X Window System, often referred to merely as X, is a complete, cross-platform and free client-server system for managing GUIs (graphical user interfaces) on single computers and on networks of computers. The client-server model is an architecture (i.e., network design) that divides the work between two separate but linked applications, referred to as clients and servers.

In the typical client-server relationship, the client application runs on the local machine. It helps the user request data from the server and displays the requested data appropriately on the user's display screen. The server application, which processes the data as requested and returns the results to the client, typically can run on either a remote machine (i.e., a computer located elsewhere on the network) or the local machine with no obvious difference to the user (so-called network transparency). When running on a remote machine, the server program can accommodate the requests of multiple clients.

In X, however. the client-server relationship is inverted in that each local machine contains X server server software and can access X clients (i.e., application programs) that run either on the same machine or on a remote machine. The X server does the actual work of managing the input and display devices, including performing the requested display operation. This has the advantage of eliminating the need for the application programs to be aware of these hardware details, thereby simplifying the development of such programs and facilitating their servicing of multiple users on the network simultaneously.

Communication between an X server and X clients is governed by the X protocol, which is sometimes termed the message format of the X Window System. Such communication consists of: (1) requests by clients for information or an action, (2) responses by the server, (3) the sending by the server of events to clients and (4) the sending by the server of error packets if client requests are invalid. An event is typically an input from a keyboard or mouse, such as a window being moved, exposed, resized or closed. Packets are the fundamental unit of information transport in all modern computer networks.

The X server provides five basic types of services: input handling, window services, graphics, text and fonts, and resource management. Input handling services consist of passing keyboard and mouse inputs to clients as events via the window manager, which X regards as just another client. A window manager is a program that provides basic management operations for windows, such as opening, closing, moving and resizing windows.

Window services are requests by clients to the X server to provide information about windows or to create or destroy them. Graphics services are the drawing of lines and shapes and performing bitmap (i.e., images made up of pixels) operations in response to client requests. Text and font services are responses to clients' requests to draw text at specified locations in specific fonts as well as responses to requests for information on available fonts. Resource management includes the provision of a content-addressable database for clients.






Created December 19, 2005. Updated April 7, 2006.
Copyright © 2005 The Linux Information Project. All Rights Reserved.