Variable: delete-selection-mode

delete-selection-mode is a customizable variable defined in delsel.el.gz.

Value

nil

Documentation

Non-nil if Delete-Selection mode is enabled.

See the delete-selection-mode(var)/delete-selection-mode(fun) command for a description of this minor mode. Setting this variable directly does not take effect; either customize it (see the info node (emacs)Easy Customization) or call the function delete-selection-mode(var)/delete-selection-mode(fun).

Probably introduced at or before Emacs version 20.1.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/delsel.el.gz
;;;###autoload
(define-minor-mode delete-selection-mode
  "Toggle Delete Selection mode.

When Delete Selection mode is enabled, typed text replaces the selection
if the selection is active.  Otherwise, typed text is just inserted at
point regardless of any selection.

See `delete-selection-helper' and `delete-selection-pre-hook' for
information on adapting behavior of commands in Delete Selection mode."
  :global t :group 'editing-basics
  (if (not delete-selection-mode)
      (remove-hook 'pre-command-hook 'delete-selection-pre-hook)
    (add-hook 'pre-command-hook 'delete-selection-pre-hook)))