Introduction to the X Window System
Total Page:16
File Type:pdf, Size:1020Kb
Information Technology Document UNIX 2 Rice University June 21, 2000 Introduction to the X Window System This document helps new account holders familiarize themselves with the X Window System, Ver- sion 11—simply called X—and maintains an emphasis on concepts and everyday use rather than highly technical details. This material includes an overview of X concepts and instructions for start- ing, conducting, and ending an X session. Also covered are the Tab Window Manager, or TWM, and the xterm terminal emulator, and other such topics such as remote processes. Rice University, 2000 All Rights Reserved Document may not be resold to, used by, nor licensed to third parties without written permission from User Services, Rice University. Table of Contents How to Use This Document......................................................................4 The X Window System.............................................................................4 Background ...............................................................................................................4 Basic X Terms...........................................................................................................5 Display Servers, Hosts, and Clients...................................................................5 Screens and Displays .........................................................................................5 Windows and Icons............................................................................................6 Pointing Devices and Cursors............................................................................6 Window Managers.............................................................................................6 Working in an X Session ..........................................................................7 Starting X ..................................................................................................................7 The Console Window................................................................................................8 Special Keys: SHIFT, CTRL, and META.................................................................8 Using the Mouse .......................................................................................................9 Mouse Motion and the Display..........................................................................9 Mouse Buttons ...................................................................................................9 Clicking and Dragging.....................................................................................10 Menu Item Selection........................................................................................10 Selecting Text ..................................................................................................11 Copying, Pasting, and Cutting .........................................................................12 Special Keys and the Mouse............................................................................13 The Scrollbar....................................................................................................14 Ending an X Session ...............................................................................................14 For More Information: Manual Pages.....................................................................15 The Tab Window Manager (TWM)........................................................16 TWM Elements.......................................................................................................16 Windows ..........................................................................................................16 Icons.................................................................................................................17 Cursors .............................................................................................................17 Standard Menus.......................................................................................................17 The TWM Window Manager Menu ................................................................18 The Applications Menu ...................................................................................19 Window Operations without Menus........................................................................21 2 Introduction to the X Window System The xterm Terminal Emulator ................................................................21 Background.............................................................................................................21 VT102 (VT) Mode..................................................................................................22 Tektronix 4010 (Tek) Mode ....................................................................................22 The Shell in xterm...................................................................................................22 xterm Window Menus.............................................................................................22 Main Options ...................................................................................................23 VT Options ......................................................................................................23 VT Fonts..........................................................................................................25 Tek Options .....................................................................................................25 Remote Processes (Clients) ....................................................................26 The DISPLAY Environment Variable.....................................................................26 Multiple Environments ...........................................................................................27 The rlogin Command..............................................................................................28 The xhost Command...............................................................................................30 For More Information.............................................................................31 Introduction to the X Window System 3 Background How to Use This Document Many books and manuals on the X Window System exist, providing varying degrees of readability and usefulness. This document attempts to present the X Window System, Version 11, with an emphasis on concepts and everyday use rather than highly technical details. Throughout this docu- ment the X Window System, Version 11, will be referred to as “the X Window System” or simply “X.” The structure of this document and its exercises is intended to help you to become acquainted with X. When beginning to read this document, keep in mind the following advice: you may find it help- ful to read through a section, and then go back and do the exercises. Section 1 presents an overview of X and introduces some important terms. Section 2 covers the basics required to start and end an X session and to use the mouse. Section 3 explains the Tab Window Manager’s (TWM) functions and its menus. Section 4 gives a brief description of the terminal window, and it lists the various options available through it. The remainder of this document is not essential to working with X. Section 5 discusses the advanced topic of remote processes. You may find it useful if you wish to display work from more than one computer at a time. Appendix A lists other sources for more information on X and related software. Although this document covers X in general, naturally many of the examples will be specific to the implementations of X on networks maintained by Information Technology (such as Owlnet). Finally, this document includes several references to the UNIX (UNIX is a registered trademark of AT&T Bell Laboratories) operating system. For more information about UNIX, see the document UNIX 1, Introduction to the UNIX Operating System. The X Window System This section describes X’s features and limitations. Some of the details may seem tedious at first, but understanding the concepts presented here will facilitate learning more about X. Background Developed at the Massachusetts Institute of Technology in 1984, X provides a graphics- window system for computer networks. Every computer network requires a system that will allow users to communicate with it. X provides such a system and employs graphics windows as its foundation. Each graphics window represents a particular application, such as a text editor, a debugger, an elec- tronic mail manager, or a terminal emulator. X lets you open multiple windows and run several applications simultaneously. The activity within one window executes independently of the activity in the other windows. For example, you can compile a FORTRAN program in one window, read electronic mail in another, run a clock in a third, and run a text editing program in a fourth window. This feature makes X very 4 Introduction to the X Window System Basic X Terms powerful because you can access many different applications—even different computers—from a single terminal; you simply open new windows as needed. First, and foremost, however, X is a windowing system, not a complete operating system. UNIX is an operating system. See the document Introduction to the UNIX Operating System for more information on UNIX. X mediates the communication between individuals and a computer network. X creates win- dows that represent applications, but does not execute the applications