From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 03 03:37:08 2022 Received: (at submit) by debbugs.gnu.org; 3 Jan 2022 08:37:08 +0000 Received: from localhost ([127.0.0.1]:34072 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4Iq4-0007Yk-3Z for submit@debbugs.gnu.org; Mon, 03 Jan 2022 03:37:08 -0500 Received: from lists.gnu.org ([209.51.188.17]:52360) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4Ipz-0007YY-5v for submit@debbugs.gnu.org; Mon, 03 Jan 2022 03:37:06 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43516) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n4Ipy-0000Ls-UR for bug-gnu-emacs@gnu.org; Mon, 03 Jan 2022 03:37:02 -0500 Received: from mout02.posteo.de ([185.67.36.66]:39869) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1n4Ipw-0000SC-9Z for bug-gnu-emacs@gnu.org; Mon, 03 Jan 2022 03:37:02 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout02.posteo.de (Postfix) with ESMTPS id E5A91240104 for ; Mon, 3 Jan 2022 09:36:57 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1641199017; bh=yXjX+coZi1dpSnbqlH2gtaU2AKBbaI7KqdzmTxkmcM8=; h=From:To:Subject:Date:Autocrypt:From; b=Abj7HMJiF0zumELIz3sn5Qm21Ff5GpEaH6gY0WVXx8m0/txwx2T/yPKFQH0PWAxOc /EJai652jWNwqvFbfQj+/sA2kQO/SX7M6ISYwR6mvv3T/x6rUuTuVhCAwB0Waawh7C Tjt6HQNpHTjsjc5uPmaB/FvBAG9S9mBU5NyHJqSgT8Gz87A1oqnTjhupd9WeB8mK34 FhAUx9pVIf6CQTbjOT4nw/Csp/LsBMHqqpasBdmhzBHkAhGvnsbuZJqbbwfxrflfB9 naAADenU0V/bA8yYmtiT+0RBpkSVyEPdZnf7XmSO/bhWdAurRyI0wIY1KgK9uqGJAY 9yul5/NoMViOw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JS8HY2Qmpz9rxD for ; Mon, 3 Jan 2022 09:36:57 +0100 (CET) From: Philip Kaludercic To: bug-gnu-emacs@gnu.org Subject: Adding a few context-menu-mode commands Date: Mon, 03 Jan 2022 08:34:18 +0000 Message-ID: <87o84tp69h.fsf@posteo.net> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" Received-SPF: pass client-ip=185.67.36.66; envelope-from=philipk@posteo.net; helo=mout02.posteo.de X-Spam_score_int: -24 X-Spam_score: -2.5 X-Spam_bar: -- X-Spam_report: (-2.5 / 5.0 requ) DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_MED=-2.3, RCVD_IN_MSPIKE_H3=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) --=-=-= Content-Type: text/plain Tags: patch Hi, I am attaching a few patches adding a few features for context-menu-mode, that I mentioned and explained here: https://ruzkuku.com/texts/emacs-mouse.html. Would it be OK to add these to Emacs itself? In GNU Emacs 29.0.50 (build 5, x86_64-pc-linux-gnu, GTK+ Version 3.24.30, cairo version 1.16.0) of 2021-12-25 built on viero Repository revision: f9d518bc2f333e03d5e7c4e935b08fbe19f33c5b Repository branch: master Windowing system distributor 'The X.Org Foundation', version 11.0.12011000 --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0001-Implement-context-menu-mode-support-for-man-pages.patch >From 17cd2634df3f71155efa5b9e534850f473b5b05e Mon Sep 17 00:00:00 2001 From: Philip Kaludercic Date: Fri, 31 Dec 2021 12:37:50 +0100 Subject: [PATCH 1/3] Implement context-menu-mode support for man pages * man.el (Man-at-mouse): Add new command (Man-context-menu): Add new function --- lisp/man.el | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/lisp/man.el b/lisp/man.el index fff31baa5f..2f956525d3 100644 --- a/lisp/man.el +++ b/lisp/man.el @@ -1976,6 +1976,29 @@ Man-bookmark-jump (bookmark-default-handler `("" (buffer . ,buf) . ,(bookmark-get-bookmark-record bookmark))))) +;;; Mouse support +(defun Man-at-mouse (e) + "Open man manual at point." + (interactive "e") + (save-excursion + (mouse-set-point e) + (man (Man-default-man-entry)))) + +(defun Man-context-menu (menu click) + "Populate MENU with commands that open a man page at point." + (save-excursion + (mouse-set-point click) + (when (save-excursion + (skip-syntax-backward "^ ") + (and (looking-at + "[[:space:]]*\\([[:alnum:]_-]+([[:alnum:]]+)\\)") + (match-string 1))) + (define-key-after menu [man-separator] menu-bar-separator) + (define-key-after menu [man-at-mouse] + '(menu-item "Open man page" man-at-mouse + :help "Open man page around mouse click")))) + menu) + ;; Init the man package variables, if not already done. (Man-init-defvars) -- 2.34.0 --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0002-Implement-context-menu-mode-support-for-hi-lock.patch >From d08f6ef980b1e6464af112f692cfdaed1a6d7256 Mon Sep 17 00:00:00 2001 From: Philip Kaludercic Date: Fri, 31 Dec 2021 12:45:52 +0100 Subject: [PATCH 2/3] Implement context-menu-mode support for hi-lock * hi-lock.el (hi-lock-symbol-at-mouse): Add new command (hi-lock-context-menu): Add new function --- lisp/hi-lock.el | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/lisp/hi-lock.el b/lisp/hi-lock.el index 7d126cb558..5d99fb5288 100644 --- a/lisp/hi-lock.el +++ b/lisp/hi-lock.el @@ -854,6 +854,25 @@ hi-lock-unload-function ;; continue standard unloading nil) +;;; Mouse support +(defun hi-lock-symbol-at-mouse (event) + "Highlight symbol at mouse click EVENT." + (interactive "e") + (save-excursion + (mouse-set-point event) + (highlight-symbol-at-point))) + +(defun hi-lock-context-menu (menu click) + "Populate MENU with a menu item to highlight symbol at CLICK." + (save-excursion + (mouse-set-point click) + (when (symbol-at-point) + (define-key-after menu [highlight-search-separator] menu-bar-separator) + (define-key-after menu [highlight-search-mouse] + '(menu-item "Highlight Symbol" highlight-symbol-at-mouse + :help "Highlight symbol at point")))) + menu) + (provide 'hi-lock) ;;; hi-lock.el ends here -- 2.34.0 --=-=-= Content-Type: text/x-patch Content-Disposition: attachment; filename=0003-Add-command-to-invoke-a-search-engine.patch >From c5fbec3e04c5e4ef641ff8f99d9c2a58f3c8a770 Mon Sep 17 00:00:00 2001 From: Philip Kaludercic Date: Fri, 31 Dec 2021 15:21:13 +0100 Subject: [PATCH 3/3] Add command to invoke a search engine * mouse.el (context-menu-online-search): Add new function (eww-search-prefix): Declare variable from eww.el (mouse-online-search-at-point): Add new command --- lisp/mouse.el | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/lisp/mouse.el b/lisp/mouse.el index 11fdd3f639..edf4504bdd 100644 --- a/lisp/mouse.el +++ b/lisp/mouse.el @@ -523,6 +523,16 @@ context-menu-ffap :help "Find file or URL from text around mouse click")))) menu) +(defun context-menu-online-search (menu click) + "Populate MENU with command to search online." + (save-excursion + (mouse-set-point click) + (define-key-after menu [online-search-separator] menu-bar-separator) + (define-key-after menu [online-search-at-mouse] + '(menu-item "Online search" mouse-online-search-at-point + :help "Search for region or word online"))) + menu) + (defvar context-menu-entry `(menu-item ,(purecopy "Context Menu") ,(make-sparse-keymap) :filter ,(lambda (_) (context-menu-map))) @@ -3209,6 +3219,26 @@ mouse-drag-and-drop-region (with-current-buffer (window-buffer window) (setq cursor-type (nth 3 state))))))) +(defvar eww-search-prefix) +(defun mouse-online-search-at-point (event) + "Query an online search engine at EVENT. +If a region is active, the entire region will be sent, otherwise +the symbol at point will be used. This command uses EWW's +default search engine, as configured by `eww-search-prefix'." + (interactive "e") + (require 'eww) + (let ((query (if (use-region-p) + (buffer-substring (region-beginning) + (region-end)) + (save-excursion + (mouse-set-point event) + (thing-at-point 'symbol))))) + (unless query + (user-error "Nothing to search for")) + (browse-url (concat + eww-search-prefix + (mapconcat #'url-hexify-string (split-string query) "+"))))) + ;;; Bindings for mouse commands. -- 2.34.0 --=-=-= Content-Type: text/plain -- Philip Kaludercic --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 03 07:45:36 2022 Received: (at 52973) by debbugs.gnu.org; 3 Jan 2022 12:45:36 +0000 Received: from localhost ([127.0.0.1]:34317 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4MiW-00023r-If for submit@debbugs.gnu.org; Mon, 03 Jan 2022 07:45:36 -0500 Received: from eggs.gnu.org ([209.51.188.92]:39750) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4MiS-00023a-BU for 52973@debbugs.gnu.org; Mon, 03 Jan 2022 07:45:35 -0500 Received: from [2001:470:142:3::e] (port=50226 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 1n4MiN-0003xb-0D; Mon, 03 Jan 2022 07:45:27 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=U8PeJ8DTqFJHyI7qfhra4ILskFO0OMnov6RZv2BoqpM=; b=RodzghMiWtue G16qIjgbD7S2VI8Xl0oGi0o389GaeMp+YvKDy1aToj0Xq8X9BVdF3uxV5YZOa7MFqC6hMmkMVCTek +G7DB2hY1nW/CfGIh1aVKU6Uw+LkLZ/LupSiuRxiSC4grCard8IdxRHFaV0xgt1sNRyEcDN80Km7Q FpG00VAbXpKN0ixpX+xZ/2qRtlBMJcENcLmMycEmMiZ9vfgqaZjwNm5j7VGSPLgpwPnySR9FmMHuY DM9onJFMft1r25ugz6ywVHWsmKz7Doz8VPz/5ySR3jDFay9hTrzGjWxa+SyJHvPifnV8EMDzYaYxX lS9Aj/6IIC3ATlYXD83eqw==; Received: from [87.69.77.57] (port=1716 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 1n4Mi6-0007oh-EZ; Mon, 03 Jan 2022 07:45:22 -0500 Date: Mon, 03 Jan 2022 14:45:14 +0200 Message-Id: <83pmp9c7j9.fsf@gnu.org> From: Eli Zaretskii To: Philip Kaludercic In-Reply-To: <87o84tp69h.fsf@posteo.net> (message from Philip Kaludercic on Mon, 03 Jan 2022 08:34:18 +0000) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Philip Kaludercic > Date: Mon, 03 Jan 2022 08:34:18 +0000 > > I am attaching a few patches adding a few features for > context-menu-mode, that I mentioned and explained here: > https://ruzkuku.com/texts/emacs-mouse.html. > > Would it be OK to add these to Emacs itself? Maybe I'm missing something, but I don't see the actual integration with context-menu-mode? From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 03 08:53:01 2022 Received: (at 52973) by debbugs.gnu.org; 3 Jan 2022 13:53:01 +0000 Received: from localhost ([127.0.0.1]:34431 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4Nll-0003zk-2k for submit@debbugs.gnu.org; Mon, 03 Jan 2022 08:53:01 -0500 Received: from mout01.posteo.de ([185.67.36.65]:56587) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4Nli-0003zV-PZ for 52973@debbugs.gnu.org; Mon, 03 Jan 2022 08:53:00 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id F38C1240029 for <52973@debbugs.gnu.org>; Mon, 3 Jan 2022 14:52:52 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1641217973; bh=KUijoNjbRPCKhemvaB00oKcVqvgP8anFDY0ftscy82A=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=ZHS1YGo/r9yEpNoRGLfbpIADXoXrnshtI2emKF8GqMTA43p+WoverGG0Cu2zYcPef Dz6uoXcYU/JNyyBERbYOEz59t7kiWdnVeGCpFoiroahUDbFJgCuNHkAWkOge8A2Q60 ieBqZEbP7539czIgaeIGgxjGQ/uMHRbuajQgck54ncOVDa+Y31AaAq3OV0NWcxWb30 +j19HecPo3SiuYdqXokRqCP4R6T85RkQDzAwgh/ki73XkdhvuJIZFAD2DZI1gXcK+J 2c8EFKO4DlroVdXrSDdeL13iwd8pSsMT3a4RgJfXS5WVTct0nb3eHfC4SdzQyK1GbC ua+12g+0N2bNw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JSHJ41DNBz6tn4; Mon, 3 Jan 2022 14:52:51 +0100 (CET) From: Philip Kaludercic To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <83pmp9c7j9.fsf@gnu.org> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Mon, 03 Jan 2022 13:52:50 +0000 In-Reply-To: <83pmp9c7j9.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 03 Jan 2022 14:45:14 +0200") Message-ID: <877dbhoril.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> From: Philip Kaludercic >> Date: Mon, 03 Jan 2022 08:34:18 +0000 >> >> I am attaching a few patches adding a few features for >> context-menu-mode, that I mentioned and explained here: >> https://ruzkuku.com/texts/emacs-mouse.html. >> >> Would it be OK to add these to Emacs itself? > > 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. -- Philip Kaludercic From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 03 09:32:30 2022 Received: (at 52973) by debbugs.gnu.org; 3 Jan 2022 14:32:30 +0000 Received: from localhost ([127.0.0.1]:34509 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4ONy-00056V-8P for submit@debbugs.gnu.org; Mon, 03 Jan 2022 09:32:30 -0500 Received: from eggs.gnu.org ([209.51.188.92]:48722) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4ONu-00056E-1m for 52973@debbugs.gnu.org; Mon, 03 Jan 2022 09:32:28 -0500 Received: from [2001:470:142:3::e] (port=52402 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 1n4ONo-0005IA-PU; Mon, 03 Jan 2022 09:32:20 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=AqalVLzBPwQkdIgbGsdq3bttHgu8cVRwS1vTFxWQFMw=; b=kgd59MsEinUh /ae5XZ0ZJ0pz8Yt7I1p8oTh+38V+OB/52Mtwn3MF1owUz+RrDoQcb3Humpq/30gduKbbqGsuOWqtE NuvMK0GTUh2vuXjbwaQnTX2kyRM4DS44uwChxuutkpDoAXjzF82ng5fRsE/e6YMkFN3U3EBBmBgEX V/AygPquUJe6Mvt1qodtXpjX2JzhKKtQImEKuS7FFZ0qGzdiiJlJKFjhPYlK+/ngAX5tSog+wNi0Q ht9RKulw8ipPegP7Rdq0y8QTIVI8clCMoLmgOnxl7fcheRc+zwj1ONQFtHUq2rGxLKZ1DpSG2NlTV cjRHPd2RQefMC95l7TIcGg==; Received: from [87.69.77.57] (port=4383 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 1n4ONo-0003u7-ML; Mon, 03 Jan 2022 09:32:21 -0500 Date: Mon, 03 Jan 2022 16:32:26 +0200 Message-Id: <837dbgdh51.fsf@gnu.org> From: Eli Zaretskii To: Philip Kaludercic In-Reply-To: <877dbhoril.fsf@posteo.net> (message from Philip Kaludercic on Mon, 03 Jan 2022 13:52:50 +0000) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <83pmp9c7j9.fsf@gnu.org> <877dbhoril.fsf@posteo.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Philip Kaludercic > Cc: 52973@debbugs.gnu.org > Date: Mon, 03 Jan 2022 13:52:50 +0000 > > Eli Zaretskii writes: > > >> From: Philip Kaludercic > >> Date: Mon, 03 Jan 2022 08:34:18 +0000 > >> > >> I am attaching a few patches adding a few features for > >> context-menu-mode, that I mentioned and explained here: > >> https://ruzkuku.com/texts/emacs-mouse.html. > >> > >> Would it be OK to add these to Emacs itself? > > > > 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 debbugs-submit-bounces@debbugs.gnu.org Mon Jan 03 12:23:58 2022 Received: (at 52973) by debbugs.gnu.org; 3 Jan 2022 17:23:58 +0000 Received: from localhost ([127.0.0.1]:36115 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4R3t-00020y-T3 for submit@debbugs.gnu.org; Mon, 03 Jan 2022 12:23:58 -0500 Received: from mout01.posteo.de ([185.67.36.65]:36323) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4R3p-00020f-GR for 52973@debbugs.gnu.org; Mon, 03 Jan 2022 12:23:56 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id 6B2C224002A for <52973@debbugs.gnu.org>; Mon, 3 Jan 2022 18:23:47 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1641230627; bh=AaG90w/MwybUbWCIgJgTlX1izNUxZXMhp+FDoGlkUmo=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=r2je+RuWpZQ3WkGtkV6srtPufrgfFX8EJnHODIk4qaOLqpZzahJ2lr3Q6vSv4RzSm 4QZ2aIes33LD6zgZ8+koTXYs368Gm/00EJBthJoxE8QwxNdmmwf2oiG/B0qnGjcQob S1rnkHc4527fYCsBFVgyWOnDfbDRuUmY6eDDl2XiJ8FkfPhMud/8AUW5+SyeyzmdyO bQuHl+6Rr2JpV3FAi4R7X3o8THOiBM9q12Y1rJ89AHhwF7tBuYuvzGFyH+XC06+pXL kTVcTRN0xqxYbk26G9TQLaN2F6YZPjPWEWjGNO/4XMgJ9LzDnnROQD/fWkVoZs1AIA iKbg1omtmuWdg== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JSMzQ1wwwz6tmK; Mon, 3 Jan 2022 18:23:45 +0100 (CET) From: Philip Kaludercic To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <83pmp9c7j9.fsf@gnu.org> <877dbhoril.fsf@posteo.net> <837dbgdh51.fsf@gnu.org> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Mon, 03 Jan 2022 17:23:45 +0000 In-Reply-To: <837dbgdh51.fsf@gnu.org> (Eli Zaretskii's message of "Mon, 03 Jan 2022 16:32:26 +0200") Message-ID: <871r1opwbi.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> From: Philip Kaludercic >> Cc: 52973@debbugs.gnu.org >> Date: Mon, 03 Jan 2022 13:52:50 +0000 >> >> Eli Zaretskii writes: >> >> >> From: Philip Kaludercic >> >> Date: Mon, 03 Jan 2022 08:34:18 +0000 >> >> >> >> I am attaching a few patches adding a few features for >> >> context-menu-mode, that I mentioned and explained here: >> >> https://ruzkuku.com/texts/emacs-mouse.html. >> >> >> >> Would it be OK to add these to Emacs itself? >> > >> > 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. -- Philip Kaludercic From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 03 12:36:09 2022 Received: (at 52973) by debbugs.gnu.org; 3 Jan 2022 17:36:09 +0000 Received: from localhost ([127.0.0.1]:36131 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4RFg-0002MZ-VI for submit@debbugs.gnu.org; Mon, 03 Jan 2022 12:36:09 -0500 Received: from eggs.gnu.org ([209.51.188.92]:38378) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4RFf-0002M9-1K for 52973@debbugs.gnu.org; Mon, 03 Jan 2022 12:36:07 -0500 Received: from [2001:470:142:3::e] (port=56796 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 1n4RFZ-0001AE-Ox; Mon, 03 Jan 2022 12:36:01 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=ZW6YiRj0Q6zgt7dW7QhMknOZVn7S3EQ9JkmHUm9nTjk=; b=JSHGtPD1oonn NvP3LpIjfS7UNcqqkq+4WGCEZHJ64CL2s/KrVR/yN3aLQp2lX7zfkfdzsuHuW5PElhXF86G+MEIwE b6GLCDlMfZfpMo0i5exfruiSfEIKokC7M8eAhDkGZQzqpgaEwCLXTHUuv+bu/O9innJ6ZpkOrQN4B Yb8uAsDK8AE+FH0BauEdkdFSPE67CCIQrBE9EZYmzlwudPz7JsOZ4TXhZzhVz+aRxzgCDoZyaCL3L VCZz0yRxVHbmSVCgQeLeKsj6OgdxFzjZp+gK1ChMImZ/5KrGNmbPT3LFVH/hsGrQpthN7tEMxKXFw HW5Twr/OpJYooKgpi+Y0qQ==; Received: from [87.69.77.57] (port=3716 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 1n4RFZ-00022z-5d; Mon, 03 Jan 2022 12:36:02 -0500 Date: Mon, 03 Jan 2022 19:36:06 +0200 Message-Id: <83wnjgbu2h.fsf@gnu.org> From: Eli Zaretskii To: Philip Kaludercic In-Reply-To: <871r1opwbi.fsf@posteo.net> (message from Philip Kaludercic on Mon, 03 Jan 2022 17:23:45 +0000) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <83pmp9c7j9.fsf@gnu.org> <877dbhoril.fsf@posteo.net> <837dbgdh51.fsf@gnu.org> <871r1opwbi.fsf@posteo.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Philip Kaludercic > Cc: 52973@debbugs.gnu.org > Date: Mon, 03 Jan 2022 17:23:45 +0000 > > >> 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. Which part of it? From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 03 16:20:34 2022 Received: (at 52973) by debbugs.gnu.org; 3 Jan 2022 21:20:34 +0000 Received: from localhost ([127.0.0.1]:36409 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4Ukf-00005u-AQ for submit@debbugs.gnu.org; Mon, 03 Jan 2022 16:20:34 -0500 Received: from relay3-d.mail.gandi.net ([217.70.183.195]:60209) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4Ukc-00005e-TA for 52973@debbugs.gnu.org; Mon, 03 Jan 2022 16:20:19 -0500 Received: (Authenticated sender: juri@linkov.net) by relay3-d.mail.gandi.net (Postfix) with ESMTPSA id 0DA3C60009; Mon, 3 Jan 2022 21:20:11 +0000 (UTC) From: Juri Linkov To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> Date: Mon, 03 Jan 2022 23:12:53 +0200 In-Reply-To: <87o84tp69h.fsf@posteo.net> (Philip Kaludercic's message of "Mon, 03 Jan 2022 08:34:18 +0000") Message-ID: <868rvwsezi.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) > I am attaching a few patches adding a few features for > context-menu-mode, that I mentioned and explained here: > https://ruzkuku.com/texts/emacs-mouse.html. > > Would it be OK to add these to Emacs itself? Thanks, it would be beneficial to enrich the packages with the context-menus. Man-context-menu is a good addition to the package man.el, and hi-lock-context-menu to hi-lock.el. However, mouse-online-search-at-point looks out of place in mouse.el. Since it relies on eww, wouldn't the right place for it be in eww.el? > +(defun Man-at-mouse (e) > ... > +(defun Man-context-menu (menu click) > + "Populate MENU with commands that open a man page at point." > + (save-excursion > + (mouse-set-point click) > + (when (save-excursion It seems the second 'save-excursion' is superfluous? > + (skip-syntax-backward "^ ") > + (and (looking-at > + "[[:space:]]*\\([[:alnum:]_-]+([[:alnum:]]+)\\)") > + (match-string 1))) > + (define-key-after menu [man-separator] menu-bar-separator) > + (define-key-after menu [man-at-mouse] > + '(menu-item "Open man page" man-at-mouse Typo: the command name is capitalized 'Man-at-mouse'. > + (mouse-set-point click) > + (when (symbol-at-point) This can be simplified to: (thing-at-mouse click 'symbol) From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 03 16:20:34 2022 Received: (at 52973) by debbugs.gnu.org; 3 Jan 2022 21:20:34 +0000 Received: from localhost ([127.0.0.1]:36412 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4Uks-00006G-B3 for submit@debbugs.gnu.org; Mon, 03 Jan 2022 16:20:34 -0500 Received: from relay8-d.mail.gandi.net ([217.70.183.201]:54313) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4Ukf-00005j-Vu for 52973@debbugs.gnu.org; Mon, 03 Jan 2022 16:20:22 -0500 Received: (Authenticated sender: juri@linkov.net) by relay8-d.mail.gandi.net (Postfix) with ESMTPSA id BDF361BF20B; Mon, 3 Jan 2022 21:20:14 +0000 (UTC) From: Juri Linkov To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <83pmp9c7j9.fsf@gnu.org> <877dbhoril.fsf@posteo.net> <837dbgdh51.fsf@gnu.org> <871r1opwbi.fsf@posteo.net> Date: Mon, 03 Jan 2022 23:17:18 +0200 In-Reply-To: <871r1opwbi.fsf@posteo.net> (Philip Kaludercic's message of "Mon, 03 Jan 2022 17:23:45 +0000") Message-ID: <86mtkcr02p.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: Eli Zaretskii , 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >>> > 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'. From debbugs-submit-bounces@debbugs.gnu.org Tue Jan 04 07:27:05 2022 Received: (at 52973) by debbugs.gnu.org; 4 Jan 2022 12:27:05 +0000 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 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 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==; 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 Date: Tue, 04 Jan 2022 14:26:59 +0200 Message-Id: <83o84rbsa4.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86mtkcr02p.fsf@mail.linkov.net> (message from Juri Linkov on Mon, 03 Jan 2022 23:17:18 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands 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 X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > 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. From debbugs-submit-bounces@debbugs.gnu.org Tue Jan 04 12:51:49 2022 Received: (at 52973) by debbugs.gnu.org; 4 Jan 2022 17:51:50 +0000 Received: from localhost ([127.0.0.1]:38613 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4nyP-0002WY-NU for submit@debbugs.gnu.org; Tue, 04 Jan 2022 12:51:49 -0500 Received: from relay12.mail.gandi.net ([217.70.178.232]:36673) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4nyN-0002Vt-5E for 52973@debbugs.gnu.org; Tue, 04 Jan 2022 12:51:48 -0500 Received: (Authenticated sender: juri@linkov.net) by relay12.mail.gandi.net (Postfix) with ESMTPSA id C0C3320000B; Tue, 4 Jan 2022 17:51:39 +0000 (UTC) From: Juri Linkov To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET 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> <83o84rbsa4.fsf@gnu.org> Date: Tue, 04 Jan 2022 19:46:31 +0200 In-Reply-To: <83o84rbsa4.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 04 Jan 2022 14:26:59 +0200") Message-ID: <86a6gbo0lk.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> 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. 'custom-add-repeat-choice' can help to add more choices to the customizable variable 'context-menu-functions', so it would be easier for users to add a function from the package that the user is really using. > 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. The main customization point is 'M-x customize-variable RET context-menu-functions' that will provide more choices with the help of 'custom-add-repeat-choice'. From debbugs-submit-bounces@debbugs.gnu.org Tue Jan 04 14:40:09 2022 Received: (at 52973) by debbugs.gnu.org; 4 Jan 2022 19:40:09 +0000 Received: from localhost ([127.0.0.1]:38769 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4pfC-0005E4-6i for submit@debbugs.gnu.org; Tue, 04 Jan 2022 14:40:09 -0500 Received: from mout01.posteo.de ([185.67.36.65]:55119) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4pf9-0005D0-ES for 52973@debbugs.gnu.org; Tue, 04 Jan 2022 14:40:05 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id 362C2240027 for <52973@debbugs.gnu.org>; Tue, 4 Jan 2022 20:39:56 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1641325197; bh=EYTZR9B60a/qukhVphOLaeC4DZwhY5hneOatJQxNfbg=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=qCPpeh3WodUGjunxeUE3/ReZ1xF5OH9cUEFgR/HRH6ee9ff9V1z+EzCdrr8N5AR9c cJzsWqHJDpFVYJK//xA7gBTjcj0jJdF2n3ZtbsUsWaW5wWp3JYy99ousP4PtHqnk+r jxuHq9Wzol/KZP6mLfMkYg4Ui+7N3F5msX6YJhJ9UocsESHpDM94hVt4CXvP2YgWyP RK8meczdEYfbbWq8m3CQ2R5mfcrMxrJ0sMwPRC8MRe5LNnVVr3THsBS4seW7kGQjQ4 F2uOhkS9h37r8tn1dTKVaZlVw9eRoZkrUCvoKlCYzSg0C61znYxgqWhgykHigEuSRt G7hhBAo4qIm8g== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JT2y431jTz9rwn; Tue, 4 Jan 2022 20:39:56 +0100 (CET) From: Philip Kaludercic To: Juri Linkov Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Tue, 04 Jan 2022 19:39:48 +0000 In-Reply-To: <868rvwsezi.fsf@mail.linkov.net> (Juri Linkov's message of "Mon, 03 Jan 2022 23:12:53 +0200") Message-ID: <87czl75lyz.fsf@posteo.net> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) --=-=-= Content-Type: text/plain Juri Linkov writes: >> I am attaching a few patches adding a few features for >> context-menu-mode, that I mentioned and explained here: >> https://ruzkuku.com/texts/emacs-mouse.html. >> >> Would it be OK to add these to Emacs itself? > > Thanks, it would be beneficial to enrich the packages with the > context-menus. Man-context-menu is a good addition to the package > man.el, and hi-lock-context-menu to hi-lock.el. However, > mouse-online-search-at-point looks out of place in mouse.el. > Since it relies on eww, wouldn't the right place for it be > in eww.el? It doesn't really depend on eww in any substantial way, rather eww is the only place where a search engine is defined. What I was thinking about was adding a command like online-search (that could then have both a keyboard and mouse-oriented command), a online-search-engine user option. While one is at it, eww could be updated to use this too, by deprecating eww-search-prefix: --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-Add-search-engine-functionality.patch >From 1ebb6881aeeb08bf574bdb688cb1e94af8b5609d Mon Sep 17 00:00:00 2001 From: Philip Kaludercic Date: Tue, 4 Jan 2022 20:36:32 +0100 Subject: [PATCH] Add search engine functionality * lisp/misc.el (online-search): Add command to query an online search engine. (online-search-engine-alist): Add user option to configure `online-search'. (online-search-engine): Add user option to configure `online-search'. (online-search-query): Add internal command to generate a search engine query, to be used elsewhere. (online-search-at-point): Add command. (online-search-at-mouse): Add command. (online-search-context-menu): Add context menu support. * lisp/net/eww.el (eww-search-prefix): Mark as obsolete (eww--dwim-expand-url): Use `online-search-query'. --- lisp/misc.el | 93 +++++++++++++++++++++++++++++++++++++++++++++++++ lisp/net/eww.el | 7 ++-- 2 files changed, 96 insertions(+), 4 deletions(-) diff --git a/lisp/misc.el b/lisp/misc.el index 39ec9497d7..473fcac33f 100644 --- a/lisp/misc.el +++ b/lisp/misc.el @@ -27,6 +27,7 @@ (eval-when-compile (require 'tabulated-list)) +(require 'cl-lib) ;;;###autoload (defun copy-from-above-command (&optional arg) @@ -209,6 +210,98 @@ list-dynamic-libraries (display-buffer buffer) nil) +(defgroup online-search () + "Search engine options." + :group 'browse-url) + +(defcustom online-search-engine-alist + '(("DuckDuckGo" . "https://duckduckgo.com/html/?q=") + ("Google" . "https://www.google.com/search?q=") + ("Wikipedia" . "https://en.wikipedia.org/w/index.php?search=")) + "Alist of search engines, mapping strings to queries. +A query is either a string, interpreted as a URL prefix ending +with an incomplete query string, onto which the query will be +concatenated, or a function that accepts one argument and returns +a URL." + :type '(alist :key-type string :value-type string) + :group 'online-search) + +(defcustom online-search-engine "DuckDuckGo" + "Search engine to use for `online-search' and related commands. +The string should denote a key in `online-search-engine-alist'." + :type 'string + :group 'online-search) + +;;;###autoload +(defun online-search-query (string &optional engine) + "Generate an URL query to search for STRING with ENGINE. +See `online-search' for more details on ENGINE." + (let ((query (alist-get (or engine online-search-engine) + online-search-engine-alist + nil nil #'string=))) + (cond + ((stringp query) + (concat query (mapconcat #'url-hexify-string + (split-string string nil t) + "+"))) + ((functionp query) + (funcall query string)) + ((error "Unknown query %S" query))))) + +;;;###autoload +(defun online-search (string &optional engine) + "Search for STRING using a search engine. +If the optional argument ENGINE may be used to override +`online-search-engine', and will be used to look up a query in +`online-search-engine-alist'." + (interactive (list (if (use-region-p) + (buffer-substring (region-beginning) (region-end)) + (read-string "Search: ")) + (and current-prefix-arg + (completing-read + "Use search engine: " + online-search-engine-alist)))) + (browse-url (online-search-query string engine))) + +;;;###autoload +(defun online-search-at-point (&optional engine) + "Search for symbol at point using ENGINE. +See `online-search' for more details." + (interactive (list (and current-prefix-arg + (completing-read + "Use search engine: " + online-search-engine-alist)))) + (let ((query (thing-at-point 'symbol))) + (unless query + (user-error "Nothing to search for")) + (online-search query engine))) + +;;;###autoload +(defun online-search-at-mouse (click) + "Query an online search engine at CLICK. +If a region is active, the entire region will be sent, otherwise +the symbol at point will be used. See `online-search' for more +details." + (interactive "e") + (let ((query (if (use-region-p) + (buffer-substring (region-beginning) + (region-end)) + (thing-at-mouse click 'symbol)))) + (unless query + (user-error "Nothing to search for")) + (online-search query))) + +;;;###autoload +(defun online-search-context-menu (menu click) + "Populate MENU with command to search online at CLICK." + (save-excursion + (mouse-set-point click) + (define-key-after menu [online-search-separator] menu-bar-separator) + (define-key-after menu [online-search-at-mouse] + '(menu-item "Online search" online-search-at-mouse + :help "Search for region or word online"))) + menu) + (provide 'misc) ;;; misc.el ends here diff --git a/lisp/net/eww.el b/lisp/net/eww.el index 8930eb427d..37e84d160b 100644 --- a/lisp/net/eww.el +++ b/lisp/net/eww.el @@ -55,6 +55,7 @@ eww-search-prefix :version "24.4" :group 'eww :type 'string) +(make-obsolete-variable 'eww-search-prefix "online-search-engine" "29.1") (defcustom eww-use-browse-url "\\`mailto:" "EWW will use `browse-url' when following links that match this regexp. @@ -355,7 +356,7 @@ eww-browse (defun eww (url &optional new-buffer buffer) "Fetch URL and render the page. If the input doesn't look like an URL or a domain name, the -word(s) will be searched for via `eww-search-prefix'. +word(s) will be searched for via `online-search'. If NEW-BUFFER is non-nil (interactively, the prefix arg), use a new buffer instead of reusing the default EWW buffer. @@ -464,9 +465,7 @@ eww--dwim-expand-url ;; Some sites do not redirect final / (when (string= (url-filename (url-generic-parse-url url)) "") (setq url (concat url "/")))) - (setq url (concat eww-search-prefix - (mapconcat - #'url-hexify-string (split-string url) "+")))))) + (setq url (online-search-query url))))) url) (defun eww--preprocess-html (start end) -- 2.34.0 --=-=-= Content-Type: text/plain I added this to misc.el, but it could be added to a separate file as well. >> +(defun Man-at-mouse (e) >> ... >> +(defun Man-context-menu (menu click) >> + "Populate MENU with commands that open a man page at point." >> + (save-excursion >> + (mouse-set-point click) >> + (when (save-excursion > > It seems the second 'save-excursion' is superfluous? > >> + (skip-syntax-backward "^ ") >> + (and (looking-at >> + "[[:space:]]*\\([[:alnum:]_-]+([[:alnum:]]+)\\)") >> + (match-string 1))) >> + (define-key-after menu [man-separator] menu-bar-separator) >> + (define-key-after menu [man-at-mouse] >> + '(menu-item "Open man page" man-at-mouse > > Typo: the command name is capitalized 'Man-at-mouse'. > >> + (mouse-set-point click) >> + (when (symbol-at-point) > > This can be simplified to: > > (thing-at-mouse click 'symbol) Thanks for the hints, I have fixed them locally. -- Philip Kaludercic --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Tue Jan 04 15:01:24 2022 Received: (at 52973) by debbugs.gnu.org; 4 Jan 2022 20:01:25 +0000 Received: from localhost ([127.0.0.1]:38786 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4pzo-0007w3-NF for submit@debbugs.gnu.org; Tue, 04 Jan 2022 15:01:24 -0500 Received: from eggs.gnu.org ([209.51.188.92]:37924) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4pzk-0007vo-3p for 52973@debbugs.gnu.org; Tue, 04 Jan 2022 15:01:23 -0500 Received: from [2001:470:142:3::e] (port=52932 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 1n4pzd-0001Sn-9a; Tue, 04 Jan 2022 15:01:14 -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=Q74e2H7OVWK7W+JQXVuQkTO+NmtFo2BVm6Ot4kpYOWU=; b=ir380m9MTZglOiS6ngnE HX7DsLt441seqXxK6zi+8ug4mamcsrQhK2v5UhQ427FhbGt1pnm2WYg6F+g6KMJScrDImbhlA8Rb5 4K6kB54CYwJX5f7fa5pv6ybG0L5qnHU/7i0O9Ruq+ya6Fir3YSfQ0EDmoCHAEj4EM73R3FGZNDCPK pnDcc/7Gp7V1dh2tCvHn8YXUNsaKoBHo5WDOO1btORFXEflww8QhQfaycx8lBKcCkQ5BrCZEHaTF5 EEK7++sS3SokEisZ7wqb5jmXrou9MMNqskn3pB8Q51ZOxkF0v5QfPn4oQXSsGrnwNaAZpvkl6Up86 q7H3KKdsiWrQUg==; Received: from [87.69.77.57] (port=1833 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 1n4pzd-0007Uw-AV; Tue, 04 Jan 2022 15:01:13 -0500 Date: Tue, 04 Jan 2022 22:01:20 +0200 Message-Id: <8335m3b78v.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86a6gbo0lk.fsf@mail.linkov.net> (message from Juri Linkov on Tue, 04 Jan 2022 19:46:31 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands 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> <83o84rbsa4.fsf@gnu.org> <86a6gbo0lk.fsf@mail.linkov.net> MIME-version: 1.0 Content-type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: 8bit X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: philipk@posteo.net, 52973@debbugs.gnu.org > Date: Tue, 04 Jan 2022 19:46:31 +0200 > > > 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. > > The main customization point is > > 'M-x customize-variable RET context-menu-functions' > > that will provide more choices with the help of > 'custom-add-repeat-choice'. I think once the user turns on context-menu-mode, all the modes that defined their context menus should automatically activate them. There should be no need for any user customizations except turning on this mode. From debbugs-submit-bounces@debbugs.gnu.org Tue Jan 04 15:08:14 2022 Received: (at 52973) by debbugs.gnu.org; 4 Jan 2022 20:08:14 +0000 Received: from localhost ([127.0.0.1]:38822 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4q6P-00087x-Si for submit@debbugs.gnu.org; Tue, 04 Jan 2022 15:08:14 -0500 Received: from mout02.posteo.de ([185.67.36.66]:50181) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4q6M-00087j-U3 for 52973@debbugs.gnu.org; Tue, 04 Jan 2022 15:08:12 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout02.posteo.de (Postfix) with ESMTPS id E8658240103 for <52973@debbugs.gnu.org>; Tue, 4 Jan 2022 21:08:04 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1641326884; bh=ADkdPx1s8D1BArsgplaNv8Y1/Ee6eQ5TVnDLRbIGPnc=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=rsHutQ3zPn0l7FQw6lXVYs+Hi7q+8yTkhnjM2nqpzzcJg8e9J4J93rSKItLVNj+ZC NykzEUmEsQv4Nsxw02nJZUKM8g27lp3Xlz0/PHdLYOqli9xfg6ljeXRLYvUmfZoOrk LPV/SDzBgjXuTY4jFMd6g6sw6TP94d92HTvAtMPXY+p/BTQN4bHV8q/3BTsvJSdb+Y 18+7bBvAQCfZhyEbysaVQC1ZiS4nsgu0tMukH8HOcZ1B3CeZQZMvVRnUe9YZpDOQm1 xGUY/1g5Gw8XSgWGHAOeNkhirVNOLv4CVJucWPatDyRyCUF0v3OMVbmsIyrhDHzn8A vF0xRDq+skqpA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JT3ZX0LKXz9rwn; Tue, 4 Jan 2022 21:08:03 +0100 (CET) From: Philip Kaludercic To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands 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> <83o84rbsa4.fsf@gnu.org> <86a6gbo0lk.fsf@mail.linkov.net> <8335m3b78v.fsf@gnu.org> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Tue, 04 Jan 2022 20:08:03 +0000 In-Reply-To: <8335m3b78v.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 04 Jan 2022 22:01:20 +0200") Message-ID: <87h7aj463g.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org, Juri Linkov X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> From: Juri Linkov >> Cc: philipk@posteo.net, 52973@debbugs.gnu.org >> Date: Tue, 04 Jan 2022 19:46:31 +0200 >>=20 >> > 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'=C3=AAtre of the feature. >>=20 >> The main customization point is >>=20 >> 'M-x customize-variable RET context-menu-functions' >>=20 >> that will provide more choices with the help of >> 'custom-add-repeat-choice'. > > I think once the user turns on context-menu-mode, all the modes that > defined their context menus should automatically activate them. There > should be no need for any user customizations except turning on this > mode. I would disagree, neither do I necessarily want all mode, nor do I necessarily want to have the entries listed the default order. In my case I fix this by manually setting context-menu-functions to the functions I want to use. --=20 Philip Kaludercic From debbugs-submit-bounces@debbugs.gnu.org Tue Jan 04 15:09:35 2022 Received: (at 52973) by debbugs.gnu.org; 4 Jan 2022 20:09:35 +0000 Received: from localhost ([127.0.0.1]:38826 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4q7j-0008A6-89 for submit@debbugs.gnu.org; Tue, 04 Jan 2022 15:09:35 -0500 Received: from mout02.posteo.de ([185.67.36.66]:41457) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4q7i-00089r-2n for 52973@debbugs.gnu.org; Tue, 04 Jan 2022 15:09:34 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout02.posteo.de (Postfix) with ESMTPS id 8BCE8240104 for <52973@debbugs.gnu.org>; Tue, 4 Jan 2022 21:09:28 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1641326968; bh=GOb6n2wWiWCcS2afM9hFk0Ng+Ln1mJVNXK4XqNuv/Z0=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=O9MHbb2eOLVL7pQGjW6+zAUULbwOZsaQIQvExT14ulCJ4yqidgav6jzGGYzl/LTzW 50s3FUQdtMmNcA/Ca4Kstuo2gQtD5FrdUf+oV6hYaryOtbDGMbZLRMMLGi+zMrLnLJ fZrMt+JdDVP5g9JDzYgHcZohjY3D9bub9uysJR2SUiCisdl0Fq05yWJ/2RmTp8Oxn8 f9v9Yr68+WVcM4uDrrnS1fgSZSCW+04LHCZZUnBIp02bex/t8o4xvsdXuO0L0T6iGL bMs6leofVLuKcVq2ipU5imFJHYkedYA77sLDbQKiHCaed4u4gS9mHQIyB6hoeLdeY7 YBjtUW1klGFnA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JT3c80tgSz6tmN; Tue, 4 Jan 2022 21:09:27 +0100 (CET) From: Philip Kaludercic To: Juri Linkov Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Tue, 04 Jan 2022 20:09:27 +0000 In-Reply-To: <868rvwsezi.fsf@mail.linkov.net> (Juri Linkov's message of "Mon, 03 Jan 2022 23:12:53 +0200") Message-ID: <87czl74614.fsf@posteo.net> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) --=-=-= Content-Type: text/plain Juri Linkov writes: >> I am attaching a few patches adding a few features for >> context-menu-mode, that I mentioned and explained here: >> https://ruzkuku.com/texts/emacs-mouse.html. >> >> Would it be OK to add these to Emacs itself? > > Thanks, it would be beneficial to enrich the packages with the > context-menus. Man-context-menu is a good addition to the package > man.el, and hi-lock-context-menu to hi-lock.el. Here an extension on my previous hi-lock commit, adding the ability to remove highlighting: --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-Implement-context-menu-mode-support-for-hi-lock.patch >From 76addfdb26b172cf1cea56f868f9f3e3afec1a20 Mon Sep 17 00:00:00 2001 From: Philip Kaludercic Date: Fri, 31 Dec 2021 12:45:52 +0100 Subject: [PATCH] Implement context-menu-mode support for hi-lock * hi-lock.el (hi-lock-symbol-at-mouse): Add new command (hi-lock-context-menu): Add new function --- lisp/hi-lock.el | 34 ++++++++++++++++++++++++++++++++++ 1 file changed, 34 insertions(+) diff --git a/lisp/hi-lock.el b/lisp/hi-lock.el index 7d126cb558..0ed2def24c 100644 --- a/lisp/hi-lock.el +++ b/lisp/hi-lock.el @@ -854,6 +854,40 @@ hi-lock-unload-function ;; continue standard unloading nil) +;;; Mouse support +(defun hi-lock-symbol-at-mouse (click) + "Highlight symbol at mouse CLICK." + (interactive "e") + (save-excursion + (mouse-set-point click) + (highlight-symbol-at-point))) + +(defun hi-lock-unhighlight-at-mouse (click) + "Remove highlighting from all regular expressions at CLICK." + (interactive "e") + (save-excursion + (mouse-set-point click) + (unless (mapc #'hi-lock-unface-buffer (hi-lock--regexps-at-point)) + (message "Nothing highlighted at point.")))) + +(defun hi-lock-context-menu (menu click) + "Populate MENU with a menu item to highlight symbol at CLICK." + (save-excursion + (mouse-set-point click) + (let ((sym (thing-at-point 'symbol)) + (rap (hi-lock--regexps-at-point))) + (when (or sym rap) + (define-key-after menu [hi-lick-separator] menu-bar-separator)) + (when sym + (define-key-after menu [hi-lock-add] + '(menu-item "Highlight Symbol" highlight-symbol-at-mouse + :help "Highlight symbol at point"))) + (when rap + (define-key-after menu [hi-lock-remove] + '(menu-item "Unhighlight Symbol" hi-lock-unhighlight-at-mouse + :help "Remove highlight at point"))))) + menu) + (provide 'hi-lock) ;;; hi-lock.el ends here -- 2.34.0 --=-=-= Content-Type: text/plain -- Philip Kaludercic --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Tue Jan 04 15:15:33 2022 Received: (at 52973) by debbugs.gnu.org; 4 Jan 2022 20:15:33 +0000 Received: from localhost ([127.0.0.1]:38836 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4qDV-0008Jf-90 for submit@debbugs.gnu.org; Tue, 04 Jan 2022 15:15:33 -0500 Received: from eggs.gnu.org ([209.51.188.92]:41050) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n4qDT-0008JR-AL for 52973@debbugs.gnu.org; Tue, 04 Jan 2022 15:15:31 -0500 Received: from [2001:470:142:3::e] (port=53270 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 1n4qDN-0006My-Lg; Tue, 04 Jan 2022 15:15:25 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=z1O2F3xQiMpqM33SVVkumX7L3vfvMRblEYF2uEdxR74=; b=kxs/ONe/Xu85 INLR9sa8XclrhQxhyj5MDVxTGhF72DwAXz7ZE95WDedLQKjGrSM15fNw5Oo5KvBgvoUzTtLn2na7R Mmo/8H5Syh3hQVqw19QMQOnfHB3EHILCyj6MCmbVKkv5plz0H1c4W51bPoYiBoFgkQUr4VLLty6bV 9SwOuyZHuth/+zFAfw3thIia+xUFaqI0rxX/MDOlhzRuSds8NOGCYFO700CvqgVcHzSH5K4/IZlYN ZdCdZ4y1QYs5iwjwS5PXih7VZQhLGrSzJv87NViUfzBza7RvNLFZ4qXNtG85j2tSTSEQOlBGwIMr3 OKdEpgHxaCkHQ5rk39yLtg==; Received: from [87.69.77.57] (port=2725 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 1n4qDG-0006bq-3E; Tue, 04 Jan 2022 15:15:24 -0500 Date: Tue, 04 Jan 2022 22:15:26 +0200 Message-Id: <83y23v9s0x.fsf@gnu.org> From: Eli Zaretskii To: Philip Kaludercic In-Reply-To: <87h7aj463g.fsf@posteo.net> (message from Philip Kaludercic on Tue, 04 Jan 2022 20:08:03 +0000) Subject: Re: bug#52973: Adding a few context-menu-mode commands 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> <83o84rbsa4.fsf@gnu.org> <86a6gbo0lk.fsf@mail.linkov.net> <8335m3b78v.fsf@gnu.org> <87h7aj463g.fsf@posteo.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org, juri@linkov.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Philip Kaludercic > Cc: Juri Linkov , 52973@debbugs.gnu.org > Date: Tue, 04 Jan 2022 20:08:03 +0000 > > Eli Zaretskii writes: > > > I think once the user turns on context-menu-mode, all the modes that > > defined their context menus should automatically activate them. There > > should be no need for any user customizations except turning on this > > mode. > > I would disagree, neither do I necessarily want all mode, nor do I > necessarily want to have the entries listed the default order. In my > case I fix this by manually setting context-menu-functions to the > functions I want to use. Then we should allow users to opt out of the automatic activation of the context menus. But the default should IMO be that they are activated in all modes. After all, this mode wants to mimic "other applications", and those don't let you choose at all. So I think users, especially newcomers, would expect that default. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 05 14:22:43 2022 Received: (at 52973) by debbugs.gnu.org; 5 Jan 2022 19:22:44 +0000 Received: from localhost ([127.0.0.1]:38826 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Brv-0000I3-O5 for submit@debbugs.gnu.org; Wed, 05 Jan 2022 14:22:43 -0500 Received: from relay10.mail.gandi.net ([217.70.178.230]:58571) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Brt-0000Hl-AZ for 52973@debbugs.gnu.org; Wed, 05 Jan 2022 14:22:42 -0500 Received: (Authenticated sender: juri@linkov.net) by relay10.mail.gandi.net (Postfix) with ESMTPSA id 6657D240004; Wed, 5 Jan 2022 19:22:32 +0000 (UTC) From: Juri Linkov To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> Date: Wed, 05 Jan 2022 20:58:22 +0200 In-Reply-To: <87czl75lyz.fsf@posteo.net> (Philip Kaludercic's message of "Tue, 04 Jan 2022 19:39:48 +0000") Message-ID: <86czl6au29.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> However, mouse-online-search-at-point looks out of place in mouse.el. >> Since it relies on eww, wouldn't the right place for it be in eww.el? > > It doesn't really depend on eww in any substantial way, rather eww is > the only place where a search engine is defined. What I was thinking > about was adding a command like online-search (that could then have both > a keyboard and mouse-oriented command), a online-search-engine > user option. Maybe then a better place to add new functions would be in lisp/net/webjump.el. webjump is a package created exactly for this purpose. Then new functions could share the same prefix webjump-. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 05 14:22:46 2022 Received: (at 52973) by debbugs.gnu.org; 5 Jan 2022 19:22:46 +0000 Received: from localhost ([127.0.0.1]:38829 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Brx-0000IJ-UB for submit@debbugs.gnu.org; Wed, 05 Jan 2022 14:22:46 -0500 Received: from relay6-d.mail.gandi.net ([217.70.183.198]:41327) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Brw-0000Hr-IB for 52973@debbugs.gnu.org; Wed, 05 Jan 2022 14:22:45 -0500 Received: (Authenticated sender: juri@linkov.net) by relay6-d.mail.gandi.net (Postfix) with ESMTPSA id 15F7FC0002; Wed, 5 Jan 2022 19:22:36 +0000 (UTC) From: Juri Linkov To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl74614.fsf@posteo.net> Date: Wed, 05 Jan 2022 21:03:44 +0200 In-Reply-To: <87czl74614.fsf@posteo.net> (Philip Kaludercic's message of "Tue, 04 Jan 2022 20:09:27 +0000") Message-ID: <861r1mattb.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > Here an extension on my previous hi-lock commit, adding the ability to > remove highlighting: Thanks, looks good that "Unhighlight Symbol" is added only on a highlighted symbol. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 05 14:22:50 2022 Received: (at 52973) by debbugs.gnu.org; 5 Jan 2022 19:22:50 +0000 Received: from localhost ([127.0.0.1]:38832 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Bs2-0000IZ-3I for submit@debbugs.gnu.org; Wed, 05 Jan 2022 14:22:50 -0500 Received: from relay9-d.mail.gandi.net ([217.70.183.199]:51297) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Bs1-0000Hw-2g for 52973@debbugs.gnu.org; Wed, 05 Jan 2022 14:22:49 -0500 Received: (Authenticated sender: juri@linkov.net) by relay9-d.mail.gandi.net (Postfix) with ESMTPSA id 4FF2BFF804; Wed, 5 Jan 2022 19:22:39 +0000 (UTC) From: Juri Linkov To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET 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> <83o84rbsa4.fsf@gnu.org> <86a6gbo0lk.fsf@mail.linkov.net> <8335m3b78v.fsf@gnu.org> <87h7aj463g.fsf@posteo.net> <83y23v9s0x.fsf@gnu.org> Date: Wed, 05 Jan 2022 21:09:31 +0200 In-Reply-To: <83y23v9s0x.fsf@gnu.org> (Eli Zaretskii's message of "Tue, 04 Jan 2022 22:15:26 +0200") Message-ID: <8635m29eik.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: Philip Kaludercic , 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> > I think once the user turns on context-menu-mode, all the modes that >> > defined their context menus should automatically activate them. There >> > should be no need for any user customizations except turning on this >> > mode. >> >> I would disagree, neither do I necessarily want all mode, nor do I >> necessarily want to have the entries listed the default order. In my >> case I fix this by manually setting context-menu-functions to the >> functions I want to use. > > Then we should allow users to opt out of the automatic activation of > the context menus. But the default should IMO be that they are > activated in all modes. After all, this mode wants to mimic "other > applications", and those don't let you choose at all. So I think > users, especially newcomers, would expect that default. The menu bar doesn't contain all available commands not to overwhelm the users. For the same reason, the context menu should stay reasonably short. Otherwise, it might grow to 28-foot long, and everyone will be mocking us for this. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 05 14:28:59 2022 Received: (at 52973) by debbugs.gnu.org; 5 Jan 2022 19:28:59 +0000 Received: from localhost ([127.0.0.1]:38847 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Bxz-0000Rv-11 for submit@debbugs.gnu.org; Wed, 05 Jan 2022 14:28:59 -0500 Received: from eggs.gnu.org ([209.51.188.92]:57198) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Bxw-0000Rh-Ms for 52973@debbugs.gnu.org; Wed, 05 Jan 2022 14:28:57 -0500 Received: from [2001:470:142:3::e] (port=50300 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 1n5Bxr-0001he-AF; Wed, 05 Jan 2022 14:28:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=6gZN1DewK82UT8mtUhSjVpeLSruwubvL+dWoPRUuDuk=; b=nByRlFaO3AK6 grRw8Wf/QaVN45RAwiVw9vp0BDBU6jAxelZ4Dqy+ZPEKQCDOBZIynr/+ptBPmKm48tSAQC6WrRLQF r1zGgn2Ck2W5bFBJDOiv++27sHWUPEPmJIrw7RLbs2dbyiYEsVZLLxKWl/1FFpuYWVNoZiiGReJ0m rwEiim1ckXwlYQJTSqlcS8c2bXmzaNWVhLKNJaQTgCvqDZaPllaXL+vknAN1NBx0Lob8WXema1Tt5 z5SWDHbd2n1yDWSjRtaFnXLxnwwHu+cyeXltCIwh6xmkXCGqC8cmqsfwoJuyH0d9w2qEc7xcGbryP g5gGs3t+eO/LHsAysCTpvg==; Received: from [87.69.77.57] (port=4793 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 1n5Bxr-0008DF-8w; Wed, 05 Jan 2022 14:28:51 -0500 Date: Wed, 05 Jan 2022 21:29:01 +0200 Message-Id: <835yqy9e2q.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <8635m29eik.fsf@mail.linkov.net> (message from Juri Linkov on Wed, 05 Jan 2022 21:09:31 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands 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> <83o84rbsa4.fsf@gnu.org> <86a6gbo0lk.fsf@mail.linkov.net> <8335m3b78v.fsf@gnu.org> <87h7aj463g.fsf@posteo.net> <83y23v9s0x.fsf@gnu.org> <8635m29eik.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: Philip Kaludercic , 52973@debbugs.gnu.org > Date: Wed, 05 Jan 2022 21:09:31 +0200 > > >> > I think once the user turns on context-menu-mode, all the modes that > >> > defined their context menus should automatically activate them. There > >> > should be no need for any user customizations except turning on this > >> > mode. > >> > >> I would disagree, neither do I necessarily want all mode, nor do I > >> necessarily want to have the entries listed the default order. In my > >> case I fix this by manually setting context-menu-functions to the > >> functions I want to use. > > > > Then we should allow users to opt out of the automatic activation of > > the context menus. But the default should IMO be that they are > > activated in all modes. After all, this mode wants to mimic "other > > applications", and those don't let you choose at all. So I think > > users, especially newcomers, would expect that default. > > The menu bar doesn't contain all available commands not to overwhelm the > users. For the same reason, the context menu should stay reasonably short. > Otherwise, it might grow to 28-foot long, and everyone will be mocking > us for this. I agree, but is that a real danger? How much context that gets into context menu can there be for a single spot in a buffer? And if indeed there's a lot of useful context, we should produce multi-level context menus, like we do with buffer-menu. Once again: this feature makes no sense whatsoever if turning on the context-menu-mode doesn't activate the context menus. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 05 15:14:37 2022 Received: (at 52973) by debbugs.gnu.org; 5 Jan 2022 20:14:37 +0000 Received: from localhost ([127.0.0.1]:38897 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Cg9-0003tI-AW for submit@debbugs.gnu.org; Wed, 05 Jan 2022 15:14:37 -0500 Received: from mout02.posteo.de ([185.67.36.66]:51733) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Cg6-0003t1-Tv for 52973@debbugs.gnu.org; Wed, 05 Jan 2022 15:14:36 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout02.posteo.de (Postfix) with ESMTPS id 640E0240104 for <52973@debbugs.gnu.org>; Wed, 5 Jan 2022 21:14:28 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1641413668; bh=x2thjmFM9ytdOdTB18RkPWZHA/b6fbQwDcbkFD+w5W0=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=GRcx8mtAgd7610MV7waFErI7ha+Sh8A4CoG7auRxee9hCCuVgdhIHZud8lQkdZrG8 24IXK5gMrlKYN4vD/NLIWPF96LkSgG8tCWVCOf2nEUm9Ufg7d5v6FJ/CkET5yFRBzJ 0udd7FD/YYYIjzHepPFiLc4xBk745IQic2AyzbtLWoX2rWUHRlUZijDxZNqRZ/5eXM 4Mz/tS2McIXpGATfwIierHZevTtXq7G7MUlw8dph7WmeI+lqRD/oYDORkrdjq9A6se 933pQdqMbc9OBkrhHaSyXYmqB/pAfqzfbc1OH82/d/rUjQgObzyFCoDsyuKks73/2d NPJ8IYnx9WlEw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JTggR6CRzz9rxM; Wed, 5 Jan 2022 21:14:27 +0100 (CET) From: Philip Kaludercic To: Juri Linkov Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Wed, 05 Jan 2022 20:14:26 +0000 In-Reply-To: <86czl6au29.fsf@mail.linkov.net> (Juri Linkov's message of "Wed, 05 Jan 2022 20:58:22 +0200") Message-ID: <874k6idjod.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Juri Linkov writes: >>> However, mouse-online-search-at-point looks out of place in mouse.el. >>> Since it relies on eww, wouldn't the right place for it be in eww.el? >> >> It doesn't really depend on eww in any substantial way, rather eww is >> the only place where a search engine is defined. What I was thinking >> about was adding a command like online-search (that could then have both >> a keyboard and mouse-oriented command), a online-search-engine >> user option. > > Maybe then a better place to add new functions would be in > lisp/net/webjump.el. webjump is a package created exactly > for this purpose. Then new functions could share the same > prefix webjump-. I didn't know about webjump, thank you for the hint. My only fear is that the prefix would make the functionality harder to discover. -- Philip Kaludercic From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 05 16:12:18 2022 Received: (at 52973) by debbugs.gnu.org; 5 Jan 2022 21:12:18 +0000 Received: from localhost ([127.0.0.1]:39029 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5DZx-0007bw-U6 for submit@debbugs.gnu.org; Wed, 05 Jan 2022 16:12:18 -0500 Received: from relay1-d.mail.gandi.net ([217.70.183.193]:47165) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5DZw-0007bk-Ry for 52973@debbugs.gnu.org; Wed, 05 Jan 2022 16:12:17 -0500 Received: (Authenticated sender: juri@linkov.net) by relay1-d.mail.gandi.net (Postfix) with ESMTPSA id D7344240004; Wed, 5 Jan 2022 21:12:09 +0000 (UTC) From: Juri Linkov To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET 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> <83o84rbsa4.fsf@gnu.org> <86a6gbo0lk.fsf@mail.linkov.net> <8335m3b78v.fsf@gnu.org> <87h7aj463g.fsf@posteo.net> <83y23v9s0x.fsf@gnu.org> <8635m29eik.fsf@mail.linkov.net> <835yqy9e2q.fsf@gnu.org> Date: Wed, 05 Jan 2022 22:57:29 +0200 In-Reply-To: <835yqy9e2q.fsf@gnu.org> (Eli Zaretskii's message of "Wed, 05 Jan 2022 21:29:01 +0200") Message-ID: <86mtka7y6u.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > I agree, but is that a real danger? How much context that gets into > context menu can there be for a single spot in a buffer? I've never seen a context menu longer than about 10 items with short submenus. > And if indeed there's a lot of useful context, we should produce > multi-level context menus, like we do with buffer-menu. > > Once again: this feature makes no sense whatsoever if turning on the > context-menu-mode doesn't activate the context menus. More context functions have the same discoverability as all user options with multiple choices. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 06 01:54:38 2022 Received: (at 52973) by debbugs.gnu.org; 6 Jan 2022 06:54:38 +0000 Received: from localhost ([127.0.0.1]:39499 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5MfV-0005c8-MC for submit@debbugs.gnu.org; Thu, 06 Jan 2022 01:54:37 -0500 Received: from eggs.gnu.org ([209.51.188.92]:42110) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5MfR-0005br-R6 for 52973@debbugs.gnu.org; Thu, 06 Jan 2022 01:54:36 -0500 Received: from [2001:470:142:3::e] (port=35820 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 1n5MfL-0004RX-HM; Thu, 06 Jan 2022 01:54:27 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=aERuZXzDTLw+CFwgIhd9/azgiU+8FsUthLKv1m68Ms8=; b=KdW8nwyhjw7d WWoU9IEeXFWkVMbluFWNdMxPwKHu6xJleCR0o8+3hlCc30Z1sD12Bv5v2U0EDFP9sFBlsyFfUdPXS Oe9c2Ynsd+WCexje1PdLD6wgPjrzaeFNgW7l3fhhYPFHcGCqfQ3UuesO/I4JlE0s0mQ4q77h2lo89 VprqEeZ8VSMYofjBUOV3kwfpe5cZCNoHSR+brwRcsWIa64P+S3maIv02MggThgWPrGzbsX2Ex+uUl gPFPk+aXDN8l4/NDjXizdUW8vatCLgCkd8dhZt7cMRS+H6YKAE4mZa/+jdcj9DCQA3uSVcD1WJSNw AaDqxnbQfkRTmICoLnrlrg==; Received: from [87.69.77.57] (port=2808 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 1n5MfL-0006Ba-7L; Thu, 06 Jan 2022 01:54:27 -0500 Date: Thu, 06 Jan 2022 08:54:39 +0200 Message-Id: <831r1l9wwg.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86mtka7y6u.fsf@mail.linkov.net> (message from Juri Linkov on Wed, 05 Jan 2022 22:57:29 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands 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> <83o84rbsa4.fsf@gnu.org> <86a6gbo0lk.fsf@mail.linkov.net> <8335m3b78v.fsf@gnu.org> <87h7aj463g.fsf@posteo.net> <83y23v9s0x.fsf@gnu.org> <8635m29eik.fsf@mail.linkov.net> <835yqy9e2q.fsf@gnu.org> <86mtka7y6u.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: philipk@posteo.net, 52973@debbugs.gnu.org > Date: Wed, 05 Jan 2022 22:57:29 +0200 > > > I agree, but is that a real danger? How much context that gets into > > context menu can there be for a single spot in a buffer? > > I've never seen a context menu longer than about 10 items with short submenus. So then this is not a real problem, and we shouldn't be worried about it, right? > > And if indeed there's a lot of useful context, we should produce > > multi-level context menus, like we do with buffer-menu. > > > > Once again: this feature makes no sense whatsoever if turning on the > > context-menu-mode doesn't activate the context menus. > > More context functions have the same discoverability > as all user options with multiple choices. I don't see what discoverability has to do with this. The issue is not discoverability, the issue is to show reasonably useful context menus when the user turns on context-menu-mode and right-clicks some part of the Emacs display. Telling the user to do more customizations _after_ turning on context-menu-mode makes little sense to me. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 06 03:25:13 2022 Received: (at 52973) by debbugs.gnu.org; 6 Jan 2022 08:25:13 +0000 Received: from localhost ([127.0.0.1]:39575 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5O5A-0007rj-Rm for submit@debbugs.gnu.org; Thu, 06 Jan 2022 03:25:13 -0500 Received: from relay8-d.mail.gandi.net ([217.70.183.201]:32887) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5O57-0007rM-RP for 52973@debbugs.gnu.org; Thu, 06 Jan 2022 03:25:11 -0500 Received: (Authenticated sender: juri@linkov.net) by relay8-d.mail.gandi.net (Postfix) with ESMTPSA id 7A2BF1BF20F; Thu, 6 Jan 2022 08:25:01 +0000 (UTC) From: Juri Linkov To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> Date: Thu, 06 Jan 2022 10:17:10 +0200 In-Reply-To: <874k6idjod.fsf@posteo.net> (Philip Kaludercic's message of "Wed, 05 Jan 2022 20:14:26 +0000") Message-ID: <86o84pthgp.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> Maybe then a better place to add new functions would be in >> lisp/net/webjump.el. webjump is a package created exactly >> for this purpose. Then new functions could share the same >> prefix webjump-. > > I didn't know about webjump, thank you for the hint. My only fear is > that the prefix would make the functionality harder to discover. The fact that its name starts with the word "web" improves discoverability. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 06 03:25:15 2022 Received: (at 52973) by debbugs.gnu.org; 6 Jan 2022 08:25:15 +0000 Received: from localhost ([127.0.0.1]:39578 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5O5D-0007s0-39 for submit@debbugs.gnu.org; Thu, 06 Jan 2022 03:25:15 -0500 Received: from relay11.mail.gandi.net ([217.70.178.231]:52051) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5O5B-0007rT-2H for 52973@debbugs.gnu.org; Thu, 06 Jan 2022 03:25:13 -0500 Received: (Authenticated sender: juri@linkov.net) by relay11.mail.gandi.net (Postfix) with ESMTPSA id DCB5310000B; Thu, 6 Jan 2022 08:25:05 +0000 (UTC) From: Juri Linkov To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET 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> <83o84rbsa4.fsf@gnu.org> <86a6gbo0lk.fsf@mail.linkov.net> <8335m3b78v.fsf@gnu.org> <87h7aj463g.fsf@posteo.net> <83y23v9s0x.fsf@gnu.org> <8635m29eik.fsf@mail.linkov.net> <835yqy9e2q.fsf@gnu.org> <86mtka7y6u.fsf@mail.linkov.net> <831r1l9wwg.fsf@gnu.org> Date: Thu, 06 Jan 2022 10:20:10 +0200 In-Reply-To: <831r1l9wwg.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 06 Jan 2022 08:54:39 +0200") Message-ID: <86wnjds2is.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> > I agree, but is that a real danger? How much context that gets into >> > context menu can there be for a single spot in a buffer? >> >> I've never seen a context menu longer than about 10 items with short submenus. > > So then this is not a real problem, and we shouldn't be worried about > it, right? Menus are usually short because long menus is a real problem. >> > And if indeed there's a lot of useful context, we should produce >> > multi-level context menus, like we do with buffer-menu. >> > >> > Once again: this feature makes no sense whatsoever if turning on the >> > context-menu-mode doesn't activate the context menus. >> >> More context functions have the same discoverability >> as all user options with multiple choices. > > I don't see what discoverability has to do with this. The issue is > not discoverability, the issue is to show reasonably useful context > menus when the user turns on context-menu-mode and right-clicks some > part of the Emacs display. If "useful" here means a long menu with all possible items, then in this case “useful” is the enemy of “usable”. > Telling the user to do more customizations _after_ turning on > context-menu-mode makes little sense to me. There are hundreds of user variables for customization, and the context menu variable is not different. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 06 04:10:35 2022 Received: (at 52973) by debbugs.gnu.org; 6 Jan 2022 09:10:35 +0000 Received: from localhost ([127.0.0.1]:39639 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5On5-0000Xc-0H for submit@debbugs.gnu.org; Thu, 06 Jan 2022 04:10:35 -0500 Received: from eggs.gnu.org ([209.51.188.92]:42118) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5On2-0000XO-KU for 52973@debbugs.gnu.org; Thu, 06 Jan 2022 04:10:33 -0500 Received: from [2001:470:142:3::e] (port=38348 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 1n5Omw-0004QJ-Bs; Thu, 06 Jan 2022 04:10:26 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=UBIkxQat15zrV9G+ZvFcXqlUnxZfJA5ZOMTP95E/HYs=; b=dahFoqo7J4zB ALrnS8a173myQ+VRlrsu0KSSzKYKjbu53DFMKkCbe6QocXBxUdXLRu1QehP1tfk4hiDgJrqbQbIGm yNA3cfU98Uk3O1yvbwClqg16e83sMdeL7DIGYoeKMGCE9kQK6HoPNbnAleF5g5CvlIa2ZO8NpZhTN z4YS6FY4hXXhopovjfvxiOEW0YtLdi7f0+U2mGf4lSTCxFXb9Qu/aOJJL0CkM5vg8g3u3Qmv9Lnuv /VbEbX/tisHOxycpNxZWI/v0JG+M/cT5ldzhl8E54XtFm3kIVthMb46teDJroa0HyHtgOFzzIprFO m3sR91eVuu1XiaD355+Rwg==; Received: from [87.69.77.57] (port=3148 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 1n5Omj-0001PH-26; Thu, 06 Jan 2022 04:10:20 -0500 Date: Thu, 06 Jan 2022 11:10:25 +0200 Message-Id: <83ilux8c1q.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86wnjds2is.fsf@mail.linkov.net> (message from Juri Linkov on Thu, 06 Jan 2022 10:20:10 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands 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> <83o84rbsa4.fsf@gnu.org> <86a6gbo0lk.fsf@mail.linkov.net> <8335m3b78v.fsf@gnu.org> <87h7aj463g.fsf@posteo.net> <83y23v9s0x.fsf@gnu.org> <8635m29eik.fsf@mail.linkov.net> <835yqy9e2q.fsf@gnu.org> <86mtka7y6u.fsf@mail.linkov.net> <831r1l9wwg.fsf@gnu.org> <86wnjds2is.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: philipk@posteo.net, 52973@debbugs.gnu.org > Date: Thu, 06 Jan 2022 10:20:10 +0200 > > > Telling the user to do more customizations _after_ turning on > > context-menu-mode makes little sense to me. > > There are hundreds of user variables for customization, > and the context menu variable is not different. I couldn't disagree more. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 06 14:00:08 2022 Received: (at 52973) by debbugs.gnu.org; 6 Jan 2022 19:00:08 +0000 Received: from localhost ([127.0.0.1]:42333 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Xzb-0006yr-Qh for submit@debbugs.gnu.org; Thu, 06 Jan 2022 14:00:08 -0500 Received: from mout02.posteo.de ([185.67.36.66]:53061) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5XzW-0006xQ-Rn for 52973@debbugs.gnu.org; Thu, 06 Jan 2022 14:00:06 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout02.posteo.de (Postfix) with ESMTPS id BCF3D240103 for <52973@debbugs.gnu.org>; Thu, 6 Jan 2022 19:59:56 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1641495596; bh=rgypaqb1p3nWcZ21pIG5M955sCTrm1G4bcRp6pjBQVk=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=pJEQgA41i899xUZtFuNiycyfb1dIcwq3zddPSj5+CrE1aCM2RPQtY7NI8GbOeX/gM t71/aP3JBtu4fTKR6sKSSvfI8JRLtnraKPl68KfYkjc7xXLm4j2wisfSWrsR+rsluM +/do2PZ6ScU8QMBHL5dw67PRSSIDkEy+vwXw8bRBw5Fypax8na/RDJ5YSMnBUhIApq sxOPmqmV0YTciq/SLysFOCWApKa2nKqTn7Kw+Esbftt6YnIPoCzODoGTDdHbFntady 7YvKrG0BbKUEOJ6mVKtMGJ97EwE4e3KvsZW8nC7A4BBQFYQgyWeRq+yT7wTIlGA/K8 be1ZVxDV4bepQ== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JVFz00XSJz9rxD; Thu, 6 Jan 2022 19:59:55 +0100 (CET) From: Philip Kaludercic To: Juri Linkov Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Thu, 06 Jan 2022 18:59:44 +0000 In-Reply-To: <86o84pthgp.fsf@mail.linkov.net> (Juri Linkov's message of "Thu, 06 Jan 2022 10:17:10 +0200") Message-ID: <87pmp4lmfz.fsf@posteo.net> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) --=-=-= Content-Type: text/plain Juri Linkov writes: >>> Maybe then a better place to add new functions would be in >>> lisp/net/webjump.el. webjump is a package created exactly >>> for this purpose. Then new functions could share the same >>> prefix webjump-. >> >> I didn't know about webjump, thank you for the hint. My only fear is >> that the prefix would make the functionality harder to discover. > > The fact that its name starts with the word "web" improves > discoverability. How is this? --=-=-= Content-Type: text/x-patch Content-Disposition: inline; filename=0001-Add-search-engine-functionality.patch >From 2a32d1f7df0b8dfdceb3f63476df150d55215b5d Mon Sep 17 00:00:00 2001 From: Philip Kaludercic Date: Tue, 4 Jan 2022 20:36:32 +0100 Subject: [PATCH] Add search engine functionality * lisp/net/eww.el (eww-search-prefix): Deprecate user option (eww): Use webjump-search-query * lisp/net/webjump.el (webjump-default-search-engine): Add user option (webjump-choose-search-engine): Add function (webjump-search-query): Add function (webjump-search): Add autoloaded command (webjump-search-at-point): Add autoloaded command (webjump-search-at-mouse): Add command (webjump-search-context-menu): Add function for context-menu support. --- lisp/misc.el | 1 + lisp/net/eww.el | 10 +++--- lisp/net/webjump.el | 80 ++++++++++++++++++++++++++++++++++++++++++++- 3 files changed, 86 insertions(+), 5 deletions(-) diff --git a/lisp/misc.el b/lisp/misc.el index 39ec9497d7..6e5aede789 100644 --- a/lisp/misc.el +++ b/lisp/misc.el @@ -27,6 +27,7 @@ (eval-when-compile (require 'tabulated-list)) +(require 'cl-lib) ;;;###autoload (defun copy-from-above-command (&optional arg) diff --git a/lisp/net/eww.el b/lisp/net/eww.el index 8930eb427d..2ef6b35100 100644 --- a/lisp/net/eww.el +++ b/lisp/net/eww.el @@ -33,6 +33,7 @@ (require 'url) (require 'url-queue) (require 'xdg) +(require 'webjump) (eval-when-compile (require 'subr-x)) (defgroup eww nil @@ -55,6 +56,9 @@ eww-search-prefix :version "24.4" :group 'eww :type 'string) +(make-obsolete-variable 'eww-search-prefix + "webjump-default-search-engine" + "29.1") (defcustom eww-use-browse-url "\\`mailto:" "EWW will use `browse-url' when following links that match this regexp. @@ -355,7 +359,7 @@ eww-browse (defun eww (url &optional new-buffer buffer) "Fetch URL and render the page. If the input doesn't look like an URL or a domain name, the -word(s) will be searched for via `eww-search-prefix'. +word(s) will be searched for via `webjump-search'. If NEW-BUFFER is non-nil (interactively, the prefix arg), use a new buffer instead of reusing the default EWW buffer. @@ -464,9 +468,7 @@ eww--dwim-expand-url ;; Some sites do not redirect final / (when (string= (url-filename (url-generic-parse-url url)) "") (setq url (concat url "/")))) - (setq url (concat eww-search-prefix - (mapconcat - #'url-hexify-string (split-string url) "+")))))) + (setq url (webjump-search-query url))))) url) (defun eww--preprocess-html (start end) diff --git a/lisp/net/webjump.el b/lisp/net/webjump.el index 7547f92d7d..17c9312c54 100644 --- a/lisp/net/webjump.el +++ b/lisp/net/webjump.el @@ -370,7 +370,85 @@ webjump-url-fix-trailing-slash (concat url "/") url)) -;;----------------------------------------------------------------------------- + +;;; Search engine functionality + +(defcustom webjump-default-search-engine "DuckDuckGo" + "Search engine to use for `webjump-search' and related commands. +The string should denote an entry in `webjump-sites', with a +`simple-query' entry." + :type 'string) + +(defun webjump-choose-search-engine () + "Choose a search engine to use from `webjump-sites'. +If no prefix argument was used, the function will return the +entry for `webjump-default-search-engine'." + (assoc-string + (if current-prefix-arg + (completing-read + (format-prompt "Use search engine" + webjump-default-search-engine) + webjump-sites + (lambda (ent) + (and (vectorp (cdr ent)) + (eq (aref (cdr ent) 0) 'simple-query))) + t nil nil webjump-default-search-engine) + webjump-default-search-engine) + webjump-sites t)) + +(defun webjump-search-query (string) + "Generate an URL query to search for STRING." + (let ((engine (cdr (webjump-choose-search-engine)))) + (webjump-url-fix + (concat (aref engine 2) + (webjump-url-encode string) + (aref engine 3))))) + +;;;###autoload +(defun webjump-search (string) + "Search for STRING using a search engine. +If the optional argument ENGINE may be used to override +`webjump-default-search-engine'." + (interactive (list (if (use-region-p) + (buffer-substring (region-beginning) (region-end)) + (read-string "Search: ")))) + (browse-url (webjump-search-query string))) + +;;;###autoload +(defun webjump-search-at-point () + "Search for symbol at point online. +See `webjump-search' for more details." + (interactive) + (let ((query (thing-at-point 'symbol))) + (unless query + (user-error "Nothing to search for")) + (webjump-search query))) + +;;;###autoload +(defun webjump-search-at-mouse (click) + "Query an online search engine at CLICK. +If a region is active, the entire region will be sent, otherwise +the symbol at point will be used. See `webjump-search' for more +details." + (interactive "e") + (let ((query (if (use-region-p) + (buffer-substring (region-beginning) + (region-end)) + (thing-at-mouse click 'symbol)))) + (unless (or query (string-match-p "\\`[[:space:]\n]*\\'" query)) + (user-error "Nothing to search for")) + (webjump-search query))) + +;;;###autoload +(defun webjump-search-context-menu (menu click) + "Populate MENU with command to search online at CLICK." + (save-excursion + (mouse-set-point click) + (define-key-after menu [webjump-search-separator] menu-bar-separator) + (define-key-after menu [webjump-search-at-mouse] + '(menu-item "Online search" webjump-search-at-mouse + :help "Search for region or word online"))) + menu) (provide 'webjump) -- 2.34.0 --=-=-= Content-Type: text/plain While I agree that web helps, I think a search-online defalias for webjump-search would be appreciated when looking for commands via apropos. -- Philip Kaludercic --=-=-=-- From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 06 15:10:52 2022 Received: (at 52973) by debbugs.gnu.org; 6 Jan 2022 20:10:52 +0000 Received: from localhost ([127.0.0.1]:42415 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Z64-000276-1l for submit@debbugs.gnu.org; Thu, 06 Jan 2022 15:10:52 -0500 Received: from relay7-d.mail.gandi.net ([217.70.183.200]:58199) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5Z62-00026d-KW for 52973@debbugs.gnu.org; Thu, 06 Jan 2022 15:10:51 -0500 Received: (Authenticated sender: juri@linkov.net) by relay7-d.mail.gandi.net (Postfix) with ESMTPSA id 62CF520004; Thu, 6 Jan 2022 20:10:42 +0000 (UTC) From: Juri Linkov To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> Date: Thu, 06 Jan 2022 22:03:01 +0200 In-Reply-To: <87pmp4lmfz.fsf@posteo.net> (Philip Kaludercic's message of "Thu, 06 Jan 2022 18:59:44 +0000") Message-ID: <86pmp41vby.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >>>> Maybe then a better place to add new functions would be in >>>> lisp/net/webjump.el. webjump is a package created exactly >>>> for this purpose. Then new functions could share the same >>>> prefix webjump-. >>> >>> I didn't know about webjump, thank you for the hint. My only fear is >>> that the prefix would make the functionality harder to discover. >> >> The fact that its name starts with the word "web" improves >> discoverability. > > How is this? Thanks, everything looks consistent. If no one will have more comments during the next few days, it seems safe to assume it's ok to push. > While I agree that web helps, I think a search-online defalias for > webjump-search would be appreciated when looking for commands via > apropos. Typing 'M-x search- TAB' shows: search-backward search-backward-regexp search-emacs-glossary search-forward search-forward-help-for-help search-forward-regexp search-text-property search-unencodable-char I don't know if 'search-online' could be added here too. We need more opinions. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 06 15:19:52 2022 Received: (at 52973) by debbugs.gnu.org; 6 Jan 2022 20:19:52 +0000 Received: from localhost ([127.0.0.1]:42429 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5ZEm-0002ZZ-Dy for submit@debbugs.gnu.org; Thu, 06 Jan 2022 15:19:52 -0500 Received: from quimby.gnus.org ([95.216.78.240]:42044) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5ZEj-0002ZH-Si for 52973@debbugs.gnu.org; Thu, 06 Jan 2022 15:19:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=v0SkVoI3ZxTA0hXonFrghqD9DgFtsvj4ufoSO2/U7YY=; b=IAHY3DeiF8uNYi387ylsVCew7G 1ovgPXVXTt3bPOc5gqJRTvGnpb5jQ5xUl99TAcw5kvuvsCkd9Zq0DDwVW7l+AiDd60s7+ifrSqLZI P6A4h/aHlooSESQmMvRQ1uGLPpDLhI9BP2oRsTO4ymJsrt4+/GoKdnEWVnqw6Px7gUh8=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n5ZEa-0001Yy-2p; Thu, 06 Jan 2022 21:19:42 +0100 From: Lars Ingebrigtsen To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwAgMAAAAqbBEUAAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAADFBMVEWvlXeNclpKODH/ //8KL3ufAAAAAWJLR0QDEQxM8gAAAAd0SU1FB+YBBhQRETaELB0AAAFzSURBVCjPVZGxbttADIZ5 Qa1BUzN4qN6gego5gAMkkwKIh1hTh9qo7ynUAM2cITJiTWpgHcL/KUuelKEHiOJ3JH8e7+gLuW+M eRGRCz6YO5ZU08ojGnQ5VbT1c1KWUbXmNvnl2zM5TgV4LAdQz3wCJDgg0JH9oPWSQUAZsz8FvJTW x2neeUJ3GBXqIw/tJVRnLaKvqxP8dHd1vFGo/F/EocuQK9w81bsDxhyF9sk3TVfgNdsVGmk7PHt8 uA+D8PvnA+6l+m5Qvv+g3ONCKYI/dCVAVSZA5/aCywJwB5nvQDfiaR5VDCadO01oIthgmIxIjyRV QIEFMCocDDLb+g+A7bBIa1XbJmk1EeKnJGAmSmO/YYaJvXxG+p7tVUKCqefWx7hPAL1Ivf+YIKi/ HxbpM9uKQp9ZnpNaxJQibU9SO4zm77wQrevist4zCwci5ltZzXkGDErAdK3meNvPsE61CRpyRs2S 5sz+0k+bUcNb9vN56n/D/g0PeljmaAAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMi0wMS0wNlQyMDox NzoxNyswMDowMG2OeMoAAAAldEVYdGRhdGU6bW9kaWZ5ADIwMjItMDEtMDZUMjA6MTc6MTcrMDA6 MDAc08B2AAAAAElFTkSuQmCC X-Now-Playing: PJ Harvey's _The B Sides_: "Somebody's Down, Somebody's Name" Date: Thu, 06 Jan 2022 21:19:39 +0100 In-Reply-To: <87pmp4lmfz.fsf@posteo.net> (Philip Kaludercic's message of "Thu, 06 Jan 2022 18:59:44 +0000") Message-ID: <87mtk8d3c4.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Philip Kaludercic writes: > * lisp/net/webjump.el (webjump-default-search-engine): Add user option > (webjump-choose-search-engine): Add function I think putting this shared functionality in the webjump package isn't optimal. Webjump is "webjump.el --- programmable Web hotlist", and this doesn't seem related. Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org, Juri Linkov X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Philip Kaludercic writes: > * lisp/net/webjump.el (webjump-default-search-engine): Add user option > (webjump-choose-search-engine): Add function I think putting this shared functionality in the webjump package isn't optimal. Webjump is "webjump.el --- programmable Web hotlist", and this doesn't seem related. browse-url (or even url-something) would be more natural, I think. The functionality otherwise looks good to me. One micro-comment on the code: > +(make-obsolete-variable 'eww-search-prefix > + "webjump-default-search-engine" Should be: > +(make-obsolete-variable 'eww-search-prefix > + 'webjump-default-search-engine -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 06 15:32:09 2022 Received: (at 52973) by debbugs.gnu.org; 6 Jan 2022 20:32:09 +0000 Received: from localhost ([127.0.0.1]:42445 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5ZQf-0004lY-1D for submit@debbugs.gnu.org; Thu, 06 Jan 2022 15:32:09 -0500 Received: from eggs.gnu.org ([209.51.188.92]:58582) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5ZQc-0004fn-7O for 52973@debbugs.gnu.org; Thu, 06 Jan 2022 15:32:07 -0500 Received: from [2001:470:142:3::e] (port=55090 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 1n5ZQW-0003Dm-Ju; Thu, 06 Jan 2022 15:32:00 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=4k79BMBqXT9O4+JzcC0oAI4Fz13M7TvvbPZ9U7/j+6U=; b=Sh+T55LkaBaW oDL1494gFMS9pOUuRwotVZXlTM6qawc0FYmP4UarQhgrcGRS0m+T04uKa+u+Sfntg5dopI/PL3oZZ VTO2WF9WfkNtgN1MbT3uuOuJtpG5dcbaJG53e7DxUx70ATn2SiHgYNY9B/tG0tDElJsx7U/tv0dT4 UtxE2A7ISZCBzn29B6yQCp44lTUnkVp4syI7vXOGfAaU/eIuEMnZ/SnLBSRr0w3aKbdxYCvUJ7u+H clLXCGTTMs0dghJIK+ad3Er9YB9XfAotNluqmbFoxx99O3dJTl+H8OayHXAn/0LgzeVZGVvvSUpuJ rLYI+sAc1WgIq8ny9z5y1Q==; Received: from [87.69.77.57] (port=1428 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 1n5ZQW-00088r-KF; Thu, 06 Jan 2022 15:32:00 -0500 Date: Thu, 06 Jan 2022 22:32:14 +0200 Message-Id: <83czl47ghd.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86pmp41vby.fsf@mail.linkov.net> (message from Juri Linkov on Thu, 06 Jan 2022 22:03:01 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Date: Thu, 06 Jan 2022 22:03:01 +0200 > Cc: 52973@debbugs.gnu.org > > Thanks, everything looks consistent. If no one will have more comments > during the next few days, it seems safe to assume it's ok to push. Yeah, feel free to push and disregard everything I said about this arrangement of context menus not making sense. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 06 15:33:05 2022 Received: (at 52973) by debbugs.gnu.org; 6 Jan 2022 20:33:05 +0000 Received: from localhost ([127.0.0.1]:42449 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5ZRZ-00058Q-Cr for submit@debbugs.gnu.org; Thu, 06 Jan 2022 15:33:05 -0500 Received: from relay7-d.mail.gandi.net ([217.70.183.200]:60943) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5ZRX-00057m-0M for 52973@debbugs.gnu.org; Thu, 06 Jan 2022 15:33:03 -0500 Received: (Authenticated sender: juri@linkov.net) by relay7-d.mail.gandi.net (Postfix) with ESMTPSA id 7D02D20005; Thu, 6 Jan 2022 20:32:55 +0000 (UTC) From: Juri Linkov To: Lars Ingebrigtsen Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <87mtk8d3c4.fsf@gnus.org> Date: Thu, 06 Jan 2022 22:32:27 +0200 In-Reply-To: <87mtk8d3c4.fsf@gnus.org> (Lars Ingebrigtsen's message of "Thu, 06 Jan 2022 21:19:39 +0100") Message-ID: <86o84ozjtw.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: Philip Kaludercic , 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> * lisp/net/webjump.el (webjump-default-search-engine): Add user option >> (webjump-choose-search-engine): Add function > > I think putting this shared functionality in the webjump package isn't > optimal. Webjump is "webjump.el --- programmable Web hotlist", and this > doesn't seem related. > > browse-url (or even url-something) would be more natural, I think. webjump.el contains a list of search engines, browse-url.el contains a list or web browsers. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 06 15:37:04 2022 Received: (at 52973) by debbugs.gnu.org; 6 Jan 2022 20:37:04 +0000 Received: from localhost ([127.0.0.1]:42453 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5ZVP-0005EC-S5 for submit@debbugs.gnu.org; Thu, 06 Jan 2022 15:37:04 -0500 Received: from relay11.mail.gandi.net ([217.70.178.231]:35149) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5ZVN-0005De-7o for 52973@debbugs.gnu.org; Thu, 06 Jan 2022 15:37:02 -0500 Received: (Authenticated sender: juri@linkov.net) by relay11.mail.gandi.net (Postfix) with ESMTPSA id DB84F100003; Thu, 6 Jan 2022 20:36:52 +0000 (UTC) From: Juri Linkov To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> Date: Thu, 06 Jan 2022 22:35:57 +0200 In-Reply-To: <83czl47ghd.fsf@gnu.org> (Eli Zaretskii's message of "Thu, 06 Jan 2022 22:32:14 +0200") Message-ID: <86ee5kzjo2.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> Thanks, everything looks consistent. If no one will have more comments >> during the next few days, it seems safe to assume it's ok to push. > > Yeah, feel free to push and disregard everything I said about this > arrangement of context menus not making sense. The patches from Philip just add new functions. Whether to include them in the default value of the context function is a separate discussion. From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 01:38:44 2022 Received: (at 52973) by debbugs.gnu.org; 7 Jan 2022 06:38:44 +0000 Received: from localhost ([127.0.0.1]:42846 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5itf-0004ba-LQ for submit@debbugs.gnu.org; Fri, 07 Jan 2022 01:38:43 -0500 Received: from eggs.gnu.org ([209.51.188.92]:50056) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5itb-0004bA-0g for 52973@debbugs.gnu.org; Fri, 07 Jan 2022 01:38:42 -0500 Received: from [2001:470:142:3::e] (port=37804 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 1n5itT-0003L3-Ks; Fri, 07 Jan 2022 01:38:32 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=FNLi0/xgPMtl9+JC/d+iNKpgfbg+PWKMEObk/IZhIa0=; b=gQOmkHa4N2JS QIsIWbZYaATqCFglSuJAaPrg3n86eBStDrmSM6Cfqoj84KbK3R8fML9TLpH4YiY2uunijsEbUsd1x 6l2nmL1m+7ur/+770cW50PgqyZaSDw4Kvn+zLHBInXKxZCleBPY+6Ju+62HzHu9IUNKVjW2wMuMEy itMsmVQvts3dt+NbjXVZABT0c2gW48XoG6a2Rd0TBg8XVt7zSU4/Zs6kUqU2kFp4lrE9/cfofzKDH OzdYVjx1Jf3BMobe9gLEaYpNi/+qqJQhIh7qerXaGk/S/O/VYBC6gFvEl/3agfCudZwSY9I9EhoQk s/wMRnUE/sAgdI5JMFwJWg==; Received: from [87.69.77.57] (port=2619 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 1n5itS-0000zN-KZ; Fri, 07 Jan 2022 01:38:31 -0500 Date: Fri, 07 Jan 2022 08:38:45 +0200 Message-Id: <83bl0o6oei.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov , Lars Ingebrigtsen In-Reply-To: <86ee5kzjo2.fsf@mail.linkov.net> (message from Juri Linkov on Thu, 06 Jan 2022 22:35:57 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: philipk@posteo.net, 52973@debbugs.gnu.org > Date: Thu, 06 Jan 2022 22:35:57 +0200 > > >> Thanks, everything looks consistent. If no one will have more comments > >> during the next few days, it seems safe to assume it's ok to push. > > > > Yeah, feel free to push and disregard everything I said about this > > arrangement of context menus not making sense. > > The patches from Philip just add new functions. > Whether to include them in the default value > of the context function is a separate discussion. How does it make sense to add functions that aren't used? Lars, what is your opinion about these issues? Am I the only one who thinks that context-menu-mode should automatically activate context menus in every mode that has support for it? From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 01:47:22 2022 Received: (at 52973) by debbugs.gnu.org; 7 Jan 2022 06:47:22 +0000 Received: from localhost ([127.0.0.1]:42851 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5j1r-0004xT-Jc for submit@debbugs.gnu.org; Fri, 07 Jan 2022 01:47:21 -0500 Received: from quimby.gnus.org ([95.216.78.240]:46294) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5j1p-0004x4-To for 52973@debbugs.gnu.org; Fri, 07 Jan 2022 01:47:10 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=g6WQI9FGPdP2foWXtxjUy1ZsLyixiCKbU3drAcJx6Ss=; b=sMfbgqhiFDxp4xBlGYvLIVePfZ gv1OraxCikBPKybN08L7/yojRhO3HMsEZVCMgCWJAbCmNNQ8o3W6lRi4s208mbhDkL5EMriCOgnNA JqJOHoSfctYtsGU8+yLhv/XBLVbtmZk4WD47sEySSl/b02a1K8m7K9Z2pRcLgSoqx87Q=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n5j1f-0007hY-ON; Fri, 07 Jan 2022 07:47:02 +0100 From: Lars Ingebrigtsen To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAKlBMVEXa18zg3dKttbTD w7zg39WinbVMUZBXjYtKaYlAhX12cqU5fnw/YIX///9YE916AAAAAWJLR0QN9rRh9QAAAAd0SU1F B+YBBwYtBfizkeQAAAEtSURBVDjLxZLRbcMwDESpegFSsPZpgMxiuRkgyAS0mgESoIO0QQcoOlZF iZLRmPkrUH76iXc8mgDbckTwBIB4D4jQBkggwCgU4JzJfFbcfKQCnA2yFG5BJgMYFpTJUEYwgSEF FYAFcDBDuPERIPoNUEdxskZjqppEK0ReptN8itrSn4f5EvmFlwPqWE3K5+cpcfxcga75PX9PPF27 lAb0NwGJlwyco10H4TuVKuZl3Abm2qHmI7Yl+ql2nKsUPXePrwquq5R23FI3lx/SQUhqXmPse8AQ U3E/yDiORvFwmrw0nKGDuknPCydO81sNnoEenL/MHPl1+oBm3pYoSz/GYxQPkhz2xa1SgOuDbEs7 q0HA/m8ASZm3K02mFNydUCtsTQ8K4R+q5LNCuEJ+AEPrT9gZDRA4AAAAJXRFWHRkYXRlOmNyZWF0 ZQAyMDIyLTAxLTA3VDA2OjQ1OjA1KzAwOjAwrPqf4wAAACV0RVh0ZGF0ZTptb2RpZnkAMjAyMi0w MS0wN1QwNjo0NTowNSswMDowMN2nJ18AAAAASUVORK5CYII= X-Now-Playing: Caribou's _Never Come Back (1)_: "Never Come Back (Four Tet Remix)" Date: Fri, 07 Jan 2022 07:46:56 +0100 In-Reply-To: <83bl0o6oei.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 07 Jan 2022 08:38:45 +0200") Message-ID: <87iluwcaan.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Eli Zaretskii writes: > Lars, what is your opinion about these issues? Am I the only one who > thinks that context-menu-mode should automatically activate context > menus in every mode that has support for it? Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org, Juri Linkov X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Eli Zaretskii writes: > Lars, what is your opinion about these issues? Am I the only one who > thinks that context-menu-mode should automatically activate context > menus in every mode that has support for it? I agree with you -- I see no reason not to activate context menus where we have support for it. (But I've only lightly skimmed this thread, so I may be missing something (I'm still a bit busy with other stuff, but should be back to normal next week, hopefully.)) -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 03:20:14 2022 Received: (at 52973) by debbugs.gnu.org; 7 Jan 2022 08:20:14 +0000 Received: from localhost ([127.0.0.1]:42956 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5kTq-0000cu-KX for submit@debbugs.gnu.org; Fri, 07 Jan 2022 03:20:14 -0500 Received: from eggs.gnu.org ([209.51.188.92]:38286) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5kTl-0000c1-KD for 52973@debbugs.gnu.org; Fri, 07 Jan 2022 03:20:08 -0500 Received: from [2001:470:142:3::e] (port=39294 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 1n5kTg-00083J-4R; Fri, 07 Jan 2022 03:20:00 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=lF2sW6aCu6Rhs2FWGqqwneBb8A+yD2p8W2PT8uNxSYo=; b=QzOwy9V2PKOy 2r/ZX6yackqkXbTlDhqWBejepQ8SqcPExkAPYaZOfgkynfj4JVLfSVk2WWwucJKaestwTFzrlfPtA Bh8eHD/3aW1HzWHAlriyzW7jc4lLT8yX1WM/kZXjVf/RSCJnVdmatva4lJe8MTz23lzcOhcQaK0p1 ceoCtoE1NJgYnyL+5q+Z1pnzCzJJslfWPtsU9Q9F9l7y7X32a/OHQsYb3zQi43yrgJpLp8jLk4pEo QB+ZpMEwEXjA7xfRm/NKVE6i2w0XdZ9D56Z0Uz1oAPgxUlXZ5B2Du1clqZv76Ivf76H99I5UgLUEo z0JMTgT6H0EjabrTy/zCRg==; Received: from [87.69.77.57] (port=4852 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 1n5kTg-00067R-1a; Fri, 07 Jan 2022 03:20:00 -0500 Date: Fri, 07 Jan 2022 10:20:15 +0200 Message-Id: <83pmp4554w.fsf@gnu.org> From: Eli Zaretskii To: Lars Ingebrigtsen In-Reply-To: <87iluwcaan.fsf@gnus.org> (message from Lars Ingebrigtsen on Fri, 07 Jan 2022 07:46:56 +0100) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwcaan.fsf@gnus.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org, juri@linkov.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Lars Ingebrigtsen > Cc: Juri Linkov , philipk@posteo.net, 52973@debbugs.gnu.org > Date: Fri, 07 Jan 2022 07:46:56 +0100 > > Eli Zaretskii writes: > > > Lars, what is your opinion about these issues? Am I the only one who > > thinks that context-menu-mode should automatically activate context > > menus in every mode that has support for it? > > I agree with you -- I see no reason not to activate context menus where > we have support for it. > > (But I've only lightly skimmed this thread, so I may be missing > something (I'm still a bit busy with other stuff, but should be back to > normal next week, hopefully.)) OK. Then I think we should wait with these patches until Lars had time to read the thread more thoroughly and expressed his views. From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 03:29:31 2022 Received: (at 52973) by debbugs.gnu.org; 7 Jan 2022 08:29:31 +0000 Received: from localhost ([127.0.0.1]:42966 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5kct-00011c-6I for submit@debbugs.gnu.org; Fri, 07 Jan 2022 03:29:31 -0500 Received: from mout01.posteo.de ([185.67.36.65]:59797) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5kcq-000119-Hw for 52973@debbugs.gnu.org; Fri, 07 Jan 2022 03:29:29 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id 84A83240027 for <52973@debbugs.gnu.org>; Fri, 7 Jan 2022 09:29:22 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1641544162; bh=+XMSSonAHmJF+SSglH/teOhYyPY+ZZuONj2u8zc4TV4=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=SHlU+PLeAqgZpDrPH/5Dpiwryi7XnxBc4qtaj3Kp6AijTylvDVSwvX20ruI8p4EPM ZW1mLczJjdiD05d9m0b+kG2taPRgbRBdkOFW/uQtZSQox2Pa5UiwfjqO8JckR6YFl5 c0tZMKXS3As63wuZ6/yXk2mUE31lcFnJoUPTX+MooyiRw0bBQZC/GGfQ+62/nrCF8E 99zh4Umi01ERJ/RaviGWLUisGdOLep8a0rSYm1dEnJiYJcXVxWb9mRDTBtsCSm5M4N /vkkjUAGgzGeBVb2q8cW4uVOAbyEcIjT9EM0+lnigL6pSkMiyWYt2jK5drhV3rRr3w ZfhM5bfOc6Xyw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JVbwx3xzCz6tmW; Fri, 7 Jan 2022 09:29:21 +0100 (CET) From: Philip Kaludercic To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Fri, 07 Jan 2022 08:29:20 +0000 In-Reply-To: <83bl0o6oei.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 07 Jan 2022 08:38:45 +0200") Message-ID: <87iluwkkyn.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: Lars Ingebrigtsen , 52973@debbugs.gnu.org, Juri Linkov X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> From: Juri Linkov >> Cc: philipk@posteo.net, 52973@debbugs.gnu.org >> Date: Thu, 06 Jan 2022 22:35:57 +0200 >> >> >> Thanks, everything looks consistent. If no one will have more comments >> >> during the next few days, it seems safe to assume it's ok to push. >> > >> > Yeah, feel free to push and disregard everything I said about this >> > arrangement of context menus not making sense. >> >> The patches from Philip just add new functions. >> Whether to include them in the default value >> of the context function is a separate discussion. > > How does it make sense to add functions that aren't used? > > Lars, what is your opinion about these issues? Am I the only one who > thinks that context-menu-mode should automatically activate context > menus in every mode that has support for it? Unless I have missed it, do mean that all context menus should be loaded by default (auto loading all *-context-menu functions and adding all of them to the default value value of context-menu-functions), or that each context menu definition should be accompanied by a add-to-list on context-menu-functions? -- Philip Kaludercic n From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 07 03:38:03 2022 Received: (at 52973) by debbugs.gnu.org; 7 Jan 2022 08:38:03 +0000 Received: from localhost ([127.0.0.1]:42978 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5kl9-0001WC-Cl for submit@debbugs.gnu.org; Fri, 07 Jan 2022 03:38:03 -0500 Received: from eggs.gnu.org ([209.51.188.92]:40756) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n5kl6-0001VN-JQ for 52973@debbugs.gnu.org; Fri, 07 Jan 2022 03:38:01 -0500 Received: from [2001:470:142:3::e] (port=39514 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 1n5kku-0003GL-2s; Fri, 07 Jan 2022 03:37:53 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=ytCw1LTyxsH15wLxj9HGHNZonjQrD2sgKrbprIp9kEs=; b=DVqUvSyo+oyc 6tNH5yMf7EbodhATJRnG9LyWNWtlGrT6G+J//mB27H6E0dO3hIBFUhWbVkzvMFccDO4fVv3HZMYRK TL6Ne3lH20tonbs7T/ym4LBFvSa+1QMpUgcmj0nyJ/waPs1vTDh+Kz74g1MK+NgutdBLLZg1wwMF3 LNwPNhCLPsYUOrnYZ64mPy6qBILJs6Rpb2BgBwFyMTDMaYlF6HxZp3ictvudPx7f/yKJEuvcFOaS2 7Zd3y/YKNcN7PLGekIZ9rV6Z+hi05yKe8oOoV/eIrA+Rhd6oW9TnpVoVaxHGREDZh9m2ihpQvlwbb Rm9X5SrVqTo6k7ZJSS97ww==; Received: from [87.69.77.57] (port=1961 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 1n5kkp-0006VU-9A; Fri, 07 Jan 2022 03:37:48 -0500 Date: Fri, 07 Jan 2022 10:37:58 +0200 Message-Id: <83k0fc54bd.fsf@gnu.org> From: Eli Zaretskii To: Philip Kaludercic In-Reply-To: <87iluwkkyn.fsf@posteo.net> (message from Philip Kaludercic on Fri, 07 Jan 2022 08:29:20 +0000) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, juri@linkov.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Philip Kaludercic > Cc: Juri Linkov , Lars Ingebrigtsen , > 52973@debbugs.gnu.org > Date: Fri, 07 Jan 2022 08:29:20 +0000 > > Eli Zaretskii writes: > > >> The patches from Philip just add new functions. > >> Whether to include them in the default value > >> of the context function is a separate discussion. > > > > How does it make sense to add functions that aren't used? > > > > Lars, what is your opinion about these issues? Am I the only one who > > thinks that context-menu-mode should automatically activate context > > menus in every mode that has support for it? > > Unless I have missed it, do mean that all context menus should be loaded > by default (auto loading all *-context-menu functions and adding all of > them to the default value value of context-menu-functions), or that each > context menu definition should be accompanied by a add-to-list on > context-menu-functions? I'm not sure I understand why any of what you say should follow. I'm probably missing something. My mental picture is that context menus are specific to modes. When a buffer has certain modes turned on (one major mode and one or more minor modes), those modes are already loaded, and so any functions those modes define are already defined. So when the user right-clicks some spot on display, and one or more modes have defined context-menu items for this spot, the code which does that is already loaded, and calling the functions to produce the menu should not need any autoloading. As for add-to-list, if the implementation of context menus requires adding stuff to some list only when the menu is about to be popped up, then yes, the add-to-list should be done only when the user clicks. But if adding to the list is done when a mode is loaded, then again, since all the relevant modes are already loaded, these functions will have been added to that list already. What am I missing? From debbugs-submit-bounces@debbugs.gnu.org Sat Jan 08 13:33:35 2022 Received: (at 52973) by debbugs.gnu.org; 8 Jan 2022 18:33:35 +0000 Received: from localhost ([127.0.0.1]:48691 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n6GX1-0001gb-KC for submit@debbugs.gnu.org; Sat, 08 Jan 2022 13:33:35 -0500 Received: from relay12.mail.gandi.net ([217.70.178.232]:38153) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n6GWx-0001gD-KU for 52973@debbugs.gnu.org; Sat, 08 Jan 2022 13:33:34 -0500 Received: (Authenticated sender: juri@linkov.net) by relay12.mail.gandi.net (Postfix) with ESMTPSA id 367AE200002; Sat, 8 Jan 2022 18:33:23 +0000 (UTC) From: Juri Linkov To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> Date: Sat, 08 Jan 2022 20:30:06 +0200 In-Reply-To: <83k0fc54bd.fsf@gnu.org> (Eli Zaretskii's message of "Fri, 07 Jan 2022 10:37:58 +0200") Message-ID: <86bl0m13o1.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: Philip Kaludercic , 52973@debbugs.gnu.org, larsi@gnus.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> Unless I have missed it, do mean that all context menus should be loaded >> by default (auto loading all *-context-menu functions and adding all of >> them to the default value value of context-menu-functions), or that each >> context menu definition should be accompanied by a add-to-list on >> context-menu-functions? > > I'm not sure I understand why any of what you say should follow. I'm > probably missing something. > > My mental picture is that context menus are specific to modes. When a > buffer has certain modes turned on (one major mode and one or more > minor modes), those modes are already loaded, and so any functions > those modes define are already defined. So when the user right-clicks > some spot on display, and one or more modes have defined context-menu > items for this spot, the code which does that is already loaded, and > calling the functions to produce the menu should not need any > autoloading. > > As for add-to-list, if the implementation of context menus requires > adding stuff to some list only when the menu is about to be popped up, > then yes, the add-to-list should be done only when the user clicks. > But if adding to the list is done when a mode is loaded, then again, > since all the relevant modes are already loaded, these functions will > have been added to that list already. > > What am I missing? None of the proposed functions is specific to a mode. When the global value of context-menu-functions contains one of the proposed functions, right-clicking anywhere will autoload every package where such context functions are defined. From debbugs-submit-bounces@debbugs.gnu.org Sat Jan 08 13:44:47 2022 Received: (at 52973) by debbugs.gnu.org; 8 Jan 2022 18:44:48 +0000 Received: from localhost ([127.0.0.1]:48696 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n6Ghr-0001yT-LD for submit@debbugs.gnu.org; Sat, 08 Jan 2022 13:44:47 -0500 Received: from eggs.gnu.org ([209.51.188.92]:57786) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n6Ghm-0001yE-DY for 52973@debbugs.gnu.org; Sat, 08 Jan 2022 13:44:46 -0500 Received: from [2001:470:142:3::e] (port=36892 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 1n6Ghg-00083k-Vc; Sat, 08 Jan 2022 13:44:36 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=Nw6fSxX74MG1WKCXJbEY2fo+x/RwxjvH3gxrNOKt/44=; b=qstvEm/7fQH9 zrCcUuekvgzDpx47C4GSIfffkXclsTtVBEDW+WPp7Q6v3bgjBb+AlvjhtFDKEjd3DWWn1K3GN6n18 41VZC4xqz1cQ4813dyMQ+Qf1wD6Yy8JVYUgy/uko9MnCwovZjB09omtcW+TdW6by5cxptU6sXfJDZ ML6a54t5PYywzde/vfY65PtKKAK24OYpsGwl3FFUfonY5xb6hZ5jAPkC9aHUD5pU/0X64iwSBQaFT jHPs1CBLzJYNi+TpwDo5JMRZBcwvuYvWJF55MwOrpND0QUNqsSxONP1Nx3y+fb49Yj8aGbYmp2DPB V94xGlreh1RDFYFRC5l3cQ==; Received: from [87.69.77.57] (port=4949 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 1n6Ghg-0006iB-AX; Sat, 08 Jan 2022 13:44:37 -0500 Date: Sat, 08 Jan 2022 20:44:21 +0200 Message-Id: <83v8yu2hkq.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86bl0m13o1.fsf@mail.linkov.net> (message from Juri Linkov on Sat, 08 Jan 2022 20:30:06 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org, larsi@gnus.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: Philip Kaludercic , larsi@gnus.org, > 52973@debbugs.gnu.org > Date: Sat, 08 Jan 2022 20:30:06 +0200 > > None of the proposed functions is specific to a mode. The way I see it, the functions in man.el are for Man-mode, and those in hi-lock.el are for hi-lock-mode. > When the global value of context-menu-functions > contains one of the proposed functions, right-clicking anywhere > will autoload every package where such context functions are defined. This is over-engineered, IMO. There should be no need for such complexity. From debbugs-submit-bounces@debbugs.gnu.org Sat Jan 08 14:01:56 2022 Received: (at 52973) by debbugs.gnu.org; 8 Jan 2022 19:01:56 +0000 Received: from localhost ([127.0.0.1]:48709 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n6GyR-0002US-Tq for submit@debbugs.gnu.org; Sat, 08 Jan 2022 14:01:56 -0500 Received: from mout02.posteo.de ([185.67.36.66]:44195) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n6GyQ-0002UE-Fm for 52973@debbugs.gnu.org; Sat, 08 Jan 2022 14:01:55 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout02.posteo.de (Postfix) with ESMTPS id 83028240103 for <52973@debbugs.gnu.org>; Sat, 8 Jan 2022 20:01:48 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1641668508; bh=bwiv0I7ca/5NgMQ55p5dwY073FImnuhziclQ9BwpBmc=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=KjSX215iTjJlivMqmJ2dXoR/78Lp1q0YqspYbybrx83vBV6J8BtEGZ0z3ccabr28U EwP/5o/V6OvjYq5+NdSRpXQPwgNcZ2TnLHOfK1wETL/tae/kDGToql4IUuLI5ZoX6w 8bnYcysn/n4T7so/9JIdBp4vNyoG28dYtcRUEyRKes75sx90Q7GXnQKdcyJ0OS0jBk 0lNTobc7KXH/+qqWnNTegf2h+/sLPCXy3JXqFJQ71lnFJsYHzXU9KdZmk6N6RtyPXN JtMB4tdjmySAjK7BinCZY7dwELD1c84efkR2M24izP/O5nJE/q8jROq4hilIydnRyC 8wrGhj2bmlv/w== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JWTwC44ZTz6tq8; Sat, 8 Jan 2022 20:01:47 +0100 (CET) From: Philip Kaludercic To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <83v8yu2hkq.fsf@gnu.org> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Sat, 08 Jan 2022 19:01:46 +0000 In-Reply-To: <83v8yu2hkq.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 08 Jan 2022 20:44:21 +0200") Message-ID: <875yqu59wl.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, Juri Linkov X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> From: Juri Linkov >> Cc: Philip Kaludercic , larsi@gnus.org, >> 52973@debbugs.gnu.org >> Date: Sat, 08 Jan 2022 20:30:06 +0200 >> >> None of the proposed functions is specific to a mode. > > The way I see it, the functions in man.el are for Man-mode, and those > in hi-lock.el are for hi-lock-mode. No, the Man functions can be used anywhere you want to read a man page. It checks if the user clicked on something like "emacs(1)", then inserts a entry into the context menu to open the man page at point. The hi-lock functions can be used to highlight a symbol, just like with `M-s h .'. Requiring hi-lock-mode to be enabled beforehand would be counterproductive. >> When the global value of context-menu-functions >> contains one of the proposed functions, right-clicking anywhere >> will autoload every package where such context functions are defined. > > This is over-engineered, IMO. There should be no need for such > complexity. What would you suggest to simplify this? -- Philip Kaludercic From debbugs-submit-bounces@debbugs.gnu.org Sat Jan 08 14:11:09 2022 Received: (at 52973) by debbugs.gnu.org; 8 Jan 2022 19:11:09 +0000 Received: from localhost ([127.0.0.1]:48727 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n6H7J-0002k6-My for submit@debbugs.gnu.org; Sat, 08 Jan 2022 14:11:09 -0500 Received: from eggs.gnu.org ([209.51.188.92]:35060) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n6H7F-0002jR-SZ for 52973@debbugs.gnu.org; Sat, 08 Jan 2022 14:11:05 -0500 Received: from [2001:470:142:3::e] (port=37480 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 1n6H7A-00046s-I8; Sat, 08 Jan 2022 14:10:56 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=abCp7nzV9nxpm7gMDbBYM3QNUc2+cFp4f6XjQpySxgI=; b=I0Stn5HmKaHJ BkU/LfdYOZ+KvOGBdRL8NiiiSv8Os+07Hn+VkWcnhj3HR4SwJhOri4HB/wjyCus6+RKjJZhRVT6/y PHh+bPHP70OJsjtmhlKgcwhLbq86Ka8/nofU9LdcWABnRRbPBep/gdrHYatz9Uj/2K/dBxlD2ZcBl YxT4aTvloH2kWmQReYwzxO6GDRsZ7ldkZjX9IgJMLEDubvfm7PY1Q3Oo7zdQk4QZ/lD9QnwS74oDa L+w0Le6Qowng8qXwJU8gtzZ9reLS9Ak7VTWQxEE8iqlFdZzqQYEkjv947o5Lko6PoOKRNlRuo3Nhh Pt9A2dcIBCV9NTDTo3kKwQ==; Received: from [87.69.77.57] (port=2583 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 1n6H7A-0007qT-Gx; Sat, 08 Jan 2022 14:10:56 -0500 Date: Sat, 08 Jan 2022 21:10:41 +0200 Message-Id: <83r19i2gcu.fsf@gnu.org> From: Eli Zaretskii To: Philip Kaludercic In-Reply-To: <875yqu59wl.fsf@posteo.net> (message from Philip Kaludercic on Sat, 08 Jan 2022 19:01:46 +0000) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <83v8yu2hkq.fsf@gnu.org> <875yqu59wl.fsf@posteo.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, juri@linkov.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Philip Kaludercic > Cc: Juri Linkov , larsi@gnus.org, 52973@debbugs.gnu.org > Date: Sat, 08 Jan 2022 19:01:46 +0000 > > > The way I see it, the functions in man.el are for Man-mode, and those > > in hi-lock.el are for hi-lock-mode. > > No, the Man functions can be used anywhere you want to read a man page. > It checks if the user clicked on something like "emacs(1)", then inserts > a entry into the context menu to open the man page at point. So it will suggest to show a man page when text like this one from the ELisp manual is displayed: To conserve memory, Emacs does not hold fixed-length 22-bit numbers that are codepoints of text characters within buffers and strings. Rather, Emacs uses a variable-length internal representation of characters, that stores each character as a sequence of 1 to 5 8-bit bytes, depending on the magnitude of its codepoint(1). When the user displays a man page, the probability that "foo(1)" references a man page is very high. In any other major mode, it is likely to be a false positive. For example, it could be an array reference in Fortran or Matlab, or a function call in C or C++. I fail to see how this kind of guesswork can be a good idea if it mostly fails. > The hi-lock functions can be used to highlight a symbol, just like with > `M-s h .'. Requiring hi-lock-mode to be enabled beforehand would be > counterproductive. Why is it counterproductive, if you are going to activate it anyway, the first time the user clicks? > >> When the global value of context-menu-functions > >> contains one of the proposed functions, right-clicking anywhere > >> will autoload every package where such context functions are defined. > > > > This is over-engineered, IMO. There should be no need for such > > complexity. > > What would you suggest to simplify this? See above. From debbugs-submit-bounces@debbugs.gnu.org Sat Jan 08 14:39:52 2022 Received: (at 52973) by debbugs.gnu.org; 8 Jan 2022 19:39:52 +0000 Received: from localhost ([127.0.0.1]:48743 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n6HZA-0003X3-7P for submit@debbugs.gnu.org; Sat, 08 Jan 2022 14:39:52 -0500 Received: from mout01.posteo.de ([185.67.36.65]:34017) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n6HZ7-0003Wj-PK for 52973@debbugs.gnu.org; Sat, 08 Jan 2022 14:39:50 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id DC9F324002A for <52973@debbugs.gnu.org>; Sat, 8 Jan 2022 20:39:43 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1641670783; bh=A66HNQiyk0s5xO3uEnlgPULIGMCn4nAL7BnVMpwwYrU=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=F0azN4CZAPyiZ7vwdGciOSLHCTrfSUnytz9C94erVcmb+PldVGVepRCOOly4tkjJP Voua28jDdP8YUKQxxlmZgmG4CqA/Pk0IksAZErBKh6TWFL/SUPe5E7mBuheqTe8c/P L7X15D6BfhVrwSXW/Di4VHBXQIcX/SKJi4wQevbhnobkgFsfnURn4wKqcHCtwaogW6 tAKIpIMqyI6J6i0zy6jwZzbegYBJWzba9qK8L4U/rCHzP1uxYJqwpfJj1zSCNNkHEu rwM0GW2gqxMj+OHJ/CcnwsgXliQwuoUZyoGnsDJc1WZplbrzXHk7bVj9klEQvm16s5 Xn8TJP31vcYgA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JWVly3PjMz6tp9; Sat, 8 Jan 2022 20:39:42 +0100 (CET) From: Philip Kaludercic To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <83v8yu2hkq.fsf@gnu.org> <875yqu59wl.fsf@posteo.net> <83r19i2gcu.fsf@gnu.org> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Sat, 08 Jan 2022 19:39:41 +0000 In-Reply-To: <83r19i2gcu.fsf@gnu.org> (Eli Zaretskii's message of "Sat, 08 Jan 2022 21:10:41 +0200") Message-ID: <87r19i3tky.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, juri@linkov.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Eli Zaretskii writes: >> From: Philip Kaludercic >> Cc: Juri Linkov , larsi@gnus.org, >> 52973@debbugs.gnu.org >> Date: Sat, 08 Jan 2022 19:01:46 +0000 >> >> > The way I see it, the functions in man.el are for Man-mode, and those >> > in hi-lock.el are for hi-lock-mode. >> >> No, the Man functions can be used anywhere you want to read a man page. >> It checks if the user clicked on something like "emacs(1)", then inserts >> a entry into the context menu to open the man page at point. > > So it will suggest to show a man page when text like this one from the > ELisp manual is displayed: > > To conserve memory, Emacs does not hold fixed-length 22-bit numbers > that are codepoints of text characters within buffers and strings. > Rather, Emacs uses a variable-length internal representation of > characters, that stores each character as a sequence of 1 to 5 8-bit > bytes, depending on the magnitude of its codepoint(1). > > When the user displays a man page, the probability that "foo(1)" > references a man page is very high. Yes, but in that case Man-mode should have already inserted a link that you can just click on, without the need for a context-menu. > In any other major mode, it is likely to be a false positive. For > example, it could be an array reference in Fortran or Matlab, or a > function call in C or C++. I fail to see how this kind of guesswork > can be a good idea if it mostly fails. True, that could be improved, either by actually additionally checking if a man pages exists or by restricting the context menu to only operate on comments. Either way, my intention was to provide context menu entries outside of Man-mode. >> The hi-lock functions can be used to highlight a symbol, just like with >> `M-s h .'. Requiring hi-lock-mode to be enabled beforehand would be >> counterproductive. > > Why is it counterproductive, if you are going to activate it anyway, > the first time the user clicks? (It might be that we are misunderstanding one another right now, so I will be verbose.) If you have nothing highlighted, hi-lock-mode is disabled. By clicking on a symbol, an entry is added to the context menu to highlight the symbol. If this were only to be done if hi-lock-mode is enabled, you couldn't highlight anything, unless you had previously already highlighted something without use of the context menu. The reasoning is basically the same as why highlight-symbol-at-point is bound to the global map and not to hi-lock-map. >> >> When the global value of context-menu-functions >> >> contains one of the proposed functions, right-clicking anywhere >> >> will autoload every package where such context functions are defined. >> > >> > This is over-engineered, IMO. There should be no need for such >> > complexity. >> >> What would you suggest to simplify this? > > See above. -- Philip Kaludercic From debbugs-submit-bounces@debbugs.gnu.org Sat Jan 08 15:10:11 2022 Received: (at 52973) by debbugs.gnu.org; 8 Jan 2022 20:10:11 +0000 Received: from localhost ([127.0.0.1]:48764 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n6I2V-0004P4-6f for submit@debbugs.gnu.org; Sat, 08 Jan 2022 15:10:11 -0500 Received: from eggs.gnu.org ([209.51.188.92]:45626) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n6I2Q-0004ON-8A for 52973@debbugs.gnu.org; Sat, 08 Jan 2022 15:10:10 -0500 Received: from [2001:470:142:3::e] (port=38498 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 1n6I2K-0003pH-NN; Sat, 08 Jan 2022 15:10:00 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=nxCJ2aoiQez0T9R3nCBlYWbNGO6mgjXIXSmBhwlBA2g=; b=Otzj/7lIcM0U WC5c+/61ZsFZTs+tsVzcwpcKgQQNV30lR7Mm+KzRpVgSfsyk3pipPDrmowQ31rNozib0YEdHbWmJp fFN0d8PdhL4rmryy9JIeHqv7wuLv8jzOLhYG53jjZcazFi5foaTzFIWa1JLAgR+CvJxwHJLY4fJdc aWqP7H4oDlHL4DngK5aCS4CUsX9I8fGoXHUwPFDHPM/M0BdfQTBdplMa29cfItUQFaWzaDBECw5LC bC6QDjV9zWnnpoDITHBWm24GOJrBXDeGjXUShcoP8xehF+RSwCG24KldHROVYdbyFCa8R1NZpvHaQ zerTcnLgnj6hYqmLzJ0Qdg==; Received: from [87.69.77.57] (port=2309 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 1n6I2K-0001Nx-NF; Sat, 08 Jan 2022 15:10:01 -0500 Date: Sat, 08 Jan 2022 22:09:44 +0200 Message-Id: <83o84m2dmf.fsf@gnu.org> From: Eli Zaretskii To: Philip Kaludercic In-Reply-To: <87r19i3tky.fsf@posteo.net> (message from Philip Kaludercic on Sat, 08 Jan 2022 19:39:41 +0000) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <83v8yu2hkq.fsf@gnu.org> <875yqu59wl.fsf@posteo.net> <83r19i2gcu.fsf@gnu.org> <87r19i3tky.fsf@posteo.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, juri@linkov.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Philip Kaludercic > Cc: juri@linkov.net, larsi@gnus.org, 52973@debbugs.gnu.org > Date: Sat, 08 Jan 2022 19:39:41 +0000 > > >> No, the Man functions can be used anywhere you want to read a man page. > >> It checks if the user clicked on something like "emacs(1)", then inserts > >> a entry into the context menu to open the man page at point. > > > > So it will suggest to show a man page when text like this one from the > > ELisp manual is displayed: > > > > To conserve memory, Emacs does not hold fixed-length 22-bit numbers > > that are codepoints of text characters within buffers and strings. > > Rather, Emacs uses a variable-length internal representation of > > characters, that stores each character as a sequence of 1 to 5 8-bit > > bytes, depending on the magnitude of its codepoint(1). > > > > When the user displays a man page, the probability that "foo(1)" > > references a man page is very high. > > Yes, but in that case Man-mode should have already inserted a link that > you can just click on, without the need for a context-menu. So let me step back a notch and ask: how else can we cause the context menus to be automatically populated in a given buffer, once context-menu-mode is turned on? It must be some buffer-local feature, because different buffers should in principle show different context menus. That's why I thought about modes -- those are always buffer-local, and mode initialization code runs in every buffer where the mode is turned on, so we have a place to produce the context menus. If you want to have context menus populated regardless of the modes, what other buffer-specific mechanism can we employ? IOW, what would be the trigger for populating the context menus? It cannot be the user, because that makes no sense to me: the user already told us he/she wants those menus when he/she turned on the context-menu-mode. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 12 01:16:31 2022 Received: (at 52973) by debbugs.gnu.org; 12 Jan 2022 06:16:31 +0000 Received: from localhost ([127.0.0.1]:56067 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7Wvv-0006rY-9w for submit@debbugs.gnu.org; Wed, 12 Jan 2022 01:16:31 -0500 Received: from quimby.gnus.org ([95.216.78.240]:39704) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7Wvt-0006rC-SC for 52973@debbugs.gnu.org; Wed, 12 Jan 2022 01:16:30 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=qeWuz+gGo1odHYzMmmQtGtaUXBuDqetywovugzUAR14=; b=QoHi+0l0s/8GuBgjC3+Oz1s1To lawzJWFy2MNgOLKYG2tF2/PqFbJ/QGSUHkKiYsMqspf7pNzlqLPA1bVW39lGRU2SNdSlFP0FpRT+H jO5Z9UJ2U8DolHZfqpE4QVzLS7cf5hWqymEohEniLOuKlj2OZw4MTyV8OmoUz9Ie2cPI=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n7Wvk-00077q-Te; Wed, 12 Jan 2022 07:16:23 +0100 From: Lars Ingebrigtsen To: Juri Linkov Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> X-Now-Playing: Cocteau Twins's _The Pink Opaque_: "From the Flagstones" Date: Wed, 12 Jan 2022 07:16:20 +0100 In-Reply-To: <86bl0m13o1.fsf@mail.linkov.net> (Juri Linkov's message of "Sat, 08 Jan 2022 20:30:06 +0200") Message-ID: <87czkxbhsb.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Juri Linkov writes: > None of the proposed functions is specific to a mode. > When the global value of context-menu-functions > contains one of the proposed functions, right-clicking anywhere > will autoload every packag [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: Eli Zaretskii , 52973@debbugs.gnu.org, Philip Kaludercic X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Juri Linkov writes: > None of the proposed functions is specific to a mode. > When the global value of context-menu-functions > contains one of the proposed functions, right-clicking anywhere > will autoload every package where such context functions are defined. Ah, I see. I misunderstood how the context menu machinery works -- I thought it contained mode-specific stuff, and in addition, things that are relevant at the point. That is, if you're over a text like "foo(1)", then there'd be a predicate to say that this might be a manual reference, and then you'd get the Man context menu. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 12 08:12:36 2022 Received: (at 52973) by debbugs.gnu.org; 12 Jan 2022 13:12:36 +0000 Received: from localhost ([127.0.0.1]:56455 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7dQZ-0005tq-OH for submit@debbugs.gnu.org; Wed, 12 Jan 2022 08:12:36 -0500 Received: from eggs.gnu.org ([209.51.188.92]:46274) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7dQX-0005ta-QX for 52973@debbugs.gnu.org; Wed, 12 Jan 2022 08:12:34 -0500 Received: from [2001:470:142:3::e] (port=44552 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 1n7dQQ-0002zr-5O; Wed, 12 Jan 2022 08:12:28 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=XLpLyY2DHkDCt3X38wvJHrVCcUrQt6E2fCBR06qcmIE=; b=I4IdPPsi6k5T gusS/PkrVJLeZ14krLanWZMj68r6uPYmPqJJGUm12FPDP480kpuUbcHurfxCyRP2gXJ3iYCk2X4C7 Ka39LS8EjQKY76pEbtxlFEA6qyIIfegwGi3ApVEUnyjj5rtfe4USwLqwJbN8YrG/sN0RWuNPu0sgO BOo/nu9Ugf+44zvJRp5gOGdrAsRafRrjwoN46HayKcaEXP9Yki5G2LmuUAlWL33X4luSqRjPEefCe uNPSP4l8pI2Nk0FnSJBAp56q8TdeZKxhGCXIDLknqbQ+W50eoYI168NBuUMDMgJMtQxvLizblPQ4/ U7bsDlKyerhXh9iZfeFBFA==; Received: from [87.69.77.57] (port=2873 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 1n7dQM-0007Nb-0B; Wed, 12 Jan 2022 08:12:24 -0500 Date: Wed, 12 Jan 2022 15:12:18 +0200 Message-Id: <83sftt5c99.fsf@gnu.org> From: Eli Zaretskii To: Lars Ingebrigtsen In-Reply-To: <87czkxbhsb.fsf@gnus.org> (message from Lars Ingebrigtsen on Wed, 12 Jan 2022 07:16:20 +0100) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org, juri@linkov.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Lars Ingebrigtsen > Cc: Eli Zaretskii , Philip Kaludercic , > 52973@debbugs.gnu.org > Date: Wed, 12 Jan 2022 07:16:20 +0100 > > Juri Linkov writes: > > > None of the proposed functions is specific to a mode. > > When the global value of context-menu-functions > > contains one of the proposed functions, right-clicking anywhere > > will autoload every package where such context functions are defined. > > Ah, I see. I misunderstood how the context menu machinery works -- I > thought it contained mode-specific stuff, and in addition, things that > are relevant at the point. That is, if you're over a text like > "foo(1)", then there'd be a predicate to say that this might be a > manual reference, and then you'd get the Man context menu. How do we make sure stuff like "foo(1)" doesn't cause a lot of false positives when applied in modes whose idea of what that means is very different from Man-mode? More importantly, if this stuff is supposed to be global, how do we provide the users with a context-menu-mode which seamlessly does TRT without asking the user to invest too much effort into populating his/her menus? I'm not aware of any popular application out there which expects the users to customize context menus before they work as expected, i.e. show relevant information in relevant places without including a lot of irrelevant menu items. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 12 12:27:22 2022 Received: (at 52973) by debbugs.gnu.org; 12 Jan 2022 17:27:22 +0000 Received: from localhost ([127.0.0.1]:58917 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7hP7-0008EX-Pr for submit@debbugs.gnu.org; Wed, 12 Jan 2022 12:27:21 -0500 Received: from relay7-d.mail.gandi.net ([217.70.183.200]:55397) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7hP6-0008EI-RJ for 52973@debbugs.gnu.org; Wed, 12 Jan 2022 12:27:21 -0500 Received: (Authenticated sender: juri@linkov.net) by relay7-d.mail.gandi.net (Postfix) with ESMTPSA id 8FDEA20007; Wed, 12 Jan 2022 17:27:12 +0000 (UTC) From: Juri Linkov To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> Date: Wed, 12 Jan 2022 19:16:22 +0200 In-Reply-To: <83sftt5c99.fsf@gnu.org> (Eli Zaretskii's message of "Wed, 12 Jan 2022 15:12:18 +0200") Message-ID: <86ilupt0d1.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: Lars Ingebrigtsen , 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> Ah, I see. I misunderstood how the context menu machinery works -- I >> thought it contained mode-specific stuff, and in addition, things that >> are relevant at the point. That is, if you're over a text like >> "foo(1)", then there'd be a predicate to say that this might be a >> manual reference, and then you'd get the Man context menu. > > How do we make sure stuff like "foo(1)" doesn't cause a lot of false > positives when applied in modes whose idea of what that means is very > different from Man-mode? For example, today while editing a shell script I needed to consult the man page about the arguments of the command `zenity` used in the script. It takes too many keystrokes to type `M-x man RET zenity RET' or first to move point to this command, then to type `M-x man RET RET'. With the context menu, it's just one click: press the right mouse button on the command name, select the item "Open man page", and release the mouse button. As you can see, there is no special syntax "foo(1)" used in the script. The context menu item "Open man page" might be useful on any word that can show a man page for any command or function. This means that the item "Open man page" can't be added to the context menu by default, because it makes no sense most of the time. But when a user can tolerate this mostly useless menu item, then the user could customize the context-menu-functions and add the item that is used occasionally. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 12 12:36:17 2022 Received: (at 52973) by debbugs.gnu.org; 12 Jan 2022 17:36:17 +0000 Received: from localhost ([127.0.0.1]:58955 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7hXl-0002Kj-24 for submit@debbugs.gnu.org; Wed, 12 Jan 2022 12:36:17 -0500 Received: from eggs.gnu.org ([209.51.188.92]:56268) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7hXj-0002KW-KL for 52973@debbugs.gnu.org; Wed, 12 Jan 2022 12:36:16 -0500 Received: from [2001:470:142:3::e] (port=52528 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 1n7hXd-0001FA-S6; Wed, 12 Jan 2022 12:36:09 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=v2MhcxXRdTTKKRRN6kgqekoc0V8D8Hceuz1QEbx3knk=; b=AptjkxU4OscW DxlbGTBToNQc5p5/giTcGR3Dg4wGge+eoTi4A765kXSsOf7uT9wItlhOA7eQAV5cx+s+AovVEB+E6 y12shXvGWpZcX3GsMi1GsFkZdwdv/u/XCkt8XMExsFjV1FHjelVmYUW8i/r8/mXfQcsStnKq16Q76 EXCZ8SHQhvzNy8VYtMbU1p+H00QK3qEl+/4DITmyyfqAqFSyVIGsj/OQaCI8tcxhwLmRLuc6pdwec rINCncCuPPHfI1ozTPd5GKlxi6pOMn9t5y5yl31WrthL1G+6BnN4Z7WhJHqZHNHmYguO2qKfFn6DO JCmRRLwFSvpdI4b8PwgNJQ==; Received: from [87.69.77.57] (port=3566 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 1n7hXd-0004DX-Tn; Wed, 12 Jan 2022 12:36:10 -0500 Date: Wed, 12 Jan 2022 19:36:03 +0200 Message-Id: <838rvk6em4.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86ilupt0d1.fsf@mail.linkov.net> (message from Juri Linkov on Wed, 12 Jan 2022 19:16:22 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: Lars Ingebrigtsen , philipk@posteo.net, > 52973@debbugs.gnu.org > Date: Wed, 12 Jan 2022 19:16:22 +0200 > > > How do we make sure stuff like "foo(1)" doesn't cause a lot of false > > positives when applied in modes whose idea of what that means is very > > different from Man-mode? I don't think you answered my question above. > For example, today while editing a shell script I needed to consult the > man page about the arguments of the command `zenity` used in the script. > It takes too many keystrokes to type `M-x man RET zenity RET' > or first to move point to this command, then to type `M-x man RET RET'. > > With the context menu, it's just one click: press the right mouse button > on the command name, select the item "Open man page", and release the > mouse button. > > As you can see, there is no special syntax "foo(1)" used in the script. > The context menu item "Open man page" might be useful on any word > that can show a man page for any command or function. > > This means that the item "Open man page" can't be added to the > context menu by default, because it makes no sense most of the time. I don't get it: is the "Open man page" item in the context menu useful or is it useless? The beginning of your description sounds like saying that it's useful, and I almost wanted to ask: so you assume that the user will decide when this item makes sense or not, and therefore we shouldn't be bothered by potential false positives?" But then you say that this item is mostly useless and shouldn't be in the context menu by default? That sounds like a contradiction of the success story with which you started, where the existence of the menu item is a win, isn't it? And then this conclusion: > But when a user can tolerate this mostly useless menu item, > then the user could customize the context-menu-functions > and add the item that is used occasionally. How would the user decide whether he can tolerate this mostly useless menu item? And why should this burden be on the user's shoulders? From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 12 13:05:52 2022 Received: (at 52973) by debbugs.gnu.org; 12 Jan 2022 18:05:52 +0000 Received: from localhost ([127.0.0.1]:59035 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7i0N-0007kd-SP for submit@debbugs.gnu.org; Wed, 12 Jan 2022 13:05:52 -0500 Received: from relay3-d.mail.gandi.net ([217.70.183.195]:59067) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7i0J-0007kK-VF for 52973@debbugs.gnu.org; Wed, 12 Jan 2022 13:05:51 -0500 Received: (Authenticated sender: juri@linkov.net) by relay3-d.mail.gandi.net (Postfix) with ESMTPSA id 5854D60006; Wed, 12 Jan 2022 18:05:39 +0000 (UTC) From: Juri Linkov To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <838rvk6em4.fsf@gnu.org> Date: Wed, 12 Jan 2022 20:03:51 +0200 In-Reply-To: <838rvk6em4.fsf@gnu.org> (Eli Zaretskii's message of "Wed, 12 Jan 2022 19:36:03 +0200") Message-ID: <86tue8rfug.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> > How do we make sure stuff like "foo(1)" doesn't cause a lot of false >> > positives when applied in modes whose idea of what that means is very >> > different from Man-mode? > > I don't think you answered my question above. The answer is that we can't make sure stuff like "foo" doesn't cause false positives. >> For example, today while editing a shell script I needed to consult the >> man page about the arguments of the command `zenity` used in the script. >> It takes too many keystrokes to type `M-x man RET zenity RET' >> or first to move point to this command, then to type `M-x man RET RET'. >> >> With the context menu, it's just one click: press the right mouse button >> on the command name, select the item "Open man page", and release the >> mouse button. >> >> As you can see, there is no special syntax "foo(1)" used in the script. >> The context menu item "Open man page" might be useful on any word >> that can show a man page for any command or function. >> >> This means that the item "Open man page" can't be added to the >> context menu by default, because it makes no sense most of the time. > > I don't get it: is the "Open man page" item in the context menu useful > or is it useless? The beginning of your description sounds like > saying that it's useful, and I almost wanted to ask: so you assume > that the user will decide when this item makes sense or not, and > therefore we shouldn't be bothered by potential false positives?" > > But then you say that this item is mostly useless and shouldn't be in > the context menu by default? That sounds like a contradiction of the > success story with which you started, where the existence of the menu > item is a win, isn't it? It's useless for most users, so it's not suitable to be enabled by default. Only a minority of users might want to customize and add it. > And then this conclusion: > >> But when a user can tolerate this mostly useless menu item, >> then the user could customize the context-menu-functions >> and add the item that is used occasionally. > > How would the user decide whether he can tolerate this mostly useless > menu item? And why should this burden be on the user's shoulders? This is suitable for users that consult man pages often, or users can add the "Open man page" item buffer-locally in some modes. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 12 14:27:47 2022 Received: (at 52973) by debbugs.gnu.org; 12 Jan 2022 19:27:47 +0000 Received: from localhost ([127.0.0.1]:59164 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7jHf-0003xD-DH for submit@debbugs.gnu.org; Wed, 12 Jan 2022 14:27:47 -0500 Received: from eggs.gnu.org ([209.51.188.92]:57358) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7jHe-0003x1-BE for 52973@debbugs.gnu.org; Wed, 12 Jan 2022 14:27:46 -0500 Received: from [2001:470:142:3::e] (port=55102 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 1n7jHP-00029p-Ob; Wed, 12 Jan 2022 14:27:39 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=ZQSM6eblSXWoARHXB/jIoQezVavrf7zeazS2kX/7+9Y=; b=Fxbqo6A2MGbj J7BYc3PxfJwbFjQ33OyIjX7QC5IsIatyRpTh7gAg/HfcuJCybqEvLN7sRPwsTkbx3cPFhLCKTgrKn vrUpeDven/6Is2JD1EQzCVbKU4+iGKQ+USQVtGFDEYkRej3eI9nXafeEcapQpCuZqINCUYUaEY5Xm 59DelBmjCoZ1JTa+p9XIH3OsHMtM+xY79YS90HTjrm4KH29k0IOErApqgW1x15OuijR8bf9zIW5V0 ooOm+SjGS0nvep/+OVY6uD60GKGQyDFMwqDN3LW0Gzhjaa49YhWjAcW4Q0V7zlZVP2GqX73cc87hI BfM1ou3MfvCl/Q/SLrcDCA==; Received: from [87.69.77.57] (port=2399 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 1n7jHL-00087K-V9; Wed, 12 Jan 2022 14:27:32 -0500 Date: Wed, 12 Jan 2022 21:27:22 +0200 Message-Id: <834k6869gl.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86tue8rfug.fsf@mail.linkov.net> (message from Juri Linkov on Wed, 12 Jan 2022 20:03:51 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <838rvk6em4.fsf@gnu.org> <86tue8rfug.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: larsi@gnus.org, philipk@posteo.net, 52973@debbugs.gnu.org > Date: Wed, 12 Jan 2022 20:03:51 +0200 > > > But then you say that this item is mostly useless and shouldn't be in > > the context menu by default? That sounds like a contradiction of the > > success story with which you started, where the existence of the menu > > item is a win, isn't it? > > It's useless for most users, so it's not suitable to be enabled by default. > Only a minority of users might want to customize and add it. > > > And then this conclusion: > > > >> But when a user can tolerate this mostly useless menu item, > >> then the user could customize the context-menu-functions > >> and add the item that is used occasionally. > > > > How would the user decide whether he can tolerate this mostly useless > > menu item? And why should this burden be on the user's shoulders? > > This is suitable for users that consult man pages often, > or users can add the "Open man page" item buffer-locally > in some modes. A menu item that is not used does no special harm. So why not have these items in the menus by default? Requesting the users to activate those items makes little sense to me, since these obscure customizations are hardly discoverable. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 12 14:45:57 2022 Received: (at 52973) by debbugs.gnu.org; 12 Jan 2022 19:45:57 +0000 Received: from localhost ([127.0.0.1]:59183 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7jZE-0004Rd-Qw for submit@debbugs.gnu.org; Wed, 12 Jan 2022 14:45:57 -0500 Received: from relay1-d.mail.gandi.net ([217.70.183.193]:41289) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7jZC-0004RL-UI for 52973@debbugs.gnu.org; Wed, 12 Jan 2022 14:45:55 -0500 Received: (Authenticated sender: juri@linkov.net) by relay1-d.mail.gandi.net (Postfix) with ESMTPSA id E811E240004; Wed, 12 Jan 2022 19:45:46 +0000 (UTC) From: Juri Linkov To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <838rvk6em4.fsf@gnu.org> <86tue8rfug.fsf@mail.linkov.net> <834k6869gl.fsf@gnu.org> Date: Wed, 12 Jan 2022 21:41:04 +0200 In-Reply-To: <834k6869gl.fsf@gnu.org> (Eli Zaretskii's message of "Wed, 12 Jan 2022 21:27:22 +0200") Message-ID: <86k0f4rbcf.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> > But then you say that this item is mostly useless and shouldn't be in >> > the context menu by default? That sounds like a contradiction of the >> > success story with which you started, where the existence of the menu >> > item is a win, isn't it? >> >> It's useless for most users, so it's not suitable to be enabled by default. >> Only a minority of users might want to customize and add it. >> >> > And then this conclusion: >> > >> >> But when a user can tolerate this mostly useless menu item, >> >> then the user could customize the context-menu-functions >> >> and add the item that is used occasionally. >> > >> > How would the user decide whether he can tolerate this mostly useless >> > menu item? And why should this burden be on the user's shoulders? >> >> This is suitable for users that consult man pages often, >> or users can add the "Open man page" item buffer-locally >> in some modes. > > A menu item that is not used does no special harm. So why not have > these items in the menus by default? Adding all these items by default will load all these packages by default, including man.el, hi-lock.el, etc. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 12 14:53:46 2022 Received: (at 52973) by debbugs.gnu.org; 12 Jan 2022 19:53:46 +0000 Received: from localhost ([127.0.0.1]:59205 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7jgn-0004gz-Pz for submit@debbugs.gnu.org; Wed, 12 Jan 2022 14:53:46 -0500 Received: from eggs.gnu.org ([209.51.188.92]:35008) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7jgm-0004go-UO for 52973@debbugs.gnu.org; Wed, 12 Jan 2022 14:53:45 -0500 Received: from [2001:470:142:3::e] (port=55372 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 1n7jgh-0006IW-Fk; Wed, 12 Jan 2022 14:53:39 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=lKKH5/7KenJnjiLe5mtkt+CmN1eAusNVb0jo7/zZx9k=; b=pSvoSr5EfrbH H6raqNNGanfDLcQFItf+PRLwnO5LlwzsJbr5560NnJOR5vxc2eJII1+ISWdifbbzSlIwcWSddtwfw vImDNoSzEEHsnCkJlXrNNVjjVUMz9dDbdiD42MoMmcIbfv2yfJ4T+JKwRUvUEDeBALzuYNSqX6yd1 sBpFvMqH93C91TxfyNet2X1pBbuvbPPvvXv7pfnlFtTVLGXqcgnqH41EpjzNc2/lmRqmFLZ1yXLga q85e/jqH9ARII5qf7OUutlG8sfYsIu37F2kZqs024LnL3Wu8p7X+w7tB2OWsIAOT5tJoVUa6emZJ3 UU5O2ovh4rIWYqGlrPKbJw==; Received: from [87.69.77.57] (port=3999 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 1n7jgh-0005nS-Hz; Wed, 12 Jan 2022 14:53:39 -0500 Date: Wed, 12 Jan 2022 21:53:36 +0200 Message-Id: <83y23k4tof.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86k0f4rbcf.fsf@mail.linkov.net> (message from Juri Linkov on Wed, 12 Jan 2022 21:41:04 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <838rvk6em4.fsf@gnu.org> <86tue8rfug.fsf@mail.linkov.net> <834k6869gl.fsf@gnu.org> <86k0f4rbcf.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: larsi@gnus.org, philipk@posteo.net, 52973@debbugs.gnu.org > Date: Wed, 12 Jan 2022 21:41:04 +0200 > > > A menu item that is not used does no special harm. So why not have > > these items in the menus by default? > > Adding all these items by default will load all these packages by default, > including man.el, hi-lock.el, etc. When will that load these packages? When context-menu-mode is turned on, when the menu is actually popped up, or something else? From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 12 15:01:43 2022 Received: (at 52973) by debbugs.gnu.org; 12 Jan 2022 20:01:43 +0000 Received: from localhost ([127.0.0.1]:59218 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7joV-0004vJ-4p for submit@debbugs.gnu.org; Wed, 12 Jan 2022 15:01:43 -0500 Received: from relay2-d.mail.gandi.net ([217.70.183.194]:38909) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7joT-0004v0-Ci for 52973@debbugs.gnu.org; Wed, 12 Jan 2022 15:01:41 -0500 Received: (Authenticated sender: juri@linkov.net) by relay2-d.mail.gandi.net (Postfix) with ESMTPSA id B608F40003; Wed, 12 Jan 2022 20:01:33 +0000 (UTC) From: Juri Linkov To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <838rvk6em4.fsf@gnu.org> <86tue8rfug.fsf@mail.linkov.net> <834k6869gl.fsf@gnu.org> <86k0f4rbcf.fsf@mail.linkov.net> <83y23k4tof.fsf@gnu.org> Date: Wed, 12 Jan 2022 22:00:37 +0200 In-Reply-To: <83y23k4tof.fsf@gnu.org> (Eli Zaretskii's message of "Wed, 12 Jan 2022 21:53:36 +0200") Message-ID: <86sftsohay.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> > A menu item that is not used does no special harm. So why not have >> > these items in the menus by default? >> >> Adding all these items by default will load all these packages by default, >> including man.el, hi-lock.el, etc. > > When will that load these packages? When context-menu-mode is turned > on, when the menu is actually popped up, or something else? When the menu is popped up the first time. From debbugs-submit-bounces@debbugs.gnu.org Wed Jan 12 15:42:47 2022 Received: (at 52973) by debbugs.gnu.org; 12 Jan 2022 20:42:47 +0000 Received: from localhost ([127.0.0.1]:59247 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7kSE-0005yD-SO for submit@debbugs.gnu.org; Wed, 12 Jan 2022 15:42:47 -0500 Received: from eggs.gnu.org ([209.51.188.92]:44494) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7kSD-0005xt-3a for 52973@debbugs.gnu.org; Wed, 12 Jan 2022 15:42:45 -0500 Received: from [2001:470:142:3::e] (port=55810 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 1n7kS7-00058L-NU; Wed, 12 Jan 2022 15:42:39 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=KKrIAYcEMwfL9a6qi3tZRqSY3qW4uF+LTfmMRiSva34=; b=YO6PdZKLM7x1 QmReDqtukSw6zTsAoN7BKagK8CaBD0rrb0oz+V+Rwvj98jXf3LxiqpGmET9/0wplTNho+WlkDTkcE IGzo++b6p0Le2rgLen/kklYz9DX1IG9/UzpDNSO2fDgkcsMJYR5LN6jixlO/HuvXL4gvUB18x+c2e dfV4oerb5s5zQGVY9H6nheJ5/SfPund1AN+3bF8dMDcBNxZD1jrLSEqNHBl9GJW7CRwK72JURWdjP b9v1aTNERIiBmUO9PcBQrGsrVd5M4LCJjI98r9ctu5JDKunBCOXbwyRlFBagr3EvEjc1cX2snmRhb ClgVNqFL6avkZZycy4lcYA==; Received: from [87.69.77.57] (port=3255 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 1n7kS7-0002s9-PD; Wed, 12 Jan 2022 15:42:40 -0500 Date: Wed, 12 Jan 2022 22:42:36 +0200 Message-Id: <83sfts4rer.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86sftsohay.fsf@mail.linkov.net> (message from Juri Linkov on Wed, 12 Jan 2022 22:00:37 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <838rvk6em4.fsf@gnu.org> <86tue8rfug.fsf@mail.linkov.net> <834k6869gl.fsf@gnu.org> <86k0f4rbcf.fsf@mail.linkov.net> <83y23k4tof.fsf@gnu.org> <86sftsohay.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: larsi@gnus.org, philipk@posteo.net, 52973@debbugs.gnu.org > Date: Wed, 12 Jan 2022 22:00:37 +0200 > > >> > A menu item that is not used does no special harm. So why not have > >> > these items in the menus by default? > >> > >> Adding all these items by default will load all these packages by default, > >> including man.el, hi-lock.el, etc. > > > > When will that load these packages? When context-menu-mode is turned > > on, when the menu is actually popped up, or something else? > > When the menu is popped up the first time. Then why is that a problem? We could alternatively only have these items when the corresponding package is loaded, but you rejected that possibility, AFAIU. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 13 01:03:59 2022 Received: (at 52973) by debbugs.gnu.org; 13 Jan 2022 06:03:59 +0000 Received: from localhost ([127.0.0.1]:59734 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7tD9-0000gA-It for submit@debbugs.gnu.org; Thu, 13 Jan 2022 01:03:59 -0500 Received: from quimby.gnus.org ([95.216.78.240]:49832) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7tD5-0000fr-Ld for 52973@debbugs.gnu.org; Thu, 13 Jan 2022 01:03:46 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=N0tsXyraCLKxf1N7tN5bJ4L1HZdiGY2cDxFEpL8CPLw=; b=ox+9Tz9meiMLxQS6fkvkUU74ZF wLybpaWx/Oe9nAQnrym2gYkXxsN3zjVhYHCNGFMkhnJt1a/oP3H/Qi7PXzg0ZzOi25FjhnRCbPVoE hdxr2BfuvTPpfkBlT8o5mwI4qdG6rB5f/HAc8PstD0XeGFh5d8lnJrHTJXkfj+JI2h6E=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n7tCv-0007yR-On; Thu, 13 Jan 2022 07:03:36 +0100 From: Lars Ingebrigtsen To: Juri Linkov Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAG1BMVEWuzdPp6+NWrNVT gm88WklAnKonJRwRBgf///+193jlAAAAAWJLR0QIht6VegAAAAd0SU1FB+YBDQU7DYcL8jwAAAGL SURBVDjLbZNtbsMgDIYdugMk2gUmKv5ngu4CZRxgiBtEyQWqcv3a2FDo6n95H7/+AALT8hIzqLP9 NXB9A7T1Gtw3fdkRnN0FTmSZr50OoLXzsHyg5XOtOkABBsGMZezU5WMprRMsZFmnZzrmYxigBvP6 ImMgWNxpbV1rUKkFLCerqpqUChiLJA6QWQYxRmuBx1FNtxTOewFc2EYWKRqgCih7iV16lEFq9k7B DqWbvkvwpLOhQqiHIh4533mvL8O6FxmD96WJrOiZA+oRVEPuQRnVc4cemApaAwHpTaUBhM7wBL6C 23+wvwDTgTwAtETXpu1KKQaBz+PeAAiQg2qOaVGyH6Hj2ARMy8yOq2PPJqeL96f5Vp0PG6LqQKBM eRu+DNaa08W2V4P6CEy01Cf0m1MPEy+o0yK5B9gi/RX9GABNm5KjHTJNSj02R8CUNUIFt+MJ6knd G/hhwE+Te5ce7FBlb1qcATkCAf7LcKyulMsg/71OHvPLq0W4BwGzjqGM2r2r8ntgGVEaeAD79ieo hh27QQAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMi0wMS0xM1QwNTo1OToxMyswMDowMDZvfgMAAAAl dEVYdGRhdGU6bW9kaWZ5ADIwMjItMDEtMTNUMDU6NTk6MTMrMDA6MDBHMsa/AAAAAElFTkSuQmCC X-Now-Playing: Was (Not Was)'s _Wheel Me Out (Long Version)_: "Wheel Me Out (Long Version)" Date: Thu, 13 Jan 2022 07:03:33 +0100 In-Reply-To: <86ilupt0d1.fsf@mail.linkov.net> (Juri Linkov's message of "Wed, 12 Jan 2022 19:16:22 +0200") Message-ID: <871r1cb2a2.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Juri Linkov writes: > For example, today while editing a shell script I needed to consult the > man page about the arguments of the command `zenity` used in the script. > It takes too many keystrokes to type `M-x man RET [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: Eli Zaretskii , 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Juri Linkov writes: > For example, today while editing a shell script I needed to consult the > man page about the arguments of the command `zenity` used in the script. > It takes too many keystrokes to type `M-x man RET zenity RET' > or first to move point to this command, then to type `M-x man RET RET'. > > With the context menu, it's just one click: press the right mouse button > on the command name, select the item "Open man page", and release the > mouse button. So it sounds to me like shell-script-mode (and derivatives and other shell-ish modes) should have the `man' bits of the context menu enabled by default? -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 13 03:46:43 2022 Received: (at 52973) by debbugs.gnu.org; 13 Jan 2022 08:46:43 +0000 Received: from localhost ([127.0.0.1]:60079 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7vko-0006Qz-Ul for submit@debbugs.gnu.org; Thu, 13 Jan 2022 03:46:43 -0500 Received: from relay8-d.mail.gandi.net ([217.70.183.201]:55713) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7vkm-0006Qc-RS for 52973@debbugs.gnu.org; Thu, 13 Jan 2022 03:46:41 -0500 Received: (Authenticated sender: juri@linkov.net) by relay8-d.mail.gandi.net (Postfix) with ESMTPSA id A39181BF204; Thu, 13 Jan 2022 08:46:33 +0000 (UTC) From: Juri Linkov To: Lars Ingebrigtsen Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <871r1cb2a2.fsf@gnus.org> Date: Thu, 13 Jan 2022 10:35:50 +0200 In-Reply-To: <871r1cb2a2.fsf@gnus.org> (Lars Ingebrigtsen's message of "Thu, 13 Jan 2022 07:03:33 +0100") Message-ID: <86tue8t4m1.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: Eli Zaretskii , 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> For example, today while editing a shell script I needed to consult the >> man page about the arguments of the command `zenity` used in the script. >> It takes too many keystrokes to type `M-x man RET zenity RET' >> or first to move point to this command, then to type `M-x man RET RET'. >> >> With the context menu, it's just one click: press the right mouse button >> on the command name, select the item "Open man page", and release the >> mouse button. > > So it sounds to me like shell-script-mode (and derivatives and other > shell-ish modes) should have the `man' bits of the context menu enabled > by default? Nope. This `man' menu item might be useful everywhere, for example, in this Gnus Article buffer, to look up the command cited above. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 13 03:46:47 2022 Received: (at 52973) by debbugs.gnu.org; 13 Jan 2022 08:46:47 +0000 Received: from localhost ([127.0.0.1]:60082 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7vkt-0006RG-5A for submit@debbugs.gnu.org; Thu, 13 Jan 2022 03:46:47 -0500 Received: from relay4-d.mail.gandi.net ([217.70.183.196]:51577) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7vkq-0006Qo-TE for 52973@debbugs.gnu.org; Thu, 13 Jan 2022 03:46:45 -0500 Received: (Authenticated sender: juri@linkov.net) by relay4-d.mail.gandi.net (Postfix) with ESMTPSA id 0F745E0005; Thu, 13 Jan 2022 08:46:36 +0000 (UTC) From: Juri Linkov To: Eli Zaretskii Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <838rvk6em4.fsf@gnu.org> <86tue8rfug.fsf@mail.linkov.net> <834k6869gl.fsf@gnu.org> <86k0f4rbcf.fsf@mail.linkov.net> <83y23k4tof.fsf@gnu.org> <86sftsohay.fsf@mail.linkov.net> <83sfts4rer.fsf@gnu.org> Date: Thu, 13 Jan 2022 10:39:25 +0200 In-Reply-To: <83sfts4rer.fsf@gnu.org> (Eli Zaretskii's message of "Wed, 12 Jan 2022 22:42:36 +0200") Message-ID: <86bl0gt47q.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >> >> > A menu item that is not used does no special harm. So why not have >> >> > these items in the menus by default? >> >> >> >> Adding all these items by default will load all these packages by default, >> >> including man.el, hi-lock.el, etc. >> > >> > When will that load these packages? When context-menu-mode is turned >> > on, when the menu is actually popped up, or something else? >> >> When the menu is popped up the first time. > > Then why is that a problem? The problem is that irrelevant packages will be loaded by default. > We could alternatively only have these items when the corresponding > package is loaded, but you rejected that possibility, AFAIU. This means there are no hi-lock/man items by default. Then once the user used `M-x man' or `M-x highlight-regexp', these items will surprisingly appear in the global menu. This makes no sense, there are no such magic things happened on the menu bar. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 13 03:54:03 2022 Received: (at 52973) by debbugs.gnu.org; 13 Jan 2022 08:54:03 +0000 Received: from localhost ([127.0.0.1]:60101 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7vru-0006gm-SH for submit@debbugs.gnu.org; Thu, 13 Jan 2022 03:54:03 -0500 Received: from quimby.gnus.org ([95.216.78.240]:51810) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7vrt-0006gG-4p for 52973@debbugs.gnu.org; Thu, 13 Jan 2022 03:54:01 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=wA3v2ho4xC6fI9/5icclXQl4N2zgj37G/23kY/fz7Ps=; b=s3by+fypheTg8KxVWd9fMAfght 2SVwBsBq84+1hO65UTxda3sYvdZTSg+Fb4hNdLdeXqFRl5ZcyvQL1Jg5CkXOvIGWbWNTjj1Yb4Y7b Oj/qCeuWy9Eqc0V3MpfMlQ2oAhKg5lbGldJpJIdZdHHDcpzbUEZwERG83E9PAGH9aTrs=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n7vrj-0000go-Si; Thu, 13 Jan 2022 09:53:54 +0100 From: Lars Ingebrigtsen To: Juri Linkov Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <871r1cb2a2.fsf@gnus.org> <86tue8t4m1.fsf@mail.linkov.net> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAFVBMVEX8/PzY1dapoKN4 hY01KTCtJST///9qMBMqAAAAAWJLR0QGYWa4fQAAAAd0SU1FB+YBDQg0L90rPEQAAAGvSURBVDjL fdPJtqMgEADQAvvtCyV7IrpPwN4nsdy/Z8v//0oXg8PpmMYjgXMtxgoAqLNSw4ci/geyvcemil2l EAQW0DRy3YcZxGDpIUPAA3A3GE2GHtz4OcAl9gcy+sWNcICeu3+IjJgi4A6xGxhSaDAbyA36DFCg i92ZQZahCkiKH37z5F2ZvICma/yuois9+rTcAjxGHa4Ag6enCDP+ez7eugaFd28H5723t24cbifg 7/yOZxF+5BrfwDUNw5A3mC4hNRARKu+VghVyS9yghWr02wiqiHBgjdjhMIexd97kCbjGo9wgZQGK FkU8v2/gJZfT5Z9fxnqXADVpylvXD4Cl5m1dUx4QCSoXNcEXWQYXAyQRdOsN8g3FY/IxoGKoylDE xfm7Um07tx0D4A7ex3DOiYVBmh1sgj4lF+gD1BFiEv0cVhUBrSl5qjk1NrAWpUNBNLUGhtGv8Mp/ A94CPXm9E27pk4dv05i8rBfsEZec7byhWB2gz0ldCp7BkpJ+BdmHS4bnMh+hC2vExM8OkjboY7WB pt8Fxq89ouHUG+o5z2HE4lZ4K2smfiif9C9YXopqu1gN5wAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAy Mi0wMS0xM1QwODo1Mjo0NyswMDowMDUMz/0AAAAldEVYdGRhdGU6bW9kaWZ5ADIwMjItMDEtMTNU MDg6NTI6NDcrMDA6MDBEUXdBAAAAAElFTkSuQmCC X-Now-Playing: A Certain Ratio's _Loco Remezclada_: "Taxi Guy (Number Rework)" Date: Thu, 13 Jan 2022 09:53:48 +0100 In-Reply-To: <86tue8t4m1.fsf@mail.linkov.net> (Juri Linkov's message of "Thu, 13 Jan 2022 10:35:50 +0200") Message-ID: <87o84g6moz.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Juri Linkov writes: >> So it sounds to me like shell-script-mode (and derivatives and other >> shell-ish modes) should have the `man' bits of the context menu enabled >> by default? > > Nope. This `man' menu item might b [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: Eli Zaretskii , 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Juri Linkov writes: >> So it sounds to me like shell-script-mode (and derivatives and other >> shell-ish modes) should have the `man' bits of the context menu enabled >> by default? > > Nope. This `man' menu item might be useful everywhere, for example, > in this Gnus Article buffer, to look up the command cited above. It might be, and I think it's fine to let people customise that, if they want it. But it seems to me like that context menu should work by default in shell-script-modeish buffers -- I think pretty much everybody would like to have it there. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 13 03:55:00 2022 Received: (at 52973) by debbugs.gnu.org; 13 Jan 2022 08:55:00 +0000 Received: from localhost ([127.0.0.1]:60105 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7vsq-0006iG-5F for submit@debbugs.gnu.org; Thu, 13 Jan 2022 03:55:00 -0500 Received: from eggs.gnu.org ([209.51.188.92]:55386) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7vso-0006i2-QR for 52973@debbugs.gnu.org; Thu, 13 Jan 2022 03:54:59 -0500 Received: from [2001:470:142:3::e] (port=39892 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 1n7vsj-0002Oh-01; Thu, 13 Jan 2022 03:54:53 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=fGrLK88GlIHN5PQBvZ4+OhBdyGEthl25jj0dPDLVmKc=; b=V9C4lB/fDhuc QvdLdtaHedC+q91d4p6nHZpv3F8EPF86wfQfmWtMFhcplpXuMEn29mUOWs0b75cydCz+YCyLOuCT1 ekPMb/HxRzXsBILwGEx6AuBiES3ER/Nf9TIdDGfyOF9iUBYlYHt/7xSByq1CsDiFW6uypI/hOr9ha XkZVvoiLNVYNZ4ubjaHluGqkdJtZo4XQ5YRktY1xbKXP4VCOnoAoBeXRXcG6bd6+euywcXDii+ntQ 5nQ81bSus44p8T0DfcFT0SI0tRwMgNiKxb+e7SUFFq0BqBaZPQ4DbSvZknRlfOHlHaCkA+P26eRbz uk/zJaDvQQu2CTKXttVYPQ==; Received: from [87.69.77.57] (port=4294 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 1n7vsj-00055Y-36; Thu, 13 Jan 2022 03:54:53 -0500 Date: Thu, 13 Jan 2022 10:54:50 +0200 Message-Id: <835yqo3tid.fsf@gnu.org> From: Eli Zaretskii To: Lars Ingebrigtsen In-Reply-To: <871r1cb2a2.fsf@gnus.org> (message from Lars Ingebrigtsen on Thu, 13 Jan 2022 07:03:33 +0100) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <871r1cb2a2.fsf@gnus.org> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: philipk@posteo.net, 52973@debbugs.gnu.org, juri@linkov.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Lars Ingebrigtsen > Cc: Eli Zaretskii , philipk@posteo.net, 52973@debbugs.gnu.org > Date: Thu, 13 Jan 2022 07:03:33 +0100 > > Juri Linkov writes: > > > For example, today while editing a shell script I needed to consult the > > man page about the arguments of the command `zenity` used in the script. > > It takes too many keystrokes to type `M-x man RET zenity RET' > > or first to move point to this command, then to type `M-x man RET RET'. > > > > With the context menu, it's just one click: press the right mouse button > > on the command name, select the item "Open man page", and release the > > mouse button. > > So it sounds to me like shell-script-mode (and derivatives and other > shell-ish modes) should have the `man' bits of the context menu enabled > by default? The mode-based approach was what I proposed (and even thought it was already implemented), but Juri seems to reject it. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 13 04:20:22 2022 Received: (at 52973) by debbugs.gnu.org; 13 Jan 2022 09:20:22 +0000 Received: from localhost ([127.0.0.1]:60204 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7wHN-0003YS-Pr for submit@debbugs.gnu.org; Thu, 13 Jan 2022 04:20:22 -0500 Received: from relay1-d.mail.gandi.net ([217.70.183.193]:46399) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7wHL-0003Y9-Kb for 52973@debbugs.gnu.org; Thu, 13 Jan 2022 04:20:20 -0500 Received: (Authenticated sender: juri@linkov.net) by relay1-d.mail.gandi.net (Postfix) with ESMTPSA id 2547D24001F; Thu, 13 Jan 2022 09:20:10 +0000 (UTC) From: Juri Linkov To: Lars Ingebrigtsen Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <871r1cb2a2.fsf@gnus.org> <86tue8t4m1.fsf@mail.linkov.net> <87o84g6moz.fsf@gnus.org> Date: Thu, 13 Jan 2022 11:10:09 +0200 In-Reply-To: <87o84g6moz.fsf@gnus.org> (Lars Ingebrigtsen's message of "Thu, 13 Jan 2022 09:53:48 +0100") Message-ID: <86wnj4ro6e.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: Eli Zaretskii , 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >>> So it sounds to me like shell-script-mode (and derivatives and other >>> shell-ish modes) should have the `man' bits of the context menu enabled >>> by default? >> >> Nope. This `man' menu item might be useful everywhere, for example, >> in this Gnus Article buffer, to look up the command cited above. > > It might be, and I think it's fine to let people customise that, if they > want it. Agreed, everyone can customize the contents of their context menus. But Eli wants to reject new functions only because they are not added to the menu by default. > But it seems to me like that context menu should work by default in > shell-script-modeish buffers -- I think pretty much everybody would like > to have it there. Actually, the context menu already works by default in all shell related modes. The problem is that adding the man-menu item by default will load man.el in every shell-script buffer. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 13 04:23:49 2022 Received: (at 52973) by debbugs.gnu.org; 13 Jan 2022 09:23:49 +0000 Received: from localhost ([127.0.0.1]:60208 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7wKj-0003ep-9q for submit@debbugs.gnu.org; Thu, 13 Jan 2022 04:23:49 -0500 Received: from quimby.gnus.org ([95.216.78.240]:52224) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7wKh-0003eW-4k for 52973@debbugs.gnu.org; Thu, 13 Jan 2022 04:23:47 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=VI2YyRhoqqmXN6Zxh1J93I5Zmk5iizAE10WnNdTwLPg=; b=IDotZVceMqzdvWI40mMGjp/Bo5 5ZNcyUY+E58cjia6FZsfnAM/Qc0hdlJ/Ph3XwlkZJDcJ5J6yPDLzphuxRoK3KfohlIT0pARVsOO/d hCMbHn+Yi26L84k7ESIwrSHrM6HhOH9Aoj+ldS9bFxK7EM0Qhv1E9R7d87Jd1ufg0/70=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n7wKX-0000vr-P3; Thu, 13 Jan 2022 10:23:40 +0100 From: Lars Ingebrigtsen To: Juri Linkov Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <871r1cb2a2.fsf@gnus.org> <86tue8t4m1.fsf@mail.linkov.net> <87o84g6moz.fsf@gnus.org> <86wnj4ro6e.fsf@mail.linkov.net> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAG1BMVEWol5Gvop1GQEfW z9Di2dvq5Nzz7+fGv77///8ehiGEAAAAAWJLR0QIht6VegAAAAd0SU1FB+YBDQkSKfZUcGIAAAGw SURBVDjLlZMxT+QwEIWdlQ7a5BpaCAUtYnxJi5RxahC2+xWb1IBvlb/PG8frZJcViKc0zjdvxh6P lVpUVmVRVWUFlX/VWlVWBAURMRsnGkX+fgaX46kSKHZwGAS7wVs2XdscwGsgzQDWMHfcUb9yCHCW CZW6ZnxcAyRjZhQYfAaDgI6FjYMUXwEk10jkYcCenzPQSCUOCXe2f1ocFAH7GWQHJyCHGS0vYE7E DptFDeMXxxz/bo10zPhtBs7h6zd/XIzot1WVgEW89fVdsOgINdt1qk4/1HVNoiY74pLw/zokkBxY ttM7wM00hTWYRG9nAIlDwB0dp4rLD4BAabtqBR5VfcuHc5SbA0BXXuoLxgnRRDgimM/L/LGXxsQm zsDzsZpnlRyYnjF1Ei2Bo8igxwXNv6F/2aHlUgcbHUcgXupgiTAR3Qp4icWVSB59BGRkcNeUqhyA 8qiO0cREuBPQkY6HN3O+DNwUdBwgJ3NNtM8O0s649GgwJj6D0xf1MxiolUtsXZgotHsB8Tn7Hd54 od5UuKqmq+l/Bv2ZVN+DL8W3SC0g0KI2jlgC5/R7sPkEliLrwYPOoLsAAAAldEVYdGRhdGU6Y3Jl YXRlADIwMjItMDEtMTNUMDk6MTg6NDErMDA6MDAsscAJAAAAJXRFWHRkYXRlOm1vZGlmeQAyMDIy LTAxLTEzVDA5OjE4OjQxKzAwOjAwXex4tQAAAABJRU5ErkJggg== X-Now-Playing: Panoptique Electrical's _Decades (2001-2021)_: "To the Bridge" Date: Thu, 13 Jan 2022 10:23:36 +0100 In-Reply-To: <86wnj4ro6e.fsf@mail.linkov.net> (Juri Linkov's message of "Thu, 13 Jan 2022 11:10:09 +0200") Message-ID: <87mtk056qv.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Juri Linkov writes: > Agreed, everyone can customize the contents of their context menus. > But Eli wants to reject new functions only because they are not added > to the menu by default. Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: Eli Zaretskii , 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Juri Linkov writes: > Agreed, everyone can customize the contents of their context menus. > But Eli wants to reject new functions only because they are not added > to the menu by default. I think both Eli and I were somewhat confused as to which parts of the context menu stuff works out of the box and which needs customisation by the user. I don't think it'd be a good idea for all context menus to be added to all modes, but they should be added to some modes, at least. Probably. >> But it seems to me like that context menu should work by default in >> shell-script-modeish buffers -- I think pretty much everybody would like >> to have it there. > > Actually, the context menu already works by default in all shell related modes. > The problem is that adding the man-menu item by default will load man.el > in every shell-script buffer. Is it possible to postpone that loading until the user actually hits mouse-3? If so, I think it's fine for mouse-3 in these modes to load man.el. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 13 05:06:34 2022 Received: (at 52973) by debbugs.gnu.org; 13 Jan 2022 10:06:34 +0000 Received: from localhost ([127.0.0.1]:60278 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7x06-0004yS-Hl for submit@debbugs.gnu.org; Thu, 13 Jan 2022 05:06:34 -0500 Received: from eggs.gnu.org ([209.51.188.92]:41624) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7x04-0004yA-Oj for 52973@debbugs.gnu.org; Thu, 13 Jan 2022 05:06:33 -0500 Received: from [2001:470:142:3::e] (port=40986 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 1n7wzx-0005KR-Ml; Thu, 13 Jan 2022 05:06:26 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=W+jQE3pvuHlmSL3S9NLtxhbn7sTvO15UUWlDrs5j6EE=; b=irqsi627TVCm tJJZ8Hgiok9mIHiX9MF9/O/umOQcCGkNDpWwh4+2AtUIgeOUfcnLNE9ObcZbTM8Qg9rRbafc6bjYJ +M0LSKM6fEl+/3Q3IctX2VTVI3Il6FjHQ8QaIzp87Y40rKODn9hS9GntNPEZJ5nUfXOpWeaFGc7F8 C3j2IjS4Hzurg8P7J8krnnyWvOsWd3hVEFreAoMs6FI1PfQXPakQJQuWk2RV1DgPmoG3jWAYy4YT+ Gliy8A8Yjeycl2bvkdsrnw20t6ksaKloI9SiDbz2gWuyaGTjNmYGIITFKJqW2HtZYONL+9fJO8SZX 9mQ4m3bmF3M7ws/vFOVBuA==; Received: from [87.69.77.57] (port=4715 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 1n7wzw-0003pe-Kt; Thu, 13 Jan 2022 05:06:25 -0500 Date: Thu, 13 Jan 2022 12:06:21 +0200 Message-Id: <83wnj42bmq.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86bl0gt47q.fsf@mail.linkov.net> (message from Juri Linkov on Thu, 13 Jan 2022 10:39:25 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <838rvk6em4.fsf@gnu.org> <86tue8rfug.fsf@mail.linkov.net> <834k6869gl.fsf@gnu.org> <86k0f4rbcf.fsf@mail.linkov.net> <83y23k4tof.fsf@gnu.org> <86sftsohay.fsf@mail.linkov.net> <83sfts4rer.fsf@gnu.org> <86bl0gt47q.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: larsi@gnus.org, philipk@posteo.net, 52973@debbugs.gnu.org > Date: Thu, 13 Jan 2022 10:39:25 +0200 > > >> > When will that load these packages? When context-menu-mode is turned > >> > on, when the menu is actually popped up, or something else? > >> > >> When the menu is popped up the first time. > > > > Then why is that a problem? > > The problem is that irrelevant packages will be loaded by default. They aren't irrelevant: the user wants to use their context-menu entries. How is this different from when the user customizes some option that belongs to a package, or displays its documentation? > > We could alternatively only have these items when the corresponding > > package is loaded, but you rejected that possibility, AFAIU. > > This means there are no hi-lock/man items by default. The same will happen under your suggestion, won't it? > Then once the user used `M-x man' or `M-x highlight-regexp', > these items will surprisingly appear in the global menu. That's no more surprising that having, e.g., M-: (setq FOO- TAB complete on variables from the package FOO only after it's loaded. > This makes no sense, there are no such magic things happened > on the menu bar. I guess our notions of what makes sense are very different, because what doesn't make sense to you does for me, and vice versa. I'm not sure how to reconcile such opposite opinions. From debbugs-submit-bounces@debbugs.gnu.org Thu Jan 13 05:11:29 2022 Received: (at 52973) by debbugs.gnu.org; 13 Jan 2022 10:11:29 +0000 Received: from localhost ([127.0.0.1]:60283 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7x4r-00056g-7J for submit@debbugs.gnu.org; Thu, 13 Jan 2022 05:11:29 -0500 Received: from eggs.gnu.org ([209.51.188.92]:42526) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n7x4p-00056R-IC for 52973@debbugs.gnu.org; Thu, 13 Jan 2022 05:11:28 -0500 Received: from [2001:470:142:3::e] (port=41036 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 1n7x4j-000606-No; Thu, 13 Jan 2022 05:11:21 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=References:Subject:In-Reply-To:To:From:Date: mime-version; bh=FN+jdrN6Ka3l9W21YhVfgVZfhp+WFFR2/MZ3l4iPOBA=; b=MDRCk0wF41eE V16YtMHx6PRZN5L/9lwccQq7CJLxN6KPkNnvr5pqjo0+MK01MdU/H0rSmnn7pnLlAs9JiQh1nGuOZ AFC7b/F1xS8/dt9JFz0kdTBw6Gx7J59T7P/c86FzZ7SFz8MHSD4ulZZ6xuy6z2+ngPLbGbojLaxzc IKB8uoutTfsmcxWzkhdhmFRhlsXksXfLOi+JXnh0Qh/JEEvlXH1Oo4kP0QxK7kD2tkTsUeCJf8dzb /qmih80Htutv0XTXzTfxZ4Hfq6o54Uyon/6qX6WW+ULuyzRGvis3ek+fCp7jaHbUh736yM6lUxFrX UBf4ScAgONwLu1oaMsBxAg==; Received: from [87.69.77.57] (port=1042 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 1n7x4h-000345-NJ; Thu, 13 Jan 2022 05:11:21 -0500 Date: Thu, 13 Jan 2022 12:11:18 +0200 Message-Id: <83v8yo2beh.fsf@gnu.org> From: Eli Zaretskii To: Juri Linkov In-Reply-To: <86wnj4ro6e.fsf@mail.linkov.net> (message from Juri Linkov on Thu, 13 Jan 2022 11:10:09 +0200) Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <86pmp41vby.fsf@mail.linkov.net> <83czl47ghd.fsf@gnu.org> <86ee5kzjo2.fsf@mail.linkov.net> <83bl0o6oei.fsf@gnu.org> <87iluwkkyn.fsf@posteo.net> <83k0fc54bd.fsf@gnu.org> <86bl0m13o1.fsf@mail.linkov.net> <87czkxbhsb.fsf@gnus.org> <83sftt5c99.fsf@gnu.org> <86ilupt0d1.fsf@mail.linkov.net> <871r1cb2a2.fsf@gnus.org> <86tue8t4m1.fsf@mail.linkov.net> <87o84g6moz.fsf@gnus.org> <86wnj4ro6e.fsf@mail.linkov.net> X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: larsi@gnus.org, 52973@debbugs.gnu.org, philipk@posteo.net X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) > From: Juri Linkov > Cc: Eli Zaretskii , philipk@posteo.net, 52973@debbugs.gnu.org > Date: Thu, 13 Jan 2022 11:10:09 +0200 > > Eli wants to reject new functions only because they are not added to > the menu by default. No, because there doesn't seem to be _any_ way of having them added by default. IOW, AFIU your proposal would _force_ users to customize context menus before they can have these entries there. That doesn't make sense to me. From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 14 03:52:51 2022 Received: (at 52973) by debbugs.gnu.org; 14 Jan 2022 08:52:51 +0000 Received: from localhost ([127.0.0.1]:35529 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n8IKF-0003lK-CG for submit@debbugs.gnu.org; Fri, 14 Jan 2022 03:52:51 -0500 Received: from quimby.gnus.org ([95.216.78.240]:35132) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n8IKD-0003l1-Ca for 52973@debbugs.gnu.org; Fri, 14 Jan 2022 03:52:46 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=e+d9x94GcyV7hgJHhc7/6LbeRbjxKH2P2JHdlu5/pZ0=; b=e0tLcL90pnye1R+cdAI45dhW1k Pau9ArkS5gRYz+2NiarM4/peSYOus+M3meFyX7yDvYfc81cz0oWlSbX7BsWrTHQvCVzgv52MxQk1l IMmeyUA8ocIOf41icRx6FcGfymjMSOIzPCiKdV1og/lgSjRi6T4IqvynKwcC44+wo98E=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n8IK3-0001tK-TL; Fri, 14 Jan 2022 09:52:38 +0100 From: Lars Ingebrigtsen To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> X-Now-Playing: Noveller's _Arrow_: "Zeaxanthin" Date: Fri, 14 Jan 2022 09:52:33 +0100 In-Reply-To: <87o84tp69h.fsf@posteo.net> (Philip Kaludercic's message of "Mon, 03 Jan 2022 08:34:18 +0000") Message-ID: <87zgnypulq.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Philip Kaludercic writes: > I am attaching a few patches adding a few features for > context-menu-mode, that I mentioned and explained here: > https://ruzkuku.com/texts/emacs-mouse.html. > > Would it be OK to add these to Emac [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Philip Kaludercic writes: > I am attaching a few patches adding a few features for > context-menu-mode, that I mentioned and explained here: > https://ruzkuku.com/texts/emacs-mouse.html. > > Would it be OK to add these to Emacs itself? These all look OK to me, so I've applied the patches to Emacs 29, and expanded the `type' of `context-menu-functions' to list them, so that people can add them more easily. The discussion then went on to whether there should be an infrastructure to make modes add more context functions automatically -- and I think there should be, but it's unclear what that mechanism would look like. In any case, it seems beyond the scope of this bug report, so I'm closing it, and a new report should be opened for discussion about the more general issue (or perhaps discussed on emacs-devel). -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 14 03:53:03 2022 Received: (at control) by debbugs.gnu.org; 14 Jan 2022 08:53:03 +0000 Received: from localhost ([127.0.0.1]:35533 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n8IKU-0003mG-HS for submit@debbugs.gnu.org; Fri, 14 Jan 2022 03:53:03 -0500 Received: from quimby.gnus.org ([95.216.78.240]:35146) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n8IKJ-0003lI-PX for control@debbugs.gnu.org; Fri, 14 Jan 2022 03:53:01 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Subject:From:To:Message-Id:Date:Sender:Reply-To:Cc: MIME-Version:Content-Type:Content-Transfer-Encoding:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=m2fBTVUDkVXEk/TxGPIZ1SmDUg92wwjKTE+IgqY5NA4=; b=chOF+Hm/lFbUDrAv36RcNQjI6J U8438A2lSZbWb/G4geQse0klvtAfGDguxPkzejAmIjiswHZalwPHwatpL3A5qh3Shdkk9xq/oQ+n1 vA2vw3IskTe+ibHNLHdxQLrCCwEJMkmFPW91PPd96+kH43LNHTogjyeuqOx95q+ymrPY=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n8IKB-0001tR-RV for control@debbugs.gnu.org; Fri, 14 Jan 2022 09:52:46 +0100 Date: Fri, 14 Jan 2022 09:52:41 +0100 Message-Id: <87y23ipuli.fsf@gnus.org> To: control@debbugs.gnu.org From: Lars Ingebrigtsen Subject: control message for bug #52973 X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: close 52973 29.1 quit Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: control X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) close 52973 29.1 quit From debbugs-submit-bounces@debbugs.gnu.org Fri Jan 14 09:33:31 2022 Received: (at 52973) by debbugs.gnu.org; 14 Jan 2022 14:33:31 +0000 Received: from localhost ([127.0.0.1]:35986 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n8Ndz-00087a-35 for submit@debbugs.gnu.org; Fri, 14 Jan 2022 09:33:31 -0500 Received: from mout01.posteo.de ([185.67.36.65]:51433) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n8Ndw-00087F-LI for 52973@debbugs.gnu.org; Fri, 14 Jan 2022 09:33:30 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id 90D8A24002E for <52973@debbugs.gnu.org>; Fri, 14 Jan 2022 15:33:22 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1642170802; bh=GUrp6EIB9k2Su6m8bzC2VwoJ4hFdbGjPK43rMXH+IZw=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=Odb0kwkWox/kZiSohkxL9CHgDgZItnzOXGz7iv1SgZjAlVLpKDO+Tve8ULv7dr5aE +zoyF4ZgTYmtQbMHcrK1MdmT9yNg1wx50r1Z8QSsq2SpIOGvpbrrQ+uJ7/pT8JoPZ5 wJYshxNHE6RwIn98KywNa8FQ31u1m/HlxCyCRGLruuPL0xMfykoz/dux9qAGzJf/TU usfCX4/76Tb+hmnhB/3uvbda8i5B1RLklbwYZ+chQZXDvJbyo9N+7TAl1BJhcfAgwT QNPkKMHV4g8n7nJwwpJrm+eEx5CuxvjUqV5LqwUDrDjIemSlm9aAPABJHtoVRTTGVo Co0G8IAz/eegw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4Jb3gj5Bz5z9rxk; Fri, 14 Jan 2022 15:33:21 +0100 (CET) From: Philip Kaludercic To: Lars Ingebrigtsen Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <87zgnypulq.fsf@gnus.org> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Fri, 14 Jan 2022 14:33:18 +0000 In-Reply-To: <87zgnypulq.fsf@gnus.org> (Lars Ingebrigtsen's message of "Fri, 14 Jan 2022 09:52:33 +0100") Message-ID: <87pmou8k0h.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Lars Ingebrigtsen writes: > Philip Kaludercic writes: > >> I am attaching a few patches adding a few features for >> context-menu-mode, that I mentioned and explained here: >> https://ruzkuku.com/texts/emacs-mouse.html. >> >> Would it be OK to add these to Emacs itself? > > These all look OK to me, so I've applied the patches to Emacs 29, and > expanded the `type' of `context-menu-functions' to list them, so that > people can add them more easily. I think that "Add command to invoke a search engine" should be reverted, because we replaced that with a few commands in webjump, that did not rely on eww. > The discussion then went on to whether there should be an infrastructure > to make modes add more context functions automatically -- and I think > there should be, but it's unclear what that mechanism would look like. > In any case, it seems beyond the scope of this bug report, so I'm > closing it, and a new report should be opened for discussion about the > more general issue (or perhaps discussed on emacs-devel). -- Philip Kaludercic From debbugs-submit-bounces@debbugs.gnu.org Sat Jan 15 03:07:38 2022 Received: (at 52973) by debbugs.gnu.org; 15 Jan 2022 08:07:38 +0000 Received: from localhost ([127.0.0.1]:38881 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n8e66-0005Bl-1k for submit@debbugs.gnu.org; Sat, 15 Jan 2022 03:07:38 -0500 Received: from quimby.gnus.org ([95.216.78.240]:46272) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1n8e64-0005BV-GW for 52973@debbugs.gnu.org; Sat, 15 Jan 2022 03:07:37 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=XOO9bs8DNX1OXbA/kyR2rT0iOFZYZqWHWDHsv9yxfYw=; b=q1qDwXpj3yVXGtnALArCtTuB6y xZwIjte5bN5cwEa4SvEp6eQVvk43flau1ZLD7DpHnY5rRpwcYaA8d7z7/gfkOucLukqF2DX4bMh2h 2bUFOg5J5syYxVSHRy+BLwHWS3IU3fckQUh2Sz0xuKdZbj2gV9REF3Q0oqUVoQI0kT80=; Received: from [84.212.220.105] (helo=xo) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1n8e5v-0002Rk-Lp; Sat, 15 Jan 2022 09:07:30 +0100 From: Lars Ingebrigtsen To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <87zgnypulq.fsf@gnus.org> <87pmou8k0h.fsf@posteo.net> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAElBMVEX16t2UXz5VNytR MSfWlGD////m+Z8KAAAAAWJLR0QF+G/pxwAAAAd0SU1FB+YBDwc6ESOcg9cAAAGmSURBVDjLdZTb ldwgEEQ1Pg7A1eoEGpyAwAGAhvxjcjWPmdGulg8diUv1G23bT+sRguH72rZf2VeMKaYc3qsM8LED +FPbVOScwuf6ACRk8QZwaQ1ul2e+AGjb55ErELTnPcgh3gKY5Xvwd7v1kXDcOz+qafcRXyB0YPWo h3iqF4BoNSNhZf5YdtqJlhureAEhVQep+S4/3wptDlAYVaL3V1SGilMJMPr2AiogKCi9JmkByxCK tLTy7ImsssdsvQn6e3v2jrxAMqNX4+cV0Kr6EGjZnqm3/wKApmVnGqvnKfY6AVFRxyzIBdRkkBA4 eXPgOjiosA7GiP1xMJwwkwMCizw5Qc/J9jmr4l2IHQTXJBnVdN8cbwd8cw1m/aO3bZjqLcj/9nDA EHaXTuddcpzpAKpEl8aloIS7LHCtonsP95H6TZNgWhWtMZ/KnUIQ1r2rqmcvGQb4uJKl+tPbSYCv QOycpl62MEzRk4N1zUU8KEwnBKwpmydrR8RP1m7KeNZz5hWUKXcwNlkOsG/vMPxfMoaadrSId9zC jIqmAlXVFctW+fGv9B9uV6ECSnYrMwAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMi0wMS0xNVQwNzo1 ODoxNyswMDowMB4v7YEAAAAldEVYdGRhdGU6bW9kaWZ5ADIwMjItMDEtMTVUMDc6NTg6MTcrMDA6 MDBvclU9AAAAAElFTkSuQmCC X-Now-Playing: Joni Mitchell's _Archives: The Early Years (3)_: "Winter Lady (Live at The 2nd Fret, Philadelphia, PA, 3-17-1967)" Date: Sat, 15 Jan 2022 09:07:26 +0100 In-Reply-To: <87pmou8k0h.fsf@posteo.net> (Philip Kaludercic's message of "Fri, 14 Jan 2022 14:33:18 +0000") Message-ID: <87r199mngh.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Philip Kaludercic writes: > I think that "Add command to invoke a search engine" should be reverted, > because we replaced that with a few commands in webjump, that did not > rely on eww. Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Philip Kaludercic writes: > I think that "Add command to invoke a search engine" should be reverted, > because we replaced that with a few commands in webjump, that did not > rely on eww. Right; reverted now. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Sat Jan 22 14:39:41 2022 Received: (at 52973) by debbugs.gnu.org; 22 Jan 2022 19:39:41 +0000 Received: from localhost ([127.0.0.1]:37977 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBMEe-0004a6-QO for submit@debbugs.gnu.org; Sat, 22 Jan 2022 14:39:41 -0500 Received: from mout01.posteo.de ([185.67.36.65]:45543) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBMEc-0004Zr-2v for 52973@debbugs.gnu.org; Sat, 22 Jan 2022 14:39:38 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id 674C6240026 for <52973@debbugs.gnu.org>; Sat, 22 Jan 2022 20:39:31 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1642880371; bh=ksM5zUNBLInrHBgn5+DvW873ieh9OJ0EJVh2aYGevUg=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=UXbxgD9MMNA6GNKvJQdWH+PP5Y0+7egk8uObndI4wOVHiguBy6kDsIf6qbEb4r/Kx F0rUA1F2ujMySCuFKj3ACRx6hlFJ/PDsIDq3UXzT1kxf1VzLMu5oLZjKV/kDjzxThu gNLkB5gUxt+g0iZoNJTBL90WewdHh2GoS87vr2l/7yepLx1zQQEqJAl9iUuq9/bznX ln7rxdUnWfdc52FYmbxOrNL+a5qT+46pBmm5UFw9CqdbAbDNUbf2b6zPt7VFE2sJSd lywNfGCR9qnTa94SxfAFcLhWq4WuesTGiJ1iQOT2+11+sYe4PP5NgOl5Ru5bdg4uNq /iIt2PlRzDDDw== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4Jh65G4KL7z9rxD; Sat, 22 Jan 2022 20:39:30 +0100 (CET) From: Philip Kaludercic To: Juri Linkov Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Sat, 22 Jan 2022 19:39:29 +0000 In-Reply-To: <87pmp4lmfz.fsf@posteo.net> (Philip Kaludercic's message of "Thu, 06 Jan 2022 19:59:44 +0100") Message-ID: <87bl038sr2.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) I just wanted to apply this patch, then I noticed that this would also change the default browser for EWW from html.duckduckgo.com to duckduckgo.com. The effect is that every search query it redirected to the JS-free version. Any ideas how to fix this? Should I just remove the EWW integration, or change the DuckDuckGo URL to the HTML-version? Philip Kaludercic writes: > Juri Linkov writes: > >>>> Maybe then a better place to add new functions would be in >>>> lisp/net/webjump.el. webjump is a package created exactly >>>> for this purpose. Then new functions could share the same >>>> prefix webjump-. >>> >>> I didn't know about webjump, thank you for the hint. My only fear is >>> that the prefix would make the functionality harder to discover. >> >> The fact that its name starts with the word "web" improves >> discoverability. > > How is this? > > From 2a32d1f7df0b8dfdceb3f63476df150d55215b5d Mon Sep 17 00:00:00 2001 > From: Philip Kaludercic > Date: Tue, 4 Jan 2022 20:36:32 +0100 > Subject: [PATCH] Add search engine functionality > > * lisp/net/eww.el (eww-search-prefix): Deprecate user option > (eww): Use webjump-search-query > * lisp/net/webjump.el (webjump-default-search-engine): Add user option > (webjump-choose-search-engine): Add function > (webjump-search-query): Add function > (webjump-search): Add autoloaded command > (webjump-search-at-point): Add autoloaded command > (webjump-search-at-mouse): Add command > (webjump-search-context-menu): Add function for context-menu support. > --- > lisp/misc.el | 1 + > lisp/net/eww.el | 10 +++--- > lisp/net/webjump.el | 80 ++++++++++++++++++++++++++++++++++++++++++++- > 3 files changed, 86 insertions(+), 5 deletions(-) > > diff --git a/lisp/misc.el b/lisp/misc.el > index 39ec9497d7..6e5aede789 100644 > --- a/lisp/misc.el > +++ b/lisp/misc.el > @@ -27,6 +27,7 @@ > > (eval-when-compile > (require 'tabulated-list)) > +(require 'cl-lib) > > ;;;###autoload > (defun copy-from-above-command (&optional arg) > diff --git a/lisp/net/eww.el b/lisp/net/eww.el > index 8930eb427d..2ef6b35100 100644 > --- a/lisp/net/eww.el > +++ b/lisp/net/eww.el > @@ -33,6 +33,7 @@ > (require 'url) > (require 'url-queue) > (require 'xdg) > +(require 'webjump) > (eval-when-compile (require 'subr-x)) > > (defgroup eww nil > @@ -55,6 +56,9 @@ eww-search-prefix > :version "24.4" > :group 'eww > :type 'string) > +(make-obsolete-variable 'eww-search-prefix > + "webjump-default-search-engine" > + "29.1") > > (defcustom eww-use-browse-url "\\`mailto:" > "EWW will use `browse-url' when following links that match this regexp. > @@ -355,7 +359,7 @@ eww-browse > (defun eww (url &optional new-buffer buffer) > "Fetch URL and render the page. > If the input doesn't look like an URL or a domain name, the > -word(s) will be searched for via `eww-search-prefix'. > +word(s) will be searched for via `webjump-search'. > > If NEW-BUFFER is non-nil (interactively, the prefix arg), use a > new buffer instead of reusing the default EWW buffer. > @@ -464,9 +468,7 @@ eww--dwim-expand-url > ;; Some sites do not redirect final / > (when (string= (url-filename (url-generic-parse-url url)) "") > (setq url (concat url "/")))) > - (setq url (concat eww-search-prefix > - (mapconcat > - #'url-hexify-string (split-string url) "+")))))) > + (setq url (webjump-search-query url))))) > url) > > (defun eww--preprocess-html (start end) > diff --git a/lisp/net/webjump.el b/lisp/net/webjump.el > index 7547f92d7d..17c9312c54 100644 > --- a/lisp/net/webjump.el > +++ b/lisp/net/webjump.el > @@ -370,7 +370,85 @@ webjump-url-fix-trailing-slash > (concat url "/") > url)) > > -;;----------------------------------------------------------------------------- > + > +;;; Search engine functionality > + > +(defcustom webjump-default-search-engine "DuckDuckGo" > + "Search engine to use for `webjump-search' and related commands. > +The string should denote an entry in `webjump-sites', with a > +`simple-query' entry." > + :type 'string) > + > +(defun webjump-choose-search-engine () > + "Choose a search engine to use from `webjump-sites'. > +If no prefix argument was used, the function will return the > +entry for `webjump-default-search-engine'." > + (assoc-string > + (if current-prefix-arg > + (completing-read > + (format-prompt "Use search engine" > + webjump-default-search-engine) > + webjump-sites > + (lambda (ent) > + (and (vectorp (cdr ent)) > + (eq (aref (cdr ent) 0) 'simple-query))) > + t nil nil webjump-default-search-engine) > + webjump-default-search-engine) > + webjump-sites t)) > + > +(defun webjump-search-query (string) > + "Generate an URL query to search for STRING." > + (let ((engine (cdr (webjump-choose-search-engine)))) > + (webjump-url-fix > + (concat (aref engine 2) > + (webjump-url-encode string) > + (aref engine 3))))) > + > +;;;###autoload > +(defun webjump-search (string) > + "Search for STRING using a search engine. > +If the optional argument ENGINE may be used to override > +`webjump-default-search-engine'." > + (interactive (list (if (use-region-p) > + (buffer-substring (region-beginning) (region-end)) > + (read-string "Search: ")))) > + (browse-url (webjump-search-query string))) > + > +;;;###autoload > +(defun webjump-search-at-point () > + "Search for symbol at point online. > +See `webjump-search' for more details." > + (interactive) > + (let ((query (thing-at-point 'symbol))) > + (unless query > + (user-error "Nothing to search for")) > + (webjump-search query))) > + > +;;;###autoload > +(defun webjump-search-at-mouse (click) > + "Query an online search engine at CLICK. > +If a region is active, the entire region will be sent, otherwise > +the symbol at point will be used. See `webjump-search' for more > +details." > + (interactive "e") > + (let ((query (if (use-region-p) > + (buffer-substring (region-beginning) > + (region-end)) > + (thing-at-mouse click 'symbol)))) > + (unless (or query (string-match-p "\\`[[:space:]\n]*\\'" query)) > + (user-error "Nothing to search for")) > + (webjump-search query))) > + > +;;;###autoload > +(defun webjump-search-context-menu (menu click) > + "Populate MENU with command to search online at CLICK." > + (save-excursion > + (mouse-set-point click) > + (define-key-after menu [webjump-search-separator] menu-bar-separator) > + (define-key-after menu [webjump-search-at-mouse] > + '(menu-item "Online search" webjump-search-at-mouse > + :help "Search for region or word online"))) > + menu) > > (provide 'webjump) > > -- > 2.34.0 > > > While I agree that web helps, I think a search-online defalias for > webjump-search would be appreciated when looking for commands via > apropos. -- Philip Kaludercic From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 23 04:43:50 2022 Received: (at 52973) by debbugs.gnu.org; 23 Jan 2022 09:43:50 +0000 Received: from localhost ([127.0.0.1]:38550 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBZPZ-00033R-S8 for submit@debbugs.gnu.org; Sun, 23 Jan 2022 04:43:50 -0500 Received: from relay3-d.mail.gandi.net ([217.70.183.195]:33007) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBZPY-00033C-4n for 52973@debbugs.gnu.org; Sun, 23 Jan 2022 04:43:48 -0500 Received: (Authenticated sender: juri@linkov.net) by mail.gandi.net (Postfix) with ESMTPSA id 1779460003; Sun, 23 Jan 2022 09:43:40 +0000 (UTC) From: Juri Linkov To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <87bl038sr2.fsf@posteo.net> Date: Sun, 23 Jan 2022 11:08:39 +0200 In-Reply-To: <87bl038sr2.fsf@posteo.net> (Philip Kaludercic's message of "Sat, 22 Jan 2022 19:39:29 +0000") Message-ID: <86bl02x04g.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) > I just wanted to apply this patch, then I noticed that this would also > change the default browser for EWW from html.duckduckgo.com to > duckduckgo.com. The effect is that every search query it redirected to > the JS-free version. Any ideas how to fix this? Should I just remove > the EWW integration, or change the DuckDuckGo URL to the HTML-version? Another option would be to add a new webjump engine for HTML DuckDuckGo, and make it default, then it could be used in eww. Or change the existing DuckDuckGo to HTML, then also add JS DuckDuckGo for users who prefer JS-based DuckDuckGo. From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 23 07:09:58 2022 Received: (at 52973) by debbugs.gnu.org; 23 Jan 2022 12:09:58 +0000 Received: from localhost ([127.0.0.1]:38682 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBbh0-00071K-CJ for submit@debbugs.gnu.org; Sun, 23 Jan 2022 07:09:58 -0500 Received: from mout01.posteo.de ([185.67.36.65]:34971) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBbgy-000715-6e for 52973@debbugs.gnu.org; Sun, 23 Jan 2022 07:09:57 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout01.posteo.de (Postfix) with ESMTPS id C8004240027 for <52973@debbugs.gnu.org>; Sun, 23 Jan 2022 13:09:49 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1642939789; bh=xIMQmB9ITod7G46LnRVRTFA8QL/lR7Av38YhrKnS7Lk=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=PoH1eQTgs/hzzOXznXweQ3ZTxKJLgWjmURXh36vwZ2WAFDePaR3bZ0PEZTjIn0yi3 tAuJ0E5fhQQil5/OnuStjdIZG+8n8VFFJnp004pPfZCn7asQT41T7QbRRjmHFWdQ3K WfTHHMLLYJ1CB3IhaQAL5GKBi1/saTgqdfSan6rDOphmn/A/NMe2sncPuLIVY2BF77 R9lIQMqJlj8jVh78BF8JT6RkT6iy/JOiqDroKQnZQyJoQHbDSt6zQAbm/MkAB4I1Sy 3pgFTnLhxkRnE9eLUZtMwAjzpW7vT68RiOOHs2+KrthDj3G+xkgZv1AKau9WCWxBFK Lzfrpvl7FQ9gg== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JhX3x0xKWz6tnr; Sun, 23 Jan 2022 13:09:48 +0100 (CET) From: Philip Kaludercic To: Juri Linkov Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <87bl038sr2.fsf@posteo.net> <86bl02x04g.fsf@mail.linkov.net> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Sun, 23 Jan 2022 12:09:48 +0000 In-Reply-To: <86bl02x04g.fsf@mail.linkov.net> (Juri Linkov's message of "Sun, 23 Jan 2022 11:08:39 +0200") Message-ID: <87iluay7oz.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Juri Linkov writes: >> I just wanted to apply this patch, then I noticed that this would >> also change the default browser for EWW from html.duckduckgo.com to >> duckduckgo.com. The effect is that every search query it redirected >> to the JS-free version. Any ideas how to fix this? Should I just >> remove the EWW integration, or change the DuckDuckGo URL to the >> HTML-version? > > Another option would be to add a new webjump engine for HTML > DuckDuckGo, and make it default, then it could be used in eww. Or > change the existing DuckDuckGo to HTML, then also add JS DuckDuckGo > for users who prefer JS-based DuckDuckGo. As the "default search engine" is a new option, changing the default to HTML DuckDuckGo should be fine. I personally use it as by default search engine, but don't know how popular or unpopular it is. Adding the default DDG (and perhaps the lite version as well) as alternatives seems sensible too. -- Philip Kaludercic From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 23 07:13:52 2022 Received: (at 52973) by debbugs.gnu.org; 23 Jan 2022 12:13:52 +0000 Received: from localhost ([127.0.0.1]:38686 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBbkl-00077C-Vx for submit@debbugs.gnu.org; Sun, 23 Jan 2022 07:13:52 -0500 Received: from quimby.gnus.org ([95.216.78.240]:37304) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBbkk-00076x-2S for 52973@debbugs.gnu.org; Sun, 23 Jan 2022 07:13:51 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=Y18bTTqegZs2Jz05/HNXfKnU9bkGs56t31LFMmdgiUE=; b=YpYCE8FmPwdwJIr1aRjSLdwNLO ksRx7tGIFJm2F83zLALKNKR+fe/Hs/KAQRn/iTHzVwqUDHJs/x93wWU/BojTHxbuzIXjyrRvfnKth ekL+aBU1hMzdJhqY0H/4h7cbxf5znLtgmglWeM/7CW8gNFmxqnLLotdbJwoTHPKZ/Ju8=; Received: from [84.212.220.105] (helo=giant) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nBbka-0004mg-IZ; Sun, 23 Jan 2022 13:13:43 +0100 From: Lars Ingebrigtsen To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <87bl038sr2.fsf@posteo.net> <86bl02x04g.fsf@mail.linkov.net> <87iluay7oz.fsf@posteo.net> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAElBMVEWwjWtxQT+fUEzR saT49O3///+dfHtVAAAAAWJLR0QF+G/pxwAAAAd0SU1FB+YBFwwNAEDTk4AAAAGRSURBVDjLfZIB YsMgCEUVcwDjLqCYAzjJAbra+59pH026dHWjasUX+BFizNzs5Cz+CcIUUB8TYEeyWao/xKPxhjtI 66t1/wrC9YmowNvoiWMki10ICe4AkZA4es82Ugwp2XQCNjjpgA2nlNgPDZ+sPwAZZmtPECydIJg4 wKnBAIGtD0j1AsyIQApP11Ts8VZhTWHlAHUOIwJ30xbQccFQjwtCT2tUMB3DPghhAK4smOIUiC7L Ud3FCKzgZ5w0pw6eEgVwdjhiFvzvpWHfToABkR5cMOBCQ4aw6TtXXjpYZq0dYuUdPNTktIfsD9GT rwEu1nZxUyCtIWoCbjidgdaPO3gK672xtNykA+JXs8wr728g6Vx5+TKNcl3yPW+u1lxdZKoun2B3 krdM91wkW1vNAJxZsuScuWZUhy6Aar4BUN3QSbpXOUCstx4BwAD1AA/Sjg+Qn6C/LsSlg09Vq/Ve tg4YX+LWXI5cI0sspOIKbOKohS7jpqGvPZUxWjpFPwXYf1VXK4mOYH3vx2H/AJnb5zdoRIS3tuUh TAAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMi0wMS0yM1QxMjoxMjo1OSswMDowMO2KG2gAAAAldEVY dGRhdGU6bW9kaWZ5ADIwMjItMDEtMjNUMTI6MTI6NTkrMDA6MDCc16PUAAAAAElFTkSuQmCC X-Now-Playing: Scritti Politti's _Cupid & Psyche 85_: "Hypnotyze" Date: Sun, 23 Jan 2022 13:13:38 +0100 In-Reply-To: <87iluay7oz.fsf@posteo.net> (Philip Kaludercic's message of "Sun, 23 Jan 2022 12:09:48 +0000") Message-ID: <87tuduabv1.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Philip Kaludercic writes: > As the "default search engine" is a new option, changing the default to > HTML DuckDuckGo should be fine. I personally use it as by default > search engine, but don't know how popular or unpopular i [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org, Juri Linkov X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Philip Kaludercic writes: > As the "default search engine" is a new option, changing the default to > HTML DuckDuckGo should be fine. I personally use it as by default > search engine, but don't know how popular or unpopular it is. > > Adding the default DDG (and perhaps the lite version as well) as > alternatives seems sensible too. The default DDG version has more features than the HTML one, so I think that's what most people would prefer... -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 23 11:31:12 2022 Received: (at 52973) by debbugs.gnu.org; 23 Jan 2022 16:31:12 +0000 Received: from localhost ([127.0.0.1]:40992 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBfln-000397-RN for submit@debbugs.gnu.org; Sun, 23 Jan 2022 11:31:12 -0500 Received: from mout02.posteo.de ([185.67.36.66]:45771) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBflm-00031L-HS for 52973@debbugs.gnu.org; Sun, 23 Jan 2022 11:31:11 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout02.posteo.de (Postfix) with ESMTPS id 00B97240107 for <52973@debbugs.gnu.org>; Sun, 23 Jan 2022 17:31:03 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1642955464; bh=xipDpooeYPhjD8hlpTZP2ho7WSdpdX58RkwvRFJ3elI=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=ZS3+oBH4R0AZWLwP78mvsty14vhzHIwJShogU2NWmsFKN0HBK5L56d5/jfW4E6Wz3 XOvonRCRcMxdy/RQA3g6QV4tQktewjnilNe4sUYw6FPBN5nIvhXjcupRCI5I/vbfpk s+1AUo47zHwLXi7OyKyeFy1O+ZwMlq1y+TXZG0flazas1+BUKGj/cIOMgbZeqwzw5I 1AiL/+eoLOWJVQM4glQjHdjunt9v8SqE+JDW2vj//tj6MGuxcoOu2WND8CNfJSzm4v 7PWkEWlrzrCkotarxRRc7kOy8AKqxEsnFJ8zwaWJfGHe4oRuU6mkUqYetaxR1pQG06 UVt3nGjrCxhYQ== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JhdsL6LkSz9rwn; Sun, 23 Jan 2022 17:31:02 +0100 (CET) From: Philip Kaludercic To: Lars Ingebrigtsen Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <87bl038sr2.fsf@posteo.net> <86bl02x04g.fsf@mail.linkov.net> <87iluay7oz.fsf@posteo.net> <87tuduabv1.fsf@gnus.org> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Sun, 23 Jan 2022 16:30:59 +0000 In-Reply-To: <87tuduabv1.fsf@gnus.org> (Lars Ingebrigtsen's message of "Sun, 23 Jan 2022 13:13:38 +0100") Message-ID: <878rv6ifcs.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org, Juri Linkov X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Lars Ingebrigtsen writes: > Philip Kaludercic writes: > >> As the "default search engine" is a new option, changing the default to >> HTML DuckDuckGo should be fine. I personally use it as by default >> search engine, but don't know how popular or unpopular it is. >> >> Adding the default DDG (and perhaps the lite version as well) as >> alternatives seems sensible too. > > The default DDG version has more features than the HTML one, so I think > that's what most people would prefer... Maybe one should not only configure a general search engine, but a search engine depending on a context. Sometimes you might want to use a specialised search engine (e.g. hoogle when working on Haskell), and that should be automatically detected as the default. In the same way, if EWW would be using a special "context" to designate that it wants a JS-free search engine (HTML DuckDuckGo). -- Philip Kaludercic From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 23 13:24:40 2022 Received: (at 52973) by debbugs.gnu.org; 23 Jan 2022 18:24:40 +0000 Received: from localhost ([127.0.0.1]:41215 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBhXc-0003yF-9a for submit@debbugs.gnu.org; Sun, 23 Jan 2022 13:24:40 -0500 Received: from relay9-d.mail.gandi.net ([217.70.183.199]:35383) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBhXa-0003xz-P5 for 52973@debbugs.gnu.org; Sun, 23 Jan 2022 13:24:39 -0500 Received: (Authenticated sender: juri@linkov.net) by mail.gandi.net (Postfix) with ESMTPSA id 9F43AFF803; Sun, 23 Jan 2022 18:24:31 +0000 (UTC) From: Juri Linkov To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <87bl038sr2.fsf@posteo.net> <86bl02x04g.fsf@mail.linkov.net> <87iluay7oz.fsf@posteo.net> <87tuduabv1.fsf@gnus.org> <878rv6ifcs.fsf@posteo.net> Date: Sun, 23 Jan 2022 20:06:14 +0200 In-Reply-To: <878rv6ifcs.fsf@posteo.net> (Philip Kaludercic's message of "Sun, 23 Jan 2022 16:30:59 +0000") Message-ID: <86fspeuy21.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: Lars Ingebrigtsen , 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >>> As the "default search engine" is a new option, changing the default to >>> HTML DuckDuckGo should be fine. I personally use it as by default >>> search engine, but don't know how popular or unpopular it is. >>> >>> Adding the default DDG (and perhaps the lite version as well) as >>> alternatives seems sensible too. >> >> The default DDG version has more features than the HTML one, so I think >> that's what most people would prefer... > > Maybe one should not only configure a general search engine, but a > search engine depending on a context. Sometimes you might want to use a > specialised search engine (e.g. hoogle when working on Haskell), and > that should be automatically detected as the default. In the same way, > if EWW would be using a special "context" to designate that it wants a > JS-free search engine (HTML DuckDuckGo). This makes sense as well with e.g. webjump-context-search-engine. From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 23 14:49:22 2022 Received: (at 52973) by debbugs.gnu.org; 23 Jan 2022 19:49:22 +0000 Received: from localhost ([127.0.0.1]:41321 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBira-0006HK-CG for submit@debbugs.gnu.org; Sun, 23 Jan 2022 14:49:22 -0500 Received: from mout02.posteo.de ([185.67.36.66]:58011) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBirY-0006H5-S6 for 52973@debbugs.gnu.org; Sun, 23 Jan 2022 14:49:21 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout02.posteo.de (Postfix) with ESMTPS id A640B240101 for <52973@debbugs.gnu.org>; Sun, 23 Jan 2022 20:49:14 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1642967354; bh=HekSYPCiurX5wTRBS1dbMJTjNXACmCEgY8VHhPmbOA4=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=hDbce4i9u6nulZ8LrGfHYnYX0o6N1gN+UmsTh/zx76rsXBzAocvPQWrhPYZCgFMCe oN/4nIknO9VHL3yOYi7At0rsF2MFWQcMCfU+d0IRvBP57zIxpDQdqlN520J3asghAX lHuFTSr8v2zgmgsQhM9KjCKKjoCqHoo/c70hj3ld+JaJZ99zZPidodmy4/9PCdEIyG aHgsMAn5TS6FiYu2jDJUpZLlSnSkRC49bR4c/iZer3VHnLzJi9j3mJtbsqS8NpSpx7 tE71lVM7DXbLgz5v3y3bk6SFOklPRMFSo0TeBYcx+jA7bmb+FOVjwz6WdOh6q2yEwT f4Pks0e+VPSpA== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4JhkG13n3Cz6tmB; Sun, 23 Jan 2022 20:49:13 +0100 (CET) From: Philip Kaludercic To: Juri Linkov Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <87bl038sr2.fsf@posteo.net> <86bl02x04g.fsf@mail.linkov.net> <87iluay7oz.fsf@posteo.net> <87tuduabv1.fsf@gnus.org> <878rv6ifcs.fsf@posteo.net> <86fspeuy21.fsf@mail.linkov.net> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Sun, 23 Jan 2022 19:49:12 +0000 In-Reply-To: <86fspeuy21.fsf@mail.linkov.net> (Juri Linkov's message of "Sun, 23 Jan 2022 20:06:14 +0200") Message-ID: <87k0eqfd1j.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: Lars Ingebrigtsen , 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Juri Linkov writes: >>>> As the "default search engine" is a new option, changing the default to >>>> HTML DuckDuckGo should be fine. I personally use it as by default >>>> search engine, but don't know how popular or unpopular it is. >>>> >>>> Adding the default DDG (and perhaps the lite version as well) as >>>> alternatives seems sensible too. >>> >>> The default DDG version has more features than the HTML one, so I think >>> that's what most people would prefer... >> >> Maybe one should not only configure a general search engine, but a >> search engine depending on a context. Sometimes you might want to use a >> specialised search engine (e.g. hoogle when working on Haskell), and >> that should be automatically detected as the default. In the same way, >> if EWW would be using a special "context" to designate that it wants a >> JS-free search engine (HTML DuckDuckGo). > > This makes sense as well with e.g. webjump-context-search-engine. I am not sure what you mean by webjump-context-search-engine. Should it be a separate command or a user option? -- Philip Kaludercic From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 23 15:06:08 2022 Received: (at 52973) by debbugs.gnu.org; 23 Jan 2022 20:06:08 +0000 Received: from localhost ([127.0.0.1]:41326 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBj7n-0006ga-SB for submit@debbugs.gnu.org; Sun, 23 Jan 2022 15:06:08 -0500 Received: from relay10.mail.gandi.net ([217.70.178.230]:44301) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBj7l-0006g1-E2 for 52973@debbugs.gnu.org; Sun, 23 Jan 2022 15:06:06 -0500 Received: (Authenticated sender: juri@linkov.net) by mail.gandi.net (Postfix) with ESMTPSA id E82C0240009; Sun, 23 Jan 2022 20:05:58 +0000 (UTC) From: Juri Linkov To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands Organization: LINKOV.NET References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <87bl038sr2.fsf@posteo.net> <86bl02x04g.fsf@mail.linkov.net> <87iluay7oz.fsf@posteo.net> <87tuduabv1.fsf@gnus.org> <878rv6ifcs.fsf@posteo.net> <86fspeuy21.fsf@mail.linkov.net> <87k0eqfd1j.fsf@posteo.net> Date: Sun, 23 Jan 2022 22:04:50 +0200 In-Reply-To: <87k0eqfd1j.fsf@posteo.net> (Philip Kaludercic's message of "Sun, 23 Jan 2022 19:49:12 +0000") Message-ID: <8635lerzfh.fsf@mail.linkov.net> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (x86_64-pc-linux-gnu) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 52973 Cc: Lars Ingebrigtsen , 52973@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.7 (-) >>>>> As the "default search engine" is a new option, changing the default to >>>>> HTML DuckDuckGo should be fine. I personally use it as by default >>>>> search engine, but don't know how popular or unpopular it is. >>>>> >>>>> Adding the default DDG (and perhaps the lite version as well) as >>>>> alternatives seems sensible too. >>>> >>>> The default DDG version has more features than the HTML one, so I think >>>> that's what most people would prefer... >>> >>> Maybe one should not only configure a general search engine, but a >>> search engine depending on a context. Sometimes you might want to use a >>> specialised search engine (e.g. hoogle when working on Haskell), and >>> that should be automatically detected as the default. In the same way, >>> if EWW would be using a special "context" to designate that it wants a >>> JS-free search engine (HTML DuckDuckGo). >> >> This makes sense as well with e.g. webjump-context-search-engine. > > I am not sure what you mean by webjump-context-search-engine. Should it > be a separate command or a user option? Probably a user option, since you already named the function webjump-search-context-menu. Then maybe a better option name would be webjump-context-menu-default-search? From debbugs-submit-bounces@debbugs.gnu.org Mon Jan 24 04:14:27 2022 Received: (at 52973) by debbugs.gnu.org; 24 Jan 2022 09:14:27 +0000 Received: from localhost ([127.0.0.1]:42049 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBvQh-00035i-HV for submit@debbugs.gnu.org; Mon, 24 Jan 2022 04:14:27 -0500 Received: from quimby.gnus.org ([95.216.78.240]:47906) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nBvQf-00035V-Om for 52973@debbugs.gnu.org; Mon, 24 Jan 2022 04:14:26 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=J39XPRHah7rEsZSxnzfDytukeAzS+BBK8WPWFT/cK2U=; b=Qup9FeqRLnc24xE/MVVjPLnPnH EY9YBxLcZR6ag4XU0YK+aWyewhEi/gtNLu1vDNHdGJHYGnNXHWauW2Y2A2aINqf/56CJZ9yTACvRU eyOrUr3/z5AHjwYFXTgLF/1Xlk1rqakNbEd9qe3nQkOHOgvBG9KxQeCWQMBKnAW42/UM=; Received: from [84.212.220.105] (helo=giant) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nBvQX-0006AS-07; Mon, 24 Jan 2022 10:14:19 +0100 From: Lars Ingebrigtsen To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <87bl038sr2.fsf@posteo.net> <86bl02x04g.fsf@mail.linkov.net> <87iluay7oz.fsf@posteo.net> <87tuduabv1.fsf@gnus.org> <878rv6ifcs.fsf@posteo.net> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAALVBMVEUDBQwfGCEtLTFs bHCrrLDR0dXw8PJ9fYFgWmGPkJS9vcFFOEN+f4NNTVH///8PU95gAAAAAWJLR0QOb70wTwAAAAd0 SU1FB+YBGAkIHpkDiBsAAAGcSURBVDjLrZJNS8NAEIZn41GEJD1JKdR4qUgOtRWtKFj6oRFvNZV6 bgb0rHfRXEQEKanQYg8iLejR/gm9qfUQkf4Xt5umH7vrzXchsPtk5t2dGYCRNNDTZRzosIgIk1Lc AFSKjj0FIOExUlq1n6cB6N06BY/uQR54kTvEnUtrUwAwX8ZcKtUXgVLE3P2LKgL9DHOND96A/hjd wFL+nQd0RV08zp9zYE4FNZbGqscD0EyIFPAkLQBwkzP0hRneA0ii5UqBppv05ZgSUhGtW6DgVfRQ WEtqosfiIACzfEV0I+hhlj83/TpKADH8NZYJH7i7Gv5bh4Ft3qF3GkzDrQA8lAHN6DWlAHT/D0BM NnFOmTOnId9tu4xHQgNpRfbatm21wr15HU5FzCtgpXExuo42KJrGQAedfGs6zbjq1fgwgBWZfZRB Y9FphZnooJEgjAHcV4cgDADyxcAu25GJdgXAqY1dQy1Rc9tKjvZqGBcp2E83C+oEGCqaaayAVHrf iMtJLLP+KTtXek1ry5CAWf/K+tElgCwbfbkJgf/WL9tlhd4YWsDQAAAAJXRFWHRkYXRlOmNyZWF0 ZQAyMDIyLTAxLTI0VDA5OjA4OjMwKzAwOjAw7+6+lQAAACV0RVh0ZGF0ZTptb2RpZnkAMjAyMi0w MS0yNFQwOTowODozMCswMDowMJ6zBikAAAAASUVORK5CYII= X-Now-Playing: This Mortal Coil's _Filigree & Shadow_: "I Want to Live" Date: Mon, 24 Jan 2022 10:14:16 +0100 In-Reply-To: <878rv6ifcs.fsf@posteo.net> (Philip Kaludercic's message of "Sun, 23 Jan 2022 16:30:59 +0000") Message-ID: <87ilu95wd3.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Philip Kaludercic writes: > Maybe one should not only configure a general search engine, but a > search engine depending on a context. Sometimes you might want to use a > specialised search engine (e.g. hoogle when working on [...] Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org, Juri Linkov X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Philip Kaludercic writes: > Maybe one should not only configure a general search engine, but a > search engine depending on a context. Sometimes you might want to use a > specialised search engine (e.g. hoogle when working on Haskell), and > that should be automatically detected as the default. In the same way, > if EWW would be using a special "context" to designate that it wants a > JS-free search engine (HTML DuckDuckGo). Sure, sounds good (but it's not immediately obvious to me how the user (and packages) would specify these contexts)... -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From debbugs-submit-bounces@debbugs.gnu.org Tue Jan 25 07:06:17 2022 Received: (at 52973) by debbugs.gnu.org; 25 Jan 2022 12:06:18 +0000 Received: from localhost ([127.0.0.1]:47178 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nCKaX-0006Gg-L5 for submit@debbugs.gnu.org; Tue, 25 Jan 2022 07:06:17 -0500 Received: from mout02.posteo.de ([185.67.36.66]:53621) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nCKaT-0006GK-Tk for 52973@debbugs.gnu.org; Tue, 25 Jan 2022 07:06:16 -0500 Received: from submission (posteo.de [89.146.220.130]) by mout02.posteo.de (Postfix) with ESMTPS id A07D5240101 for <52973@debbugs.gnu.org>; Tue, 25 Jan 2022 13:06:06 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1643112366; bh=c9vtIcHmA6IMO004VLNmlh0SFEcsWRJViQzR9xXWG00=; h=From:To:Cc:Subject:Autocrypt:Date:From; b=aoUpEF8zh/5ji+sflZDmi9lzKCKDi/MVvwM4SoUETOwAnkIiOz0ZcdnRm42xws4kP tEOmGfiIKSR0zSh60tob/kapA396Yl1MSVKqVukGzcREKnkfpRdbAWGx5H6HeTuoGp z5dZPMNBB94RVXnjqZkFim1RoFPoEtFGXtDCrR0bCH7YoUUAOlpTKrB3Crh4FmD82A Hs3sIlrxsUqsRCWM1pJhkpCwqkDliDYJRziFcnYLbwTE5xSXBnXdWB2un38d7psuIU uUeOmojuYeODtvEIr+qVHK8lnLplZzdyopz/QQ6bNLeQab5MHIcrwORBOBkGOjRKC9 x/XmkETo4vVLg== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4Jjltj4TWbz9rxR; Tue, 25 Jan 2022 13:06:05 +0100 (CET) From: Philip Kaludercic To: Lars Ingebrigtsen Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <87bl038sr2.fsf@posteo.net> <86bl02x04g.fsf@mail.linkov.net> <87iluay7oz.fsf@posteo.net> <87tuduabv1.fsf@gnus.org> <878rv6ifcs.fsf@posteo.net> <87ilu95wd3.fsf@gnus.org> Autocrypt: addr=philipk@posteo.net; prefer-encrypt=nopreference; keydata= mDMEYHHqUhYJKwYBBAHaRw8BAQdAp3GdmYJ6tm5McweY6dEvIYIiry+Oz9rU4MH6NHWK0Ee0QlBo aWxpcCBLYWx1ZGVyY2ljIChnZW5lcmF0ZWQgYnkgYXV0b2NyeXB0LmVsKSA8cGhpbGlwa0Bwb3N0 ZW8ubmV0PoiQBBMWCAA4FiEEDM2H44ZoPt9Ms0eHtVrAHPRh1FwFAmBx6lICGwMFCwkIBwIGFQoJ CAsCBBYCAwECHgECF4AACgkQtVrAHPRh1FyTkgEAjlbGPxFchvMbxzAES3r8QLuZgCxeAXunM9gh io0ePtUBALVhh9G6wIoZhl0gUCbQpoN/UJHI08Gm1qDob5zDxnIHuDgEYHHqUhIKKwYBBAGXVQEF AQEHQNcRB+MUimTMqoxxMMUERpOR+Q4b1KgncDZkhrO2ql1tAwEIB4h4BBgWCAAgFiEEDM2H44Zo Pt9Ms0eHtVrAHPRh1FwFAmBx6lICGwwACgkQtVrAHPRh1Fw1JwD/Qo7kvtib8jy7puyWrSv0MeTS g8qIxgoRWJE/KKdkCLEA/jb9b9/g8nnX+UcwHf/4VfKsjExlnND3FrBviXUW6NcB Date: Tue, 25 Jan 2022 12:06:04 +0000 In-Reply-To: <87ilu95wd3.fsf@gnus.org> (Lars Ingebrigtsen's message of "Mon, 24 Jan 2022 10:14:16 +0100") Message-ID: <87y234vx3n.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org, Juri Linkov X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Lars Ingebrigtsen writes: > Philip Kaludercic writes: > >> Maybe one should not only configure a general search engine, but a >> search engine depending on a context. Sometimes you might want to use a >> specialised search engine (e.g. hoogle when working on Haskell), and >> that should be automatically detected as the default. In the same way, >> if EWW would be using a special "context" to designate that it wants a >> JS-free search engine (HTML DuckDuckGo). > > Sure, sounds good (but it's not immediately obvious to me how the user > (and packages) would specify these contexts)... I would suggest a variable like `webjump-search-context' that could be locally bound in cases like eww or set as a buffer local variable for things like haskell-mode. The structure and contents of such a variable are another question that I will try to experiment with once I have the time to do s. -- Philip Kaludercic From debbugs-submit-bounces@debbugs.gnu.org Tue Jan 25 07:24:17 2022 Received: (at 52973) by debbugs.gnu.org; 25 Jan 2022 12:24:17 +0000 Received: from localhost ([127.0.0.1]:47223 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nCKrx-0000cf-Gi for submit@debbugs.gnu.org; Tue, 25 Jan 2022 07:24:17 -0500 Received: from quimby.gnus.org ([95.216.78.240]:34476) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1nCKrv-0000cM-4l for 52973@debbugs.gnu.org; Tue, 25 Jan 2022 07:24:15 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnus.org; s=20200322; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date: References:Subject:Cc:To:From:Sender:Reply-To:Content-Transfer-Encoding: Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender: Resent-To:Resent-Cc:Resent-Message-ID:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=imxykwmC8nrWRcvxbd5KE/3h1EfPVhQRSAtgdk+gTUM=; b=A9j3bcjWoCUO/jBreQzbXGlKpF dNBGBGHXqwLjvZVrKeBtwg8jo7ow59/RN5ZDexxN1mSsUV9QYo68A+NFErh7gkvo/cLNVDkR90tmr 0/bufMsRjlKbu7NtP1golLHICCtDp9gJltxevQh2A2HckZlZz2jCEcAk2a/yyQUtZaDY=; Received: from [84.212.220.105] (helo=giant) by quimby.gnus.org with esmtpsa (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nCKrm-0003NO-DJ; Tue, 25 Jan 2022 13:24:08 +0100 From: Lars Ingebrigtsen To: Philip Kaludercic Subject: Re: bug#52973: Adding a few context-menu-mode commands References: <87o84tp69h.fsf@posteo.net> <868rvwsezi.fsf@mail.linkov.net> <87czl75lyz.fsf@posteo.net> <86czl6au29.fsf@mail.linkov.net> <874k6idjod.fsf@posteo.net> <86o84pthgp.fsf@mail.linkov.net> <87pmp4lmfz.fsf@posteo.net> <87bl038sr2.fsf@posteo.net> <86bl02x04g.fsf@mail.linkov.net> <87iluay7oz.fsf@posteo.net> <87tuduabv1.fsf@gnus.org> <878rv6ifcs.fsf@posteo.net> <87ilu95wd3.fsf@gnus.org> <87y234vx3n.fsf@posteo.net> Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwBAMAAAClLOS0AAAABGdBTUEAALGPC/xhBQAAACBj SFJNAAB6JgAAgIQAAPoAAACA6AAAdTAAAOpgAAA6mAAAF3CculE8AAAAGFBMVEU0LipDOjVLQzyP hnZlW1CEeWuqpZb////IoTa+AAAAAWJLR0QHFmGI6wAAAAd0SU1FB+YBGQwFD/hqcyoAAAGdSURB VDjLtZNNcoMwDIVlhgNYnnQPLj2BIOvEkXOBQC/gJvc/QmUZ8sOERRf1yrzPepIlA8YRM/su+Lxa xOriQ2g9YAHezcCeYgMOBezSE0DEG7cAYGaQUSF1Ym/lFLjuGbRYy74B4zIYp2khLe6Y+6MzBvxX ml7B949UiAroGcRbH1wrEZ/XiYb4AOdbz14K810faZgKkPvhOY0crJHkfKJhLEB0TCfi0AA45riA rFc90xisWEWOe1KQjbC+RqIgd/fM0z7dQU17MThatVpADjjTPgmAGUiDg4JdohvR2FQHBXQHtZQo CaE+ADKPl+GeW0qcOOcG00m99xT4SdK4owLf5a4XJ7RnmsYVUCfs4mUBzpc5FfDBNKwAzlY0RwBm rzmFQcqzaQpw+qhEBolIEuDljRQvv2SQNzJwa8E3c4gCMGjqPsjwqqDAoOo2byuZRP60JYsu3VoE iS+yxsx6Xu6hv66qea/DxnmoNnTwWwGHvzr9y5Kfytjcf7MC0iUrovy+j7MFGAG552YF9LQarsGb tJsAN0DVbgAd4S9w9G1nnHni8gAAACV0RVh0ZGF0ZTpjcmVhdGUAMjAyMi0wMS0yNVQxMjowNTox NSswMDowMN6j0rsAAAAldEVYdGRhdGU6bW9kaWZ5ADIwMjItMDEtMjVUMTI6MDU6MTUrMDA6MDCv /moHAAAAAElFTkSuQmCC X-Now-Playing: David Bowie's _Brilliant Adventure (9): Re:Call 5_: "Don't Let Me Down & Down (Indonesian Vocal Version)" Date: Tue, 25 Jan 2022 13:24:05 +0100 In-Reply-To: <87y234vx3n.fsf@posteo.net> (Philip Kaludercic's message of "Tue, 25 Jan 2022 12:06:04 +0000") Message-ID: <87wnioxau2.fsf@gnus.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/29.0.50 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Report: Spam detection software, running on the system "quimby.gnus.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see @@CONTACT_ADDRESS@@ for details. Content preview: Philip Kaludercic writes: > I would suggest a variable like `webjump-search-context' that could be > locally bound in cases like eww or set as a buffer local variable for > things like haskell-mode. Content analysis details: (-2.9 points, 5.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] X-Spam-Score: -2.3 (--) X-Debbugs-Envelope-To: 52973 Cc: 52973@debbugs.gnu.org, Juri Linkov X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -3.3 (---) Philip Kaludercic writes: > I would suggest a variable like `webjump-search-context' that could be > locally bound in cases like eww or set as a buffer local variable for > things like haskell-mode. Sounds reasonable to me. -- (domestic pets only, the antidote for overdose, milk.) bloggy blog: http://lars.ingebrigtsen.no From unknown Wed Jun 18 23:08:20 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Wed, 23 Feb 2022 12:24:07 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator