X Window System core protocol: Difference between revisions

Content deleted Content added
m Reverted edit by 2409:408D:10F:F78E:0:0:275D:50B1 (talk) to last version by VulcanSphere
AnomieBOT (talk | contribs)
m Dating maintenance tags: {{Cn}}
 
(5 intermediate revisions by 5 users not shown)
Line 1:
{{Short description|none}}
[[Image:X11.svg|thumb|100px|The X Window System logo]]
The '''X Window System core protocol'''<ref name="sche-gett">Robert W. Scheifler and James Gettys: ''X Window System: Core and extension protocols, X version 11, releases 6 and 6.1'', Digital Press 1996, {{ISBN|1-55558-148-X}}</ref><ref name="rfc 1013">RFC 1013</ref><ref name="intr">Grant Edwards. [http://www.visi.com/~grante/Xtut/ An Introduction to X11 User Interfaces] {{Webarchive|url=https://web.archive.org/web/20070103060448/http://www.visi.com/~grante/Xtut/ |date=2007-01-03 }}</ref> is the base protocol of the [[X Window System]], which is a [[Computer network|networked]] [[windowing system]] for [[bitmap]] displays used to build [[graphical user interface]]s on [[Unix]], [[Unix-like]], and other [[operating system]]s. The X Window System is based on a [[client–server model]]: a single [[Server (computing)|server]] controls the [[input/output]] hardware, such as the [[Computer screen|screen]], the [[Computer keyboard|keyboard]], and the [[Computer mouse|mouse]]; all application [[Computer program|program]]s act as [[client (computing)|client]]s, interacting with the [[user (computing)|user]] and with the other clients via the server. This interaction is regulated by the X Window System core protocol. Other [[protocol (computing)|protocol]]s related to the X Window System exist, both built at the top of the X Window System core protocol or as separate protocols.
 
In the X Window System core protocol, only four kinds of packets are sent, [[wikt:asynchronously|asynchronously]], over the network: requests, replies, events, and errors. ''Requests'' are sent by a client to the server to ask it to perform some operation (for example, create a new window) and to send back data it holds. ''Replies'' are sent by the server to provide such data. ''Events'' are sent by the server to notify clients of user activity or other occurrences they are interested in. ''Errors'' are packets sent by the server to notify a client of errors occurred during processing of its requests. Requests may generate replies, events, and errors; other than this, the protocol does not mandate a specific order in which packets are sent over the network. Some extensions to the core protocol exist, each one having its own requests, replies, events, and errors.
Line 55:
Most requests for graphic operations include a ''graphic context'', which is a structure that contains the parameters of the graphic operations. A graphic context includes the foreground color, the background color, the font of text, and other graphic parameters. When requesting a graphic operation, the client includes a graphic context. Not all parameters of the graphic context affect the operation: for example, the font does not affect drawing a line.
 
The core protocol specifies the use of server-side fonts.<ref name="font-faq">{{Cite web|url=http://www.faqs.org/faqs/fonts-faq/part15/|title=comp.fonts FAQ: X11 Info|website=www.faqs.org}}</ref> Such fonts are stored as [[Computer file|file]]s, and the server accesses them either directly via the local [[filesystem]] or via the network from another program called ''font server''. Clients can request the list of fonts available to the server and can request a font to be loaded (if not already) or unloaded (if not used by other clients) by the server. A client can request general information about a font (for example, the font ascent) and the space a specific string takes when drawn with a specific font.{{cn|date=March 2025}}
 
[[Image:Xfontsel.png|thumb|450px|The <code>xfontsel</code> program allows the user to view the glyphs of a font.]]
The names of the fonts are arbitrary strings at the level of the X Window core protocol. The [[X logical font description]] conventions<ref name="logi-font">{{cite web|url=http://www.xfree86.org/current/xlfd.pdf |title=X Logical Font Description Conventions |access-date=2005-12-30 |author=Jim Flowers |author2=Stephen Gildea |year=1994 |format=PDF |work=[[Digital Equipment Corporation]] |publisher=[[X Consortium]] |url-status=dead |archive-url=https://web.archive.org/web/20050328124653/http://www.xfree86.org/current/xlfd.pdf |archive-date=March 28, 2005 }}</ref> specify how fonts should be named according to their attributes. These conventions also specify the values of optional properties that can be attached to fonts.
 
The <code>xlsfonts</code> program prints the list of fonts stored in the server. The <code>xfontsel</code> program shows the glyphs of fonts, and allows the user to select the name of a font for pasting it in another window.
Line 160:
 
A part of the X colour system is the X Color Management System (xcms). This system was introduced with X11R6 Release 5 in 1991. This system consists of several additional features in xlib, found in the Xcms* series of functions. This system defines device independent color schemes which can be converted into device dependent RGB systems. The system consists of the xlib Xcms* functions and as well the X Device Color Characterization Convention (XDCCC) which describes how to convert the various device independent colour systems into device dependent RGB colour systems. This system supports the [[CIEXYZ]], [[xyY]], [[CIELUV]] and [[CIELAB]] and as well the [[TekHVC]] colour systems.
[http://insar.stanford.edu/~lharcke/programming/Xcms/] {{Webarchive|url=https://web.archive.org/web/20111005224650/http://insar.stanford.edu/~lharcke/programming/Xcms/ |date=2011-10-05 }}, [http://tronche.com/gui/x/xlib/color/]
 
== Atoms ==
Line 289:
== External links ==
*[http://www.x.org/ X.Org Foundation] (official home page) - [http://xorg.freedesktop.org/wiki/ Mirror] with the ___domain name 'freedesktop.org'.
*[httphttps://xwindow.angelfire.com/ X Window System Internals]
*[http://www.rahul.net/kenton/bib.html Kenton Lee's pages on X Window and Motif] {{Webarchive|url=https://web.archive.org/web/20130520013725/http://www.rahul.net/kenton/bib.html |date=2013-05-20 }}
*[http://www.x.org/releases/current/doc/xproto/x11protocol.html X Window System Protocol, Version 11 (current Release)]
{{XWinSys}}