From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Stephen Berman via "Bug reports for GNU Emacs, the Swiss army knife of text editors" Newsgroups: gmane.emacs.bugs Subject: bug#70413: 30.0.50; FR: skip inactive widgets when tabbing Date: Wed, 17 Apr 2024 00:04:33 +0200 Message-ID: <87r0f5otfy.fsf@gmx.net> References: <87zfttpstx.fsf@gmx.net> <865xwhjwo3.fsf@gnu.org> <87v84hott7.fsf@gmx.net> Reply-To: Stephen Berman Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="28951"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Gnus/5.13 (Gnus v5.13) Cc: 70413@debbugs.gnu.org To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Wed Apr 17 00:05: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 1rwqvV-0007HL-7E for geb-bug-gnu-emacs@m.gmane-mx.org; Wed, 17 Apr 2024 00:05:17 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rwqv7-00011x-QM; Tue, 16 Apr 2024 18:04:53 -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 1rwqv6-00011e-46 for bug-gnu-emacs@gnu.org; Tue, 16 Apr 2024 18:04:52 -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 1rwqv5-0005Jx-Pg for bug-gnu-emacs@gnu.org; Tue, 16 Apr 2024 18:04:51 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rwqvI-0006hE-85 for bug-gnu-emacs@gnu.org; Tue, 16 Apr 2024 18:05:04 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Stephen Berman Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 16 Apr 2024 22:05:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70413 X-GNU-PR-Package: emacs Original-Received: via spool by 70413-submit@debbugs.gnu.org id=B70413.171330509825673 (code B ref 70413); Tue, 16 Apr 2024 22:05:04 +0000 Original-Received: (at 70413) by debbugs.gnu.org; 16 Apr 2024 22:04:58 +0000 Original-Received: from localhost ([127.0.0.1]:45292 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rwqvB-0006fz-I5 for submit@debbugs.gnu.org; Tue, 16 Apr 2024 18:04:58 -0400 Original-Received: from mout.gmx.net ([212.227.17.20]:40229) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rwqv6-0006et-MH for 70413@debbugs.gnu.org; Tue, 16 Apr 2024 18:04:55 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmx.net; s=s31663417; t=1713305074; x=1713909874; i=stephen.berman@gmx.net; bh=d4b2ghEJsKrnlHHAHYyK1waopPnQmbuS87D5qm0QK3M=; h=X-UI-Sender-Class:From:To:Cc:Subject:In-Reply-To:References:Date: Message-ID:MIME-Version:Content-Type:cc:content-transfer-encoding: content-type:date:from:message-id:mime-version:reply-to:subject: to; b=TYNycwKyo3SxNN0WmyeFScC+7zhU65sQBM327uLPHYAqQoymwYGpIrGLSF+DNVaz wkUO61FjL6FdfrBH4wm3aqdbveFxvf9bHv4CTruS7JY9Cwh9fv6O8mS9wWBtKjKkG +BHduRIpmn4fBb6r41heTInL9lV6XL0gUuQBoqXMpZSr3tt2R6q13q01xpcH5U68c gT3ntjFKDSebWWSCVQXd26XmSxb1cBobfiOzmr05OGmlVGBqCohngVNJ86YuY56u2 l+asFnZkAQod5nPGF2E5YsDZfqqQXm4w1tP85SFbHot2eSyw2YR6z3+aDZnDqiTb9 I6QveTpcOnugjOjiLw== X-UI-Sender-Class: 724b4f7f-cbec-4199-ad4e-598c01a50d3a Original-Received: from strobelfs ([88.130.48.38]) by mail.gmx.net (mrgmx105 [212.227.17.168]) with ESMTPSA (Nemesis) id 1M4JmT-1rx7tj03Wr-000KeA; Wed, 17 Apr 2024 00:04:34 +0200 In-Reply-To: <87v84hott7.fsf@gmx.net> (Stephen Berman's message of "Tue, 16 Apr 2024 23:56:36 +0200") X-Provags-ID: V03:K1:4MILmmyAJtItaZYkdazl6IyeCeF95w8KoAIIH7Y098hKzQAFe3I DW87KGDrdec9bEB1oOsNQYmdfuQCVN4XDg16rrFUNf7dY0MZ7D6XomXV/ZZuBp/4BFiC76m 6PDvQXpXuiz9F5BuWdWqFyt5f37LllGQpEmF6AzdK/agCqHDFS3sfnJqYgSncxT/Yu1S+VN W5EVU5Ec2LC4pBHvXcUhQ== UI-OutboundReport: notjunk:1;M01:P0:5oA2vUI3Yyw=;t88J+FiSsDPKxP6YCIUV4Gur1sb +eEEWocgVQx+0dj+q9JXjH4WjDdDs1J3lawiqOEwNU7Td5hsR2VmPMqyqsO1Vywh8pqD814EB I5KkuoKJRQYhHS21PhFdDCtETl681o0exIE19wBXCD+QbJa7+dq+wc850zaVfSnXZ6V9BpVAc G5UTgE3+o3CT/xWC9qzdgC5n7+YMHz6S5iHjLur9RQy+0nbnzlnA269Oa4QaKiBhkMl7dmmRO EtxqZIsGWfB72LlWTLy/ZG3b2Yh+770QxLgLRaPiuzkHkLmXGL4ir27Ovs81SNVFrH48pldiP XWO6g1NArakaJRyEwJCKoDXbQVZPKdyiByuC9Fc9uNzpZag3JYnNHFj0QGujVlUkmw98WGeU3 Z00sq8LEzqdCN+swnJHPIZMU7od9Rf27wxfApBYLSELtKVma5nr4SxIPVSJrpZl2LnEziCNod 4Lg0Dp6gf9h1mL2xszjLh1EEsWLCwUVH8R2gj7ykQA8VkWO2NhspwEMpqNruQEWodK1yWr6Wv 92F5UlXrdUa1YlB1ywykoJ7kloBJLFwAW3ipIGDKkfbB0nHYRQaZ0APMBAMqhf4RX8dGWp9tc PWq9t4cjjNy4oszxTK3AkA64vEp+dK1eGB3d4OGhzDSFId1x8a4HE8M+IfXiYKvh3l4bjpKso YIGWQyl1HtnC6haNaeMqrimdiiF9FKqsA1gJ/g/s3cYGrw1PksiwAmQK3iieX9DR4rXlWBln9 A3sP4NlhcfAjqiFao0n6Aa51TYVTN1QPcvTfDoT/eH+JRcLt235oj1LxRUp3EScOYIIhmdKH 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:283461 Archived-At: --=-=-= Content-Type: text/plain Content-Transfer-Encoding: quoted-printable On Tue, 16 Apr 2024 23:56:36 +0200 Stephen Berman = wrote: > On Tue, 16 Apr 2024 15:53:48 +0300 Eli Zaretskii wrote: > >>> Date: Tue, 16 Apr 2024 11:20:10 +0200 >>> From: Stephen Berman via "Bug reports for GNU Emacs, >>> the Swiss army knife of text editors" >>> >>> In buffers containing widgets, such as the Customize buffers, the >>> widgets can be either active or inactive: when you click (with the mou= se >>> or RET) on an active widget, its associated action is executed, and wh= en >>> you click on an inactive widget, this raises the error "Attempt to >>> perform action on inactive widget". You can navigate among the widget= s >>> by pressing TAB or S-TAB to move point to the next or previous widget. >>> >>> I think it would be useful and convenient to skip over inactive widget= s >>> when tabbing; e.g. you then avoid accidentally tabbing to an inactive >>> widget, typing RET and getting the error, and in a buffer with many >>> active and inactive widgets, you can tab more quickly to the desired >>> active widget by skipping over the inactive ones. >>> >>> The attached patch implements this behavior. Since tabbing to inactiv= e >>> widgets has always been the behavior in the widget library, skipping i= s >>> conditioned on the value of a boolean defcustom, with the default bein= g >>> the current non-skipping. >> >> This is OK, but please announce this new option in NEWS. > > Thanks; see the attached patch. I think this user option should also be > documented in the Widget manual, so the patch includes that as well. > The Widget manual has a node for widget customizations, so I added it > there. But I think it is helpful to mention it also in the node > "Widgets and the Buffer", where the tabbing commands `widget-forward' > and `widget-backward' are documented, so that patch does that too. If > you confirm this is ok, I'll push the code and doc changes to master. > > Steve Berman ... and here's the patch: --=-=-= Content-Type: text/x-patch Content-Disposition: attachment Content-Description: widget doc and NEWS patch Content-Transfer-Encoding: quoted-printable diff --git a/doc/misc/widget.texi b/doc/misc/widget.texi index cfb9d2211cf..154d8446b75 100644 =2D-- a/doc/misc/widget.texi +++ b/doc/misc/widget.texi @@ -795,6 +795,11 @@ Widgets and the Buffer @end deffn @end table +@noindent +By default, tabbing can put point on an inactive widget. To skip over +inactive widgets when tabbing, set the user option +@code{widget-skip-inactive} to a non-@code{nil} value. +@xref{Customization}. When editing an @code{editable-field} widget, the following commands are available: @@ -3321,6 +3326,15 @@ Customization By default, its value is @code{nil}. @end defopt +@defopt widget-skip-inactive +If non-@code{nil}, navigating between widgets by @kbd{M-@key{TAB}} +(@code{widget-forward}) or @kbd{S-@key{TAB}} (@code{widget-backward}, +also bound to @kbd{M-@key{TAB}}) skips over inactive widgets. + +By default, its value is @code{nil} and tabbing does not skip over +inactive widgets. +@end defopt + @defopt widget-documentation-links If non-@code{nil}, add hyperlinks to documentation strings. @end defopt diff --git a/etc/NEWS b/etc/NEWS index 99f33a7b8dd..7b87e0b17c5 100644 =2D-- a/etc/NEWS +++ b/etc/NEWS @@ -1603,6 +1603,13 @@ This allows disabling JavaScript in xwidget Webkit = sessions. 'insert-directory', now supports the '--time=3DTIME' and '--sort=3Dtime' options of GNU 'ls'. +** Widget + ++++ +*** New user option 'widget-skip-inactive'. +If non-nil, moving point forward or backward between widgets by typing +TAB or S-TAB skips over inactive widgets. The default value is nil. + =0C * New Modes and Packages in Emacs 30.1 --=-=-=--