1 / 22

The X Window System

The X Window System. Module 5. X Window System. The X Window system was developed as part of Project Athena at MIT. In 1987, X Version 11 is released. X is now controlled and maintained by the Open Group.

bud
Download Presentation

The X Window System

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. The X Window System Module 5 X-Windows P.K.K.Thambi

  2. X Window System • The X Window system was developed as part of Project Athena at MIT. In 1987, X Version 11 is released. X is now controlled and maintained by the Open Group. • The X Windows System, also referred to as ‘X’ or “X11”, is the standard graphical engine for Unix , Linux and Sun workstations. • It is largely OS and hardware independent, it is network-transparent, and it supports many different desktops. X-Windows P.K.K.Thambi

  3. The Graphic User Interface in X • X Window uses a bit-mapped display where each pixel can be manipulated individually. • The entire display is known as the root window, and individual applications are displayed as windows on this root window. • X is started with the startx or xinit commands. • X can also be invoked during system startup X-Windows P.K.K.Thambi

  4. X-window Screen X-Windows P.K.K.Thambi

  5. Client / Server Architecture • Separate programs that talks together for a specific aim. • Server will be the program that supplies the services and the client is who make the requests. X-Windows P.K.K.Thambi

  6. X Window Clients and Servers • Although you can easily use the X Window system to run programs stored on your local computer, you can also run applications over the network • X Window uses a client/server model in which a program can run on one computer but display its output on another • The desktop system from which you run a program is called the X server, the system that hosts and executes the program is called the X client (this is opposite of normal networking) X-Windows P.K.K.Thambi

  7. X Protocol • Based on TCP/IP stack • The X Protocol provides a client-server architecture at the application level: • The X client is the processing part of the application and often runs on a remote machine. • The X server is the display and interaction system. X-Windows P.K.K.Thambi

  8. X Protocol cont’d The X Protocol is also divided into device dependent and device independent layers. X-Windows P.K.K.Thambi

  9. X architecture The client-server nature of the X Protocol allows a single X server to support many clients (applications) on several hosts. X-Windows P.K.K.Thambi

  10. Client-Server Window System Could beWindowManager Client Application Programs Application 1 Application 2 Application n Virtualdisplay 1 Virtualdisplay 2 Virtualdisplay n Server Resourceallocator Device-independent abstraction level Device driver Translates abstraction into reality: one per terminal type Window1 Devices Keyboard Mouse Window2 Windown (After Fig 10.2, Dix, Finlay, Abowd and Beale) X-Windows P.K.K.Thambi

  11. X Server Design • Device Dependent Layer • It is this layer that is responsible for localizing the X server to the native environment, be it Windows NT or Solaris. • This layer swaps bytes of data from machines with differing byte ordering. Byte ordering (MSB and LSB) is noted in each X request. • This layer hides the architectural differences in hardware and operating systems. • Maintains device driver dependencies for keyboard, mouse and video. X-Windows P.K.K.Thambi

  12. X Server The X server therefore: • displays drawing requests on the screen. • replies to information requests. • reports an error in a request. • Manages the keyboard, mouse and display device. • Multiplexes keyboard and mouse input onto the network (or via local IPC) to the respective X clients. (X events) • creates, maps and destroys windows. • writes and draws in windows X-Windows P.K.K.Thambi

  13. X Client • sends requests to the server. • receives events from server. • receives errors from the server X-Windows P.K.K.Thambi

  14. X Protocol • X client communicate with X server using the X protocol. • Data is exchanged in an asynchronous manner over a two-way communication path that enables transmission of a stream of 8 –bit bytes. • X protocol is the machine language for the X Window system X-Windows P.K.K.Thambi

  15. X Protocol messages • Requests – client sends requests to the server (e.g. create window) • Replies – server response to client requests • Events – server forwards events (such as mouse clicks or keyboard entry) to the client • Errors – server reports errors to the client X-Windows P.K.K.Thambi

  16. Protocol Messages - Requests Requests • X clients make requests to the X server for a certain action to take place. i.e.: Create Window • To enhance performance, the X client normally does not expect nor wait for a response. The request is typically left to the reliable network layer to deliver. X-Windows P.K.K.Thambi

  17. Protocol Messages - Replies Replies • The X Server will respond to certain X client requests that require a reply. As noted, not all requests require a reply. X-Windows P.K.K.Thambi

  18. Protocol Messages - Events Events • The X server will forward to the X client an event that the application is expecting. This could include keyboard or mouse input. To minimize network traffic, only expected events are sent to X clients. • X events are 32 bytes X-Windows P.K.K.Thambi

  19. Protocol Messages - Errors Errors • The X server will report errors in requests to the X client. Errors are like an event but are handled differently. • X errors are the same size as events to simplify their handling. They are sent to the error handling routine of the X client. X-Windows P.K.K.Thambi

  20. Xlib: The Assemble language of X • A set of C library of X window system • Xlib gives you access to the X protocol through more than 300 utility routines. • It is the The Assemble language of X Window System. X-Windows P.K.K.Thambi

  21. X Toolkit: The High level language of X • XToolkit Intrinsic (Xt Intrinsic) – an object- oriented approach to implement the basic building blocks called widgets X-Windows P.K.K.Thambi

  22. X application X toolkit Xt intrinsic Xlib X protocol Network Interface X protocol X Server Device- dependent Layer User Structure of an X application X-Windows P.K.K.Thambi

More Related