X Window System Programmer's Guide

Contents


Proprietary Notice

Copyright Notice

Introduction

Chapter 1: Xmu Library

Introduction
1.1 Atom Functions
1.2 Error Handler Functions
1.3 System Utility Functions
1.4 Window Utility Functions
1.5 Cursor Utility Functions
1.6 Graphics Functions
1.7 Selection Functions
1.8 Type Converter Functions
1.9 Character Set Functions
1.10 Compound Text Functions
1.11 Close Display Hook Functions
1.12 Display Queue Functions
1.13 Toolkit Convenience Functions
1.14 Standard Colormap Functions
1.15 Widget Description Functions
1.16 Participation in the Editres Protocol

Chapter 2: Xau Library

2.1 Xau Functions

Chapter 3: Inter-Client Communication Conventions Manual

Preface to Version 2.0
Preface to Version 1.1
3.1 Introduction
3.1.1 Evolution of the Conventions
3.1.2 Atoms
3.1.2.1 What Are Atoms?
3.1.2.2 Predefined Atoms
3.1.2.3 Naming Conventions
3.1.2.4 Semantics
3.1.2.5 Name Spaces
3.1.2.6 Discriminated Names
3.2 Communication by Means of Selections
3.2.1 Acquiring Selection Ownership
3.2.2 Responsibilities of the Selection Owner
3.2.3 Giving Up Selection Ownership
3.2.3.1 Voluntarily Giving Up Selection Ownership
3.2.3.2 Forcibly Giving up Selection Ownership
3.2.4. Requesting a Selection
3.2.5. Large Data Transfers
3.2.6. Use of Selection Atoms
3.2.6.1 Selection Atoms
3.2.6.1.1 The PRIMARY Selection
3.2.6.1.2 The SECONDARY Selection
3.2.6.1.3 The CLIPBOARD Selection
3.2.6.2 Target Atoms
3.2.6.3 Selection Targets with Side Effects
3.2.6.3.1 DELETE
3.2.6.3.2 INSERT_SELECTION
3.2.6.3.3 INSERT_PROPERTY
3.2.7 Use of Selection Properties
3.2.7.1 TEXT Properties
3.2.7.2 INCR Properties
3.2.7.3 DRAWABLE Properties
3.2.7.4 SPAN Properties
3.2.8 Manager Selections
3.3 Communication by Means of Cut Buffers
3.4 Client to Window Manager Communication
3.4.1 Client's Actions
3.4.1.1 Creating a Top-Level Window
3.4.1.2 Client Properties
3.4.1.2.1 WM_NAME Property
3.4.1.2.2 WM_ICON_NAME Property
3.4.1.2.3 WM_NORMAL_HINTS Property
3.4.1.2.4 WM_HINTS Property
3.4.1.2.5 WM_CLASS Property
3.4.1.2.6 WM_TRANSIENT_FOR Property
3.4.1.2.7 WM_PROTOCOLS Property
3.4.1.2.8 WM_COLORMAP_WINDOWS Property
3.4.1.2.9 WM_CLIENT MACHINE Property
3.4.1.3 Window Manager Properties
3.4.1.3.1 WM_STATE Property
3.4.1.3.2 WM_ICON_SIZE Property
3.4.1.4 Changing Window State
3.4.1.5 Configuring the Window
3.4.1.6 Changing Window Attributes
3.4.1.7 Input Focus
3.4.1.8 Colormaps
3.4.1.9 Icons
3.4.1.10 Pop-up Windows
3.4.1.11 Window Groups
3.4.2 Client Responses to Window Manager Actions
3.4.2.1 Reparenting
3.4.2.2 Redirection of Operations
3.4.2.3 Window Move
3.4.2.4 Window Resize
3.4.2.5 Iconify and Deiconify
3.4.2.6 Colormap Change
3.4.2.7 Input Focus
3.4.2.8 Client Message Events
3.4.2.8.1 Window Deletion
3.4.2.9 Redirecting Requests
3.4.3 Communication with the Window Manager by Means of Selections
3.4.4 Summary of Window Manager Property Types
3.5 Session Management
3.5.1 Client Support for Session Management
3.5.2 Window Manager Support for Session Management
3.6 Manipulation of Shared Resource
3.6.1 The Input Focus
3.6.2 The Pointer
3.6.3 Grabs
3.6.4. Colormaps
3.6.5 The Keyboard Mapping
3.6.6 The Modifier Mapping
3.7 Device Color characterization
3.7.1 XYZ RGB Conversion Matrices
3.7.2 Intensity RGB value Conversion
3.8 Conclusion
3.8.1 The X Registry

Chapter 4: Compound Text Encoding

Overview
4.1 Values
4.2 Control Characters
4.3 Standard Character Set Encoding
4.4 Approved Standard Encoding
4.5 Non-Standard Character Set Encoding
4.6 Directionality
4.7 Resources
4.8 Font Names
4.9 Extensions
4.10 Errors

Chapter 5: X Logical Font Description Conventions

Introduction
5.1 Requirements and Goals
5.1.1 Provide Unique and Descriptive Font Names
5.1.2 Support Multiple Font Vendors and Character Sets
5.1.3 Support Scalable Fonts and Polymorphic Fonts
5.1.4 Support Transformations and Subsetting of Fonts
5.1.5 Be Independent of X Server and Operating or File System Implementations
5.1.6 Support Arbitrarily Complex Font Matching and Substitution
5.1.7 Be Extensible
5.2 X Logical Font Description
5.2.1 Font Name
5.2.1.1 Font Name Syntax
5.2.1.2 Font Name Field Definitions
5.2.1.2.1 FOUNDRY Field
5.2.1.2.2 FAMILY_NAME Field
5.2.1.2.3 WEIGHT NAME Field
5.2.1.2.4 SLANT Field
5.2.1.2.5 SETWIDTH_NAME Field
5.2.1.2.6 ADD_STYLE_NAME Field
5.2.1.2.7 PIXEL_SIZE Field
5.2.1.2.8 POINT_SIZE Field
5.2.1.2.9 RESOLUTION_X and RESOLUTION_Y Fields
5.2.1.2.10 SPACING Field
5.2.1.2.11 AVERAGE_WIDTH Field
5.2.1.2.12 CHARSET_REGISTRY and CHARSET_ENCODING Fields
5.2.1.3. Examples
5.2.2. Font Properties
5.2.2.1 FOUNDRY
5.2.2.2 FAMILY_NAME
5.2.2.3 WEIGHT_NAME
5.2.2.4 SLANT
5.2.2.5 SETWIDTH_NAME
5.2.2.6 ADD_STYLE_NAME
5.2.2.7 PIXEL_SIZE
5.2.2.8 POINT_SIZE
5.2.2.9 RESOLUTION_X
5.2.2.10 RESOLUTION_Y
5.2.2.11 SPACING
5.2.2.12 AVERAGE_WIDTH
5.2.2.13 CHARSET_REGISTRY
5.2.2.14 CHARSET_ENCODING
5.2.2.15 MIN_SPACE
5.2.2.16 NORM_SPACE
5.2.2.17 MAX_SPACE
5.2.2.18 END_SPACE
5.2.2.19 AVG_CAPITAL_WIDTH
5.2.2.20 AVG_LOWERCASE_WIDTH
5.2.2.21 QUAD_WIDTH
5.2.2.22 FIGURE_WIDTH
5.2.2.23 SUPERSCRIPT_X
5.2.2.24 SUPERSCRIPT_Y
5.2.2.25 SUBSCRIPT_X
5.2.2.26 SUBSCRIPT_Y
5.2.2.27 SUPERSCRIPT_SIZE
5.2.2.28 SUBSCRIPT_SIZE
5.2.2.29 SMALL_CAP_SIZE
5.2.2.30 UNDERLINE POSITION
5.2.2.31 UNDERLINE_THICKNESS
5.2.2.32 STRIKEOUT_ASCENT
5.2.2.33 STRIKEOUT_DESCENT
5.2.2.34 ITALIC_ANGLE
5.2.2.35 CAP_HEIGHT
5.2.2.36 X_HEIGHT
5.2.2.37 RELATIVE_SETWIDTH
5.2.2.38 RELATIVE_WEIGHT
5.2.2.39 WEIGHT
5.2.2.40 RESOLUTION
5.2.2.41 FONT
5.2.2.42 FACE_NAME
5.2.2.43 FULL_NAME
5.2.2.44 COPYRIGHT
5.2.2.45 NOTICE
5.2.2.46 DESTINATION
5.2.2.47 FONT_TYPE
5.2.2.48 FONT_VERSION
5.2.2.49 RASTERIZER_NAME
5.2.2.50 RASTERIZER_VERSION
5.2.2.51 RAW_ASCENT
5.2.2.52 RAW_DESCENT
5.2.2.53 RAW_*
5.2.2.54 AXIS_NAMES
5.2.2.55 AXIS_LIMITS
5.2.2.56 AXIS_TYPES
5.2.3. Built-in Font Property Atoms
5.3 Metrix Transformations
5.3.1 Metrix and Font Properties
5.4 Scalable Fonts
5.5. Polymorphic Fonts
5.6 Affected Elements of Xlib and the X Protocol
5.7 BDF Conformance
5.7.1 XLFD Conformance Requirements
5.7.2 FONT_ASCENT, FONT_DESCENT, and DEFAULT_CHAR
5.7.2.1 FONT_ASCENT
5.7.2.2 FONT_DESCENT
5.7.2.3 DEFAULT CHAR

Chapter 6: Bit distribution Format

6.1 FILE FORMAT
6.2 METRIC INFORMATION

Chapter 7: X Display Manager Control Protocol

7.1 Purpose and Goals
7.2 Overview of the Protocol
7.3 Data Types
7.4 Packet Format
7.5 Protocol
7.6 Session Termination
7.7 State Diagrams
7.8 Protocol Encoding
7.9 Display Class Format
7.10 Manufacturer Display ID Format
7.11 Authentication

Chapter 8: MVEX, Minimal Video Extension to X

8.1. External Interfaces
8.1.1. Header File and Library
8.1.2. Data Structures
8.1.3. Event Structures
8.1.4. MVEX Protocol Functions
8.1.5. Application Utility Functions
8.1.6. Option to the X server 8-16
8.2. Notes
8.2.1. Notes on Port Identifiers and Signal Formats
8.2.2. Notes on VIDEO GEOMETRY
8.2.3. Notes on Saturation, Contrast, Hue, and Brightness
8.2.4. Notes on Video Input Model
8.2.5. Other Notes
8.3. MVEX Protocol
8.3.1. Overview
8.3.2. Terminology
8.3.3. Visuals
8.3.4. Types
8.3.5. Errors
8.3.6. Requests
8.3.7. Core Request
8.3.8. Events

Chapter 9: X Synchronization Extension

9.1. Synchronization
9.2. Description
9.3. Types
9.4. Errors
9.5. Requests
9.6. Events
9.7. Encoding
9.7.1. New Types
9.7.2. Errors
9.7.3. Requests
9.7.4. Events
9.8. C Language Binding
9.8.1. C Functions
9.8.2. C Macros/Functions
9.8.3. Events
9.8.4. Errors

Chapter 10: X Locale Database

10.1. General
10.2. Database Format Definition
10.3. Contents of Database
10.4. XLC_FONTSET Category
10.5. XLC_XLOCALE Category
10.6. Sample of X Locale Database
10.7. Reference

Chapter 11: Inter-Client Exchange (ICE) Library

11.1. The Ice Library -A "C"Language Interface To Ice
11.2. Intended Audience
11.3. Header Files and Library Name
11.4. Note on Prefixes
11.5. Protocol Registration
11.5.1Callbacks for Processing Messages
11.5.2 Authentication Methods
11.6. ICE Connections
11.7. Protocol Setup and Shutdown
11.8. Processing Messages
11.9. Ping
11.10. Informational Functions
11.11. ICE Messages
11.13.1. Sending ICE Messages
11.13.2. Reading ICE Messages
11.12. Error Handling
11.13. Multi-Threading Support
11.14. Miscellaneous Functions

Chapter 12: X Session Management Library

12.1. The Session Management Library
12.2. Understanding SMlib's Dependence on ICE
12.3. Header Files and Library Name
12.4. Session Management Client (Smc) Functions
12.4.1. Connecting to the Session Manager
12.4.1.1. The Save Yourself Callback
12.4.1.2. The Die Callback
12.4.1.3. The Save Complete Callback
12.4.1.4. The Shutdown Cancelled Callback
12.4.2. Closing the Connection
12.4.3. Modifying Callbacks
12.4.4. Setting, Deleting, and Retrieving Session Management Properties
12.4.5. Interaction With the User
12.4.6. Requesting a Save Yourself
12.4.7. Requesting a Save Yourself Phase 2
12.4.8. Completing a Save Yourself
12.4.9. Informational Functions
12.4.10. Error Handling
12.5. Session Management Server (Sms) Functions
12.5.1. Initializing the Library
12.5.1.1. The Register Client Callback
12.5.1.2. The Interact Request Callback
12.5.1.3. The Interact Done Callback
12.5.1.4. The Save Yourself Request Callback
12.5.1.5. The Save Yourself Phase 2 Request Callback
12.5.1.6. The Save Yourself Done Callback
12.5.1.7. The Connection Closed Callback
12.5.1.8. The Set Properties Callback
12.5.1.9. The Delete Properties Callback
12.5.1.10. The Get Properties Callback
12.5.2. Registering the Client
12.5.3. Sending a Save Yourself Message
12.5.4. Sending a Save Yourself Phase 2 Message
12.5.5. Sending an Interact Message
12.5.6. Sending a Save Complete Message
12.5.7. Sending a Die Message
12.5.8. Cancelling a Shutdown
12.5.9. Returning Properties
12.5.10. Pinging a Client
12.5.11. Cleaning Up After a Client Disconnects
12.5.12. Informational Functions
12.5.13. Error Handling
12.6. Session Management Properties
12.7. Freeing Data
12.8. Authentication of Clients
12.9. Working in a Multi-Threaded Environment

Appendix A Revision History

Appendix B Suggested Protocol Revisions

Appendix C Authentication Utility Functions

Appendix D MIT-MAGIC-COOKIE-1 Authentication

Index

Home