From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Nikolaj Schumacher Newsgroups: gmane.emacs.help Subject: Re: Cursor stays in middle of frame vertically- minor mode? Date: Fri, 11 Apr 2008 14:44:25 +0200 Message-ID: References: <2af4b$47fcd693$d80c35a9$15591@NAXS.COM> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: ger.gmane.org 1207918039 30434 80.91.229.12 (11 Apr 2008 12:47:19 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Fri, 11 Apr 2008 12:47:19 +0000 (UTC) Cc: EMACS list To: Timothy Hobbs Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Fri Apr 11 14:47:43 2008 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1JkIf1-0005SV-8S for geh-help-gnu-emacs@m.gmane.org; Fri, 11 Apr 2008 14:47:19 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JkIeN-0004xe-Iu for geh-help-gnu-emacs@m.gmane.org; Fri, 11 Apr 2008 08:46:39 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1JkIcM-0003PX-50 for help-gnu-emacs@gnu.org; Fri, 11 Apr 2008 08:44:34 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1JkIcG-0003IY-Br for help-gnu-emacs@gnu.org; Fri, 11 Apr 2008 08:44:32 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1JkIcF-0003I6-UU for help-gnu-emacs@gnu.org; Fri, 11 Apr 2008 08:44:28 -0400 Original-Received: from fmmailgate03.web.de ([217.72.192.234]) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1JkIcF-0006zU-EV for help-gnu-emacs@gnu.org; Fri, 11 Apr 2008 08:44:27 -0400 Original-Received: from smtp08.web.de (fmsmtp08.dlan.cinetic.de [172.20.5.216]) by fmmailgate03.web.de (Postfix) with ESMTP id 1D9CFD6A9B99; Fri, 11 Apr 2008 14:44:26 +0200 (CEST) Original-Received: from [77.135.40.61] (helo=thursday) by smtp08.web.de with asmtp (WEB.DE 4.109 #226) id 1JkIcD-0007QV-00; Fri, 11 Apr 2008 14:44:26 +0200 In-Reply-To: (Timothy Hobbs's message of "Thu\, 10 Apr 2008 21\:14\:09 -0700") User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.2.50 (darwin) X-Sender: n_schumacher@web.de X-Provags-ID: V01U2FsdGVkX19sTHYn+6ihLlmgPM7XQ4MZvPlEN+dYwq/LULkw jX6T3yxqWC/2RtCPD3A14nkMKQfly/LZwurQZIplThABTYmUqf zdRD70OAhzAepAQ8FH5g== X-detected-kernel: by monty-python.gnu.org: Linux 2.4-2.6 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:53241 Archived-At: Timothy Hobbs wrote: > Jens Teich writes: > > Though I'll note that my recenter-non-flashy is not perfect, and since > the flashyness is only a problem with x11 emacs and I use -nw, I use > at home: By flashy, do you mean the redraw that occurs? >From the doc: "If arg is omitted or nil, erase the entire frame and then redraw with point in the center of the current window." Here's what I use. (defun recenter-without-redraw (arg) "Like `recenter', but invert the prefix behavior." (interactive "P") (recenter (if arg (unless (consp arg) (prefix-numeric-value arg)) '(nil . nil)))) But calling (recenter '(nil . nil)) should be enough for non-interactive use. regards, Nikolaj Schumacher