X-WINDOW Overview

xiaoxiao2021-03-06  45

For ordinary users, the most important feature of the operating system is probably the various resources that can easily provide computer hardware, complete their daily work. Most users are very familiar with the Windows system, then from the user interface, what is the attractive place in linux? The answer is that he has X-windows. Let us enter XWindows's colorful world, truly understand the glare of Linux.

First, X windows brief history

X began development at the Massachusetts Institute of Computer Science Research Institute in 1984. At that time, Bob Scheifler was developing a distributed system. At the same time, DEC's JimgetTys was also part of the ATHENA program in the MIT, and two plans need one thing - a set of excellent window systems on UNIX machines. So they started working, from Stanford University, a set of experimental window systems called W, because they started to develop based on the W window system, when developing enough to distinguish between the original system, they called this new system X.

Second, X's basic components

The X system is unlike an early window system to set a pile of similar software, but is combined by three associated portions.

(1) Server: Controls the actual display and input device. Server is the software that controls the display and input devices (keyboards, and mouse). Server can create a window, draw graphics and text in the window, respond to the "Requests" of the Client program, but he will not move, only after the client program is required to make actions.

Each display device only corresponds to a unique server, and Server is generally provided by the system's vendor, usually cannot be modified by the user. For operating systems, Server is just a normal user program, so it is easy to change a new version, even the original program provided by a third party.

(2) Client: Client is some applications using the system window feature. Applications under X are called Client because he is a Server customer, and he asked Server to respond to his needs to complete a specific action.

Client cannot directly affect the window or display, they can only send a request to Server, and Server to complete their request. A typical request is usually "a string written in a window" or draw a straight line from A to B.

Client's functionality can be roughly divided into such a part: "Demand" to Server is just part of his function, and other functions are prepared for the user. For example, enter text information, mapping, calculation, and more. Typically, this part of the client program is independent of X, and he doesn't need to know about X. Typically, applications (especially large standard drawing software, statistical software, etc.) have the ability to output a lot of output devices, while displaying in the X window is just one of a number of output formats in the Client program, so a Client program The neutralization-related part is only a very small part of the entire program.

Users can use the Client program through different ways: Use the program provided by the system; use software from third parties; or users who write themselves for some special application.

(3) Communication channel: With Server and Client, they will transfer some information, which is the third component of the X we want to introduce: Communication channels. With this channel, Client Transfer "Demand" to Server, while Server Recycling Status (STATUS) and other information give to client.

Client is using a library to use communication channels. Supporting communication morphology requirements on system or network is the basic X Window Function Library built in the system. As long as the Client program uses a library, it naturally has the ability to use all available communication methods. At this time, the channel itself is no longer important, but it is just a concept. Third, the communication between Server and Client

Server and Client communication methods have roughly two types, corresponding to two basic operating modes of the X system. The first, Server and Client are performed on the same machine, which can use any available communication methods on the machine to communicate with interactive information. In this mode, X can work with other traditional window systems. Second, the client runs on a machine, while the display and server run on another machine. Therefore, the information exchange must be performed by a network protocol complied with each other, and the most common protocol is a TCP / IP protocol. This communication method is generally referred to as network transparency, which is almost a unique characteristic.

Four, x user interface

One of the design objectives of X is to create many different forms of user interfaces. Others are the window west, and X only provides a general architecture to make the system build the desired interactive style. This feature allows developers to build a new interface on the basis of X and can choose the appropriate interface according to their own needs at any time. In general, the user interface can be divided into two parts. The management interface is the window manager. It is the highest layer of command. He is responsible for constructing or rebuilding the window on the screen, changing the size, location of the window, or changing the window into icons. The application interface determines how interactive style between users and applications, that is, how users use the device programs of the window system to control applications and input materials to it. For example, how to use a mouse to select an option.

V. X is independent of the operating system

X is not built into the operating system, he is just a little higher than the user level. It is also a relatively independent component in the system. Doing so the following advantages:

(1) Easy to install and revisit, even removed. This job does not need to restart the system, nor does it cause interference to other applications.

(2) The third part is easy to support and strengthen its function. For example, your manufacturer is not good enough, you can buy better or faster versions to others.

(3) X does not formulate an operating system, so become a standard, which is also the original power of third-party development software.

(4) In order to develop the interests. When working on Server, if the program is abnormal, it will only affect the window system, which will not cause damage to the machine or the core of the operating system.

转载请注明原文地址:https://www.9cbs.com/read-60173.html

New Post(0)