diff -Nacr cvs/bindings.el new/bindings.el *** cvs/bindings.el 2004-09-10 19:13:47.000000000 -0600 --- new/bindings.el 2004-09-17 11:11:27.000000000 -0600 *************** *** 889,895 **** (define-key esc-map "<" 'beginning-of-buffer) (define-key esc-map ">" 'end-of-buffer) (define-key ctl-x-map "h" 'mark-whole-buffer) - (define-key esc-map "\\" 'delete-horizontal-space) (defalias 'mode-specific-command-prefix (make-sparse-keymap)) (defvar mode-specific-map (symbol-function 'mode-specific-command-prefix) --- 889,894 ---- diff -Nacr cvs/simple.el new/simple.el *** cvs/simple.el 2004-09-17 11:18:59.000000000 -0600 --- new/simple.el 2004-09-17 11:42:28.000000000 -0600 *************** *** 596,613 **** nil (insert ?\ )))) ! (defun delete-horizontal-space (&optional backward-only) ! "Delete all spaces and tabs around point. ! If BACKWARD-ONLY is non-nil, only delete spaces before point." ! (interactive "*") ! (let ((orig-pos (point))) (delete-region ! (if backward-only ! orig-pos ! (progn ! (skip-chars-forward " \t") ! (constrain-to-field nil orig-pos t))) ! (progn (skip-chars-backward " \t") (constrain-to-field nil orig-pos))))) --- 596,619 ---- nil (insert ?\ )))) ! ! (defun delete-horizontal-space (&optional dir) ! "Delete all spaces and tabs around point in one or both directions. ! If DIR is negative or (for backward-compatibility) t, delete backward. ! If DIR is omitted, nil, or 0, delete both forward and backward. ! Otherwise, delete forward. (This is the case for \\[universal-argument] \ ! \\[delete-horizontal-space].)" ! (interactive "*P") ! (let* ((ndir (prefix-numeric-value dir)) ! (notboth (and dir (/= ndir 0))) ! (backonly (and notboth (or (eq dir t) (< ndir 0)))) ! (forthonly (and notboth (not backonly))) ! (orig-pos (point))) (delete-region ! (if backonly orig-pos ! (skip-chars-forward " \t") ! (constrain-to-field nil orig-pos t)) ! (if forthonly orig-pos (skip-chars-backward " \t") (constrain-to-field nil orig-pos))))) diff -Nacr cvs/woman.el new/woman.el *** cvs/woman.el 2004-09-17 11:44:11.000000000 -0600 --- new/woman.el 2004-09-17 11:46:24.000000000 -0600 *************** *** 1095,1105 **** (beginning-of-line) (woman-delete-line 1)) - (defsubst woman-delete-following-space () - "Delete all spaces and tabs FOLLOWING point (cf. `delete-horizontal-space')." - ;; cf. delete-horizontal-space in simple.el: - (delete-region (point) (progn (skip-chars-forward " \t") (point)))) - (defsubst woman-delete-match (subexp) "Delete subexpression SUBEXP of buffer text matched by last search." (delete-region (match-beginning subexp) (match-end subexp))) --- 1095,1100 ---- *************** *** 3117,3123 **** (skip-syntax-forward "^ ")) (cond ((null concat) (skip-chars-forward " \t")) ; don't skip eol! ((eq concat 'noskip)) ; do not skip following whitespace ! (t (woman-delete-following-space))) ) --- 3112,3118 ---- (skip-syntax-forward "^ ")) (cond ((null concat) (skip-chars-forward " \t")) ; don't skip eol! ((eq concat 'noskip)) ; do not skip following whitespace ! (t (delete-horizontal-space 1))) )