emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] Changes to emacs/lisp/emulation/tpu-edt.el,v


From: Miles Bader
Subject: [Emacs-diffs] Changes to emacs/lisp/emulation/tpu-edt.el,v
Date: Mon, 13 Aug 2007 13:42:54 +0000

CVSROOT:        /cvsroot/emacs
Module name:    emacs
Changes by:     Miles Bader <miles>     07/08/13 13:41:28

Index: lisp/emulation/tpu-edt.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/emulation/tpu-edt.el,v
retrieving revision 1.53
retrieving revision 1.54
diff -u -b -r1.53 -r1.54
--- lisp/emulation/tpu-edt.el   3 Aug 2007 05:49:59 -0000       1.53
+++ lisp/emulation/tpu-edt.el   13 Aug 2007 13:41:26 -0000      1.54
@@ -792,10 +792,13 @@
         (use-local-map tpu-buffer-local-map)))
   (local-set-key key func))
 
-(defun tpu-current-line nil
+(defun tpu-current-line ()
   "Return the vertical position of point in the selected window.
 Top line is 0.  Counts each text line only once, even if it wraps."
-  (+ (count-lines (window-start) (point)) (if (= (current-column) 0) 1 0) -1))
+  (or
+   (cdr (nth 6 (posn-at-point)))
+   (if (eq (window-start) (point)) 0
+     (1- (count-screen-lines (window-start) (point) 'count-final-newline)))))
 
 
 ;;;
@@ -2422,6 +2425,7 @@
         (if (eq tpu-global-map parent)
             (set-keymap-parent map (keymap-parent parent))
           (setq map parent)))))
+  (ad-disable-regexp "\\`tpu-")
   (setq tpu-edt-mode nil))
 
 (provide 'tpu-edt)




reply via email to

[Prev in Thread] Current Thread [Next in Thread]