diff options
| author | Eli Zaretskii | 2008-10-15 16:48:06 +0000 |
|---|---|---|
| committer | Eli Zaretskii | 2008-10-15 16:48:06 +0000 |
| commit | 16624be86339185c93f36c5bd6a7540c4982f5ce (patch) | |
| tree | 95a3ff427a7fbab0e2fab078826831a3c0cfdd88 | |
| parent | ee6e73b8d939430ec9647114d84fa79085c81025 (diff) | |
| download | emacs-16624be86339185c93f36c5bd6a7540c4982f5ce.tar.gz emacs-16624be86339185c93f36c5bd6a7540c4982f5ce.zip | |
(The Mark): Document the `lambda' and `(only . OLD)' values of
transient-mark-mode. Document handle-shift-selection.
| -rw-r--r-- | doc/lispref/markers.texi | 28 |
1 files changed, 23 insertions, 5 deletions
diff --git a/doc/lispref/markers.texi b/doc/lispref/markers.texi index 6a02a95e038..c63b383d1ba 100644 --- a/doc/lispref/markers.texi +++ b/doc/lispref/markers.texi | |||
| @@ -555,11 +555,15 @@ every buffer-modifying primitive sets @code{deactivate-mark}. The | |||
| 555 | consequence of this is that commands that modify the buffer normally | 555 | consequence of this is that commands that modify the buffer normally |
| 556 | make the mark inactive. | 556 | make the mark inactive. |
| 557 | 557 | ||
| 558 | Lisp programs can set @code{transient-mark-mode} to @code{only} to | 558 | Lisp programs can set @code{transient-mark-mode} to non-@code{nil}, |
| 559 | enable Transient Mark mode for the following command only. During | 559 | non-@code{t} values to enable Transient Mark mode temporarily. If the |
| 560 | that following command, the value of @code{transient-mark-mode} is | 560 | value is @code{lambda}, Transient Mark Mode is automatically turned |
| 561 | @code{identity}. If it is still @code{identity} at the end of the | 561 | off after any action, such as buffer modification, that would normally |
| 562 | command, it changes to @code{nil}. | 562 | deactivate the mark. If the value is @w{@code{(only . @var{oldval})}}, |
| 563 | then @code{transient-mark-mode} is set to the value @var{oldval} after | ||
| 564 | any subsequent command that moves point and is not shift-translated | ||
| 565 | (@pxref{Key Sequence Input, shift-translation}), or after any other | ||
| 566 | action that would normally deactivate the mark. | ||
| 563 | @end defopt | 567 | @end defopt |
| 564 | 568 | ||
| 565 | @defopt mark-even-if-inactive | 569 | @defopt mark-even-if-inactive |
| @@ -626,6 +630,20 @@ more marks than this are pushed onto the @code{mark-ring}, | |||
| 626 | @code{push-mark} discards an old mark when it adds a new one. | 630 | @code{push-mark} discards an old mark when it adds a new one. |
| 627 | @end defopt | 631 | @end defopt |
| 628 | 632 | ||
| 633 | @defun handle-shift-selection &optional deactivate | ||
| 634 | This function checks whether the current command was invoked via shift | ||
| 635 | translation (@pxref{Key Sequence Input, shift-translation}), and if | ||
| 636 | so, sets the mark and temporarily activates the region, unless the | ||
| 637 | region is already temporarily activated in this way. If the command | ||
| 638 | was invoked without shift translation, or if the optional argument | ||
| 639 | @var{deactivate} is non-nil, the function deactivates the mark. This | ||
| 640 | function is called whenever a command with a @samp{^} character in its | ||
| 641 | @code{interactive} spec (@pxref{Interactive Codes, ^}) is invoked | ||
| 642 | while @code{shift-select-mode} (@pxref{Shift Selection,,, emacs, The | ||
| 643 | GNU Emacs Manual}) is non-@code{nil}. | ||
| 644 | |||
| 645 | @end defun | ||
| 646 | |||
| 629 | @node The Region | 647 | @node The Region |
| 630 | @section The Region | 648 | @section The Region |
| 631 | @cindex region (between point and mark) | 649 | @cindex region (between point and mark) |