From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.bugs Subject: bug#69993: Wrap window buffers while cycling Date: Thu, 25 Apr 2024 20:40:51 +0300 Organization: LINKOV.NET Message-ID: <86msph2vdo.fsf@mail.linkov.net> References: <86h6gug41x.fsf@mail.linkov.net> <1e50bd70-8cbb-46f9-9078-dd0e6226da63@gmx.at> <861q7k8gms.fsf@mail.linkov.net> <2d3f0d14-e39b-4399-be30-03f11725c505@gmx.at> <86ttkf6a8r.fsf@mail.linkov.net> <86jzlajpqq.fsf@mail.linkov.net> <85109880-3370-47e0-b7c9-6c5a32cfaafa@gmx.at> <86le5nhwqy.fsf@mail.linkov.net> <864jcajzxi.fsf@mail.linkov.net> <86o7ahglre.fsf@mail.linkov.net> <28a8149b-283a-4b08-9df5-f1139a0fccbe@gmx.at> <86ttk7m7ir.fsf@mail.linkov.net> <1b38c78c-6697-4c6b-81cf-5a72fdd3ba8d@gmx.at> <868r1i8si0.fsf@mail.linkov.net> <867ch09bx6.fsf@mail.linkov.net> <867cgxn7lx.fsf@mail.linkov.net> <86zftrlvo4.fsf@mail.linkov.net> <86zftivhnn.fsf@mail.linkov.net> <1e0dd4b7-5866-4645-a0a5-57850861dd71@gmx.at> Mime-Version: 1.0 Content-Type: text/plain Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="25167"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/30.0.50 (x86_64-pc-linux-gnu) Cc: 69993@debbugs.gnu.org To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Thu Apr 25 19:45:17 2024 Return-path: Envelope-to: geb-bug-gnu-emacs@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 1s039o-0006N9-3l for geb-bug-gnu-emacs@m.gmane-mx.org; Thu, 25 Apr 2024 19:45:16 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s039a-0002Ve-WB; Thu, 25 Apr 2024 13:45:03 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s039T-0002Sl-IZ for bug-gnu-emacs@gnu.org; Thu, 25 Apr 2024 13:44:56 -0400 Original-Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1s039T-0007fx-8o for bug-gnu-emacs@gnu.org; Thu, 25 Apr 2024 13:44:55 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1s039k-0001e2-5g for bug-gnu-emacs@gnu.org; Thu, 25 Apr 2024 13:45:12 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Juri Linkov Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Thu, 25 Apr 2024 17:45:11 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 69993 X-GNU-PR-Package: emacs Original-Received: via spool by 69993-submit@debbugs.gnu.org id=B69993.17140670585727 (code B ref 69993); Thu, 25 Apr 2024 17:45:11 +0000 Original-Received: (at 69993) by debbugs.gnu.org; 25 Apr 2024 17:44:18 +0000 Original-Received: from localhost ([127.0.0.1]:33233 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s038k-0001SW-KJ for submit@debbugs.gnu.org; Thu, 25 Apr 2024 13:44:16 -0400 Original-Received: from relay6-d.mail.gandi.net ([217.70.183.198]:45997) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s038b-0001P2-S0 for 69993@debbugs.gnu.org; Thu, 25 Apr 2024 13:44:06 -0400 Original-Received: by mail.gandi.net (Postfix) with ESMTPSA id CA1A9C0007; Thu, 25 Apr 2024 17:43:36 +0000 (UTC) In-Reply-To: <1e0dd4b7-5866-4645-a0a5-57850861dd71@gmx.at> (martin rudalics's message of "Thu, 25 Apr 2024 10:31:47 +0200") X-GND-Sasl: juri@linkov.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.bugs:283954 Archived-At: >> There is one problem with this line: >> >> (add-to-list 'window-persistent-parameters '(tab-line-buffers . writable)) >> >> This line is needed to be able to use 'window-swap-states' >> because window-state-get/window-state-put should move the window >> parameter 'tab-line-buffers' to the swapped window. > > Why does it have to be "writable"? 'window-swap-states' doesn't care > about "writability". Sorry, I don't know why I missed that cdr can be 't' instead of 'writable'. Now fixed. >> A third solution would be to support a lambda in >> 'window-persistent-parameters' that will process >> the parameter before saving. For example: >> >> (add-to-list 'window-persistent-parameters >> '(tab-line-buffers . (lambda (p) (mapcar #'buffer-name p)))) > > You would call that function in window.el here > > (when (and pers (or (not writable) (eq pers 'writable))) > (setq list (cons (cons (car par) (cdr par)) list))))) > > iff WRITABLE is non-nil and you would not call it here in window.c > > /* If the window has a value for the parameter, > save it. */ > p->window_parameters = Fcons (Fcons (XCAR (par), XCDR (par)), > p->window_parameters); This might be needed later for some other window parameters.