# HG changeset patch # User Chong Yidong # Date 1177700186 0 # Node ID 7be6bca439a565b7d843da4d2c969c9f7b89f0b5 # Parent 98b0586210402d857f4700648a91e855d3385964 (flyspell-auto-correct-previous-word): Use window-start and window-end. diff -r 98b058621040 -r 7be6bca439a5 lisp/textmodes/flyspell.el --- a/lisp/textmodes/flyspell.el Fri Apr 27 18:56:16 2007 +0000 +++ b/lisp/textmodes/flyspell.el Fri Apr 27 18:56:26 2007 +0000 @@ -1961,12 +1961,8 @@ But don't look beyond what's visible on the screen." (interactive "d") - (let (top bot) - (save-excursion - (move-to-window-line 0) - (setq top (point)) - (move-to-window-line -1) - (setq bot (point))) + (let ((top (window-start)) + (bot (window-end))) (save-excursion (save-restriction (narrow-to-region top bot)