📄 155-157.html
字号:
<HTML>
<HEAD>
<TITLE>Linux Configuration and Installation:Installing and Configuring XFree86</TITLE>
<META NAME="ROBOTS" CONTENT="NOINDEX, NOFOLLOW">
<SCRIPT>
<!--
function displayWindow(url, width, height) {
var Win = window.open(url,"displayWindow",'width=' + width +
',height=' + height + ',resizable=1,scrollbars=yes');
}
//-->
</SCRIPT>
</HEAD>
-->
<!--ISBN=1558285660//-->
<!--TITLE=Linux Configuration and Installation//-->
<!--AUTHOR=Patrick Volkerding//-->
<!--AUTHOR=Kevin Reichard//-->
<!--AUTHOR=Eric Foster//-->
<!--PUBLISHER=IDG Books Worldwide, Inc.//-->
<!--IMPRINT=M & T Books//-->
<!--CHAPTER=3//-->
<!--PAGES=155-157//-->
<!--UNASSIGNED1//-->
<!--UNASSIGNED2//-->
<CENTER>
<TABLE BORDER>
<TR>
<TD><A HREF="153-155.html">Previous</A></TD>
<TD><A HREF="../ewtoc.html">Table of Contents</A></TD>
<TD><A HREF="157-161.html">Next</A></TD>
</TR>
</TABLE>
</CENTER>
<P><BR></P>
<H4 ALIGN="LEFT"><A NAME="Heading28"></A><FONT COLOR="#000077">Copying and Pasting between xterm Windows</FONT></H4>
<P>One of the best benefits of <B>xterm</B> over the console terminal is that you can copy and paste text between <B>xterm</B> windows. This is very handy if you edit documents. You can view one document in one <B>xterm</B> window and edit another in a different <B>xterm</B> window, copying and pasting between the two.</P>
<P><B>Xterm</B> is highly configurable, but in the default configuration, you select text by holding down the left mouse button and dragging over the text you want to select. Double-clicking over a word selects just that word. Triple-clicking anywhere in a line selects the entire line.</P>
<P>To paste, press the middle mouse button. The text will be inserted, just as if you typed it.</P>
<P><B>Xterm</B> just presents a shell window. Inside the <B>xterm</B> window, you run text-based shell programs, few of which know anything about the mouse and selecting text. Therefore, you have to ensure that the program you run within the <B>xterm</B> window is ready for the pasted text. In the <B>elvis</B> text editor, for example, you should enter input mode by typing <B>i</B> in command mode.</P>
<BLOCKQUOTE>
<P><FONT SIZE="-1"><HR><B>NOTE: </B><B>Elvis</B> does not support middle-mouse button pastes, which is very annoying. To paste in <B>elvis</B>, you must hold down the <B>Shift</B> key while you press the middle mouse button.
<P>Our fix is to use a different <B>vi</B> clone that comes with Linux, called <B>vim</B>. <B>Vim</B> fully supports mouse pasting in <B>xterm</B> windows without the hassle of <B>elvis</B>.<HR></FONT>
</BLOCKQUOTE>
</P>
<P><FONT SIZE="+1"><B>Other Shell Window Programs</B></FONT></P>
<P>In addition to the ubiquitous <B>xterm</B>, Linux ships with a few other shell programs, including <B>color_xterm</B>, <B>rxvt</B>, and <B>shelltool</B>.</P>
<P>If you want a shell with color, use <B>color_xterm</B>. This program acts just like <B>xterm</B>, but it presents a lot more color. For example, when you make a directory listing with <B>ls</B>, <B>color_xterm</B> presents directories in one color and ordinary files in another.</P>
<P>The <B>rxvt</B> program is very similar to <B>xterm</B>. Many claim that <B>rxvt</B> uses a smaller memory footprint than <B>xterm</B>, but we find its quirks aren’t worth the difference (particularly with Linux shared libraries, which reduce <B>xterm</B>’s memory footprint to a reasonable level).</P>
<P>If you use Open Look applications on a Sun system at work, you will find yourself right at home with <B>shelltool</B>, found in <B>/usr/openwin/bin</B>.</P>
<P>You must have loaded the Open Look applications when you installed Linux to have this program. We recommend you install these programs, which also include the <B>olwm</B> and <B>olvwm</B> window managers.</P>
<P>All in all, we tend to only use <B>xterm</B> instead of other shell window programs, because <B>xterm</B> remains constant on all the UNIX systems we use, at home and at work.</P>
<H3><A NAME="Heading29"></A><FONT COLOR="#000077">Starting X Automatically at Boot-Up and Creating an X Login Screen</FONT></H3>
<P>Up to now, we’ve been running <B>startx</B> to begin an X session. You still need to login at the console and start X yourself (or use the automatic method we describe later). In addition to this method, there’s a way to set up an X login screen, using XDM. <I>XDM</I> stands for the X Display Manager; it is a means to control an X session. As such, XDM is generally much nicer to the user, as it automatically starts the X server and presents a graphical login window, like the one shown in Figure 3.7.</P>
<P><A NAME="Fig7"></A><A HREF="javascript:displayWindow('images/03-07.jpg',483,268 )"><IMG SRC="images/03-07t.jpg"></A>
<BR><A HREF="javascript:displayWindow('images/03-07.jpg',483,268)"><FONT COLOR="#000077"><B>Figure 3.7</B></FONT></A> A graphical login window.</P>
<P>The X Display Manager is run from a program called <B>xdm</B>. While <B>xdm</B> takes a little getting used to, we like it better than the <B>startx/xinit</B> that we’ve been running so far. This is because <B>start</B>x (which runs <B>xinit</B>) requires you to login to a text screen and then start up X (via <B>startx</B>). <B>Xdm</B> allows you to log directly into an X session.</P>
<P><B>Xdm</B> also allows one program to control your workstation’s console and a number of X terminals. If you’re interested in this, look in Appendix A for books that cover <B>xdm</B>.</P>
<P>To set up <B>xdm</B>, you need to edit at least one system file, a key file used when booting Linux; this is a serious endeavor. <I>Always</I> back up any system file before you edit it.</P><P><BR></P>
<CENTER>
<TABLE BORDER>
<TR>
<TD><A HREF="153-155.html">Previous</A></TD>
<TD><A HREF="../ewtoc.html">Table of Contents</A></TD>
<TD><A HREF="157-161.html">Next</A></TD>
</TR>
</TABLE>
</CENTER>
</td>
</tr>
</table>
<!-- begin footer information -->
</body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -