42
A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

Embed Size (px)

Citation preview

Page 1: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux Fourth Edition

Chapter 11The X Window System

Page 2: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 2

Objectives

• Describe the X Window System and its client/server model

• Understand the role of the Window Manager

• Understand desktops such as GNOME and KDE

• Start the X Window System

Page 3: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 3

Objectives (continued)

• Interact with the X Window System and use its components

• Use Nautilus and Konqueror for file management

• Run an application

• Configure a desktop

• Shut down a system from the desktop

Page 4: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 4

What is the X Window System?

• X Window System: GUI that runs on Linux and many UNIX operating systems– Two popular desktops:

• GNOME• KDE

– Originally developed at MIT• Currently in its eleventh version: X11• Current release is R7.2.0 (X11R7)

– XFree86: free version of X11 that was ported from non-PC-based UNIX computers to run on PCs

• Compatible with Linux

Page 5: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 5

Page 6: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 6

Page 7: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 7

X Window Clients and Servers

• Use X Window System to run programs stored:– On your local computer– Over a network

• X Window System uses a client/server model:– X server: underlying desktop system from which you

run a program– X client: system that hosts and executes the

program

• X server approaches for Windows-based PCs:– X-Win32, X-Win32 Flash, and Exceed

Page 8: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 8

Using Window Managers

• X Window System is layered and built from components– At top layer is the Window Manager

• Window Manager: controls how windows appear and how users control them

• Many Window Managers have been developed– Most of them are available for free

Page 9: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 9

Page 10: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 10

Using a Desktop

• Desktop: provides GUI appearance, software applications, and other resources that you use– Works hand-in-hand with a Window Manager– Enables you to create and place icons in your

screen’s workspace• Is customizable

– Most popular UNIX/Linux desktops: • GNOME

• KDE

Page 11: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 11

Using GNOME

• GNOME: GNU Network Object Model Environment– Product of the GNU Project– Desktop environment that is used along with a

Window Manager– Installed by default in Fedora and Red Hat

Enterprise Linux– Very user-friendly– Very popular– Compatible with X11– Compatible with a variety of Window Managers

Page 12: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 12

Using KDE

• KDE is an alternative to GNOME– Can be installed along with GNOME– Is more popular internationally than GNOME– Offers a broader range of drag-and-drop capabilities– Intended to provide UNIX/Linux users with a

graphical point-and-click experience– Compatible with X11– Compatible with a variety of Window Managers

Page 13: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 13

Starting the X Window System

• startx is intended for a computer or login session that does not automatically boot into X Window

Page 14: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 14

Configuring Linux to Automatically Start the X Window System

• To change runlevel, modify /etc/inittab– From: id:3:initdefault:– To: id:5:initdefault:

Page 15: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 15

Interacting with the X Window System Using GNOME

Page 16: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 16

Interacting with Windows

Page 17: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 17

More About the Window Menu Button

• Options of Window Menu button (when clicked):– Minimize (and Maximize/Unmaximize)– On Top– Move– Resize– Close– Always on Visible Workspace/Only on This

Workspace– Move to Workspace Right (and Left)– Move to Another Workspace

Page 18: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 18

Interacting with the Panel

• The Panel in Fedora and Red Hat Enterprise Linux appears, by default, at the top of the desktop– Another Panel is at the bottom– Top panel:

– Bottom panel:• On left side: button to hide all windows

• On right side: access to the four workspaces

Page 19: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 19

Interacting with the Panel (continued)

• Applications menu:– Submenus and programs that you can open

• Places menu has options to:– Open your home folder– Access items on desktop– Open storage devices and file systems on computer– Create a CD/DVD– Access network servers and resources– Perform a fast search for a specific item– Access recently opened documents

Page 20: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 20

Interacting with the Panel (continued)

• System menu options:– A submenu for setting preferences on the computer– A submenu for administering the computer– An option to obtain help– An option to find out about GNOME– An option to learn more about the OS– An option to lock screen– An option to log off– An option to suspend the computer’s operation– An option to shut down the computer

Page 21: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 21

Using Nautilus

• Nautilus: GNOME’s file management tool

• Used to:– View files and folders– Create new folders– Delete and move files and folders– Copy and paste files and folders– Configure permissions– Open a file or start a program– Access the Internet– Set a bookmark (to a file, folder, or Internet location)

Page 22: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 22

Using Nautilus (continued)

Page 23: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 23

Configuring the Desktop

• You can customize many aspects of the X Window System

• Examples:– Change background image– Specify screensaver– Configure items on the Panel– Add applets to the Panel– Add a new Panel to desktop

Page 24: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 24

Changing the Background

• Background: desktop area behind all windows and icons– Is customizable:

• Can change color

• Can specify a wallpaper to be used as background

– To change background in GNOME:• Right-click a blank area in the desktop

• Select Change Desktop Background

Page 25: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 25

Changing the Screensaver

• Use screensaver to deter unauthorized use of a server or workstation by requiring a password

• In Fedora and Red Hat Enterprise Linux:– Click System menu– Point to Preferences– Click Screensaver

• In SUSE:– Click Computer menu– Click Control Center– Click Screensaver

Page 26: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 26

Configuring the Panel

• GNOME Panel can be configured in several ways:– Add an icon or applet to the Panel– Rearrange placement of icons– Add programs you have written– Move the Panel to another location:

• Move pointer to a blank area of Panel

• Drag and drop Panel to another location

Page 27: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 27

Configuring the Panel (continued)

Page 28: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 28

Adding a Menu to the Panel

• You can add a menu within the Applications or Computer menu directly to the Panel

• Example:– Put the Office menu on the Panel

Page 29: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 29

Adding a New Panel

• General steps:– Right-click an open space on an existing Panel– Click New Panel– If you want to change the location of the new Panel,

click and drag it to the new location– Right-click the new Panel, click Add to Panel, and

select what you want to place on the Panel

Page 30: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 30

Shutting Down from the GNOME Desktop

• Proper shutdown is important to ensure that all files are closed and to protect file system integrity

• In Fedora and Red Hat Enterprise Linux:– Click System menu– Click Shut Down

• In SUSE:– Click Computer menu– Click Log Out– Click Shut down

Page 31: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 31

Interacting with the X Window System Using KDE

Page 32: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 32

Interacting with Konqueror

Page 33: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 33

Interacting with Kicker

• Kicker is similar to the Panel in GNOME

• Can be customized in several ways:– Relocate it, add/remove applets, add panels, etc.

Page 34: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 34

Configuring the KDE Desktop

• You can customize the KDE desktop in X Window

• Examples:– Change the desktop background– Specify a screensaver– Create additional desktops

• Beyond the four set up by default

Page 35: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 35

Changing the Background in KDE

• Right-click unused desktop area Configure Desktop

Page 36: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 36

Configuring the Screensaver

• KDE offers a huge selection of screensavers

• Use Configure – KDesktop utility to choose a screensaver– For security reasons, set it up so that it requires a

password after it starts

• Use Screen Saver option to set up your screensaver preferences

Page 37: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 37

Configuring Additional Desktops

• KDE is set by default to enable four desktops– Accessible through Kicker– Configurable to fewer than four or up to 20 desktops

• Use the Configure – KDesktop utility

• Then, click Multiple Desktops in side pane

Page 38: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 38

Shutting Down from the KDE Desktop

• Proper shutdown of KDE desktop is important– Ensures all of your open program and system files

are properly closed and kept intact

• General steps:– Click the K Menu– Click Log Out– Click End Current Session or Turn Off Computer

Page 39: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 39

OpenOffice.org and Open Source Software

• OpenOffice.org: suite of office productivity software– Open source software– Included in many UNIX/Linux distributions– Also available for Windows and Mac OS systems– Program elements include:

• Writer• Calc• Impress• Draw• Math• Base

Page 40: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 40

Summary

• X Window System runs on UNIX/Linux systems– Window Manager: layer with which user interacts– Use startx to start the X Window System

• Modify /etc/inittab to have it start automatically

• GNOME environment is a popular desktop– The Panel provides access to menus, icons,

Workspace Switcher, and other utilities– Nautilus is a graphical application for managing

directories/files and for navigating the file system– Desktop background and other elements are

customizable

Page 41: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 41

Summary (continued)

• KDE is another popular desktop– Similar in functionality to GNOME

– Major components include:• Icons

• Kicker

– Similar to the Panel in GNOME

• Windows

• Desktop area on which to work

– Konqueror: application for managing files/folders

– Desktop background, screensaver, and other features are customizable

Page 42: A Guide to Unix Using Linux Fourth Edition Chapter 11 The X Window System

A Guide to Unix Using Linux, Fourth Edition 42

Command Summary