From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Alan Mackenzie Newsgroups: gmane.emacs.devel Subject: Linux console scrollback [ Was: Allowing point to be outside the window? ] Date: Wed, 8 Dec 2021 20:31:00 +0000 Message-ID: References: <87ilwd7zaq.fsf@yahoo.com> <83bl24yaed.fsf@gnu.org> <87sfvg7l51.fsf@yahoo.com> <87r1az6bpy.fsf@yahoo.com> <87ee6nx42p.fsf@ankarstrom.se> <834k7jxo33.fsf@gnu.org> <87zgpbi5ma.fsf@ankarstrom.se> <86ilvyrhts.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="40695"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Rudolf Schlatte , emacs-devel@gnu.org To: Juri Linkov Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Wed Dec 08 21:33:35 2021 Return-path: Envelope-to: ged-emacs-devel@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1mv3d9-000AP3-5n for ged-emacs-devel@m.gmane-mx.org; Wed, 08 Dec 2021 21:33:35 +0100 Original-Received: from localhost ([::1]:53902 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mv3d8-0004a8-7M for ged-emacs-devel@m.gmane-mx.org; Wed, 08 Dec 2021 15:33:34 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:53828) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mv3ap-0000j9-0x for emacs-devel@gnu.org; Wed, 08 Dec 2021 15:31:11 -0500 Original-Received: from colin.muc.de ([193.149.48.1]:39067 helo=mail.muc.de) by eggs.gnu.org with smtp (Exim 4.90_1) (envelope-from ) id 1mv3ah-00014g-6d for emacs-devel@gnu.org; Wed, 08 Dec 2021 15:31:07 -0500 Original-Received: (qmail 39602 invoked by uid 3782); 8 Dec 2021 20:31:00 -0000 Original-Received: from acm.muc.de (p4fe15d44.dip0.t-ipconnect.de [79.225.93.68]) (using STARTTLS) by colin.muc.de (tmda-ofmipd) with ESMTP; Wed, 08 Dec 2021 21:31:00 +0100 Original-Received: (qmail 1614 invoked by uid 1000); 8 Dec 2021 20:31:00 -0000 Content-Disposition: inline In-Reply-To: <86ilvyrhts.fsf@mail.linkov.net> X-Submission-Agent: TMDA/1.3.x (Ph3nix) X-Primary-Address: acm@muc.de Received-SPF: pass client-ip=193.149.48.1; envelope-from=acm@muc.de; helo=mail.muc.de X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: "Emacs-devel" Xref: news.gmane.io gmane.emacs.devel:281392 Archived-At: Hello, Juri. On Wed, Dec 08, 2021 at 21:56:47 +0200, Juri Linkov wrote: > > I briefly tested with two contemporary editors (Atom and VS Code), and > > their behavior indeed differs between mouse-based and keyboard-based > > scrolling: in the former case (scrolling via mouse), the cursor stays > > put and moves out of view, while in the latter case (scrolling via the > > PgDn key), the cursor changes position to stay on screen. > Linux console supported keyboard-based scrolling with > Shift-PageDown/PageUp where the cursor stays on the command line and it > scrolls back on a key press, but recently this feature was removed. Just as a matter of interest, I've hacked the Linux sources to put this essential feature back again, in an improved fashion. Where previously one scrollback buffer was shared by all the tty's, causing the scrollback to be lost on moving to a different tty, now each tty has its own buffer which does not lose its contents by such a move. I've published the patch on the Gentoo user's list. It is slightly different for different kernel major versions. If anybody is interested in this patch, and can't be bothered to dig it out of the Gentoo list archive, feel free to send me an email, and I will reply with the patch and (short) directions for its use. -- Alan Mackenzie (Nuremberg, Germany).