From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp2.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms13.migadu.com with LMTPS id qPM0FiKQYGftDgEAe85BDQ:P1 (envelope-from ) for ; Mon, 16 Dec 2024 20:40:02 +0000 Received: from aspmx1.migadu.com ([2001:41d0:303:e224::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp2.migadu.com with LMTPS id qPM0FiKQYGftDgEAe85BDQ (envelope-from ) for ; Mon, 16 Dec 2024 21:40:02 +0100 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b="Ab7l/BKj"; dmarc=pass (policy=none) header.from=posteo.net; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" ARC-Seal: i=1; s=key1; d=yhetil.org; t=1734381602; a=rsa-sha256; cv=none; b=MyivtROs7TutN6BwZbZHsPp37BmBjJH0eZYm9r17pfKhXm6l8RE/xj1lfqiIytq3hTrAKi toXH8kuKOnY0Xnc57xrLVdiH9FzYiq1ltBk9NdxAgkJBUVrVqSDy+9GUZbDxdp3fTzGBe8 xjm57AdDUgbOtXoauSY2ODWuvUvX8lEwtdrCtBW7Ie0fTfx133yhNZdePHjDYY1vwV9g5z 1aR7tSbV8E5l7I8rXkcIMfJ++hJlWuFFK05Gtj3KikjNKTqjLQOom/7XMBomWgjRWTPWNI 3BzZyRW1eXciacLeTJn73e1/KmebspuNJoWpW2AJS6VVa/CdvaO4pEWgKWUFvg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b="Ab7l/BKj"; dmarc=pass (policy=none) header.from=posteo.net; spf=pass (aspmx1.migadu.com: domain of "emacs-orgmode-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="emacs-orgmode-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1734381602; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=THXU5m3SJUH9GSYWQjvMLSZ1Lej8FsBtRzIvD5gL8Xo=; b=tDR7r1Sq9b0HW+gKofhsyPEJxqZSNWp3JZnfY5i3ocTXjqJXnNLFgy3ySTqsba0fd5iVBY HZ1BRSTCkk5e6haiwrZzUWSxo4k2IxswpRe+qcADV57qLxRJD6ammLkFcoVokAXeK96Ebs QdXlTolSKbUw1lZDPxlbu3Y7ydH4HG4jRLHhXsUsA7XIFw5x3bFQt09Rasdb/bI3r1ocd2 ihec26YZxLa5loFN3etPdNbYbA6FiysIA4dtZCtMDCAyyzPvPcC9iKA3RIGi0tUQdq5QGe 3Slb8uUlLzIFr9k66FQayvQzEQa/3J2Q87AmUArEMaX/RyxXps/qh9ELdQTLNQ== Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id D506818E0D for ; Mon, 16 Dec 2024 21:40:01 +0100 (CET) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1tNFSl-000068-AG; Mon, 16 Dec 2024 13:05:01 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tNFSj-00005T-Hv for emacs-orgmode@gnu.org; Mon, 16 Dec 2024 13:04:57 -0500 Received: from mout02.posteo.de ([185.67.36.66]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1tNFSf-0007u5-C0 for emacs-orgmode@gnu.org; Mon, 16 Dec 2024 13:04:56 -0500 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id DC5E1240101 for ; Mon, 16 Dec 2024 19:04:50 +0100 (CET) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1734372290; bh=mRDpg+LuCVbYcaNakF4Y+1guJRC3SsSk87NsiCusJIQ=; h=From:To:Cc:Subject:Date:Message-ID:MIME-Version:Content-Type: From; b=Ab7l/BKjCXWNVRhENXH2tQe+OPJ4AIrTR4cbRyW1eGP0OxXhiF+FvErRm0OGDpsWp palI0LyTEkPmsOGhFHhFeCmBlk60HHzWufECE6jvwNWt93xTbWcJ6AhMMXKpkWEK8h MHtOfRj3AxUdGD5Dfs+5mTkTy17R7uSFmUVs7hwPRGQ5EdtrqKfRLRv0WapRFuNkw3 kWN/FdGv0+ocLdu92NlM8G6zNCia3xk+6ZVGi0y8OvyTK226sEubUp/FiRQGkZANqX 7vl0yvQjN8V6oAQ4IpqBy1rNKie1oFal09osYbWg+kIYLlBZJsdL3SFDqPobYHSxI0 H+S8BykqU62wQ== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4YBnsG1csCz9rxL; Mon, 16 Dec 2024 19:04:50 +0100 (CET) From: Ihor Radchenko To: Juri Linkov Cc: emacs-devel@gnu.org, emacs-orgmode@gnu.org Subject: Re: [RFC] The best way to choose an "action" at point: context-menu-mode, transient, which-key or embark? In-Reply-To: <8734io3xyo.fsf@mail.linkov.net> References: <8734m28l9a.fsf@gmail.com> <874j4m9ep6.fsf@gmail.com> <87h68gfqj1.fsf@localhost> <87pln3f3cc.fsf@localhost> <87jzd9ojj0.fsf@localhost> <87cyj0ajm9.fsf@gmail.com> <87zfm4s50x.fsf@localhost> <87wmh8s358.fsf@localhost> <87y11nwp9z.fsf@gmail.com> <87v7wd9a2h.fsf@localhost> <878qt7fbki.fsf@gmail.com> <87o71jwdxz.fsf@localhost> <87wmg6edr0.fsf@gmail.com> <87msgzh1dh.fsf@localhost> <87frmq6ufj.fsf@mail.linkov.net> <87zfkx1fha.fsf@localhost> <8734io3xyo.fsf@mail.linkov.net> Date: Mon, 16 Dec 2024 18:06:18 +0000 Message-ID: <87ttb3cxk5.fsf@localhost> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=185.67.36.66; envelope-from=yantar92@posteo.net; helo=mout02.posteo.de X-Spam_score_int: -43 X-Spam_score: -4.4 X-Spam_bar: ---- X-Spam_report: (-4.4 / 5.0 requ) BAYES_00=-1.9, 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, RCVD_IN_VALIDITY_RPBL_BLOCKED=0.001, RCVD_IN_VALIDITY_SAFE_BLOCKED=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=unavailable autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-orgmode@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org Sender: emacs-orgmode-bounces+larch=yhetil.org@gnu.org X-Migadu-Country: US X-Migadu-Flow: FLOW_IN X-Migadu-Spam-Score: -1.11 X-Spam-Score: -1.11 X-Migadu-Queue-Id: D506818E0D X-Migadu-Scanner: mx12.migadu.com X-TUID: PR7IsMWQQXP7 Juri Linkov writes: > Then you can use something like the buffer-local variable with the > same name 'context-menu-functions' (handled in 'context-menu-map'). > The main point is that these functions return a menu. > > But instead of a menu, an org function could return > a more high-level data structure like > ((name1 . action1 props) (name2 . action2 ...) ...) > > IOW, this means adding an abstraction layer on top of the existing > user interfaces such as transient and context-menu. Yeah. I am not 100% sure if adding an abstraction layer is a great idea. Another idea I was considering is similar to what you propose: have some kind of hook like `context-menu-functions', but accepting an extra argument - menu type (context menu, transient, which-key, etc.). Then, it should produce appropriate menu spec. However, this will require Elisp to customize things. Also not ideal. -- Ihor Radchenko // yantar92, Org mode maintainer, Learn more about Org mode at . Support Org development at , or support my work at