emacs-devel
[Top][All Lists]
Advanced

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

Re: recenter-ratio (was: Re: Toolbars on MacOSX)


From: Andreas Schwab
Subject: Re: recenter-ratio (was: Re: Toolbars on MacOSX)
Date: Thu, 13 May 2004 11:58:57 +0200
User-agent: Gnus/5.110002 (No Gnus v0.2) Emacs/21.3.50 (gnu/linux)

Juri Linkov <address@hidden> writes:

> @@ -11722,7 +11724,7 @@
>         /* If point does not appear, try to move point so it does
>            appear. The desired matrix has been built above, so we
>            can use it here.  */
> -       new_vpos = window_box_height (w) / 2;
> +       new_vpos = window_box_height (w) / XFLOATINT (Vrecenter_ratio);
>       }
>  
>        if (!make_cursor_line_fully_visible (w, 0))
> @@ -11922,7 +11924,7 @@
>    /* Finally, just choose place to start which centers point */
>  
>   recenter:
> -  centering_position = window_box_height (w) / 2;
> +  centering_position = window_box_height (w) / XFLOATINT (Vrecenter_ratio);
>  
>   point_at_top:
>    /* Jump here with centering_position already set to 0.  */

I think you need to be careful to avoid an infinite redisplay loop when
recenter-ratio does not contain a number.

Andreas.

-- 
Andreas Schwab, SuSE Labs, address@hidden
SuSE Linux AG, Maxfeldstraße 5, 90409 Nürnberg, Germany
Key fingerprint = 58CA 54C7 6D53 942B 1756  01D3 44D5 214B 8276 4ED5
"And now for something completely different."




reply via email to

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