bug-gnu-emacs
[Top][All Lists]
Advanced

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

bug#30747: Emacs lacks a command to horizontally recenter


From: Eli Zaretskii
Subject: bug#30747: Emacs lacks a command to horizontally recenter
Date: Fri, 25 Jun 2021 17:59:23 +0300

> From: Lars Ingebrigtsen <larsi@gnus.org>
> Date: Fri, 25 Jun 2021 16:46:28 +0200
> Cc: 30747@debbugs.gnu.org
> 
> > The future horizontal-recenter command (please implement) should keep
> > the cursor upon the same character (x), but just move the view screen ([
> > ]) so that x is now in the center.
> >
> > ......[.......x..]...... BEFORE
> > .........[....x.....]... AFTER
> 
> So this would only be for buffers where truncate-lines is non-nil?

No, also in partial-width windows (as in after "C-x 3").

> Yes, it'd be handy to have such a command...  or perhaps `C-l'
> should just do this automatically (in these buffers)?
> 
> Any opinions?

Since lines are generally not all of the same width, such horizontal
scrolling can only guarantee to center one line, and sometimes cannot
center it at all (if it's narrower than the window).  I wonder whether
the OP indeed understands what he will get as result of implementing
this feature.





reply via email to

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