From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp10.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id uNQiFJjDnmIUkwAAbAwnHQ (envelope-from ) for ; Tue, 07 Jun 2022 05:18:48 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp10.migadu.com with LMTPS id GGAkE5jDnmLnlQAAG6o9tA (envelope-from ) for ; Tue, 07 Jun 2022 05:18:48 +0200 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 D0D4D12695 for ; Tue, 7 Jun 2022 05:18:47 +0200 (CEST) Received: from localhost ([::1]:58288 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nyPjy-0007uy-Tr for larch@yhetil.org; Mon, 06 Jun 2022 23:18:46 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:36610) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nyPhj-00065N-QJ for emacs-orgmode@gnu.org; Mon, 06 Jun 2022 23:16:28 -0400 Received: from mail-ej1-x634.google.com ([2a00:1450:4864:20::634]:42890) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1nyPhg-0004Lp-J1 for emacs-orgmode@gnu.org; Mon, 06 Jun 2022 23:16:27 -0400 Received: by mail-ej1-x634.google.com with SMTP id q1so32533770ejz.9 for ; Mon, 06 Jun 2022 20:16:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-transfer-encoding; bh=+pL5a4Ow7HcQS8OYuZ2BTk0D0uBOsin0jm9FIjIzqIA=; b=dP1AF6SoPc5moa2FFJ99BkMl/JNPKvnXe5shE/pWfcZMZJdUkyfsSvQs7zUPk3Lpev TaJnmjGp6Vg4PAcp9gzza0HMHV6GdBL/KNonP0rtDArCinKXnfVI8jzzpRuGtnwrNrCO unxooJdEvi8c4zBoofaUIOOWZ0OgBJSDpv2bxEfT8WuVy7RXT95F4tHkc0NZmcnBs1b3 jx05TIiQ5RPkNEgu1EwuxKGp9w5z5/fKT5gFAVoYm0wVtKM1965NI1a0KsaJLVtyhUYK /ETHzK9ildOiW3J0bUT5u5n8gMIW2/0+b2nHp3wpB1JXdppEKue7y+S94VCXngM9B6c2 mnEg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc:content-transfer-encoding; bh=+pL5a4Ow7HcQS8OYuZ2BTk0D0uBOsin0jm9FIjIzqIA=; b=P/CtTyM3sxCtwpOr5xmb4VRlypUlTII9FoL/JYfTLFsmdgdsEo8hYWsBFIAkzmlWSL tjrJ3jwh+PLri6spr7nC97dCJGN9zTtdEm01KnT4GMydJrFmMeKeGOh/9Q/YXysQwdr4 S6ZaL6uiHREaijEnJFQ0KwOomw1LByOtpG15LFqOcFN3lGvMw9UthNyaSNMfvJYQKtFx 58DkM34UIXvUPFL+9oP1U3zf643J3MQlw6HzGMOCEG3FSP0pVD3wBaM9d7J8R1YfTLy6 lcI+/VYf8MAoXfMteDyxfiv8IGNQjEC3wvD4sYONAPVAyWm4G8YMVA8qrZnY623IgoFV Aydg== X-Gm-Message-State: AOAM531TUuMO/l2zQxgQvlEUQ9lu+jPhOaT1o++p5P/f7YVHsqkbAJMr CW6dbUgvH4JygHKtDbooQeLoV1mX1eSnKAekxVY= X-Google-Smtp-Source: ABdhPJxYA9t9a/xYof6bBl6ltF6ZYLhe8ZdWLas/qbM/IqXhFxt0PDave495J1ssVdkqKQ4NBxZZ8303sX86ddAv9D0= X-Received: by 2002:a17:906:38d3:b0:710:daf0:52f8 with SMTP id r19-20020a17090638d300b00710daf052f8mr13532701ejd.406.1654571781563; Mon, 06 Jun 2022 20:16:21 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a17:906:478b:b0:6fe:f76c:8596 with HTTP; Mon, 6 Jun 2022 20:16:20 -0700 (PDT) In-Reply-To: References: <87mtf3tui1.fsf@localhost> <87pmjyco0x.fsf@localhost> <87fskrobiw.fsf@localhost> <87a6ay1enh.fsf@localhost> From: Samuel Wales Date: Mon, 6 Jun 2022 20:16:20 -0700 Message-ID: Subject: Re: Proposal: 'executable' org-capture-templaes To: Max Nikulin Cc: emacs-orgmode@gnu.org Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Received-SPF: pass client-ip=2a00:1450:4864:20::634; envelope-from=samologist@gmail.com; helo=mail-ej1-x634.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 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, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham 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" X-Migadu-Flow: FLOW_IN X-Migadu-To: larch@yhetil.org X-Migadu-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1654571927; 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: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post:dkim-signature; bh=+pL5a4Ow7HcQS8OYuZ2BTk0D0uBOsin0jm9FIjIzqIA=; b=hjQOvyjhK7DWXO5C3PKUErdisgRA4lRYHYKeilaeos56bs4GTBNpFtIqwIPtU1nN2RcLwf OBiLlj7i9zuQ2tj1LtMa0GhyTxmcLPNTwiSDQIyXjPKN4PVSe/otyG4cMUdN3YFGIE1fg9 szQLXSNHLeNSJRkacmn5kBwm6W9CqqR2BjZaYyvPOLZgMxB5LANNarUbch/bVonRJ3e2hS F8XELl7N19kGwjsWuzraFArwPo8LecgpIyMt2zctekp3pmSjAnK8WbAbh+h4rMz3KcwDe5 B/lMjXteSe0SnUH7pxphpfsK4CtgmvUchjGO6gLDmGXfVZJv7gHwJXMc/NCXFA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1654571927; a=rsa-sha256; cv=none; b=vAlXxWCq6xLwFLzaIP+mLHy/O/4dhC8Qne06QnEZ4umnN5RCu2eS6gSK1U1T6dyK1lb+4t TEpM7Agw3va10j93f4WD0UdYdwpI2nPFlMKDu4Uy/3KffTItObK7sh1H852jXC+0DoQIIP aviQgL5dYq0e8h1I4wULJS2z7PdyS8UIwnYhW7vyaPQWMhI0EIhuxcnl17Ysv9CZO5/Nwr cgxqztVxDF4Nwq9Nyx5hV42j0eMZ/XxRmxzbpVmmz5cmgNt+W/Fg5sdiZMl1sCGox4hByw WZyGS/5aZlElxsFD7CqCnTiQ+hwNjnFRgDQuLOzaSJ3KijMrZGKarnOSdShmAg== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=dP1AF6So; dmarc=pass (policy=none) header.from=gmail.com; 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" X-Migadu-Spam-Score: -4.01 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=dP1AF6So; dmarc=pass (policy=none) header.from=gmail.com; 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" X-Migadu-Queue-Id: D0D4D12695 X-Spam-Score: -4.01 X-Migadu-Scanner: scn1.migadu.com X-TUID: lFwdG50O4VYN [i put an unnecessary and not really meant word truly there. accessbililty reasons could of course make it necessary.] i think it is needed to do accessibility and great to do factoring. shows our maturity as a project and developers. [accessbilty/refactoring aside, i want to say i really like many aspects of the care taken to make many of our menus. e.g. kw selection or tag selection use colors, have low key count. date selection too. i wonder how much of this will survive?] On 6/6/22, Samuel Wales wrote: > i must be confused. menus aside, you can currently capture and it > uses the org forest itself, so it is both crash-proof and snappy. and > you can yakshave as much as you want, starting a capture while doing a > capture. those were design goals. > > you can even be in the middle of a capture, get distracted, navigate > around your forest, and find where you are in the middle of a capture. > goes with the original crash-proof and yakshave and snappy > use-original-buffer design goal. > > so are we talking about menus then? is there truly a need to make > /menu state/ persistent or yakshaveable? > > > On 6/6/22, Max Nikulin wrote: >> On 05/06/2022 22:07, Arthur Miller wrote: >>> Max Nikulin writes: >>> >>> After input from Ihor I agree that it isn't the best way, and was >>> able to refactor org-mks to create a menu where I can execute any lisp >>> form, >>> when it comes in a list like this : ("h" "hello-word" (message "Hello, >>> World")), where third element is just a lisp form. I have something lik= e >>> this: >> >> This message is merely my opinion that you may disagree. I am not trying >> to prevent you from going forward. >> >> From my point of view current `org-mks' is more general giving you >> opportunity to treat extra elements as you wish. A thin wrapper allows >> to evaluate 3rd element of returned list. You have not convinced me that >> built-in executable form is the essential feature. >> >>> (defun demo3 () >>> "Illustrate nested menus, unicode separator and alternative >>> decorator." >>> (interactive) >>> (let ((quick-menu-key-decorator-chars "<>") >>> (quick-menu-vertical-separator ?=E2=94=80)) >>> (quick-menu >>> ;; table >>> '(("g" "Greetings") >>> ("gh" "Hello, World!" (message "Hello, World!")) >>> ("gb" "Bar" (message "Hello, Bar!"))) >>> ;; description >>> nil >>> ;; more tables >>> '(("f" "Functions") >>> ("ff" "Find File" (call-interactively #'find-file)) >>> ("fo" "Open File" (flet ((next-read-file-uses-dialog-p () t)) >>> (call-interactively 'find-file)))) >>> '(("q" "Abort" (user-error "Abort")))))) >> >> It is tightly based on org-mks, but actually it is way to represent list >> of choices with some hints to possible hierarchy and accelerator keys. >> Quite similar list may be fed to completion read or represented as a >> hierarchical GUI menu. The only specific is "always visible" elements >> like "abort". When Ubuntu used Unity desktop their had a nice feature of >> searching in application menu. >> >> There should be an extension point that allows users to replace >> representation e.g. to improve accessibility. >> >>> DESCRIPTON is a property list containing following members: >> ... >>> :horizontal when `t', if multiple menus are present they are rendere= d >>> from >>> left to right, otherwise from top to bottom. >> >> It may depend on whether a window created to display menu is tall and >> narrow or wide. >> >>> I have paramterized decorator character for shortcut keys as they appea= r >>> in the >>> buffer, org-capture uses "[]", as well as menu separator, which is >>> currently >>> hard-coded in org-capture, >> >> I agree that org-mks may have additional argument to specify menu >> decoration. >> >>> Exactly. It is important that org-capture is one capture at the time s= o >>> people >>> don't mess their note files, agenda files etc. >>> >>>> Unsure if som= e >>>> intermediate persistent store would be an improvement. >>> >>> Not sure what you mean here, but I don't plan to change anything in >>> org-capture >>> itself, it should still be one-task at the time. >> >> Changing interface to less degree of blocking may be confusing for >> users. Capture template selection menu may be displayed in another frame >> hidden behind other application, on another monitor, on another virtual >> desktop, so invisible. So a user earlier distracted by something urgent >> may try to start another capture. Captures may be initiated from other >> applications using org-protocol. >> >> To avoid data loss while other capture is in progress, the data of next >> capture may be temporary saved to some place till the user pops it from >> the queue. I mentioned persistence since something may unexpectedly >> crash, so it should be possible to resurrect enqueued captures in next >> Emacs session. >> >>>> Likely nobody performed any steps toward `transient' as the interface, >>>> but due >>>> to such requests it would be nice to have possibility to switch betwee= n >>>> menu >>>> implementations. >>> >>> I am not building some generalized framework, as I said in my first >>> respone to >>> Ihor :-). >> >> I am not requesting for a framework, I mean API compatible with other >> frameworks to let user choose their preferred ones. >> >> So tunables to control decoration sounds interesting. I am in doubts >> concerning fixing some element as executable. Mode-map instead of >> minibuffer may be a great step to more convenient interface (it >> resembles help buffers), but may require more changes in functions that >> do actual job. From other messages on this list my impression is that >> API should be designed having in mind flexibility and other UI packages. >> >> >> > > > -- > The Kafka Pandemic > > A blog about science, health, human rights, and misopathy: > https://thekafkapandemic.blogspot.com > --=20 The Kafka Pandemic A blog about science, health, human rights, and misopathy: https://thekafkapandemic.blogspot.com