aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPaul Eggert2011-10-13 23:14:17 -0700
committerPaul Eggert2011-10-13 23:14:17 -0700
commit91107bd98003435fbeead3325ce694248863da39 (patch)
treec7495c1957f51dac6567af73f390a3be287f9a5f
parentc8d5c85772067347a53bca0149c7018651dedb93 (diff)
parent8b7a997c1a891d390b0d3e9483bf9e605fabd11a (diff)
downloademacs-91107bd98003435fbeead3325ce694248863da39.tar.gz
emacs-91107bd98003435fbeead3325ce694248863da39.zip
Merge from trunk.
-rw-r--r--doc/emacs/ChangeLog15
-rw-r--r--doc/emacs/dired.texi2
-rw-r--r--doc/emacs/emacs.texi4
-rw-r--r--doc/emacs/frames.texi6
-rw-r--r--doc/emacs/killing.texi397
-rw-r--r--doc/emacs/mark.texi60
-rw-r--r--doc/emacs/mule.texi4
-rw-r--r--doc/lispref/ChangeLog7
-rw-r--r--doc/lispref/package.texi3
-rw-r--r--doc/lispref/text.texi18
-rw-r--r--etc/NEWS8
-rw-r--r--lisp/ChangeLog5
-rw-r--r--lisp/textmodes/flyspell.el8
13 files changed, 307 insertions, 230 deletions
diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog
index 3089d2b3d5d..3fa8eece141 100644
--- a/doc/emacs/ChangeLog
+++ b/doc/emacs/ChangeLog
@@ -1,3 +1,18 @@
12011-10-13 Chong Yidong <cyd@stupidchicken.com>
2
3 * killing.texi (Deletion): Add xref to Using Region. Document
4 delete-forward-char.
5 (Yanking): Move yank-excluded-properties to Lisp manual. Move C-y
6 description here. Recommend C-u C-SPC for jumping to mark.
7 (Kill Ring): Move kill ring variable documentation here.
8 (Primary Selection): Copyedits.
9 (Rectangles): Document new command rectangle-number-lines.
10 (CUA Bindings): Note that this disables the mark-even-if-inactive
11 behavior for C-x and C-c.
12
13 * mark.texi (Mark): Mention "active region" terminology.
14 (Using Region): Document delete-active-region.
15
12011-10-12 Chong Yidong <cyd@stupidchicken.com> 162011-10-12 Chong Yidong <cyd@stupidchicken.com>
2 17
3 * mark.texi (Mark): Clarify description of disabled Transient Mark 18 * mark.texi (Mark): Clarify description of disabled Transient Mark
diff --git a/doc/emacs/dired.texi b/doc/emacs/dired.texi
index eb2bcc109e8..b6ed47fdb3f 100644
--- a/doc/emacs/dired.texi
+++ b/doc/emacs/dired.texi
@@ -1403,7 +1403,7 @@ directory than in this one. It also marks files with no counterpart,
1403in both directories, as always. 1403in both directories, as always.
1404 1404
1405@cindex drag and drop, Dired 1405@cindex drag and drop, Dired
1406 On the X window system, Emacs supports the ``drag and drop'' 1406 On the X Window System, Emacs supports the ``drag and drop''
1407protocol. You can drag a file object from another program, and drop 1407protocol. You can drag a file object from another program, and drop
1408it onto a Dired buffer; this either moves, copies, or creates a link 1408it onto a Dired buffer; this either moves, copies, or creates a link
1409to the file in that directory. Precisely which action is taken is 1409to the file in that directory. Precisely which action is taken is
diff --git a/doc/emacs/emacs.texi b/doc/emacs/emacs.texi
index d34ecb01ad6..8a15c783fc0 100644
--- a/doc/emacs/emacs.texi
+++ b/doc/emacs/emacs.texi
@@ -319,9 +319,9 @@ Killing and Moving Text
319 319
320Yanking 320Yanking
321 321
322* Kill Ring:: Where killed text is stored. Basic yanking. 322* Kill Ring:: Where killed text is stored.
323* Appending Kills:: Several kills in a row all yank together.
324* Earlier Kills:: Yanking something killed some time ago. 323* Earlier Kills:: Yanking something killed some time ago.
324* Appending Kills:: Several kills in a row all yank together.
325 325
326Killing and Yanking on Graphical Displays 326Killing and Yanking on Graphical Displays
327 327
diff --git a/doc/emacs/frames.texi b/doc/emacs/frames.texi
index fc78f90db15..14fdb3121a4 100644
--- a/doc/emacs/frames.texi
+++ b/doc/emacs/frames.texi
@@ -93,7 +93,7 @@ clicked.
93 Normally, Emacs does not distinguish between ordinary mouse clicks 93 Normally, Emacs does not distinguish between ordinary mouse clicks
94and clicks that select a frame. When you click on a frame to select 94and clicks that select a frame. When you click on a frame to select
95it, that also changes the selected window and cursor position 95it, that also changes the selected window and cursor position
96according to the mouse click position. On the X window system, you 96according to the mouse click position. On the X Window System, you
97can change this behavior by setting the variable 97can change this behavior by setting the variable
98@code{x-mouse-click-focus-ignore-position} to @code{t}. Then the 98@code{x-mouse-click-focus-ignore-position} to @code{t}. Then the
99first click selects the frame, but does not affect the selected window 99first click selects the frame, but does not affect the selected window
@@ -961,7 +961,7 @@ the left of each Emacs window, running the height of the
961window.@footnote{Placing it at the left is usually more useful with 961window.@footnote{Placing it at the left is usually more useful with
962overlapping frames with text starting at the left margin.} 962overlapping frames with text starting at the left margin.}
963 963
964 When Emacs is compiled with GTK+ support on the X window system, or 964 When Emacs is compiled with GTK+ support on the X Window System, or
965in operating systems such as Microsoft Windows or Mac OS, you can use 965in operating systems such as Microsoft Windows or Mac OS, you can use
966the scroll bar as you do in other graphical applications. If you 966the scroll bar as you do in other graphical applications. If you
967click @kbd{Mouse-1} on the scroll bar's up and down buttons, that 967click @kbd{Mouse-1} on the scroll bar's up and down buttons, that
@@ -971,7 +971,7 @@ the entire height of the window, like @kbd{M-v} and @kbd{C-v}
971respectively (@pxref{Moving Point}). Dragging the inner box with 971respectively (@pxref{Moving Point}). Dragging the inner box with
972@kbd{Mouse-1} scrolls the window continuously. 972@kbd{Mouse-1} scrolls the window continuously.
973 973
974 If Emacs is compiled without GTK+ support on the X window system, 974 If Emacs is compiled without GTK+ support on the X Window System,
975the scroll bar behaves differently. The scroll bar's inner box is 975the scroll bar behaves differently. The scroll bar's inner box is
976drawn to represent the portion of the buffer currently displayed, with 976drawn to represent the portion of the buffer currently displayed, with
977the entire height of the scroll bar representing the entire length of 977the entire height of the scroll bar representing the entire length of
diff --git a/doc/emacs/killing.texi b/doc/emacs/killing.texi
index 06839ce5187..493316daa52 100644
--- a/doc/emacs/killing.texi
+++ b/doc/emacs/killing.texi
@@ -77,12 +77,18 @@ the most part, the Emacs commands that delete text are those that
77erase just one character or only whitespace. 77erase just one character or only whitespace.
78 78
79@table @kbd 79@table @kbd
80@item C-d
81@itemx @key{Delete}
82Delete next character (@code{delete-char}).
83@item @key{DEL} 80@item @key{DEL}
84@itemx @key{Backspace} 81@itemx @key{Backspace}
85Delete previous character (@code{delete-backward-char}). 82Delete the previous character, or the text in the region if it is
83active (@code{delete-backward-char}).
84
85@item @key{Delete}
86Delete the next character, or the text in the region if it is active
87(@code{delete-forward-char}).
88
89@item C-d
90Delete the next character (@code{delete-char}).
91
86@item M-\ 92@item M-\
87Delete spaces and tabs around point (@code{delete-horizontal-space}). 93Delete spaces and tabs around point (@code{delete-horizontal-space}).
88@item M-@key{SPC} 94@item M-@key{SPC}
@@ -95,9 +101,13 @@ Join two lines by deleting the intervening newline, along with any
95indentation following it (@code{delete-indentation}). 101indentation following it (@code{delete-indentation}).
96@end table 102@end table
97 103
98 We have already described the basic deletion commands @kbd{C-d} 104 We have already described the basic deletion commands @key{DEL}
99(@code{delete-char}) and @key{DEL} (@code{delete-backward-char}). 105(@code{delete-backward-char}), @key{delete}
100@xref{Erasing}. 106(@code{delete-forward-char}), and @kbd{C-d} (@code{delete-char}).
107@xref{Erasing}. With a numeric argument, they delete the specified
108number of characters. If the numeric argument is omitted or one, they
109delete all the text in the region if it is active (@pxref{Using
110Region}).
101 111
102@kindex M-\ 112@kindex M-\
103@findex delete-horizontal-space 113@findex delete-horizontal-space
@@ -177,35 +187,35 @@ key sequence @kbd{C-S-backspace}.
177 187
178@table @kbd 188@table @kbd
179@item C-w 189@item C-w
180Kill region (@code{kill-region}). @xref{Mark}. 190Kill the region (@code{kill-region}).
181@item M-w 191@item M-w
182Save region as last killed text without actually killing it 192Copy the region into the kill ring (@code{kill-ring-save}).
183(@code{kill-ring-save}). Some programs call this ``copying.''
184@item M-d 193@item M-d
185Kill word (@code{kill-word}). @xref{Words}. 194Kill the next word (@code{kill-word}). @xref{Words}.
186@item M-@key{DEL} 195@item M-@key{DEL}
187Kill word backwards (@code{backward-kill-word}). 196Kill one word backwards (@code{backward-kill-word}).
188@item C-x @key{DEL} 197@item C-x @key{DEL}
189Kill back to beginning of sentence (@code{backward-kill-sentence}). 198Kill back to beginning of sentence (@code{backward-kill-sentence}).
190@xref{Sentences}. 199@xref{Sentences}.
191@item M-k 200@item M-k
192Kill to end of sentence (@code{kill-sentence}). 201Kill to the end of the sentence (@code{kill-sentence}).
193@item C-M-k 202@item C-M-k
194Kill the following balanced expression (@code{kill-sexp}). @xref{Expressions}. 203Kill the following balanced expression (@code{kill-sexp}). @xref{Expressions}.
195@item M-z @var{char} 204@item M-z @var{char}
196Kill through the next occurrence of @var{char} (@code{zap-to-char}). 205Kill through the next occurrence of @var{char} (@code{zap-to-char}).
197@end table 206@end table
198 207
199 Apart from @kbd{C-k}, the most commonly-used kill command is 208@kindex C-w
200@kbd{C-w} (@code{kill-region}), which kills the text in the region 209@findex kill-region
201(i.e., between point and mark). @xref{Mark}. If the mark is inactive
202when you type @kbd{C-w}, it first reactivates the mark where it was
203last set. The mark is deactivated at the end of the command.
204
205@kindex M-w 210@kindex M-w
206@findex kill-ring-save 211@findex kill-ring-save
207 @kbd{M-w} (@code{kill-ring-save}) copies the region into the kill 212 One of the commonly-used kill commands is @kbd{C-w}
208ring without removing it from the buffer. 213(@code{kill-region}), which kills the text in the region
214(@pxref{Mark}). Similarly, @kbd{M-w} (@code{kill-ring-save}) copies
215the text in the region into the kill ring without removing it from the
216buffer. If the mark is inactive when you type @kbd{C-w} or @kbd{M-w},
217the command acts on the text between point and where you last set the
218mark (@pxref{Using Region}).
209 219
210 Emacs also provides commands to kill specific syntactic units: 220 Emacs also provides commands to kill specific syntactic units:
211words, with @kbd{M-@key{DEL}} and @kbd{M-d} (@pxref{Words}); balanced 221words, with @kbd{M-@key{DEL}} and @kbd{M-d} (@pxref{Words}); balanced
@@ -248,34 +258,45 @@ kill-ring entry, without duplication.
248@cindex pasting 258@cindex pasting
249 259
250 @dfn{Yanking} means reinserting text previously killed. The usual 260 @dfn{Yanking} means reinserting text previously killed. The usual
251way to move or copy text is to kill it and then yank it elsewhere one 261way to move or copy text is to kill it and then yank it elsewhere.
252or more times.
253 262
254@table @kbd 263@table @kbd
255@item C-y 264@item C-y
256Yank last killed text (@code{yank}). 265Yank the last kill into the buffer, at point (@code{yank}).
257@item M-y 266@item M-y
258Replace text just yanked with an earlier batch of killed text 267Replace the text just yanked with an earlier batch of killed text
259(@code{yank-pop}). 268(@code{yank-pop}). @xref{Earlier Kills}.
260@item C-M-w 269@item C-M-w
261Append next kill to last batch of killed text (@code{append-next-kill}). 270Cause the following command, if it is a kill command, to append to the
271previous kill (@code{append-next-kill}). @xref{Appending Kills}.
262@end table 272@end table
263 273
264@cindex yanking and text properties 274@kindex C-y
265@vindex yank-excluded-properties 275@findex yank
266 The yank commands discard certain properties from the yanked text. 276 The basic yanking command is @kbd{C-y} (@code{yank}). It inserts
267These are properties that might lead to annoying results, such as 277the most recent kill, leaving the cursor at the end of the inserted
268causing the text to respond to the mouse or specifying key bindings. 278text. It also sets the mark at the beginning of the inserted text,
269The list of properties to discard is stored in the variable 279without activating the mark; this lets you jump easily to that
270@code{yank-excluded-properties}. These properties are also discarded 280position, if you wish, with @kbd{C-u C-@key{SPC}} (@pxref{Mark Ring}).
271when yanking register contents and rectangles. @xref{Text 281
272Properties,,, elisp, the Emacs Lisp Reference Manual}, for more 282 With a plain prefix argument (@kbd{C-u C-y}), the command instead
273information about text properties. 283leaves the cursor in front of the inserted text, and sets the mark at
284the end. Using any other prefix argument specifies an earlier kill;
285e.g. @kbd{C-u 4 C-y} reinserts the fourth most recent kill.
286@xref{Earlier Kills}.
287
288 On graphical displays, @kbd{C-y} first checks if another application
289has placed any text in the system clipboard more recently than the
290last Emacs kill. If so, it inserts the text in the clipboard instead.
291Thus, Emacs effectively treats ``cut'' or ``copy'' clipboard
292operations performed in other applications like Emacs kills, except
293that they are not recorded in the kill ring. @xref{Cut and Paste},
294for details.
274 295
275@menu 296@menu
276* Kill Ring:: Where killed text is stored. Basic yanking. 297* Kill Ring:: Where killed text is stored.
277* Appending Kills:: Several kills in a row all yank together.
278* Earlier Kills:: Yanking something killed some time ago. 298* Earlier Kills:: Yanking something killed some time ago.
299* Appending Kills:: Several kills in a row all yank together.
279@end menu 300@end menu
280 301
281@node Kill Ring 302@node Kill Ring
@@ -284,31 +305,69 @@ information about text properties.
284 The @dfn{kill ring} is a list of blocks of text that were previously 305 The @dfn{kill ring} is a list of blocks of text that were previously
285killed. There is only one kill ring, shared by all buffers, so you 306killed. There is only one kill ring, shared by all buffers, so you
286can kill text in one buffer and yank it in another buffer. This is 307can kill text in one buffer and yank it in another buffer. This is
287the usual way to move text from one file to another. (There are 308the usual way to move text from one buffer to another. (There are
288several other methods: for instance, you could store the text in a 309several other methods: for instance, you could store the text in a
289register; see @ref{Registers}. @xref{Accumulating Text}, for some 310register; see @ref{Registers}. @xref{Accumulating Text}, for some
290other ways to move text around.) 311other ways to move text around.)
291 312
292@kindex C-y 313@vindex kill-ring-max
293@findex yank 314 The maximum number of entries in the kill ring is controlled by the
294 @kbd{C-y} (@code{yank}) reinserts the text of the most recent kill, 315variable @code{kill-ring-max}. The default is 60. If you make a new
295leaving the cursor at the end of the text. It also adds the position 316kill when this limit has been reached, Emacs makes room by deleting
296of the beginning of the text to the mark ring, without activating the 317the oldest entry in the kill ring.
297mark; this allows you to jump easily to that position with @kbd{C-x
298C-x} (@pxref{Setting Mark}).
299 318
300 On graphical displays, @kbd{C-y} first checks if another application 319@vindex kill-ring
301has placed any text in the system clipboard more recently than the 320 The actual contents of the kill ring are stored in a variable named
302last Emacs kill. If so, it inserts from the clipboard instead of the 321@code{kill-ring}; you can view the entire contents of the kill ring
303kill ring. Conceptually, you can think of the clipboard as an 322with @kbd{C-h v kill-ring}.
304``extra'' entry in the kill ring, which is present if you recently cut 323
305or copied some text in another application. @xref{Cut and Paste}. 324@node Earlier Kills
325@subsection Yanking Earlier Kills
326@cindex yanking previous kills
327
328 As explained in @ref{Yanking}, you can use a numeric argument to
329@kbd{C-y} to yank text that is no longer the most recent kill. This
330is useful if you remember which kill ring entry you want. If you
331don't, you can use the @kbd{M-y} (@code{yank-pop}) command to cycle
332through the possibilities.
333
334@kindex M-y
335@findex yank-pop
336 If the previous command was a yank command, @kbd{M-y} takes the text
337that was yanked and replaces it with the text from an earlier kill.
338So, to recover the text of the next-to-the-last kill, first use
339@kbd{C-y} to yank the last kill, and then use @kbd{M-y} to replace it
340with the previous kill. @kbd{M-y} is allowed only after a @kbd{C-y}
341or another @kbd{M-y}.
342
343 You can understand @kbd{M-y} in terms of a ``last yank'' pointer which
344points at an entry in the kill ring. Each time you kill, the ``last
345yank'' pointer moves to the newly made entry at the front of the ring.
346@kbd{C-y} yanks the entry which the ``last yank'' pointer points to.
347@kbd{M-y} moves the ``last yank'' pointer to a different entry, and the
348text in the buffer changes to match. Enough @kbd{M-y} commands can move
349the pointer to any entry in the ring, so you can get any entry into the
350buffer. Eventually the pointer reaches the end of the ring; the next
351@kbd{M-y} loops back around to the first entry again.
352
353 @kbd{M-y} moves the ``last yank'' pointer around the ring, but it does
354not change the order of the entries in the ring, which always runs from
355the most recent kill at the front to the oldest one still remembered.
356
357 @kbd{M-y} can take a numeric argument, which tells it how many entries
358to advance the ``last yank'' pointer by. A negative argument moves the
359pointer toward the front of the ring; from the front of the ring, it
360moves ``around'' to the last entry and continues forward from there.
361
362 Once the text you are looking for is brought into the buffer, you can
363stop doing @kbd{M-y} commands and it will stay there. It's just a copy
364of the kill ring entry, so editing it in the buffer does not change
365what's in the ring. As long as no new killing is done, the ``last
366yank'' pointer remains at the same place in the kill ring, so repeating
367@kbd{C-y} will yank another copy of the same previous kill.
306 368
307 With a plain prefix argument (@kbd{C-u C-y}), the @code{yank} 369 When you call @kbd{C-y} with a numeric argument, that also sets the
308command instead leaves the cursor in front of the text, and adds the 370``last yank'' pointer to the entry that it yanks.
309position of the end of the text to the mark ring. Using any other
310prefix argument specifies an earlier kill; for example, @kbd{C-u 4
311C-y} reinserts the fourth most recent kill. @xref{Earlier Kills}.
312 371
313@node Appending Kills 372@node Appending Kills
314@subsection Appending Kills 373@subsection Appending Kills
@@ -365,65 +424,6 @@ accumulate them to be yanked back in one place.@refill
365 A kill command following @kbd{M-w} (@code{kill-ring-save}) does not 424 A kill command following @kbd{M-w} (@code{kill-ring-save}) does not
366append to the text that @kbd{M-w} copied into the kill ring. 425append to the text that @kbd{M-w} copied into the kill ring.
367 426
368@node Earlier Kills
369@subsection Yanking Earlier Kills
370
371@cindex yanking previous kills
372@kindex M-y
373@findex yank-pop
374 To recover killed text that is no longer the most recent kill, use the
375@kbd{M-y} command (@code{yank-pop}). It takes the text previously
376yanked and replaces it with the text from an earlier kill. So, to
377recover the text of the next-to-the-last kill, first use @kbd{C-y} to
378yank the last kill, and then use @kbd{M-y} to replace it with the
379previous kill. @kbd{M-y} is allowed only after a @kbd{C-y} or another
380@kbd{M-y}.
381
382 You can understand @kbd{M-y} in terms of a ``last yank'' pointer which
383points at an entry in the kill ring. Each time you kill, the ``last
384yank'' pointer moves to the newly made entry at the front of the ring.
385@kbd{C-y} yanks the entry which the ``last yank'' pointer points to.
386@kbd{M-y} moves the ``last yank'' pointer to a different entry, and the
387text in the buffer changes to match. Enough @kbd{M-y} commands can move
388the pointer to any entry in the ring, so you can get any entry into the
389buffer. Eventually the pointer reaches the end of the ring; the next
390@kbd{M-y} loops back around to the first entry again.
391
392 @kbd{M-y} moves the ``last yank'' pointer around the ring, but it does
393not change the order of the entries in the ring, which always runs from
394the most recent kill at the front to the oldest one still remembered.
395
396 @kbd{M-y} can take a numeric argument, which tells it how many entries
397to advance the ``last yank'' pointer by. A negative argument moves the
398pointer toward the front of the ring; from the front of the ring, it
399moves ``around'' to the last entry and continues forward from there.
400
401 Once the text you are looking for is brought into the buffer, you can
402stop doing @kbd{M-y} commands and it will stay there. It's just a copy
403of the kill ring entry, so editing it in the buffer does not change
404what's in the ring. As long as no new killing is done, the ``last
405yank'' pointer remains at the same place in the kill ring, so repeating
406@kbd{C-y} will yank another copy of the same previous kill.
407
408 If you know how many @kbd{M-y} commands it would take to find the
409text you want, you can yank that text in one step using @kbd{C-y} with
410a numeric argument. @kbd{C-y} with an argument restores the text from
411the specified kill ring entry, counting back from the most recent as
4121. Thus, @kbd{C-u 2 C-y} gets the next-to-the-last block of killed
413text---it is equivalent to @kbd{C-y M-y}. @kbd{C-y} with a numeric
414argument starts counting from the ``last yank'' pointer, and sets the
415``last yank'' pointer to the entry that it yanks.
416
417@vindex kill-ring-max
418 The length of the kill ring is controlled by the variable
419@code{kill-ring-max}; no more than that many blocks of killed text are
420saved.
421
422@vindex kill-ring
423 The actual contents of the kill ring are stored in a variable named
424@code{kill-ring}; you can view the entire contents of the kill ring with
425the command @kbd{C-h v kill-ring}.
426
427@node Cut and Paste 427@node Cut and Paste
428@section ``Cut and Paste'' Operations on Graphical Displays 428@section ``Cut and Paste'' Operations on Graphical Displays
429@cindex cut 429@cindex cut
@@ -462,7 +462,7 @@ and yank commands in Emacs make use of it.
462 When you kill some text with a command such as @kbd{C-w} 462 When you kill some text with a command such as @kbd{C-w}
463(@code{kill-region}), or copy it to the kill ring with a command such 463(@code{kill-region}), or copy it to the kill ring with a command such
464as @kbd{M-w} (@code{kill-ring-save}), that text is also put in the 464as @kbd{M-w} (@code{kill-ring-save}), that text is also put in the
465clipboard. @xref{Killing}. 465clipboard.
466 466
467@vindex save-interprogram-paste-before-kill 467@vindex save-interprogram-paste-before-kill
468 When an Emacs kill command puts text in the clipboard, the existing 468 When an Emacs kill command puts text in the clipboard, the existing
@@ -472,12 +472,11 @@ will first save the clipboard to its kill ring, preventing you from
472losing the old clipboard data---at the risk of high memory consumption 472losing the old clipboard data---at the risk of high memory consumption
473if that data turns out to be large. 473if that data turns out to be large.
474 474
475 The usual yank commands, such as @kbd{C-y} (@code{yank}), also use 475 Yank commands, such as @kbd{C-y} (@code{yank}), also use the
476the clipboard. If another application ``owns'' the clipboard---i.e., 476clipboard. If another application ``owns'' the clipboard---i.e., if
477if you cut or copied text there more recently than your last kill 477you cut or copied text there more recently than your last kill command
478command in Emacs---then Emacs yanks from the clipboard instead of the 478in Emacs---then Emacs yanks from the clipboard instead of the kill
479kill ring. Otherwise, it yanks from the kill ring, as described in 479ring.
480@ref{Yanking}.
481 480
482@vindex yank-pop-change-selection 481@vindex yank-pop-change-selection
483 Normally, rotating the kill ring with @kbd{M-y} (@code{yank-pop}) 482 Normally, rotating the kill ring with @kbd{M-y} (@code{yank-pop})
@@ -511,20 +510,20 @@ yanks the contents of the clipboard at point.
511@cindex primary selection 510@cindex primary selection
512@cindex selection, primary 511@cindex selection, primary
513 512
514 Under the X window system, there exists a @dfn{primary selection} 513 Under the X Window System, there exists a @dfn{primary selection}
515containing the last stretch of text selected in an X application 514containing the last stretch of text selected in an X application
516(usually by dragging the mouse). Typically, this text can be inserted 515(usually by dragging the mouse). Typically, this text can be inserted
517into other X applications by @kbd{mouse-2} clicks. The primary 516into other X applications by @kbd{mouse-2} clicks. The primary
518selection is separate from the clipboard (@pxref{Clipboard}). Its 517selection is separate from the clipboard. Its contents are more
519contents are more ``fragile''; they are overwritten by any mouse 518``fragile''; they are overwritten each time you select text with the
520selection, whereas the clipboard is only overwritten by explicit 519mouse, whereas the clipboard is only overwritten by explicit ``cut''
521``cut'' or ``copy'' commands. 520or ``copy'' commands.
522 521
523 Under X, whenever you set an active region (@pxref{Mark}), Emacs 522 Under X, whenever the region is active (@pxref{Mark}), the text in
524saves the text in the active region to the primary selection. This 523the region is saved in the primary selection. This applies regardless
525applies to active regions made by dragging or clicking the mouse 524of whether the region was made by dragging or clicking the mouse
526(@pxref{Mouse Commands}), and those made by keyboard commands (e.g. by 525(@pxref{Mouse Commands}), or by keyboard commands (e.g. by typing
527typing @kbd{C-@key{SPC}} and moving point; see @ref{Setting Mark}). 526@kbd{C-@key{SPC}} and moving point; @pxref{Setting Mark}).
528 527
529@vindex select-active-regions 528@vindex select-active-regions
530 If you change the variable @code{select-active-regions} to 529 If you change the variable @code{select-active-regions} to
@@ -636,9 +635,9 @@ starting from wherever point happens to be at that moment.
636successive uses of @code{append-to-buffer} accumulate the text in the 635successive uses of @code{append-to-buffer} accumulate the text in the
637specified buffer in the same order as they were copied. Strictly 636specified buffer in the same order as they were copied. Strictly
638speaking, @code{append-to-buffer} does not always append to the text 637speaking, @code{append-to-buffer} does not always append to the text
639already in the buffer---it appends only if point in that buffer is at the end. 638already in the buffer---it appends only if point in that buffer is at
640However, if @code{append-to-buffer} is the only command you use to alter 639the end. However, if @code{append-to-buffer} is the only command you
641a buffer, then point is always at the end. 640use to alter a buffer, then point is always at the end.
642 641
643 @kbd{M-x prepend-to-buffer} is just like @code{append-to-buffer} 642 @kbd{M-x prepend-to-buffer} is just like @code{append-to-buffer}
644except that point in the other buffer is left before the copied text, so 643except that point in the other buffer is left before the copied text, so
@@ -682,19 +681,16 @@ them. Rectangle commands are useful with text in multicolumn formats,
682and for changing text into or out of such formats. 681and for changing text into or out of such formats.
683 682
684@cindex mark rectangle 683@cindex mark rectangle
685 When you must specify a rectangle for a command to work on, you do it 684 To specify a rectangle for a command to work on, set the mark at one
686by putting the mark at one corner and point at the opposite corner. The 685corner and point at the opposite corner. The rectangle thus specified
687rectangle thus specified is called the @dfn{region-rectangle} because 686is called the @dfn{region-rectangle}. If point and the mark are in
688you control it in much the same way as the region is controlled. But 687the same column, the region-rectangle is empty. If they are in the
689remember that a given combination of point and mark values can be 688same line, the region-rectangle is one line high.
690interpreted either as a region or as a rectangle, depending on the 689
691command that uses them. 690 The region-rectangle is controlled in much the same way as the
692 691region is controlled. But remember that a given combination of point
693 If point and the mark are in the same column, the rectangle they 692and mark values can be interpreted either as a region or as a
694delimit is empty. If they are in the same line, the rectangle is one 693rectangle, depending on the command that uses them.
695line high. This asymmetry between lines and columns comes about
696because point (and likewise the mark) is between two columns, but within
697a line.
698 694
699@table @kbd 695@table @kbd
700@item C-x r k 696@item C-x r k
@@ -708,7 +704,11 @@ Yank the last killed rectangle with its upper left corner at point
708@item C-x r o 704@item C-x r o
709Insert blank space to fill the space of the region-rectangle 705Insert blank space to fill the space of the region-rectangle
710(@code{open-rectangle}). This pushes the previous contents of the 706(@code{open-rectangle}). This pushes the previous contents of the
711region-rectangle rightward. 707region-rectangle to the right.
708@item C-x r N
709Insert line numbers along the left edge of the region-rectangle
710(@code{rectangle-number-lines}). This pushes the previous contents of
711the region-rectangle to the right.
712@item C-x r c 712@item C-x r c
713Clear the region-rectangle by replacing all of its contents with spaces 713Clear the region-rectangle by replacing all of its contents with spaces
714(@code{clear-rectangle}). 714(@code{clear-rectangle}).
@@ -722,42 +722,39 @@ Replace rectangle contents with @var{string} on each line
722Insert @var{string} on each line of the rectangle. 722Insert @var{string} on each line of the rectangle.
723@end table 723@end table
724 724
725 The rectangle operations fall into two classes: commands for 725 The rectangle operations fall into two classes: commands to erase or
726deleting and inserting rectangles, and commands for blank rectangles. 726insert rectangles, and commands to make blank rectangles.
727 727
728@kindex C-x r k 728@kindex C-x r k
729@kindex C-x r d 729@kindex C-x r d
730@findex kill-rectangle 730@findex kill-rectangle
731@findex delete-rectangle 731@findex delete-rectangle
732 There are two ways to get rid of the text in a rectangle: you can 732 There are two ways to erase the text in a rectangle: @kbd{C-x r d}
733discard the text (delete it) or save it as the ``last killed'' 733(@code{delete-rectangle}) to delete the text outright, or @kbd{C-x r
734rectangle. The commands for these two ways are @kbd{C-x r d} 734k} (@code{kill-rectangle}) to remove the text and and save it as the
735(@code{delete-rectangle}) and @kbd{C-x r k} (@code{kill-rectangle}). In 735@dfn{last killed rectangle}. In both cases, erasing the
736either case, the portion of each line that falls inside the rectangle's 736region-rectangle is like erasing the specified text on each line of
737boundaries is deleted, causing any following text on the line to 737the rectange; if there is any following text on the line, it moves
738move left into the gap. 738backwards to fill the gap.
739 739
740 Note that ``killing'' a rectangle is not killing in the usual sense; the 740 ``Killing'' a rectangle is not killing in the usual sense; the
741rectangle is not stored in the kill ring, but in a special place that 741rectangle is not stored in the kill ring, but in a special place that
742can only record the most recent rectangle killed. This is because yanking 742only records the most recent rectangle killed. This is because
743a rectangle is so different from yanking linear text that different yank 743yanking a rectangle is so different from yanking linear text that
744commands have to be used. It is hard to define yank-popping for rectangles, 744different yank commands have to be used. Yank-popping is not defined
745so we do not try. 745for rectangles.
746 746
747@kindex C-x r y 747@kindex C-x r y
748@findex yank-rectangle 748@findex yank-rectangle
749 To yank the last killed rectangle, type @kbd{C-x r y} 749 To yank the last killed rectangle, type @kbd{C-x r y}
750(@code{yank-rectangle}). Yanking a rectangle is the opposite of killing 750(@code{yank-rectangle}). The rectangle's first line is inserted at
751one. Point specifies where to put the rectangle's upper left corner. 751point, the rectangle's second line is inserted at the same horizontal
752The rectangle's first line is inserted there, the rectangle's second 752position one line vertically below, and so on. The number of lines
753line is inserted at the same horizontal position, but one line 753affected is determined by the height of the saved rectangle.
754vertically down, and so on. The number of lines affected is determined 754
755by the height of the saved rectangle. 755 For example, you can convert two single-column lists into a
756 756double-column list by killing one of the single-column lists as a
757 You can convert single-column lists into double-column lists using 757rectangle, and then yanking it beside the other list.
758rectangle killing and yanking; kill the second half of the list as a
759rectangle and then yank it beside the first line of the list.
760@xref{Two-Column}, for another way to edit multi-column text.
761 758
762 You can also copy rectangles into and out of registers with @kbd{C-x r 759 You can also copy rectangles into and out of registers with @kbd{C-x r
763r @var{r}} and @kbd{C-x r i @var{r}}. @xref{Rectangle Registers}. 760r @var{r}} and @kbd{C-x r i @var{r}}. @xref{Rectangle Registers}.
@@ -767,17 +764,26 @@ r @var{r}} and @kbd{C-x r i @var{r}}. @xref{Rectangle Registers}.
767@kindex C-x r c 764@kindex C-x r c
768@findex clear-rectangle 765@findex clear-rectangle
769 There are two commands you can use for making blank rectangles: 766 There are two commands you can use for making blank rectangles:
770@kbd{C-x r c} (@code{clear-rectangle}) which blanks out existing text, 767@kbd{C-x r c} (@code{clear-rectangle}) blanks out existing text in the
771and @kbd{C-x r o} (@code{open-rectangle}) which inserts a blank 768region-rectangle, and @kbd{C-x r o} (@code{open-rectangle}) inserts a
772rectangle. Clearing a rectangle is equivalent to deleting it and then 769blank rectangle.
773inserting a blank rectangle of the same size.
774 770
775@findex delete-whitespace-rectangle 771@findex delete-whitespace-rectangle
776 The command @kbd{M-x delete-whitespace-rectangle} deletes horizontal 772 @kbd{M-x delete-whitespace-rectangle} deletes horizontal whitespace
777whitespace starting from a particular column. This applies to each of 773starting from a particular column. This applies to each of the lines
778the lines in the rectangle, and the column is specified by the left 774in the rectangle, and the column is specified by the left edge of the
779edge of the rectangle. The right edge of the rectangle does not make 775rectangle. The right edge of the rectangle does not make any
780any difference to this command. 776difference to this command.
777
778@kindex C-x r N
779@findex rectangle
780 The command @kbd{C-x r N} (@code{rectangle-number-lines}) inserts
781line numbers along the left edge of the region-rectangle. Normally,
782the numbering begins from 1 (for the first line of the rectangle).
783With a prefix argument, the command prompts for a number to begin
784from, and for a format string with which to print the numbers
785(@pxref{Formatting Strings,,, elisp, The Emacs Lisp Reference
786Manual}).
781 787
782@kindex C-x r t 788@kindex C-x r t
783@findex string-rectangle 789@findex string-rectangle
@@ -801,18 +807,25 @@ shifting the original text to the right.
801@vindex cua-enable-cua-keys 807@vindex cua-enable-cua-keys
802 The command @kbd{M-x cua-mode} sets up key bindings that are 808 The command @kbd{M-x cua-mode} sets up key bindings that are
803compatible with the Common User Access (CUA) system used in many other 809compatible with the Common User Access (CUA) system used in many other
804applications. @kbd{C-x} means cut (kill), @kbd{C-c} copy, @kbd{C-v} 810applications.
805paste (yank), and @kbd{C-z} undo. Standard Emacs commands like 811
806@kbd{C-x C-c} still work, because @kbd{C-x} and @kbd{C-c} only take 812 When CUA mode is enabled, the keys @kbd{C-x}, @kbd{C-c}, @kbd{C-v},
807effect when the mark is active (and the region is highlighted). 813and @kbd{C-z} invoke commands that cut (kill), copy, paste (yank), and
808However, if you don't want to override these bindings in Emacs at all, 814undo respectively. The @kbd{C-x} and @kbd{C-c} keys perform cut and
809set @code{cua-enable-cua-keys} to @code{nil}. 815copy only if the region is active. Otherwise, they still act as
816prefix keys, so that standard Emacs commands like @kbd{C-x C-c} still
817work. Note that this means the variable @code{mark-even-if-inactive}
818has no effect for @kbd{C-x} and @kbd{C-c} (@pxref{Using Region}).
810 819
811 To enter an Emacs command like @kbd{C-x C-f} while the mark is 820 To enter an Emacs command like @kbd{C-x C-f} while the mark is
812active, use one of the following methods: either hold @kbd{Shift} 821active, use one of the following methods: either hold @kbd{Shift}
813together with the prefix key, e.g. @kbd{S-C-x C-f}, or quickly type 822together with the prefix key, e.g. @kbd{S-C-x C-f}, or quickly type
814the prefix key twice, e.g. @kbd{C-x C-x C-f}. 823the prefix key twice, e.g. @kbd{C-x C-x C-f}.
815 824
825 To disable the overriding of standard Emacs binding by CUA mode,
826while retaining the other features of CUA mode described below, set
827the variable @code{cua-enable-cua-keys} to @code{nil}.
828
816 In CUA mode, typed text replaces the active region as in 829 In CUA mode, typed text replaces the active region as in
817Delete-Selection mode (@pxref{Mouse Commands}). 830Delete-Selection mode (@pxref{Mouse Commands}).
818 831
diff --git a/doc/emacs/mark.texi b/doc/emacs/mark.texi
index 21d90a3fc79..0eccef41711 100644
--- a/doc/emacs/mark.texi
+++ b/doc/emacs/mark.texi
@@ -16,18 +16,22 @@ The region always extends between point and the mark, no matter which
16one comes earlier in the text; each time you move point, the region 16one comes earlier in the text; each time you move point, the region
17changes. 17changes.
18 18
19@cindex active region
19 Setting the mark at a position in the text also @dfn{activates} it. 20 Setting the mark at a position in the text also @dfn{activates} it.
20When the mark is active, Emacs indicates the extent of the region by 21When the mark is active, we say also that the region is active; Emacs
21highlighting the text within it, using the @code{region} face 22indicates its extent by highlighting the text within it, using the
22(@pxref{Face Customization}). After certain non-motion commands, 23@code{region} face (@pxref{Face Customization}).
23including any command that changes the text in the buffer, Emacs 24
24automatically @dfn{deactivates} the mark; this turns off the 25 After certain non-motion commands, including any command that
25highlighting. You can also explicitly deactivate the mark at any 26changes the text in the buffer, Emacs automatically @dfn{deactivates}
26time, by typing @kbd{C-g} (@pxref{Quitting}). 27the mark; this turns off the highlighting. You can also explicitly
27 28deactivate the mark at any time, by typing @kbd{C-g}
28 This default behavior is known as Transient Mark mode. Disabling 29(@pxref{Quitting}).
29Transient Mark mode switches Emacs to an alternative behavior, in 30
30which the region is usually not highlighted. @xref{Disabled Transient Mark}. 31 The above default behavior is known as Transient Mark mode.
32Disabling Transient Mark mode switches Emacs to an alternative
33behavior, in which the region is usually not highlighted.
34@xref{Disabled Transient Mark}.
31 35
32@vindex highlight-nonselected-windows 36@vindex highlight-nonselected-windows
33 Setting the mark in one buffer has no effect on the marks in other 37 Setting the mark in one buffer has no effect on the marks in other
@@ -141,10 +145,10 @@ can tell that a command does this when it shows @samp{Mark set} in the
141echo area. 145echo area.
142 146
143@cindex primary selection 147@cindex primary selection
144 Under X, every time the region changes while the mark is active, 148 Under X, every time the active region changes, Emacs saves the text
145Emacs saves the text in the region to the @dfn{primary selection}. 149in the region to the @dfn{primary selection}. This lets you insert
146This lets you insert that text into other X applications with 150that text into other X applications with @kbd{mouse-2} clicks.
147@kbd{mouse-2} clicks. @xref{Primary Selection}. 151@xref{Primary Selection}.
148 152
149@node Marking Objects 153@node Marking Objects
150@section Commands to Mark Textual Objects 154@section Commands to Mark Textual Objects
@@ -243,18 +247,30 @@ Save it in a buffer or a file (@pxref{Accumulating Text}).
243@end itemize 247@end itemize
244 248
245 Some commands have a default behavior when the mark is inactive, but 249 Some commands have a default behavior when the mark is inactive, but
246operate on the text in the region if the mark is active. For example, 250operate on the region if the mark is active. For example, @kbd{M-$}
247@kbd{M-$} (@code{ispell-word}) normally checks the spelling of the 251(@code{ispell-word}) normally checks the spelling of the word at
248word at point, but it checks the text in the region if the region is 252point, but it checks the text in the region if the mark is active
249active (@pxref{Spelling}). Normally, such commands use their default 253(@pxref{Spelling}). Normally, such commands use their default
250behavior if the region is empty (i.e., if mark and point are at the 254behavior if the region is empty (i.e., if mark and point are at the
251same position). If you want them to operate on the empty region, 255same position). If you want them to operate on the empty region,
252change the variable @code{use-empty-active-region} to @code{t}. 256change the variable @code{use-empty-active-region} to @code{t}.
253 257
258@vindex delete-active-region
259 As described in @ref{Erasing}, the @key{DEL}
260(@code{backward-delete-char}) and @key{delete}
261(@code{delete-forward-char}) commands also act this way. If the mark
262is active, they delete the text in the region. (As an exception, if
263you supply a numeric argument @var{n}, where @var{n} is not one, these
264commands delete @var{n} characters regardless of whether the mark is
265active). If you change the variable @code{delete-active-region} to
266@code{nil}, then these commands don't act differently when the mark is
267active. If you change the value to @code{kill}, these commands
268@dfn{kill} the region instead of deleting it (@pxref{Killing}).
269
254@vindex mark-even-if-inactive 270@vindex mark-even-if-inactive
255 Other commands always operate on the text in the region, and have no 271 Other commands always operate on the region, and have no default
256default behavior. Such commands usually have the word @code{region} 272behavior. Such commands usually have the word @code{region} in their
257in their names, like @kbd{C-w} (@code{kill-region}) and @code{C-x C-u} 273names, like @kbd{C-w} (@code{kill-region}) and @code{C-x C-u}
258(@code{upcase-region}). If the mark is inactive, they operate on the 274(@code{upcase-region}). If the mark is inactive, they operate on the
259``inactive region''---that is, on the text between point and the 275``inactive region''---that is, on the text between point and the
260position at which the mark was last set (@pxref{Mark Ring}). To 276position at which the mark was last set (@pxref{Mark Ring}). To
diff --git a/doc/emacs/mule.texi b/doc/emacs/mule.texi
index 29b6c69e38f..f676f0b96ce 100644
--- a/doc/emacs/mule.texi
+++ b/doc/emacs/mule.texi
@@ -81,8 +81,8 @@ appropriate keyboard coding system (@pxref{Terminal Coding}), and Emacs
81will accept those characters. Latin-1 characters can also be input by 81will accept those characters. Latin-1 characters can also be input by
82using the @kbd{C-x 8} prefix, see @ref{Unibyte Mode}. 82using the @kbd{C-x 8} prefix, see @ref{Unibyte Mode}.
83 83
84On X Window systems, your locale should be set to an appropriate value 84On the X Window System, your locale should be set to an appropriate
85to make sure Emacs interprets keyboard input correctly; see 85value to make sure Emacs interprets keyboard input correctly; see
86@ref{Language Environments, locales}. 86@ref{Language Environments, locales}.
87@end itemize 87@end itemize
88 88
diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog
index fa5aac6e9ec..345e69e6989 100644
--- a/doc/lispref/ChangeLog
+++ b/doc/lispref/ChangeLog
@@ -1,3 +1,10 @@
12011-10-13 Chong Yidong <cyd@stupidchicken.com>
2
3 * text.texi (Yanking): Document yank-excluded-properties.
4
5 * package.texi (Packaging Basics): The commentary should say how
6 to begin using the package.
7
12011-10-11 Martin Rudalics <rudalics@gmx.at> 82011-10-11 Martin Rudalics <rudalics@gmx.at>
2 9
3 * windows.texi (Deleting Windows): Mention which window gets 10 * windows.texi (Deleting Windows): Mention which window gets
diff --git a/doc/lispref/package.texi b/doc/lispref/package.texi
index 62fbc2a9a07..5533f8ab5fa 100644
--- a/doc/lispref/package.texi
+++ b/doc/lispref/package.texi
@@ -63,7 +63,8 @@ should occupy a single line, ideally in 36 characters or less.
63This is shown in the buffer created by @kbd{C-h P} 63This is shown in the buffer created by @kbd{C-h P}
64(@code{describe-package}), following the package's brief description 64(@code{describe-package}), following the package's brief description
65and installation status. It normally spans multiple lines, and should 65and installation status. It normally spans multiple lines, and should
66fully describe the package and its capabilities. 66fully describe the package's capabilities and how to begin using it
67once it is installed.
67 68
68@item Dependencies 69@item Dependencies
69A list of other packages (possibly including minimal acceptable 70A list of other packages (possibly including minimal acceptable
diff --git a/doc/lispref/text.texi b/doc/lispref/text.texi
index 2348e3706dc..3a081dddc61 100644
--- a/doc/lispref/text.texi
+++ b/doc/lispref/text.texi
@@ -907,10 +907,11 @@ text that they copy into the buffer.
907 907
908@defun insert-for-yank string 908@defun insert-for-yank string
909This function normally works like @code{insert} except that it doesn't 909This function normally works like @code{insert} except that it doesn't
910insert the text properties in the @code{yank-excluded-properties} 910insert the text properties (@pxref{Text Properties}) in the list
911list. However, if any part of @var{string} has a non-@code{nil} 911variable @code{yank-excluded-properties}. However, if any part of
912@code{yank-handler} text property, that property can do various 912@var{string} has a non-@code{nil} @code{yank-handler} text property,
913special processing on that part of the text being inserted. 913that property can do various special processing on that part of the
914text being inserted.
914@end defun 915@end defun
915 916
916@defun insert-buffer-substring-as-yank buf &optional start end 917@defun insert-buffer-substring-as-yank buf &optional start end
@@ -958,6 +959,15 @@ region. @var{function} can set @code{yank-undo-function} to override
958the @var{undo} value. 959the @var{undo} value.
959@end table 960@end table
960 961
962@cindex yanking and text properties
963@defopt yank-excluded-properties
964Yanking discards certain text properties from the yanked text, as
965described above. The value of this variable is the list of properties
966to discard. Its default value contains properties that might lead to
967annoying results, such as causing the text to respond to the mouse or
968specifying key bindings.
969@end defopt
970
961@node Yank Commands 971@node Yank Commands
962@comment node-name, next, previous, up 972@comment node-name, next, previous, up
963@subsection Functions for Yanking 973@subsection Functions for Yanking
diff --git a/etc/NEWS b/etc/NEWS
index b9fed18355d..386462fe92e 100644
--- a/etc/NEWS
+++ b/etc/NEWS
@@ -459,16 +459,16 @@ bound to M-=, which shows the number of lines, words, and characters.
459also deletes newlines around point. 459also deletes newlines around point.
460 460
461** Deletion changes 461** Deletion changes
462 462+++
463*** New option `delete-active-region'. 463*** New option `delete-active-region'.
464If non-nil, [delete] and DEL delete the region if it is active and no 464If non-nil, [delete] and DEL delete the region if it is active and no
465prefix argument is given. If set to `kill', these commands kill 465prefix argument is given. If set to `kill', these commands kill
466instead. 466instead.
467 467+++
468*** New command `delete-forward-char', bound to [delete]. 468*** New command `delete-forward-char', bound to [delete].
469This is meant for interactive use, and obeys `delete-active-region'. 469This is meant for interactive use, and obeys `delete-active-region'.
470The command `delete-char' does not obey `delete-active-region'. 470The command `delete-char' does not obey `delete-active-region'.
471 471---
472*** `delete-backward-char' is now a Lisp function. 472*** `delete-backward-char' is now a Lisp function.
473Apart from obeying `delete-active-region', its behavior is unchanged. 473Apart from obeying `delete-active-region', its behavior is unchanged.
474However, the byte compiler now warns if it is called from Lisp; you 474However, the byte compiler now warns if it is called from Lisp; you
@@ -537,6 +537,7 @@ between applications.
537*** X clipboard managers are now supported. 537*** X clipboard managers are now supported.
538To inhibit this, change `x-select-enable-clipboard-manager' to nil. 538To inhibit this, change `x-select-enable-clipboard-manager' to nil.
539 539
540+++
540** New command `rectangle-number-lines', bound to `C-x r N', numbers 541** New command `rectangle-number-lines', bound to `C-x r N', numbers
541the lines in the current rectangle. With a prefix argument, this 542the lines in the current rectangle. With a prefix argument, this
542prompts for a number to count from and for a format string. 543prompts for a number to count from and for a format string.
@@ -947,6 +948,7 @@ variable `menu-bar-mode'/`tool-bar-mode' to determine whether to create
947a menu-bar or tool-bar, respectively. If the alist entries are added, 948a menu-bar or tool-bar, respectively. If the alist entries are added,
948they override the value of `menu-bar-mode'/`tool-bar-mode'. 949they override the value of `menu-bar-mode'/`tool-bar-mode'.
949 950
951+++
950** Regions created by mouse dragging are now normal active regions, 952** Regions created by mouse dragging are now normal active regions,
951similar to the ones created by shift-selection. In previous Emacs 953similar to the ones created by shift-selection. In previous Emacs
952versions, these regions were delineated by `mouse-drag-overlay', which 954versions, these regions were delineated by `mouse-drag-overlay', which
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 10570c2a878..68a85a43387 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
12011-10-13 Agustín Martín Domingo <agustin.martin@hispalinux.es>
2
3 * textmodes/flyspell.el (flyspell-large-region): Make sure
4 extended character mode is used if defined (Bug#1339).
5
12011-10-13 Eli Zaretskii <eliz@gnu.org> 62011-10-13 Eli Zaretskii <eliz@gnu.org>
2 7
3 * simple.el (what-cursor-position): Fix the display of the 8 * simple.el (what-cursor-position): Fix the display of the
diff --git a/lisp/textmodes/flyspell.el b/lisp/textmodes/flyspell.el
index c2af3f7be84..d496298768d 100644
--- a/lisp/textmodes/flyspell.el
+++ b/lisp/textmodes/flyspell.el
@@ -1559,6 +1559,14 @@ The buffer to mark them in is `flyspell-large-region-buffer'."
1559 (list "-p" 1559 (list "-p"
1560 (expand-file-name 1560 (expand-file-name
1561 ispell-current-personal-dictionary))))) 1561 ispell-current-personal-dictionary)))))
1562
1563 ;; Check for extended character mode
1564 (let ((extended-char-mode (ispell-get-extended-character-mode)))
1565 (and extended-char-mode ; ~ extended character mode
1566 (string-match "[^~]+$" extended-char-mode)
1567 (add-to-list 'args (concat "-T" (match-string 0 extended-char-mode)))))
1568
1569 ;; Add ispell-extra-args
1562 (setq args (append args ispell-extra-args)) 1570 (setq args (append args ispell-extra-args))
1563 1571
1564 ;; If we are using recent aspell or hunspell, make sure we use the right encoding 1572 ;; If we are using recent aspell or hunspell, make sure we use the right encoding