From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#52973: Adding a few context-menu-mode commands Date: Tue, 04 Jan 2022 14:26:59 +0200 Message-ID: <83o84rbsa4.fsf@gnu.org> References: <87o84tp69h.fsf@posteo.net> <83pmp9c7j9.fsf@gnu.org> <877dbhoril.fsf@posteo.net> <837dbgdh51.fsf@gnu.org> <871r1opwbi.fsf@posteo.net> <86mtkcr02p.fsf@mail.linkov.net> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="30154"; mail-complaints-to="usenet@ciao.gmane.io" Cc: philipk@posteo.net, 52973@debbugs.gnu.org To: Juri Linkov Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Tue Jan 04 13:28:22 2022 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 1n4ivO-0007cy-4l for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 04 Jan 2022 13:28:22 +0100 Original-Received: from localhost ([::1]:50014 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1n4ivM-0007dU-Ex for geb-bug-gnu-emacs@m.gmane-mx.org; Tue, 04 Jan 2022 07:28:20 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:44674) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n4iv4-0007dI-Td for bug-gnu-emacs@gnu.org; Tue, 04 Jan 2022 07:28:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:53787) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1n4iv4-00027K-KL for bug-gnu-emacs@gnu.org; Tue, 04 Jan 2022 07:28:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1n4iv4-0005eU-DR for bug-gnu-emacs@gnu.org; Tue, 04 Jan 2022 07:28:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 04 Jan 2022 12:28:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 52973 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: patch Original-Received: via spool by 52973-submit@debbugs.gnu.org id=B52973.164129922521647 (code B ref 52973); Tue, 04 Jan 2022 12:28:02 +0000 Original-Received: (at 52973) by debbugs.gnu.org; 4 Jan 2022 12:27:05 +0000 Original-Received: from localhost ([127.0.0.1]:37100 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4iu9-0005d5-8X for submit@debbugs.gnu.org; Tue, 04 Jan 2022 07:27:05 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:43674) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4iu4-0005cS-9d for 52973@debbugs.gnu.org; Tue, 04 Jan 2022 07:27:03 -0500 Original-Received: from [2001:470:142:3::e] (port=44354 helo=fencepost.gnu.org) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n4ity-0001uJ-Oh; Tue, 04 Jan 2022 07:26:54 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-version:References:Subject:In-Reply-To:To:From: Date; bh=cM/EWlZGa5i+zogtIsUOv4AOKJ4xWHlutJ/gUCZHJpw=; b=r4hSHvdyXJkqoitpY6qw ZKodJ9gmTew5sxk8+3fmfF00diXrIp7T11yxNRFVWAArLiq2JDIdNSYUS0TtL34JW0OvTafU/E/nz nr/KlpeIvJh242VdkLmzkDKHzAFJt0NCvh194HFYum50HwmC8blFNMX0ATlWZL+6GLE58rEeVcMbA 5zl9rh0sa6/9lN8fBZH+3sgjEJxH4+lIYVkpQkDQQmtCiLi+hD/Iun1PWC8nw+kZglqhp4TBBiWdD pH8A1+k1So4CGabuv8/Ap6uuwHmq8InlYGZ4R6wW23jD9iH0998Dq8fSXPGTy2h7opgM1S+Zydwm5 bIuMFMvTG1NhYQ==; Original-Received: from [87.69.77.57] (port=1688 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n4itx-0006mc-Pg; Tue, 04 Jan 2022 07:26:55 -0500 In-Reply-To: <86mtkcr02p.fsf@mail.linkov.net> (message from Juri Linkov on Mon, 03 Jan 2022 23:17:18 +0200) 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" Xref: news.gmane.io gmane.emacs.bugs:223640 Archived-At: > From: Juri Linkov > Cc: Eli Zaretskii , 52973@debbugs.gnu.org > Date: Mon, 03 Jan 2022 23:17:18 +0200 > > >>> > Maybe I'm missing something, but I don't see the actual integration > >>> > with context-menu-mode? > >>> > >>> Each commit adds a function that can be added to context-menu-functions. > >> > >> That was my guess, but without having those additions, not even as a > >> user option, or (better) automagically when context-menu-mode is > >> turned on, those functions are just dead ballast, aren't they? > > > > From my understanding of bug#50552, this was preferred. > > bug#50552 proposed to add to every package such lines: > > (custom-add-choice 'context-menu-functions > '(function-item :tag "Dictionary menu" context-menu-dictionary)) > > but 'custom-add-choice' fails on the current structure of > 'context-menu-functions', so either a new function 'custom-add-repeat-choice' > should be created, or better would be to improve the existing > 'custom-add-choice' to handle the choices inside 'repeat'. How about add-context-menu-items, or something to that effect? We are talking about quite a different feature to "add", IMO, so a new API would be better, I think. And it doesn't have to have anything to do with custom.el. But in any case, we need to do this soon, because adding functions that are not used unless the user plays with hooks is not clean, definitely not for a feature such as this one, because it's supposed to be very easy, ideally seamless, to activate. Otherwise it would be against the raisons d'ĂȘtre of the feature.