changeset 11421:c53961dfba50

(tabify): Include entire first line in narrowing.
author Richard M. Stallman <rms@gnu.org>
date Thu, 13 Apr 1995 17:04:57 +0000
parents 8ab99c3646a7
children fd0a461e9c72
files lisp/tabify.el
diffstat 1 files changed, 5 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/tabify.el	Thu Apr 13 16:56:05 1995 +0000
+++ b/lisp/tabify.el	Thu Apr 13 17:04:57 1995 +0000
@@ -57,7 +57,11 @@
   (interactive "r")
   (save-excursion
     (save-restriction
-      (narrow-to-region start end)
+      ;; Include the beginning of the line in the narrowing
+      ;; since otherwise it will throw off current-column.
+      (goto-char start)
+      (beginning-of-line)
+      (narrow-to-region (point) end)
       (goto-char start)
       (while (re-search-forward "[ \t][ \t][ \t]*" nil t)
 	(let ((column (current-column))