From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Gregory Heytings Newsgroups: gmane.emacs.bugs Subject: bug#64619: [PATCH] Add toggle-window-dedicated command Date: Sat, 19 Aug 2023 16:43:15 +0000 Message-ID: <387ee04aa9601b936ac5@heytings.org> References: <87h6ovgnpn.fsf@catern.com> Mime-Version: 1.0 Content-Type: text/plain; format=flowed; charset=us-ascii Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="40495"; mail-complaints-to="usenet@ciao.gmane.io" Cc: Spencer Baugh , Philip Kaludercic , 64619@debbugs.gnu.org, martin rudalics , Eli Zaretskii , Drew Adams To: sbaugh@catern.com Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Aug 19 18:44:22 2023 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 1qXP3m-000AHo-Az for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 19 Aug 2023 18:44:22 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qXP3U-0001ZC-Q3; Sat, 19 Aug 2023 12:44:04 -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 1qXP3R-0001Pe-An for bug-gnu-emacs@gnu.org; Sat, 19 Aug 2023 12:44:01 -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 1qXP3Q-00038U-PT for bug-gnu-emacs@gnu.org; Sat, 19 Aug 2023 12:44:00 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1qXP3R-0004RA-Ly for bug-gnu-emacs@gnu.org; Sat, 19 Aug 2023 12:44:01 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Gregory Heytings Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 19 Aug 2023 16:44:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 64619 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 64619-submit@debbugs.gnu.org id=B64619.169246340616988 (code B ref 64619); Sat, 19 Aug 2023 16:44:01 +0000 Original-Received: (at 64619) by debbugs.gnu.org; 19 Aug 2023 16:43:26 +0000 Original-Received: from localhost ([127.0.0.1]:52213 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXP2p-0004Pt-7g for submit@debbugs.gnu.org; Sat, 19 Aug 2023 12:43:26 -0400 Original-Received: from heytings.org ([95.142.160.155]:45068) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1qXP2k-0004Pe-9Z for 64619@debbugs.gnu.org; Sat, 19 Aug 2023 12:43:22 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=heytings.org; s=20220101; t=1692463395; bh=1/+truucZJqjBcepAC8U6IROoFZSq2fPUtyWAdYzwGk=; h=Date:From:To:cc:Subject:In-Reply-To:Message-ID:References:From; b=K9xHWhJwzc225KrwOcqNGyXCE0ZUUBbDUBcFpxT2EPWvvxGrYbBS7Vrrsz6+iVvja 6K3vGL0wx9QkPknVZOkHWW2C5qC/CD06FaS80qnA/jbc9Prg6forCPGxWZLbS/PTR9 MVzV6+iUE2Z+DsTzJoCqEtCRR3Ygi627ft6amaK9CjwPBLhpk2bc2hv6dkReVp8ScI DKDyx/KXCG+E+mYUueZOSvHKnDgxDcjcVsb1c3jtzoUHFJtDWaEXfU25PlMltx01h/ wpq1Ri4hc47oauSe7JqIa4bgSI1DgqVJgO63DbzujbQ+lENddAwOWH+/vZ5otv3eAP 03yZlotaZefJA== In-Reply-To: <87h6ovgnpn.fsf@catern.com> 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:267894 Archived-At: >> OK, this patch adds support for making the buffer strongly dedicated >> with a prefix argument, and also adds an indicator to the mode line of >> whether the current window is dedicated (which seems useful even if we >> don't apply the toggle part of this patch). > > Any thoughts on this patch? > Two thoughs: 1. I would simplify the body of toggle-window-dedicated, using (set-window-dedicated-p window (not (window-dedicated-p))) This makes the window "strongly" dedicated, which is more in line with what "Window will now display only its current buffer" promises (e.g. C-x b will refuse to switch to another buffer). 2. I would not bind it to the "d" key but to the "!" key: ISTM that toggling window dedication is not such a common action that it needs a letter key binding.