]> code.delx.au - gnu-emacs/commitdiff
(outline-next-preface, outline-show-heading): Don't leave unhidden blank line before...
authorJuri Linkov <juri@jurta.org>
Thu, 29 Apr 2004 15:34:58 +0000 (15:34 +0000)
committerJuri Linkov <juri@jurta.org>
Thu, 29 Apr 2004 15:34:58 +0000 (15:34 +0000)
(outline-end-of-subtree): Include last newline into subtree.
(hide-entry): Leave point at beginning of heading instead of end.
(outline-up-heading): Push mark for the first call of successive command calls.

lisp/ChangeLog
lisp/outline.el

index 8a1bba88874dd4af3052931a5def1da5a4604545..c5e98bfc703cbaa406f89e6c344f3eaff38c331b 100644 (file)
@@ -1,3 +1,24 @@
+2004-04-29  Juri Linkov  <juri@jurta.org>
+
+       * isearch.el (isearch-mode-map): Bind \C-w to isearch-yank-word
+       instead of isearch-yank-word-or-char.  Add new key bindings for
+       isearch-yank-char to \C-f, and isearch-del-char to \C-b.
+       (isearch-del-char): New fun.
+       (isearch-forward, isearch-edit-string): Update docstring.
+       (isearch-yank-char): Doc fix.
+       (isearch-other-meta-char): Restore point after scrolling.
+
+       * progmodes/compile.el (compilation-context-lines): Add nil option
+       to disable compilation output window scrolling.
+       (compilation-set-window): Use it.
+
+       * outline.el (outline-next-preface, outline-show-heading): Don't
+       leave unhidden blank line before heading.
+       (outline-end-of-subtree): Include last newline into subtree.
+       (hide-entry): Leave point at beginning of heading instead of end.
+       (outline-up-heading): Push mark for the first call of successive
+       command calls.
+
 2004-04-28  Luc Teirlinck  <teirllm@auburn.edu>
 
        * comint.el (comint-prompt-read-only): New variable.
index 59aeb233fdd8a4fdd6c4f98065fe770ae6680cfa..2985b432824efbdb8c182775f7f75f96d2a320bb 100644 (file)
@@ -349,7 +349,7 @@ at the end of the buffer."
   (if (re-search-forward (concat "\n\\(?:" outline-regexp "\\)")
                         nil 'move)
       (goto-char (match-beginning 0)))
-  (if (and (bolp) (not (bobp)))
+  (if (and (bolp) (eobp) (not (bobp)))
       (forward-char -1)))
 
 (defun outline-next-heading ()
@@ -706,8 +706,8 @@ If FLAG is nil then text is shown, while if FLAG is t the text is hidden."
   "Hide the body directly following this heading."
   (interactive)
   (outline-back-to-heading)
-  (outline-end-of-heading)
   (save-excursion
+    (outline-end-of-heading)
     (outline-flag-region (point) (progn (outline-next-preface) (point)) t)))
 
 (defun show-entry ()
@@ -769,10 +769,7 @@ Show the heading too, if it is currently invisible."
 
 (defun outline-show-heading ()
   "Show the current heading and move to its end."
-  (outline-flag-region (- (point)
-                         (if (bobp) 0
-                           (if (eq (char-before (1- (point))) ?\n)
-                               2 1)))
+  (outline-flag-region (- (point) (if (bobp) 0 1))
                       (progn (outline-end-of-heading) (point))
                       nil))
 
@@ -840,10 +837,7 @@ Show the heading too, if it is currently invisible."
     (if (bolp)
        (progn
          ;; Go to end of line before heading
-         (forward-char -1)
-         (if (bolp)
-             ;; leave blank line before heading
-             (forward-char -1))))))
+         (forward-char -1)))))
 \f
 (defun show-branches ()
   "Show all subheadings of this heading, but not their bodies."
@@ -884,6 +878,8 @@ Default is enough to cause the following heading to appear."
 With argument, move up ARG levels.
 If INVISIBLE-OK is non-nil, also consider invisible lines."
   (interactive "p")
+  (and (eq this-command 'outline-up-heading)
+       (or (eq last-command 'outline-up-heading) (push-mark)))
   (outline-back-to-heading invisible-ok)
   (let ((start-level (funcall outline-level)))
     (if (eq start-level 1)