Mercurial > emacs
annotate doc/emacs/frames.texi @ 112098:40af77a50adc
Merge changes from emacs-23 branch
author | Chong Yidong <cyd@stupidchicken.com> |
---|---|
date | Sun, 02 Jan 2011 15:28:40 -0500 |
parents | bcc7c00e9ef4 f1e03f250c47 |
children | 417b1e4d63cd |
rev | line source |
---|---|
84242 | 1 @c This is part of the Emacs manual. |
2 @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 1999, 2000, | |
109262
51ddcf320fe4
Untabify doc/emacs/*.texi files.
Glenn Morris <rgm@gnu.org>
parents:
107526
diff
changeset
|
3 @c 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009, 2010 |
51ddcf320fe4
Untabify doc/emacs/*.texi files.
Glenn Morris <rgm@gnu.org>
parents:
107526
diff
changeset
|
4 @c Free Software Foundation, Inc. |
84242 | 5 @c See file emacs.texi for copying conditions. |
6 @node Frames, International, Windows, Top | |
7 @chapter Frames and Graphical Displays | |
8 @cindex frames | |
9 | |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
10 When using a graphical display, you can create multiple system-level |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
11 ``windows'' in a single Emacs session. We refer to these system-level |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
12 windows as @dfn{frames}. A frame initially contains a single Emacs |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
13 window; however, you can subdivide this Emacs window into smaller |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
14 windows, all fitting into the same frame. Each frame normally |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
15 contains its own echo area and minibuffer. |
84242 | 16 |
17 To avoid confusion, we reserve the word ``window'' for the | |
18 subdivisions that Emacs implements, and never use it to refer to a | |
19 frame. | |
20 | |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
21 Any editing you do in one frame affects the other frames. For |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
22 instance, if you put text in the kill ring in one frame, you can yank |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
23 it in another frame. If you exit Emacs through @kbd{C-x C-c} in one |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
24 frame, it terminates all the frames. To delete just one frame, use |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
25 @kbd{C-x 5 0} (that is zero, not @kbd{o}). |
84242 | 26 |
27 Emacs compiled for MS-DOS emulates some windowing functionality, | |
28 so that you can use many of the features described in this chapter. | |
29 @iftex | |
30 @xref{MS-DOS Mouse,,,emacs-xtra,Specialized Emacs Features}. | |
31 @end iftex | |
32 @ifnottex | |
33 @xref{MS-DOS Mouse}. | |
34 @end ifnottex | |
35 | |
36 @menu | |
37 * Cut and Paste:: Mouse commands for cut and paste. | |
38 * Mouse References:: Using the mouse to select an item from a list. | |
39 * Menu Mouse Clicks:: Mouse clicks that bring up menus. | |
40 * Mode Line Mouse:: Mouse clicks on the mode line. | |
41 * Creating Frames:: Creating additional Emacs frames with various contents. | |
42 * Frame Commands:: Iconifying, deleting, and switching frames. | |
107521
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
43 * Fonts:: Changing the frame font. |
84242 | 44 * Speedbar:: How to make and use a speedbar frame. |
45 * Multiple Displays:: How one Emacs job can talk to several displays. | |
46 * Special Buffer Frames:: You can make certain buffers have their own frames. | |
47 * Frame Parameters:: Changing the colors and other modes of frames. | |
109262
51ddcf320fe4
Untabify doc/emacs/*.texi files.
Glenn Morris <rgm@gnu.org>
parents:
107526
diff
changeset
|
48 * Scroll Bars:: How to enable and disable scroll bars; how to use them. |
84242 | 49 * Wheeled Mice:: Using mouse wheels for scrolling. |
50 * Drag and Drop:: Using drag and drop to open files and insert text. | |
109262
51ddcf320fe4
Untabify doc/emacs/*.texi files.
Glenn Morris <rgm@gnu.org>
parents:
107526
diff
changeset
|
51 * Menu Bars:: Enabling and disabling the menu bar. |
84242 | 52 * Tool Bars:: Enabling and disabling the tool bar. |
53 * Dialog Boxes:: Controlling use of dialog boxes. | |
54 * Tooltips:: Displaying information at the current mouse position. | |
107324
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
55 * Mouse Avoidance:: Preventing the mouse pointer from obscuring text. |
84242 | 56 * Non-Window Terminals:: Multiple frames on terminals that show only one. |
57 * Text-Only Mouse:: Using the mouse in text-only terminals. | |
58 @end menu | |
59 | |
60 @node Cut and Paste | |
112077
2f24255ca500
Fix bug #7702 with docs of selections wrt MS-Windows.
Eli Zaretskii <eliz@gnu.org>
parents:
109262
diff
changeset
|
61 @section Cutting and Pasting on Graphical Displays |
84242 | 62 |
112077
2f24255ca500
Fix bug #7702 with docs of selections wrt MS-Windows.
Eli Zaretskii <eliz@gnu.org>
parents:
109262
diff
changeset
|
63 This section describes commands for selecting a region, cutting, and |
2f24255ca500
Fix bug #7702 with docs of selections wrt MS-Windows.
Eli Zaretskii <eliz@gnu.org>
parents:
109262
diff
changeset
|
64 pasting using the mouse. |
84242 | 65 |
66 @menu | |
67 * Mouse Commands:: Moving, cutting, and pasting, with the mouse. | |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
68 * Word and Line Mouse:: Mouse commands for selecting whole words or lines. |
84242 | 69 * Cut/Paste Other App:: Transfering text between Emacs and other apps. |
70 * Secondary Selection:: Cutting without altering point and mark. | |
71 * Clipboard:: Using the clipboard for selections. | |
72 @end menu | |
73 | |
74 @node Mouse Commands | |
75 @subsection Mouse Commands for Editing | |
76 @cindex mouse buttons (what they do) | |
77 | |
78 @kindex Mouse-1 | |
79 @kindex Mouse-2 | |
80 @kindex Mouse-3 | |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
81 @table @kbd |
84242 | 82 @item Mouse-1 |
83 Move point to where you click (@code{mouse-set-point}). | |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
84 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
85 @item Drag-Mouse-1 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
86 Activate the region around the text selected by dragging, and copy it |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
87 to the kill ring (@code{mouse-set-region}). |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
88 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
89 @item Mouse-2 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
90 Yank the last killed text at the click position |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
91 (@code{mouse-yank-at-click}). |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
92 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
93 @item Mouse-3 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
94 If the region is active, move the nearer end of the region to the |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
95 click position; otherwise, set mark at the current value of point and |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
96 point at the click position. Save the resulting region in the kill |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
97 ring; on a second click, kill it (@code{mouse-save-then-kill}). |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
98 @end table |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
99 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
100 @findex mouse-set-point |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
101 The most basic mouse command is @code{mouse-set-point}, which is |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
102 called by clicking with the left mouse button, @kbd{Mouse-1}, in the |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
103 text area of a window. This moves point to the position where you |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
104 clicked. |
84242 | 105 |
106 @vindex x-mouse-click-focus-ignore-position | |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
107 Normally, Emacs does not distinguish between ordinary mouse clicks |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
108 and clicks that select a frame. When you click on a frame to select |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
109 it, that also changes the selected window and cursor position |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
110 according to the mouse click position. On the X window system, you |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
111 can change this behavior by setting the variable |
84242 | 112 @code{x-mouse-click-focus-ignore-position} to @code{t}. Then the |
113 first click selects the frame, but does not affect the selected window | |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
114 or cursor position. If you click again in the same place, that click |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
115 will be in the selected frame, so it will change the window or cursor |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
116 position. |
84242 | 117 |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
118 @findex mouse-set-region |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
119 @vindex mouse-drag-copy-region |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
120 Holding down @kbd{Mouse-1} and ``dragging'' the mouse over a stretch |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
121 of text activates the region around that text |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
122 (@code{mouse-set-region}). @xref{Mark}. Emacs places the mark where |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
123 you started holding down the mouse button, and point where you release |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
124 it. In addition, the region is copied into the kill ring (@pxref{Kill |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
125 Ring}). If you don't want Emacs to copy the region, change the |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
126 variable @code{mouse-drag-copy-region} to @code{nil}. |
84242 | 127 |
128 @vindex mouse-scroll-min-lines | |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
129 If you move the mouse off the top or bottom of the window while |
84242 | 130 dragging, the window scrolls at a steady rate until you move the mouse |
131 back into the window. This way, you can select regions that don't fit | |
132 entirely on the screen. The number of lines scrolled per step depends | |
133 on how far away from the window edge the mouse has gone; the variable | |
134 @code{mouse-scroll-min-lines} specifies a minimum step size. | |
135 | |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
136 @findex mouse-yank-at-click |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
137 @vindex mouse-yank-at-point |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
138 Clicking with the middle mouse button, @kbd{Mouse-2}, moves point to |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
139 the position where you clicked and performs a yank |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
140 (@code{mouse-yank-at-click}). @xref{Yanking}. If you change the |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
141 variable @code{mouse-yank-at-point} to a non-@code{nil} value, |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
142 @kbd{Mouse-2} does not move point. Then it does not matter where you |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
143 click, or even which of the frame's windows you click on; the yank |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
144 occurs at the existing point. This variable also affects yanking the |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
145 primary and secondary selections (@pxref{Cut/Paste Other App}). |
84242 | 146 |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
147 @findex mouse-save-then-kill |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
148 Clicking with the right mouse button, @kbd{Mouse-3}, runs the |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
149 command @code{mouse-save-then-kill}. This performs several actions |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
150 depending on where you click and the status of the region: |
84242 | 151 |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
152 @itemize @bullet |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
153 @item |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
154 If no region is active, clicking @kbd{Mouse-3} activates the region, |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
155 placing the mark where point was and point at the clicked position. |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
156 In addition, the text in the region is copied to the kill ring. |
84242 | 157 |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
158 @item |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
159 If a region is active, clicking @kbd{Mouse-3} adjusts the nearer end |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
160 of the region by moving it to the clicked position. The adjusted |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
161 region's text is copied to the kill ring; if the text in the original |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
162 region was already on the kill ring, it replaces it there. |
84242 | 163 |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
164 @item |
84242 | 165 If you originally specified the region using a double or triple |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
166 @kbd{Mouse-1}, so that the region is defined to consist of entire |
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
167 words or lines, then adjusting the region with @kbd{Mouse-3} also |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
168 proceeds by entire words or lines. |
84242 | 169 |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
170 @item |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
171 If you use @kbd{Mouse-3} a second time consecutively, at the same |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
172 place, that kills the region already selected. Thus, the simplest way |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
173 to kill text with the mouse is to click @kbd{Mouse-1} at one end, then |
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
174 click @kbd{Mouse-3} twice at the other end. To copy the text into the |
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
175 kill ring without deleting it from the buffer, press @kbd{Mouse-3} |
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
176 just once---or just drag across the text with @kbd{Mouse-1}. Then you |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
177 can copy it elsewhere by yanking it. |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
178 @end itemize |
84242 | 179 |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
180 Whenever you set the region using any of the mouse commands |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
181 described above, the mark will be deactivated by any subsequent |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
182 unshifted cursor motion command, in addition to the usual ways of |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
183 deactivating the mark. @xref{Shift Selection}. While the region |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
184 remains active, typing @key{Backspace} or @key{Delete} deletes the |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
185 text in that region and deactivates the mark; this behavior follows a |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
186 convention established by other graphical programs, and it does |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
187 @emph{not} apply when you set the region any other way, including |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
188 shift-selection (@pxref{Shift Selection}). |
84242 | 189 |
190 @cindex Delete Selection mode | |
191 @cindex mode, Delete Selection | |
192 @findex delete-selection-mode | |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
193 Many graphical applications also follow the convention that |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
194 insertion while text is selected deletes the selected text. You can |
99668
b8704eb1a8e9
(Mouse Commands): Move most of the description of Delete Selection
Chong Yidong <cyd@stupidchicken.com>
parents:
99040
diff
changeset
|
195 make Emacs behave this way by enabling Delete Selection mode. |
b8704eb1a8e9
(Mouse Commands): Move most of the description of Delete Selection
Chong Yidong <cyd@stupidchicken.com>
parents:
99040
diff
changeset
|
196 @xref{Using Region}. |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
197 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
198 @node Word and Line Mouse |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
199 @subsection Mouse Commands for Words and Lines |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
200 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
201 These variants of @kbd{Mouse-1} select entire words or lines at a |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
202 time. Emacs activates the region around the selected text, which is |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
203 also copied to the kill ring. |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
204 |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
205 @table @kbd |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
206 @item Double-Mouse-1 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
207 Select the text around the word which you click on. |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
208 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
209 Double-clicking on a character with ``symbol'' syntax (such as |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
210 underscore, in C mode) selects the symbol surrounding that character. |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
211 Double-clicking on a character with open- or close-parenthesis syntax |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
212 selects the parenthetical grouping which that character starts or |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
213 ends. Double-clicking on a character with string-delimiter syntax |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
214 (such as a singlequote or doublequote in C) selects the string |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
215 constant (Emacs uses heuristics to figure out whether that character |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
216 is the beginning or the end of it). |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
217 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
218 @item Double-Drag-Mouse-1 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
219 Select the text you drag across, in the form of whole words. |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
220 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
221 @item Triple-Mouse-1 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
222 Select the line you click on. |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
223 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
224 @item Triple-Drag-Mouse-1 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
225 Select the text you drag across, in the form of whole lines. |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
226 @end table |
84242 | 227 |
228 @node Cut/Paste Other App | |
229 @subsection Cut and Paste with Other Window Applications | |
230 | |
231 @cindex X cutting and pasting | |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
232 @cindex X selection |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
233 @cindex primary selection |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
234 @cindex selection, primary |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
235 When running Emacs under the X window system, you can easily |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
236 transfer text between Emacs and other X applications using the |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
237 @dfn{primary selection} (also called the @dfn{X selection}). This is |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
238 @emph{not} the same thing as the @dfn{clipboard}, which is a separate |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
239 facility used on desktop environments such as Gnome, and on operating |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
240 systems such as Microsoft Windows (@pxref{Clipboard}). |
84242 | 241 |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
242 Under X, whenever you select some text in Emacs by dragging or |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
243 clicking the mouse (@pxref{Mouse Commands}), it is also saved in the |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
244 primary selection. You can then @dfn{paste} that text into any other |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
245 X application, usually by clicking @kbd{Mouse-2} in that application. |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
246 Unlike the Emacs kill ring (@pxref{Kill Ring}), the primary selection |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
247 has no ``memory'': each time you save something in the primary |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
248 selection, either in Emacs or in another X application, the previous |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
249 contents of the primary selection are lost. |
84242 | 250 |
112077
2f24255ca500
Fix bug #7702 with docs of selections wrt MS-Windows.
Eli Zaretskii <eliz@gnu.org>
parents:
109262
diff
changeset
|
251 @cindex MS-Windows, and primary selection |
2f24255ca500
Fix bug #7702 with docs of selections wrt MS-Windows.
Eli Zaretskii <eliz@gnu.org>
parents:
109262
diff
changeset
|
252 MS-Windows provides no primary selection, but Emacs emulates it |
112080
f1e03f250c47
Fix wording of changes in revno 100330.
Eli Zaretskii <eliz@gnu.org>
parents:
112077
diff
changeset
|
253 within a single Emacs session, by storing the selected text |
f1e03f250c47
Fix wording of changes in revno 100330.
Eli Zaretskii <eliz@gnu.org>
parents:
112077
diff
changeset
|
254 internally. Therefore, all the features and commands related to the |
f1e03f250c47
Fix wording of changes in revno 100330.
Eli Zaretskii <eliz@gnu.org>
parents:
112077
diff
changeset
|
255 primary selection work on Windows as they do on X, for cutting and |
f1e03f250c47
Fix wording of changes in revno 100330.
Eli Zaretskii <eliz@gnu.org>
parents:
112077
diff
changeset
|
256 pasting within the same session, but not across Emacs sessions or with |
f1e03f250c47
Fix wording of changes in revno 100330.
Eli Zaretskii <eliz@gnu.org>
parents:
112077
diff
changeset
|
257 other applications. |
112077
2f24255ca500
Fix bug #7702 with docs of selections wrt MS-Windows.
Eli Zaretskii <eliz@gnu.org>
parents:
109262
diff
changeset
|
258 |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
259 Whenever you kill some text using a command such as @kbd{C-w} |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
260 (@code{kill-region}), or copy it into the kill ring using a command |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
261 such as @kbd{M-w} (@code{kill-ring-save}), that text is also saved in |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
262 the primary selection. @xref{Killing}. |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
263 |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
264 @vindex select-active-regions |
106636
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
265 If you set the region using the keyboard---for instance, by typing |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
266 @kbd{C-@key{SPC}} and moving point away from the mark---the text in |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
267 the region is not normally saved to the primary selection. However, |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
268 if you change the variable @code{select-active-regions} to @code{t}, |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
269 the region is saved to the primary selection whenever you activate the |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
270 mark. Each change to the region also updates the primary selection. |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
271 |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
272 @vindex yank-pop-change-selection |
106636
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
273 If you change @code{yank-pop-change-selection} to @code{t}, rotating |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
274 the kill ring with @kbd{M-y} (@code{yank-pop}) also saves the new yank |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
275 to the primary selection (@pxref{Yanking}). |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
276 |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
277 @vindex save-interprogram-paste-before-kill |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
278 If you change @code{save-interprogram-paste-before-kill} to |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
279 @code{t}, each kill command first saves the existing selection onto |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
280 the kill ring. This prevents you from losing the existing selection, |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
281 at the risk of large memory consumption if other applications generate |
6c68929f170b
* emacs.texi (Top): Update node listing.
Chong Yidong <cyd@stupidchicken.com>
parents:
105118
diff
changeset
|
282 large selections. |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
283 |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
284 You can yank the primary selection into Emacs using the usual yank |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
285 commands, such as @kbd{C-y} (@code{yank}) and @kbd{Mouse-2} |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
286 (@code{mouse-yank-at-click}). These commands actually check the |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
287 primary selection before referring to the kill ring; if no primary |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
288 selection is available, the kill ring contents are used. To prevent |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
289 yank commands from accessing the primary selection, set the variable |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
290 @code{x-select-enable-primary} to @code{nil}. |
84242 | 291 |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
292 The standard coding system for the primary selection is |
86138
1e3c83a62c3d
(Cut/Paste Other App): Mention x-select-request-type.
Kenichi Handa <handa@m17n.org>
parents:
85393
diff
changeset
|
293 @code{compound-text-with-extensions}. You may find that the pasted |
1e3c83a62c3d
(Cut/Paste Other App): Mention x-select-request-type.
Kenichi Handa <handa@m17n.org>
parents:
85393
diff
changeset
|
294 text is not what you expected. In such a case, you can specify |
98757
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
295 another coding system for the selection by typing @kbd{C-x @key{RET} |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
296 x} or @kbd{C-x @key{RET} X}. Alternatively, you can request a |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
297 different data type by modifying the variable |
a0d8754b4079
(Mouse Commands, Cut/Paste Other App): Rewrite.
Chong Yidong <cyd@stupidchicken.com>
parents:
93354
diff
changeset
|
298 @code{x-select-request-type}. @xref{Communication Coding}. |
84242 | 299 |
300 @node Secondary Selection | |
301 @subsection Secondary Selection | |
302 @cindex secondary selection | |
303 | |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
304 In addition to the primary selection, the X Window System provides a |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
305 second similar facility known as the @dfn{secondary selection}. |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
306 Nowadays, few X applications make use of the secondary selection, but |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
307 you can access it using the following Emacs commands: |
84242 | 308 |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
309 @table @kbd |
84242 | 310 @findex mouse-set-secondary |
311 @kindex M-Drag-Mouse-1 | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
312 @item M-Drag-Mouse-1 |
84242 | 313 Set the secondary selection, with one end at the place where you press |
314 down the button, and the other end at the place where you release it | |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
315 (@code{mouse-set-secondary}). The selected text is highlighted, using |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
316 the @code{secondary-selection} face, as you drag. The window scrolls |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
317 automatically if you drag the mouse off the top or bottom of the |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
318 window, just like @code{mouse-set-region} (@pxref{Mouse Commands}). |
84242 | 319 |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
320 This command does not alter the kill ring. |
84242 | 321 |
322 @findex mouse-start-secondary | |
323 @kindex M-Mouse-1 | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
324 @item M-Mouse-1 |
84242 | 325 Set one endpoint for the @dfn{secondary selection} |
326 (@code{mouse-start-secondary}). | |
327 | |
328 @findex mouse-secondary-save-then-kill | |
329 @kindex M-Mouse-3 | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
330 @item M-Mouse-3 |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
331 Set the secondary selection, with one end at the position clicked and |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
332 the other at the position specified with @kbd{M-Mouse-1} |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
333 (@code{mouse-secondary-save-then-kill}). This also puts the selected |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
334 text in the kill ring. A second @kbd{M-Mouse-3} at the same place |
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
335 kills the secondary selection just made. |
84242 | 336 |
337 @findex mouse-yank-secondary | |
338 @kindex M-Mouse-2 | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
339 @item M-Mouse-2 |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
340 Insert the secondary selection where you click, placing point at the |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
341 end of the yanked text (@code{mouse-yank-secondary}). |
84242 | 342 @end table |
343 | |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
344 Double or triple clicking of @kbd{M-Mouse-1} operates on words and |
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
345 lines, much like @kbd{Mouse-1}. |
84242 | 346 |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
347 If @code{mouse-yank-at-point} is non-@code{nil}, @kbd{M-Mouse-2} yanks |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
348 at point. Then it does not matter precisely where you click, or even |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
349 which of the frame's windows you click on. @xref{Mouse Commands}. |
84242 | 350 |
351 @node Clipboard | |
352 @subsection Using the Clipboard | |
353 @cindex clipboard | |
354 | |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
355 In desktop environments such as Gnome, and operating systems such as |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
356 Microsoft Windows and Mac OS X, you can transfer data (usually text) |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
357 between different applications using the @dfn{clipboard}. The |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
358 clipboard is distinct from the primary selection and secondary |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
359 selection discussed earlier. You can access the clipboard through the |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
360 @samp{Edit} menu of the menu bar (@pxref{Menu Bar}). |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
361 |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
362 @cindex cut |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
363 @findex clipboard-kill-region |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
364 The command @code{clipboard-kill-region}, which is bound to the |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
365 @code{Cut} menu item, kills the region and saves it in the clipboard. |
84242 | 366 |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
367 @cindex copy |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
368 @findex clipboard-kill-ring-save |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
369 The command @code{clipboard-kill-ring-save}, which is bound to the |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
370 @code{Copy} menu item, copies the region to the kill ring and saves it |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
371 in the clipboard. |
84242 | 372 |
99677
af10fef1a1dc
(Clipboard): Note that paste is bound to clipboard-yank.
Chong Yidong <cyd@stupidchicken.com>
parents:
99668
diff
changeset
|
373 @findex clipboard-yank |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
374 @cindex paste |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
375 The @code{Paste} menu item in the Edit menu yanks the contents of |
99677
af10fef1a1dc
(Clipboard): Note that paste is bound to clipboard-yank.
Chong Yidong <cyd@stupidchicken.com>
parents:
99668
diff
changeset
|
376 the clipboard at point (@code{clipboard-yank}). |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
377 |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
378 @vindex x-select-enable-clipboard |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
379 You can customize the variable @code{x-select-enable-clipboard} to |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
380 make the Emacs yank functions consult the clipboard before the primary |
84242 | 381 selection, and to make the kill functions to store in the clipboard as |
98854
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
382 well as the primary selection. Otherwise, these commands do not |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
383 access the clipboard at all. Using the clipboard is the default on |
3045af7ce2cb
(Cut/Paste Other App): Document yank-pop-change-selection.
Chong Yidong <cyd@stupidchicken.com>
parents:
98757
diff
changeset
|
384 MS-Windows and Mac OS, but not on other systems. |
84242 | 385 |
386 @node Mouse References | |
387 @section Following References with the Mouse | |
388 @kindex Mouse-1 @r{(selection)} | |
389 @kindex Mouse-2 @r{(selection)} | |
390 | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
391 @vindex mouse-highlight |
98941
3f36bcd67163
(Mouse References): Copyedits.
Chong Yidong <cyd@stupidchicken.com>
parents:
98933
diff
changeset
|
392 Some Emacs buffers include @dfn{buttons}. A button is a piece of |
3f36bcd67163
(Mouse References): Copyedits.
Chong Yidong <cyd@stupidchicken.com>
parents:
98933
diff
changeset
|
393 text that performs some action when you activate it, such as following |
3f36bcd67163
(Mouse References): Copyedits.
Chong Yidong <cyd@stupidchicken.com>
parents:
98933
diff
changeset
|
394 a reference. Usually, a button's text is visually highlighted: it is |
3f36bcd67163
(Mouse References): Copyedits.
Chong Yidong <cyd@stupidchicken.com>
parents:
98933
diff
changeset
|
395 underlined, or a box is drawn around it. If you move the mouse over a |
3f36bcd67163
(Mouse References): Copyedits.
Chong Yidong <cyd@stupidchicken.com>
parents:
98933
diff
changeset
|
396 button, the shape of the mouse cursor changes and the button lights up |
3f36bcd67163
(Mouse References): Copyedits.
Chong Yidong <cyd@stupidchicken.com>
parents:
98933
diff
changeset
|
397 (if you change the variable @code{mouse-highlight} to @code{nil}, |
3f36bcd67163
(Mouse References): Copyedits.
Chong Yidong <cyd@stupidchicken.com>
parents:
98933
diff
changeset
|
398 Emacs disables this highlighting). |
84242 | 399 |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
400 You can activate a button by moving point to it and typing |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
401 @key{RET}, or by clicking either @kbd{Mouse-1} or @kbd{Mouse-2} on the |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
402 button. For example, typing @key{RET} or clicking on a file name in a |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
403 Dired buffer visits that file (@pxref{Dired}). Doing it on an error |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
404 message in the @samp{*Compilation*} buffer goes to the source code for |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
405 that error message (@pxref{Compilation}). Doing it on a completion in |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
406 the @samp{*Completions*} buffer chooses that completion |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
407 (@pxref{Completion}). |
84242 | 408 |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
409 Although clicking @kbd{Mouse-1} on a button usually activates that |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
410 button, if you hold the mouse button down for a short period of time |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
411 before releasing it (specifically, for more than 450 milliseconds), |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
412 then Emacs moves point where you clicked instead. This behavior |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
413 allows you to use the mouse to move point over a button without |
98941
3f36bcd67163
(Mouse References): Copyedits.
Chong Yidong <cyd@stupidchicken.com>
parents:
98933
diff
changeset
|
414 following it. Dragging---moving the mouse while it is held down---has |
3f36bcd67163
(Mouse References): Copyedits.
Chong Yidong <cyd@stupidchicken.com>
parents:
98933
diff
changeset
|
415 its usual behavior of setting the region, even if you drag from or |
3f36bcd67163
(Mouse References): Copyedits.
Chong Yidong <cyd@stupidchicken.com>
parents:
98933
diff
changeset
|
416 onto a button. |
84242 | 417 |
418 @vindex mouse-1-click-in-non-selected-windows | |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
419 Normally, clicking @kbd{Mouse-1} on a button activates the button |
98941
3f36bcd67163
(Mouse References): Copyedits.
Chong Yidong <cyd@stupidchicken.com>
parents:
98933
diff
changeset
|
420 even if it is in a nonselected window. If you change the variable |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
421 @code{mouse-1-click-in-non-selected-windows} to @code{nil}, clicking |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
422 @kbd{Mouse-1} on a button in an un-selected window moves point to the |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
423 clicked position and selects that window, without activating the |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
424 button. |
84242 | 425 |
426 @vindex mouse-1-click-follows-link | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
427 In Emacs versions before 22, only @kbd{Mouse-2} activates buttons |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
428 and @kbd{Mouse-1} always sets point. If you prefer this older |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
429 behavior, set the variable @code{mouse-1-click-follows-link} to |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
430 @code{nil}. This variable also lets you choose various other |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
431 alternatives for following links with the mouse. Type @kbd{C-h v |
84242 | 432 mouse-1-click-follows-link @key{RET}} for more details. |
433 | |
434 @node Menu Mouse Clicks | |
435 @section Mouse Clicks for Menus | |
436 | |
437 Several mouse clicks with the @key{CTRL} and @key{SHIFT} modifiers | |
438 bring up menus. | |
439 | |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
440 @table @kbd |
84242 | 441 @item C-Mouse-1 |
442 @kindex C-Mouse-1 | |
443 This menu is for selecting a buffer. | |
444 | |
445 The MSB (``mouse select buffer'') global minor mode makes this | |
446 menu smarter and more customizable. @xref{Buffer Menus}. | |
447 | |
448 @item C-Mouse-2 | |
449 @kindex C-Mouse-2 | |
450 This menu is for specifying faces and other text properties | |
451 for editing formatted text. @xref{Formatted Text}. | |
452 | |
453 @item C-Mouse-3 | |
454 @kindex C-Mouse-3 | |
455 This menu is mode-specific. For most modes if Menu-bar mode is on, | |
456 this menu has the same items as all the mode-specific menu-bar menus | |
457 put together. Some modes may specify a different menu for this | |
458 button.@footnote{Some systems use @kbd{Mouse-3} for a mode-specific | |
459 menu. We took a survey of users, and found they preferred to keep | |
460 @kbd{Mouse-3} for selecting and killing regions. Hence the decision | |
461 to use @kbd{C-Mouse-3} for this menu. To use @kbd{Mouse-3} instead, | |
462 do @code{(global-set-key [mouse-3] 'mouse-popup-menubar-stuff)}.} If | |
463 Menu-bar mode is off, this menu contains all the items which would be | |
464 present in the menu bar---not just the mode-specific ones---so that | |
465 you can access them without having to display the menu bar. | |
466 | |
467 @item S-Mouse-1 | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
468 This menu is for changing the default face within the window's buffer. |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
469 @xref{Temporary Face Changes}. |
84242 | 470 @end table |
471 | |
472 @node Mode Line Mouse | |
473 @section Mode Line Mouse Commands | |
474 @cindex mode line, mouse | |
475 @cindex mouse on mode line | |
476 | |
477 You can use mouse clicks on window mode lines to select and manipulate | |
478 windows. | |
479 | |
85393
9040ce19727b
(Mode Line Mouse): Mention minor mode names.
Glenn Morris <rgm@gnu.org>
parents:
84242
diff
changeset
|
480 Some areas of the mode line, such as the buffer name, and major and minor |
9040ce19727b
(Mode Line Mouse): Mention minor mode names.
Glenn Morris <rgm@gnu.org>
parents:
84242
diff
changeset
|
481 mode names, have their own special mouse bindings. These areas are |
84242 | 482 highlighted when you hold the mouse over them, and information about |
483 the special bindings will be displayed (@pxref{Tooltips}). This | |
484 section's commands do not apply in those areas. | |
485 | |
486 @table @kbd | |
487 @item Mouse-1 | |
488 @kindex Mouse-1 @r{(mode line)} | |
489 @kbd{Mouse-1} on a mode line selects the window it belongs to. By | |
490 dragging @kbd{Mouse-1} on the mode line, you can move it, thus | |
491 changing the height of the windows above and below. Changing heights | |
492 with the mouse in this way never deletes windows, it just refuses to | |
493 make any window smaller than the minimum height. | |
494 | |
495 @item Mouse-2 | |
496 @kindex Mouse-2 @r{(mode line)} | |
497 @kbd{Mouse-2} on a mode line expands that window to fill its frame. | |
498 | |
499 @item Mouse-3 | |
500 @kindex Mouse-3 @r{(mode line)} | |
501 @kbd{Mouse-3} on a mode line deletes the window it belongs to. If the | |
502 frame has only one window, it buries the current buffer instead, and | |
503 switches to another buffer. | |
504 | |
505 @item C-Mouse-2 | |
506 @kindex C-mouse-2 @r{(mode line)} | |
507 @kbd{C-Mouse-2} on a mode line splits the window above | |
508 horizontally, above the place in the mode line where you click. | |
509 @end table | |
510 | |
511 @kindex C-Mouse-2 @r{(scroll bar)} | |
512 @kindex Mouse-1 @r{(scroll bar)} | |
513 Using @kbd{Mouse-1} on the divider between two side-by-side mode | |
514 lines, you can move the vertical boundary left or right. Using | |
515 @kbd{C-Mouse-2} on a scroll bar splits the corresponding window | |
516 vertically. @xref{Split Window}. | |
517 | |
518 @node Creating Frames | |
519 @section Creating Frames | |
520 @cindex creating frames | |
521 | |
522 @kindex C-x 5 | |
99834
296816e24605
(Frame Commands): Mention "minimize" terminology.
Chong Yidong <cyd@stupidchicken.com>
parents:
99677
diff
changeset
|
523 The prefix key @kbd{C-x 5} is analogous to @kbd{C-x 4}, with |
296816e24605
(Frame Commands): Mention "minimize" terminology.
Chong Yidong <cyd@stupidchicken.com>
parents:
99677
diff
changeset
|
524 parallel subcommands. The difference is that @kbd{C-x 5} commands |
296816e24605
(Frame Commands): Mention "minimize" terminology.
Chong Yidong <cyd@stupidchicken.com>
parents:
99677
diff
changeset
|
525 create a new frame rather than just a new window in the selected frame |
296816e24605
(Frame Commands): Mention "minimize" terminology.
Chong Yidong <cyd@stupidchicken.com>
parents:
99677
diff
changeset
|
526 (@pxref{Pop Up Window}). If an existing visible or iconified |
296816e24605
(Frame Commands): Mention "minimize" terminology.
Chong Yidong <cyd@stupidchicken.com>
parents:
99677
diff
changeset
|
527 (``minimized'') frame already displays the requested material, these |
296816e24605
(Frame Commands): Mention "minimize" terminology.
Chong Yidong <cyd@stupidchicken.com>
parents:
99677
diff
changeset
|
528 commands use the existing frame, after raising or deiconifying |
296816e24605
(Frame Commands): Mention "minimize" terminology.
Chong Yidong <cyd@stupidchicken.com>
parents:
99677
diff
changeset
|
529 (``un-minimizing'') as necessary. |
84242 | 530 |
531 The various @kbd{C-x 5} commands differ in how they find or create the | |
532 buffer to select: | |
533 | |
534 @table @kbd | |
535 @item C-x 5 2 | |
536 @kindex C-x 5 2 | |
537 @findex make-frame-command | |
538 Create a new frame (@code{make-frame-command}). | |
539 @item C-x 5 b @var{bufname} @key{RET} | |
540 Select buffer @var{bufname} in another frame. This runs | |
541 @code{switch-to-buffer-other-frame}. | |
542 @item C-x 5 f @var{filename} @key{RET} | |
543 Visit file @var{filename} and select its buffer in another frame. This | |
544 runs @code{find-file-other-frame}. @xref{Visiting}. | |
545 @item C-x 5 d @var{directory} @key{RET} | |
546 Select a Dired buffer for directory @var{directory} in another frame. | |
547 This runs @code{dired-other-frame}. @xref{Dired}. | |
548 @item C-x 5 m | |
549 Start composing a mail message in another frame. This runs | |
550 @code{mail-other-frame}. It is the other-frame variant of @kbd{C-x m}. | |
551 @xref{Sending Mail}. | |
552 @item C-x 5 . | |
553 Find a tag in the current tag table in another frame. This runs | |
554 @code{find-tag-other-frame}, the multiple-frame variant of @kbd{M-.}. | |
555 @xref{Tags}. | |
556 @item C-x 5 r @var{filename} @key{RET} | |
557 @kindex C-x 5 r | |
558 @findex find-file-read-only-other-frame | |
559 Visit file @var{filename} read-only, and select its buffer in another | |
560 frame. This runs @code{find-file-read-only-other-frame}. | |
561 @xref{Visiting}. | |
562 @end table | |
563 | |
564 @cindex default-frame-alist | |
565 @cindex initial-frame-alist | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
566 @cindex face customization, in init file |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
567 @cindex color customization, in init file |
84242 | 568 You can control the appearance of new frames you create by setting the |
569 frame parameters in @code{default-frame-alist}. You can use the | |
570 variable @code{initial-frame-alist} to specify parameters that affect | |
571 only the initial frame. @xref{Initial Parameters,,, elisp, The Emacs | |
572 Lisp Reference Manual}, for more information. | |
573 | |
574 @cindex font (default) | |
107521
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
575 Here is an example of using @code{default-frame-alist} to specify |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
576 the default foreground color and font: |
84242 | 577 |
578 @example | |
579 (add-to-list 'default-frame-alist '(font . "10x20")) | |
580 (add-to-list 'default-frame-alist '(foreground-color . "blue")) | |
581 @end example | |
582 | |
583 @noindent | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
584 By putting such customizations in your init file, you can control the |
107521
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
585 appearance of all the frames Emacs creates, including the initial one |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
586 (@pxref{Init File}). @xref{Fonts}, for other ways to set the default |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
587 font. |
84242 | 588 |
589 @node Frame Commands | |
590 @section Frame Commands | |
591 | |
592 The following commands let you create, delete and operate on frames: | |
593 | |
594 @table @kbd | |
595 @item C-z | |
596 @kindex C-z @r{(X windows)} | |
105118
e73a8ec76227
* frames.texi (Frame Commands): C-z is now bound to suspend-frame.
Chong Yidong <cyd@stupidchicken.com>
parents:
104019
diff
changeset
|
597 @findex suspend-frame |
e73a8ec76227
* frames.texi (Frame Commands): C-z is now bound to suspend-frame.
Chong Yidong <cyd@stupidchicken.com>
parents:
104019
diff
changeset
|
598 Minimize (or ``iconify) the selected Emacs frame |
e73a8ec76227
* frames.texi (Frame Commands): C-z is now bound to suspend-frame.
Chong Yidong <cyd@stupidchicken.com>
parents:
104019
diff
changeset
|
599 (@code{suspend-frame}). @xref{Exiting}. |
84242 | 600 |
601 @item C-x 5 0 | |
602 @kindex C-x 5 0 | |
603 @findex delete-frame | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
604 Delete the selected frame (@code{delete-frame}). This is not allowed |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
605 if there is only one frame. |
84242 | 606 |
607 @item C-x 5 o | |
608 @kindex C-x 5 o | |
609 @findex other-frame | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
610 Select another frame, raise it, and warp the mouse to it. If you |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
611 repeat this command, it cycles through all the frames on your |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
612 terminal. |
84242 | 613 |
614 @item C-x 5 1 | |
615 @kindex C-x 5 1 | |
616 @findex delete-other-frames | |
617 Delete all frames except the selected one. | |
618 @end table | |
619 | |
107205
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
620 The @kbd{C-x 5 0} (@code{delete-frame}) command will never delete |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
621 the last frame, to prevent you from losing the ability to interact |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
622 with the Emacs process. Note that when Emacs is run as a daemon |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
623 (@pxref{Emacs Server}), there is always a ``virtual frame'' that |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
624 remains after all the ordinary, interactive frames are deleted. In |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
625 this case, @kbd{C-x 5 0} can delete the last interactive frame; you |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
626 can use @command{emacsclient} to reconnect to the Emacs session. |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
627 |
84242 | 628 @vindex focus-follows-mouse |
107205
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
629 On X, you may have to tell Emacs how the system (or the window |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
630 manager) handles focus-switching between windows, in order for the |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
631 command @kbd{C-x 5 o} (@code{other-frame}) to work properly. |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
632 Unfortunately, there is no way for Emacs to detect this automatically, |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
633 so you should set the variable @code{focus-follows-mouse}. If simply |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
634 moving the mouse onto a window selects it and gives it focus, the |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
635 variable should be @code{t}; if you have to click on the window to |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
636 select it, the variable should be @code{nil}. The default is |
e91df3663a07
* frames.texi (Frame Commands): Note that the last ordinary frame can
Chong Yidong <cyd@stupidchicken.com>
parents:
106815
diff
changeset
|
637 @code{t}. |
84242 | 638 |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
639 The window manager that is part of MS-Windows always gives focus to |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
640 a frame that raises, so this variable has no effect in the native |
84242 | 641 MS-Windows build of Emacs. |
642 | |
107521
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
643 @node Fonts |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
644 @section Fonts |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
645 @cindex fonts |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
646 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
647 By default, Emacs displays text in X using a 12-point monospace |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
648 font. There are several different ways to specify a different font: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
649 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
650 @itemize |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
651 @item |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
652 Click on @samp{Set Default Font} in the @samp{Options} menu. To save |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
653 this for future sessions, click on @samp{Save Options} in the |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
654 @samp{Options} menu. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
655 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
656 @item |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
657 Add a line to your init file (@pxref{Init File}), modifying the |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
658 variable @code{default-frame-alist} to specify the @code{font} |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
659 parameter (@pxref{Creating Frames}), like this: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
660 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
661 @smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
662 (add-to-list 'default-frame-alist '(font . "DejaVu Sans Mono-12")) |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
663 @end smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
664 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
665 @cindex X defaults file |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
666 @cindex X resources file |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
667 @item |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
668 Add an @samp{emacs.font} X resource setting to your X resource file, |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
669 like this: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
670 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
671 @smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
672 emacs.font: DejaVu Sans Mono-12 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
673 @end smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
674 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
675 @noindent |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
676 You must restart X, or use the @command{xrdb} command, for the X |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
677 resources file to take effect. @xref{Resources}. When specifying a |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
678 font in your X resources file, you should not quote it. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
679 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
680 @item |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
681 If you are running Emacs on the GNOME desktop, you can tell Emacs to |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
682 use the default system font by setting the variable |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
683 @code{font-use-system-font} to @code{t} (the default is @code{nil}). |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
684 For this to work, Emacs must be compiled with Gconf support; this is |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
685 done automatically if the libraries are present at compile time. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
686 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
687 @item |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
688 Use the command line option @samp{-fn} (or @samp{--font}). @xref{Font |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
689 X}. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
690 @end itemize |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
691 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
692 @cindex fontconfig |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
693 On X, there are four different ways to express a ``font name''. The |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
694 first is to use a @dfn{Fontconfig pattern}. Fontconfig patterns have |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
695 the following form: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
696 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
697 @smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
698 @var{fontname}[-@var{fontsize}][:@var{name1}=@var{values1}][:@var{name2}=@var{values2}]... |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
699 @end smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
700 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
701 @noindent |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
702 Within this format, any of the elements in braces may be omitted. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
703 Here, @var{fontname} is the @dfn{family name} of the font, such as |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
704 @samp{Monospace} or @samp{DejaVu Serif}; @var{fontsize} is the |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
705 @dfn{point size} of the font (one @dfn{printer's point} is about 1/72 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
706 of an inch); and the @samp{@var{name}=@var{values}} entries specify |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
707 settings such as the slant and weight of the font. Each @var{values} |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
708 may be a single value, or a list of values separated by commas. In |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
709 addition, some property values are valid with only one kind of |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
710 property name, in which case the @samp{@var{name}=} part may be |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
711 omitted. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
712 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
713 Here is a list of common font properties: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
714 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
715 @table @samp |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
716 @item slant |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
717 One of @samp{italic}, @samp{oblique} or @samp{roman}. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
718 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
719 @item weight |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
720 One of @samp{light}, @samp{medium}, @samp{demibold}, @samp{bold} or |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
721 @samp{black}. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
722 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
723 @item style |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
724 Some fonts define special styles which are a combination of slant and |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
725 weight. For instance, @samp{Dejavu Sans} defines the @samp{book} |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
726 style, which overrides the slant and weight properties. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
727 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
728 @item width |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
729 One of @samp{condensed}, @samp{normal}, or @samp{expanded}. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
730 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
731 @item spacing |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
732 One of @samp{monospace}, @samp{proportional}, @samp{dual-width}, or |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
733 @samp{charcell}. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
734 @end table |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
735 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
736 @noindent |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
737 Here are some examples of Fontconfig patterns: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
738 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
739 @smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
740 Monospace |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
741 Monospace-12 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
742 Monospace-12:bold |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
743 DejaVu Sans Mono:bold:italic |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
744 Monospace-12:weight=bold:slant=italic |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
745 @end smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
746 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
747 See the Fontconfig manual for a more detailed description of |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
748 Fontconfig patterns. This manual is located in the file |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
749 @file{fontconfig-user.html}, distributed with Fontconfig. It is also |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
750 available online at @url{http://fontconfig.org/fontconfig-user.html}. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
751 In particular, that manual describes additional font properties that |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
752 influence how the font is hinted, antialiased, or scaled. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
753 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
754 The second way to specify a font is to use a @dfn{GTK font |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
755 description}. These have the syntax |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
756 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
757 @smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
758 @var{fontname} [@var{properties}] [@var{fontsize}] |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
759 @end smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
760 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
761 @noindent |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
762 where @var{fontname} is the family name, @var{properties} is a list of |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
763 property values separated by spaces, and @var{fontsize} is the point |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
764 size. The properties that you may specify are as follows: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
765 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
766 @table @samp |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
767 @item style |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
768 One of @samp{roman}, @samp{italic} or @samp{oblique}. If omitted, the |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
769 @samp{roman} style is used. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
770 @item weight |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
771 One of @samp{medium}, @samp{ultra-light}, @samp{light}, |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
772 @samp{semi-bold}, or @samp{bold}. If omitted, @samp{medium} weight is |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
773 used. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
774 @end table |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
775 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
776 @noindent |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
777 Here are some examples of GTK font descriptions: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
778 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
779 @smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
780 Monospace 12 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
781 Monospace Bold Italic 12 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
782 @end smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
783 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
784 @cindex XLFD |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
785 @cindex X Logical Font Description |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
786 The third way to specify a font is to use an @dfn{XLFD} (@dfn{X |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
787 Logical Font Description}). This is the traditional method for |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
788 specifying fonts under X. Each XLFD consists of fourteen words or |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
789 numbers, separated by dashes, like this: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
790 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
791 @smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
792 -misc-fixed-medium-r-semicondensed--13-*-*-*-c-60-iso8859-1 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
793 @end smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
794 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
795 @noindent |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
796 A wildcard character (@samp{*}) in an XLFD matches any sequence of |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
797 characters (including none), and @samp{?} matches any single |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
798 character. However, matching is implementation-dependent, and can be |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
799 inaccurate when wildcards match dashes in a long name. For reliable |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
800 results, supply all 14 dashes and use wildcards only within a field. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
801 Case is insignificant in an XLFD. The syntax for an XLFD is as |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
802 follows: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
803 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
804 @smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
805 -@var{maker}-@var{family}-@var{weight}-@var{slant}-@var{widthtype}-@var{style}@dots{} |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
806 @dots{}-@var{pixels}-@var{height}-@var{horiz}-@var{vert}-@var{spacing}-@var{width}-@var{registry}-@var{encoding} |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
807 @end smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
808 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
809 @noindent |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
810 The entries have the following meanings: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
811 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
812 @table @var |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
813 @item maker |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
814 The name of the font manufacturer. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
815 @item family |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
816 The name of the font family (e.g. @samp{courier}). |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
817 @item weight |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
818 The font weight---normally either @samp{bold}, @samp{medium} or |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
819 @samp{light}. Some font names support other values. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
820 @item slant |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
821 The font slant---normally @samp{r} (roman), @samp{i} (italic), |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
822 @samp{o} (oblique), @samp{ri} (reverse italic), or @samp{ot} (other). |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
823 Some font names support other values. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
824 @item widthtype |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
825 The font width---normally @samp{condensed}, @samp{extended}, |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
826 @samp{semicondensed} or @samp{normal} (some font names support other |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
827 values). |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
828 @item style |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
829 An optional additional style name. Usually it is empty---most long |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
830 font names have two hyphens in a row at this point. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
831 @item pixels |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
832 The font height, in pixels. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
833 @item height |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
834 The font height on the screen, measured in tenths of a printer's |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
835 point. This is the point size of the font, times ten. For a given |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
836 vertical resolution, @var{height} and @var{pixels} are proportional; |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
837 therefore, it is common to specify just one of them and use @samp{*} |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
838 for the other. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
839 @item horiz |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
840 The horizontal resolution, in pixels per inch, of the screen for which |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
841 the font is intended. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
842 @item vert |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
843 The vertical resolution, in pixels per inch, of the screen for which |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
844 the font is intended. Normally the resolution of the fonts on your |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
845 system is the right value for your screen; therefore, you normally |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
846 specify @samp{*} for this and @var{horiz}. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
847 @item spacing |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
848 This is @samp{m} (monospace), @samp{p} (proportional) or @samp{c} |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
849 (character cell). |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
850 @item width |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
851 The average character width, in pixels, multiplied by ten. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
852 @item registry |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
853 @itemx encoding |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
854 The X font character set that the font depicts. (X font character |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
855 sets are not the same as Emacs character sets, but they are similar.) |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
856 You can use the @command{xfontsel} program to check which choices you |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
857 have. Normally you should use @samp{iso8859} for @var{registry} and |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
858 @samp{1} for @var{encoding}. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
859 @end table |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
860 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
861 The fourth and final method of specifying a font is to use a ``font |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
862 nickname''. Certain fonts have shorter nicknames, which you can use |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
863 instead of a normal font specification. For instance, @samp{6x13} is |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
864 equivalent to |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
865 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
866 @smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
867 -misc-fixed-medium-r-semicondensed--13-*-*-*-c-60-iso8859-1 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
868 @end smallexample |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
869 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
870 @cindex client-side fonts |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
871 @cindex server-side fonts |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
872 On X, Emacs recognizes two types of fonts: @dfn{client-side} fonts, |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
873 which are provided by the Xft and Fontconfig libraries, and |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
874 @dfn{server-side} fonts, which are provided by the X server itself. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
875 Most client-side fonts support advanced font features such as |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
876 antialiasing and subpixel hinting, while server-side fonts do not. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
877 Fontconfig and GTK patterns match only client-side fonts. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
878 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
879 @cindex listing system fonts |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
880 You will probably want to use a fixed-width default font---that is, |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
881 a font in which all characters have the same width. For Xft and |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
882 Fontconfig fonts, you can use the @command{fc-list} command to list |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
883 the available fixed-width fonts, like this: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
884 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
885 @example |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
886 fc-list :spacing=mono fc-list :spacing=charcell |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
887 @end example |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
888 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
889 @noindent |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
890 For server-side X fonts, you can use the @command{xlsfonts} program to |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
891 list the available fixed-width fonts, like this: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
892 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
893 @example |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
894 xlsfonts -fn '*x*' | egrep "^[0-9]+x[0-9]+" |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
895 xlsfonts -fn '*-*-*-*-*-*-*-*-*-*-*-m*' |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
896 xlsfonts -fn '*-*-*-*-*-*-*-*-*-*-*-c*' |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
897 @end example |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
898 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
899 @noindent |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
900 Any font with @samp{m} or @samp{c} in the @var{spacing} field of the |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
901 XLFD is a fixed-width font. To see what a particular font looks like, |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
902 use the @command{xfd} command. For example: |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
903 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
904 @example |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
905 xfd -fn 6x13 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
906 @end example |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
907 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
908 @noindent |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
909 displays the entire font @samp{6x13}. |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
910 |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
911 While running Emacs, you can also set the font of a specific kind of |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
912 text (@pxref{Faces}), or a particular frame (@pxref{Frame |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
913 Parameters}). |
54f3a4d055ee
Document font-use-system-font.
Chong Yidong <cyd@stupidchicken.com>
parents:
107324
diff
changeset
|
914 |
84242 | 915 @node Speedbar |
916 @section Speedbar Frames | |
917 @cindex speedbar | |
918 | |
919 @cindex attached frame (of speedbar) | |
920 The @dfn{speedbar} is a special frame for conveniently navigating in | |
921 or operating on another frame. The speedbar, when it exists, is | |
922 always associated with a specific frame, called its @dfn{attached | |
923 frame}; all speedbar operations act on that frame. | |
924 | |
925 Type @kbd{M-x speedbar} to create the speedbar and associate it with | |
926 the current frame. To dismiss the speedbar, type @kbd{M-x speedbar} | |
927 again, or select the speedbar and type @kbd{q}. (You can also delete | |
928 the speedbar frame like any other Emacs frame.) If you wish to | |
929 associate the speedbar with a different frame, dismiss it and call | |
930 @kbd{M-x speedbar} from that frame. | |
931 | |
932 The speedbar can operate in various modes. Its default mode is | |
933 @dfn{File Display} mode, which shows the files in the current | |
934 directory of the selected window of the attached frame, one file per | |
935 line. Clicking on a file name visits that file in the selected window | |
936 of the attached frame, and clicking on a directory name shows that | |
937 directory in the speedbar (@pxref{Mouse References}). Each line also | |
938 has a box, @samp{[+]} or @samp{<+>}, that you can click on to | |
939 @dfn{expand} the contents of that item. Expanding a directory adds | |
940 the contents of that directory to the speedbar display, underneath the | |
941 directory's own line. Expanding an ordinary file adds a list of the | |
942 tags in that file to the speedbar display; you can click on a tag name | |
943 to jump to that tag in the selected window of the attached frame. | |
944 When a file or directory is expanded, the @samp{[+]} changes to | |
945 @samp{[-]}; you can click on that box to @dfn{contract} the item, | |
946 hiding its contents. | |
947 | |
948 You navigate through the speedbar using the keyboard, too. Typing | |
949 @kbd{RET} while point is on a line in the speedbar is equivalent to | |
950 clicking the item on the current line, and @kbd{SPC} expands or | |
951 contracts the item. @kbd{U} displays the parent directory of the | |
952 current directory. To copy, delete, or rename the file on the current | |
953 line, type @kbd{C}, @kbd{D}, and @kbd{R} respectively. To create a | |
954 new directory, type @kbd{M}. | |
955 | |
956 Another general-purpose speedbar mode is @dfn{Buffer Display} mode; | |
957 in this mode, the speedbar displays a list of Emacs buffers. To | |
958 switch to this mode, type @kbd{b} in the speedbar. To return to File | |
959 Display mode, type @kbd{f}. You can also change the display mode by | |
960 clicking @kbd{mouse-3} anywhere in the speedbar window (or | |
961 @kbd{mouse-1} on the mode-line) and selecting @samp{Displays} in the | |
962 pop-up menu. | |
963 | |
964 Some major modes, including Rmail mode, Info, and GUD, have | |
965 specialized ways of putting useful items into the speedbar for you to | |
966 select. For example, in Rmail mode, the speedbar shows a list of Rmail | |
967 files, and lets you move the current message to another Rmail file by | |
968 clicking on its @samp{<M>} box. | |
969 | |
970 For more details on using and programming the speedbar, @xref{Top, | |
971 Speedbar,,speedbar, Speedbar Manual}. | |
972 | |
973 @node Multiple Displays | |
974 @section Multiple Displays | |
975 @cindex multiple displays | |
976 | |
977 A single Emacs can talk to more than one X display. Initially, Emacs | |
978 uses just one display---the one specified with the @env{DISPLAY} | |
979 environment variable or with the @samp{--display} option (@pxref{Initial | |
980 Options}). To connect to another display, use the command | |
981 @code{make-frame-on-display}: | |
982 | |
983 @findex make-frame-on-display | |
984 @table @kbd | |
985 @item M-x make-frame-on-display @key{RET} @var{display} @key{RET} | |
986 Create a new frame on display @var{display}. | |
987 @end table | |
988 | |
989 A single X server can handle more than one screen. When you open | |
990 frames on two screens belonging to one server, Emacs knows they share a | |
991 single keyboard, and it treats all the commands arriving from these | |
992 screens as a single stream of input. | |
993 | |
994 When you open frames on different X servers, Emacs makes a separate | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
995 input stream for each server. Each server also has its own selected |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
996 frame. The commands you enter with a particular X server apply to |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
997 that server's selected frame. |
84242 | 998 |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
999 It is even possible to use this feature to let two or more users |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1000 type simultaneously on the two displays, within the same Emacs job. |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1001 In practice, however, the different users can easily interfere with |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1002 each others' edits if they are not careful. |
84242 | 1003 |
1004 @node Special Buffer Frames | |
1005 @section Special Buffer Frames | |
1006 | |
1007 @vindex special-display-buffer-names | |
1008 You can make certain chosen buffers, which Emacs normally displays | |
1009 in ``another window,'' appear in special frames of their own. To do | |
1010 this, set the variable @code{special-display-buffer-names} to a list | |
1011 of buffer names; any buffer whose name is in that list automatically | |
1012 gets a special frame, when an Emacs command wants to display it ``in | |
1013 another window.'' | |
1014 | |
1015 For example, if you set the variable this way, | |
1016 | |
1017 @example | |
1018 (setq special-display-buffer-names | |
1019 '("*Completions*" "*grep*" "*tex-shell*")) | |
1020 @end example | |
1021 | |
1022 @noindent | |
1023 then completion lists, @code{grep} output and the @TeX{} mode shell | |
1024 buffer get individual frames of their own. These frames, and the | |
1025 windows in them, are never automatically split or reused for any other | |
1026 buffers. They continue to show the buffers they were created for, | |
1027 unless you alter them by hand. Killing the special buffer deletes its | |
1028 frame automatically. | |
1029 | |
1030 @vindex special-display-regexps | |
1031 More generally, you can set @code{special-display-regexps} to a list | |
1032 of regular expressions; then a buffer gets its own frame if its name | |
1033 matches any of those regular expressions. (Once again, this applies only | |
1034 to buffers that normally get displayed for you in ``another window.'') | |
1035 | |
1036 @vindex special-display-frame-alist | |
1037 The variable @code{special-display-frame-alist} specifies the frame | |
1038 parameters for these frames. It has a default value, so you don't need | |
1039 to set it. | |
1040 | |
1041 For those who know Lisp, an element of | |
1042 @code{special-display-buffer-names} or @code{special-display-regexps} | |
1043 can also be a list. Then the first element is the buffer name or | |
1044 regular expression; the rest of the list specifies how to create the | |
1045 frame. It can be an association list specifying frame parameter | |
1046 values; these values take precedence over parameter values specified | |
1047 in @code{special-display-frame-alist}. If you specify the symbol | |
1048 @code{same-window} as a ``frame parameter'' in this list, with a | |
1049 non-@code{nil} value, that means to use the selected window if | |
1050 possible. If you use the symbol @code{same-frame} as a ``frame | |
1051 parameter'' in this list, with a non-@code{nil} value, that means to | |
1052 use the selected frame if possible. | |
1053 | |
1054 Alternatively, the value can have this form: | |
1055 | |
1056 @example | |
1057 (@var{function} @var{args}...) | |
1058 @end example | |
1059 | |
1060 @noindent | |
1061 where @var{function} is a symbol. Then the frame is constructed by | |
1062 calling @var{function}; its first argument is the buffer, and its | |
1063 remaining arguments are @var{args}. | |
1064 | |
1065 An analogous feature lets you specify buffers which should be | |
1066 displayed in the selected window. @xref{Force Same Window}. The | |
1067 same-window feature takes precedence over the special-frame feature; | |
1068 therefore, if you add a buffer name to | |
1069 @code{special-display-buffer-names} and it has no effect, check to see | |
1070 whether that feature is also in use for the same buffer name. | |
1071 | |
1072 @node Frame Parameters | |
1073 @section Setting Frame Parameters | |
1074 @cindex Auto-Raise mode | |
1075 @cindex Auto-Lower mode | |
1076 | |
1077 These commands are available for controlling the window management | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1078 behavior of the selected frame: |
84242 | 1079 |
1080 @table @kbd | |
1081 @findex auto-raise-mode | |
1082 @item M-x auto-raise-mode | |
1083 Toggle whether or not the selected frame should auto-raise. Auto-raise | |
1084 means that every time you move the mouse onto the frame, it raises the | |
1085 frame. | |
1086 | |
1087 Some window managers also implement auto-raise. If you enable | |
1088 auto-raise for Emacs frames in your window manager, it will work, but | |
1089 it is beyond Emacs' control, so @code{auto-raise-mode} has no effect | |
1090 on it. | |
1091 | |
1092 @findex auto-lower-mode | |
1093 @item M-x auto-lower-mode | |
1094 Toggle whether or not the selected frame should auto-lower. | |
1095 Auto-lower means that every time you move the mouse off the frame, | |
1096 the frame moves to the bottom of the stack on the screen. | |
1097 | |
1098 The command @code{auto-lower-mode} has no effect on auto-lower | |
1099 implemented by the window manager. To control that, you must use the | |
1100 appropriate window manager features. | |
1101 @end table | |
1102 | |
1103 In Emacs versions that use an X toolkit, the color-setting and | |
1104 font-setting functions don't affect menus and the menu bar, since they | |
1105 are displayed by their own widget classes. To change the appearance of | |
1106 the menus and menu bar, you must use X resources (@pxref{Resources}). | |
1107 @xref{Colors}, regarding colors. @xref{Font X}, regarding choice of | |
1108 font. | |
1109 | |
1110 Colors, fonts, and other attributes of the frame's display can also | |
1111 be customized by setting frame parameters in the variable | |
1112 @code{default-frame-alist} (@pxref{Creating Frames}). For a detailed | |
1113 description of frame parameters and customization, see @ref{Frame | |
1114 Parameters,,, elisp, The Emacs Lisp Reference Manual}. | |
1115 | |
1116 @node Scroll Bars | |
1117 @section Scroll Bars | |
1118 @cindex Scroll Bar mode | |
1119 @cindex mode, Scroll Bar | |
1120 | |
1121 On graphical displays, Emacs normally makes a @dfn{scroll bar} at | |
98918
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1122 the left of each Emacs window, running the height of the |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1123 window.@footnote{Placing it at the left is usually more useful with |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1124 overlapping frames with text starting at the left margin.} |
84242 | 1125 |
98918
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1126 When Emacs is compiled with GTK+ support on the X window system, or |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1127 in operating systems such as Microsoft Windows or Mac OS, you can use |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1128 the scroll bar as you do in other graphical applications. If you |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
1129 click @kbd{Mouse-1} on the scroll bar's up and down buttons, that |
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
1130 scrolls the window by one line at a time. Clicking @kbd{Mouse-1} |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1131 above or below the scroll bar's inner box scrolls the window by nearly |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1132 the entire height of the window, like @kbd{M-v} and @kbd{C-v} |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1133 respectively (@pxref{Moving Point}). Dragging the inner box with |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
1134 @kbd{Mouse-1} scrolls the window continuously. |
84242 | 1135 |
98918
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1136 If Emacs is compiled without GTK+ support on the X window system, |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1137 the scroll bar behaves differently. The scroll bar's inner box is |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1138 drawn to represent the portion of the buffer currently displayed, with |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1139 the entire height of the scroll bar representing the entire length of |
99040
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
1140 the buffer. @kbd{Mouse-1} anywhere on the scroll bar scrolls forward |
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
1141 like @kbd{C-v}, and @kbd{Mouse-3} scrolls backward like @kbd{M-v}. |
b9877df5d1a8
Use @kbd instead of @key for mouse commands throughout.
Chong Yidong <cyd@stupidchicken.com>
parents:
98941
diff
changeset
|
1142 Clicking @kbd{Mouse-2} in the scroll bar lets you move or drag the |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1143 inner box up and down. |
84242 | 1144 |
1145 You can also click @kbd{C-Mouse-2} in the scroll bar to split a | |
1146 window vertically. The split occurs on the line where you click. | |
1147 | |
1148 @findex scroll-bar-mode | |
1149 @vindex scroll-bar-mode | |
98903
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1150 You can toggle the use of the scroll bar with the command @kbd{M-x |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1151 scroll-bar-mode}. With a prefix argument, this command turns use of |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1152 scroll bars on if and only if the argument is positive. This command |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1153 applies to all frames, including frames yet to be created. Customize |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1154 the variable @code{scroll-bar-mode} to control the use of scroll bars |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1155 at startup. You can use it to specify that they are placed at the |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1156 right of windows if you prefer that. You have to set this variable |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1157 through the @samp{Customize} interface (@pxref{Easy Customization}), |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1158 or it will not work properly. You can also use the X resource |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1159 @samp{verticalScrollBars} to control the initial setting of Scroll Bar |
4ce02f730f61
Use @key throughout for mouse clicks.
Chong Yidong <cyd@stupidchicken.com>
parents:
98854
diff
changeset
|
1160 mode. @xref{Resources}. |
84242 | 1161 |
1162 @findex toggle-scroll-bar | |
1163 To enable or disable scroll bars for just the selected frame, use the | |
1164 command @kbd{M-x toggle-scroll-bar}. | |
1165 | |
1166 @vindex scroll-bar-width | |
1167 @cindex width of the scroll bar | |
1168 You can control the scroll bar width by changing the value of the | |
1169 @code{scroll-bar-width} frame parameter. | |
1170 | |
1171 @node Wheeled Mice | |
1172 @section Scrolling With ``Wheeled'' Mice | |
1173 | |
1174 @cindex mouse wheel | |
1175 @cindex wheel, mouse | |
1176 @findex mouse-wheel-mode | |
1177 @cindex Mouse Wheel minor mode | |
1178 @cindex mode, Mouse Wheel | |
1179 Some mice have a ``wheel'' instead of a third button. You can | |
1180 usually click the wheel to act as either @kbd{Mouse-2} or | |
1181 @kbd{Mouse-3}, depending on the setup. You can also use the wheel to | |
1182 scroll windows instead of using the scroll bar or keyboard commands. | |
1183 Mouse wheel support only works if the system generates appropriate | |
1184 events; whenever possible, it is turned on by default. To toggle this | |
1185 feature, use @kbd{M-x mouse-wheel-mode}. | |
1186 | |
1187 @vindex mouse-wheel-follow-mouse | |
1188 @vindex mouse-wheel-scroll-amount | |
1189 @vindex mouse-wheel-progressive-speed | |
1190 The two variables @code{mouse-wheel-follow-mouse} and | |
1191 @code{mouse-wheel-scroll-amount} determine where and by how much | |
1192 buffers are scrolled. The variable | |
1193 @code{mouse-wheel-progressive-speed} determines whether the scroll | |
1194 speed is linked to how fast you move the wheel. | |
1195 | |
1196 @node Drag and Drop | |
1197 @section Drag and Drop | |
1198 @cindex drag and drop | |
1199 | |
1200 Emacs supports @dfn{drag and drop} using the mouse. For instance, | |
1201 dropping text onto an Emacs frame inserts the text where it is dropped. | |
1202 Dropping a file onto an Emacs frame visits that file. As a special | |
1203 case, dropping the file on a Dired buffer moves or copies the file | |
1204 (according to the conventions of the application it came from) into the | |
1205 directory displayed in that buffer. | |
1206 | |
1207 @vindex dnd-open-file-other-window | |
1208 Dropping a file normally visits it in the window you drop it on. If | |
1209 you prefer to visit the file in a new window in such cases, customize | |
1210 the variable @code{dnd-open-file-other-window}. | |
1211 | |
1212 The XDND and Motif drag and drop protocols, and the old KDE 1.x | |
1213 protocol, are currently supported. | |
1214 | |
1215 @node Menu Bars | |
1216 @section Menu Bars | |
1217 @cindex Menu Bar mode | |
1218 @cindex mode, Menu Bar | |
1219 @findex menu-bar-mode | |
1220 @vindex menu-bar-mode | |
1221 | |
1222 You can turn display of menu bars on or off with @kbd{M-x | |
1223 menu-bar-mode} or by customizing the variable @code{menu-bar-mode}. | |
1224 With no argument, this command toggles Menu Bar mode, a | |
1225 minor mode. With an argument, the command turns Menu Bar mode on if the | |
1226 argument is positive, off if the argument is not positive. You can use | |
107526
af52c11fa4bd
bug #5736: Allow X-resource menuBar to take on/off as documented.
Jan D. <jan.h.d@swipnet.se>
parents:
107521
diff
changeset
|
1227 the X resource @samp{menuBar} to control the initial setting of |
84242 | 1228 Menu Bar mode. @xref{Resources}. |
1229 | |
1230 @kindex C-Mouse-3 @r{(when menu bar is disabled)} | |
1231 Expert users often turn off the menu bar, especially on text-only | |
1232 terminals, where this makes one additional line available for text. | |
1233 If the menu bar is off, you can still pop up a menu of its contents | |
1234 with @kbd{C-Mouse-3} on a display which supports pop-up menus. | |
1235 @xref{Menu Mouse Clicks}. | |
1236 | |
1237 @xref{Menu Bar}, for information on how to invoke commands with the | |
1238 menu bar. @xref{X Resources}, for how to customize the menu bar | |
1239 menus' visual appearance. | |
1240 | |
1241 @node Tool Bars | |
1242 @section Tool Bars | |
1243 @cindex Tool Bar mode | |
1244 @cindex mode, Tool Bar | |
1245 @cindex icons, toolbar | |
1246 | |
1247 The @dfn{tool bar} is a line (or lines) of icons at the top of the | |
1248 Emacs window, just below the menu bar. You can click on these icons | |
1249 with the mouse to do various jobs. | |
1250 | |
1251 The global tool bar contains general commands. Some major modes | |
1252 define their own tool bars to replace it. A few ``special'' modes | |
1253 that are not designed for ordinary editing remove some items from the | |
1254 global tool bar. | |
1255 | |
1256 Tool bars work only on a graphical display. The tool bar uses colored | |
1257 XPM icons if Emacs was built with XPM support. Otherwise, the tool | |
1258 bar uses monochrome icons (PBM or XBM format). | |
1259 | |
1260 @findex tool-bar-mode | |
1261 @vindex tool-bar-mode | |
1262 You can turn display of tool bars on or off with @kbd{M-x | |
1263 tool-bar-mode} or by customizing the option @code{tool-bar-mode}. | |
1264 | |
108025 | 1265 @vindex tool-bar-style |
1266 @cindex Tool Bar style | |
1267 When Emacs is compiled with GTK+ support, tool bars can have text and images. | |
1268 Customize @code{tool-bar-style} to select style. The default style is | |
1269 the same as for the desktop in the Gnome case. If no default is found, | |
1270 the tool bar uses just images. | |
1271 | |
109582
9c41ffa303a2
Add doc and NEWS for tool-bar-position.
Jan D. <jan.h.d@swipnet.se>
parents:
109302
diff
changeset
|
1272 @cindex Tool Bar position |
9c41ffa303a2
Add doc and NEWS for tool-bar-position.
Jan D. <jan.h.d@swipnet.se>
parents:
109302
diff
changeset
|
1273 You can also control the placement of the tool bar for the GTK+ tool bar |
9c41ffa303a2
Add doc and NEWS for tool-bar-position.
Jan D. <jan.h.d@swipnet.se>
parents:
109302
diff
changeset
|
1274 with the frame parameter @code{tool-bar-position}. |
9c41ffa303a2
Add doc and NEWS for tool-bar-position.
Jan D. <jan.h.d@swipnet.se>
parents:
109302
diff
changeset
|
1275 For a detailed description of frame parameters and customization, |
9c41ffa303a2
Add doc and NEWS for tool-bar-position.
Jan D. <jan.h.d@swipnet.se>
parents:
109302
diff
changeset
|
1276 see @ref{Frame Parameters,,, elisp, The Emacs Lisp Reference Manual}. |
9c41ffa303a2
Add doc and NEWS for tool-bar-position.
Jan D. <jan.h.d@swipnet.se>
parents:
109302
diff
changeset
|
1277 |
84242 | 1278 @node Dialog Boxes |
1279 @section Using Dialog Boxes | |
1280 @cindex dialog boxes | |
1281 | |
1282 @vindex use-dialog-box | |
1283 A dialog box is a special kind of menu for asking you a yes-or-no | |
1284 question or some other special question. Many Emacs commands use a | |
1285 dialog box to ask a yes-or-no question, if you used the mouse to | |
98918
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1286 invoke the command that led to the question. |
84242 | 1287 |
98918
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1288 To disable the use of dialog boxes, change the variable |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1289 @code{use-dialog-box} to @code{nil}. In that case, Emacs always |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1290 performs yes-or-no prompts using the echo area and keyboard input. |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1291 This variable also controls whether to use file selection windows (but |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1292 those are not supported on all platforms). |
84242 | 1293 |
1294 @vindex use-file-dialog | |
98933
c9f192c1da86
(Dialog Boxes): Add @cindex entries.
Eli Zaretskii <eliz@gnu.org>
parents:
98918
diff
changeset
|
1295 @cindex file selection dialog, how to disable |
84242 | 1296 A file selection window is a special kind of dialog box for asking |
1297 for file names. You can customize the variable @code{use-file-dialog} | |
1298 to suppress the use of file selection windows, even if you still want | |
1299 other kinds of dialogs. This variable has no effect if you have | |
1300 suppressed all dialog boxes with the variable @code{use-dialog-box}. | |
1301 | |
1302 @vindex x-gtk-show-hidden-files | |
98918
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1303 @vindex x-gtk-file-dialog-help-text |
98933
c9f192c1da86
(Dialog Boxes): Add @cindex entries.
Eli Zaretskii <eliz@gnu.org>
parents:
98918
diff
changeset
|
1304 @cindex hidden files, in GTK+ file chooser |
c9f192c1da86
(Dialog Boxes): Add @cindex entries.
Eli Zaretskii <eliz@gnu.org>
parents:
98918
diff
changeset
|
1305 @cindex help text, in GTK+ file chooser |
98918
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1306 When Emacs is compiled with GTK+ support, it uses the GTK+ ``file |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1307 chooser'' dialog. Emacs adds an additional toggle button to this |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1308 dialog, which you can use to enable or disable the display of hidden |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1309 files (files starting with a dot) in that dialog. If you want this |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1310 toggle to be activated by default, change the variable |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1311 @code{x-gtk-show-hidden-files} to @code{t}. In addition, Emacs adds |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1312 help text to the GTK+ file chooser dialog; to disable this help text, |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1313 change the variable @code{x-gtk-file-dialog-help-text} to @code{nil}. |
84242 | 1314 |
98933
c9f192c1da86
(Dialog Boxes): Add @cindex entries.
Eli Zaretskii <eliz@gnu.org>
parents:
98918
diff
changeset
|
1315 @vindex x-gtk-use-old-file-dialog |
98918
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1316 In GTK+ versions 2.4 through 2.10, you can choose to use an older |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1317 version of the GTK+ file dialog by setting the variable |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1318 @code{x-gtk-use-old-file-dialog} to a non-@code{nil} value. If Emacs |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1319 is built with a GTK+ version that has only one file dialog, this |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1320 variable has no effect. |
84242 | 1321 |
1322 @node Tooltips | |
1323 @section Tooltips | |
1324 @cindex tooltips | |
1325 | |
1326 @dfn{Tooltips} are small windows that display text information at the | |
1327 current mouse position. They activate when there is a pause in mouse | |
1328 movement. There are two types of tooltip: help tooltips and GUD | |
1329 tooltips. | |
1330 | |
1331 @dfn{Help tooltips} typically display over text---including the mode | |
1332 line---but are also available for other parts of the Emacs frame, such | |
1333 as the tool bar and menu items. | |
1334 | |
1335 @findex tooltip-mode | |
1336 You can toggle display of help tooltips (Tooltip mode) with the | |
1337 command @kbd{M-x tooltip-mode}. When Tooltip mode is disabled, the | |
1338 help text is displayed in the echo area instead. | |
1339 | |
1340 @dfn{GUD tooltips} show values of variables. They are useful when | |
1341 you are debugging a program. @xref{Debugger Operation}. | |
1342 | |
1343 @vindex tooltip-delay | |
1344 The variables @code{tooltip-delay} specifies how long Emacs should | |
1345 wait before displaying a tooltip. For additional customization | |
1346 options for displaying tooltips, use @kbd{M-x customize-group | |
1347 @key{RET} tooltip @key{RET}}. @xref{X Resources}, for information on | |
1348 customizing the windows that display tooltips. | |
1349 | |
1350 @node Mouse Avoidance | |
1351 @section Mouse Avoidance | |
1352 @cindex avoiding mouse in the way of your typing | |
1353 @cindex mouse avoidance | |
1354 | |
107324
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1355 On graphical terminals, the mouse pointer may obscure the text in |
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1356 the Emacs frame. Emacs provides two methods to avoid this problem. |
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1357 |
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1358 @vindex make-pointer-invisible |
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1359 Firstly, Emacs hides the mouse pointer each time you type a |
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1360 self-inserting character, if the pointer lies inside an Emacs frame; |
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1361 moving the mouse pointer makes it visible again. To disable this |
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1362 feature, set the variable @code{make-pointer-invisible} to @code{nil}. |
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1363 |
84242 | 1364 @vindex mouse-avoidance-mode |
107324
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1365 Secondly, you can use Mouse Avoidance mode, a minor mode, to keep |
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1366 the mouse pointer away from point. To use Mouse Avoidance mode, |
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1367 customize the variable @code{mouse-avoidance-mode}. You can set this |
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1368 to various values to move the mouse in several ways: |
84242 | 1369 |
1370 @table @code | |
1371 @item banish | |
1372 Move the mouse to the upper-right corner on any key-press; | |
1373 @item exile | |
1374 Move the mouse to the corner only if the cursor gets too close, | |
1375 and allow it to return once the cursor is out of the way; | |
1376 @item jump | |
1377 If the cursor gets too close to the mouse, displace the mouse | |
1378 a random distance & direction; | |
1379 @item animate | |
1380 As @code{jump}, but shows steps along the way for illusion of motion; | |
1381 @item cat-and-mouse | |
1382 The same as @code{animate}; | |
1383 @item proteus | |
1384 As @code{animate}, but changes the shape of the mouse pointer too. | |
1385 @end table | |
1386 | |
1387 @findex mouse-avoidance-mode | |
1388 You can also use the command @kbd{M-x mouse-avoidance-mode} to enable | |
107324
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1389 the mode. Whenever Mouse Avoidance mode moves the mouse, it also |
fc1fe31413a7
* frames.texi (Mouse Avoidance): Mention make-pointer-invisible.
Chong Yidong <cyd@stupidchicken.com>
parents:
107205
diff
changeset
|
1390 raises the frame. |
84242 | 1391 |
1392 @node Non-Window Terminals | |
1393 @section Non-Window Terminals | |
1394 @cindex non-window terminals | |
1395 @cindex single-frame terminals | |
1396 | |
1397 On a text-only terminal, Emacs can display only one Emacs frame at a | |
1398 time. However, you can still create multiple Emacs frames, and switch | |
1399 between them. Switching frames on these terminals is much like | |
1400 switching between different window configurations. | |
1401 | |
1402 Use @kbd{C-x 5 2} to create a new frame and switch to it; use @kbd{C-x | |
1403 5 o} to cycle through the existing frames; use @kbd{C-x 5 0} to delete | |
1404 the current frame. | |
1405 | |
1406 Each frame has a number to distinguish it. If your terminal can | |
1407 display only one frame at a time, the selected frame's number @var{n} | |
1408 appears near the beginning of the mode line, in the form | |
1409 @samp{F@var{n}}. | |
1410 | |
1411 @findex set-frame-name | |
1412 @findex select-frame-by-name | |
1413 @samp{F@var{n}} is in fact the frame's initial name. You can give | |
1414 frames more meaningful names if you wish, and you can select a frame | |
1415 by its name. Use the command @kbd{M-x set-frame-name @key{RET} | |
1416 @var{name} @key{RET}} to specify a new name for the selected frame, | |
1417 and use @kbd{M-x select-frame-by-name @key{RET} @var{name} @key{RET}} | |
1418 to select a frame according to its name. The name you specify appears | |
1419 in the mode line when the frame is selected. | |
1420 | |
1421 @node Text-Only Mouse | |
1422 @section Using a Mouse in Terminal Emulators | |
1423 @cindex mouse support | |
1424 @cindex terminal emulators, mouse support | |
1425 | |
98918
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1426 Some text-only terminals support mouse clicks in the terminal window. |
84242 | 1427 |
1428 @cindex xterm | |
1429 In a terminal emulator which is compatible with @code{xterm}, | |
1430 you can use @kbd{M-x xterm-mouse-mode} to give Emacs control over | |
1431 simple use of the mouse---basically, only non-modified single clicks | |
1432 are supported. The normal @code{xterm} mouse functionality for such | |
1433 clicks is still available by holding down the @kbd{SHIFT} key when you | |
1434 press the mouse button. Xterm Mouse mode is a global minor mode | |
1435 (@pxref{Minor Modes}). Repeating the command turns the mode off | |
1436 again. | |
1437 | |
103088
34ff9f0a5ff2
* frames.texi (Text-Only Mouse): Mention gpm-mouse-mode instead of
Chong Yidong <cyd@stupidchicken.com>
parents:
100974
diff
changeset
|
1438 @findex gpm-mouse-mode |
34ff9f0a5ff2
* frames.texi (Text-Only Mouse): Mention gpm-mouse-mode instead of
Chong Yidong <cyd@stupidchicken.com>
parents:
100974
diff
changeset
|
1439 In the console on GNU/Linux, you can use @kbd{M-x gpm-mouse-mode} to |
98918
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1440 enable terminal mouse support. You must have the gpm package |
709798863427
(Dialog Boxes): Clarify description of GTK+ file chooser.
Chong Yidong <cyd@stupidchicken.com>
parents:
98903
diff
changeset
|
1441 installed and running on your system in order for this to work. |
84242 | 1442 |
1443 @ignore | |
1444 arch-tag: 7dcf3a31-a43b-45d4-a900-445b10d77e49 | |
1445 @end ignore |