From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp11.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 6MZ9BSfvQWMiPQEAbAwnHQ (envelope-from ) for ; Sat, 08 Oct 2022 23:44:07 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:bcc0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp11.migadu.com with LMTPS id YKaUBSfvQWPuyQAA9RJhRA (envelope-from ) for ; Sat, 08 Oct 2022 23:44:07 +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 60FAE87AC for ; Sat, 8 Oct 2022 23:44:06 +0200 (CEST) Received: from localhost ([::1]:52958 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1ohHc5-0003RT-05 for larch@yhetil.org; Sat, 08 Oct 2022 17:44:05 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48188) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ohHbf-0003R5-KB for emacs-orgmode@gnu.org; Sat, 08 Oct 2022 17:43:39 -0400 Received: from mout02.posteo.de ([185.67.36.66]:56477) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ohHbd-0005MY-FE for emacs-orgmode@gnu.org; Sat, 08 Oct 2022 17:43:39 -0400 Received: from submission (posteo.de [185.67.36.169]) by mout02.posteo.de (Postfix) with ESMTPS id 09DCB240104 for ; Sat, 8 Oct 2022 23:43:34 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=posteo.net; s=2017; t=1665265415; bh=HyZHhaLcEAC8y2Efs6KVAlNinMOvAHuhZPYSLJt/dCU=; h=From:To:Cc:Subject:Date:From; b=qy3sKEf5TAuC8m7yOt0bVhz0Ubd70ZadJNPcWtFwPcqED2bghKUhRB7AZZImp0bV6 G1TSg4LpoAuldtIg+zy5TMJdOmPv9Ng33om/9xKUnGSD9Hu7E84H6wG2FJnrMmN62k UnXdqiN9imxTwfn32c7QxuuC82o2xr/4VTdzb9A/7VocrsnBSLPFEruVSLK2w96vg9 Tjb35SgL2HBKIiWQ20fNEBWFLTOJUWdRWG6pxPrM27pR9uFyyn9p4J+hSgYr52B7BG 7JJTQcQXQwyz+kUvTIxsyqTr9lkAYhN+yeiAtm89sDCPvmDCf8kyB1+2rJlSUllXEX 4GXvhw1Esm0og== Received: from customer (localhost [127.0.0.1]) by submission (posteo.de) with ESMTPSA id 4MlJZt23FQz6tmQ; Sat, 8 Oct 2022 23:43:34 +0200 (CEST) From: =?utf-8?Q?Juan_Manuel_Mac=C3=ADas?= To: Robert Weiner Cc: rswgnu@gmail.com, orgmode Subject: Re: Org and Hyperbole References: <87k096b240.fsf@posteo.net> <87czew7qzy.fsf@posteo.net> Date: Sat, 08 Oct 2022 21:43:32 +0000 In-Reply-To: (Robert Weiner's message of "Sat, 8 Oct 2022 16:34:05 -0400") Message-ID: <87edving8r.fsf@posteo.net> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=185.67.36.66; envelope-from=maciaschain@posteo.net; helo=mout02.posteo.de X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 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_LOW=-0.7, RCVD_IN_MSPIKE_H2=-0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 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-Country: US ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1665265446; 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=q9iJlapXcrcPbEhQnw07way9cEaC/BdF1Dhmf7Xn2Vk=; b=LzrfVb6q7eAXeQdTW4XbCjx2PmyCEZkl4XrE3/L5s605PYINifOKclBqvxCbDX/1LdrfTf 4amMBVT3TsRR8xJiSwcBN7V/CjkpXOPVGu97PAigjcOJeBmnElYK34ORsfJwEokwmKO6tK e1wLjg0oQushXhi1JJEspM6OkyQIx3zyCSZhjgfonNLSAS5VUeuvNpmSGXwWgOSjFnU/Kj CLRLJiPb0bDx2F8IFR1oi/aqbOKpbMT2zixeNTuU4rA0163BlzpIS9g4SepTJVW6Qhdn/9 MFXaIlkcHJuEPW4I9M9DdKykFqf98daQHek40Jy7mF5+8nZdtvCARLzP7m+kkw== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1665265446; a=rsa-sha256; cv=none; b=RjK0qNX4/a36mTNssG5UFEBUP3AbEaKQG3qTc04PR4L985/72fB2soel+30viFy1TfqyR6 N6zUJnMjl/R6ZIbFvor8bt3ySl18uYC7HRM47JoovcR8J/8Ipk1vuzKwK3ROoa0cef2khL wEeI+hn/gvql5JaNQPzx8s2Q4+/I+D+xW9sWTO2IjWWdWiOLzR4P3wLfz0gPe25pvsnOYT rYXF0if7ADx1JD9TjBHKubQTO5JQKYFaCTAMX1tIGSy2v6vYyFrtZLbuWDtrgavwuM/4MG 52mpqG8Anl9UtekUDob9Hvx5cw78Znx+oFZE/R9V2AKoSP17JTPCJXOwT7C+PA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=qy3sKEf5; 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" X-Migadu-Spam-Score: -2.48 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=posteo.net header.s=2017 header.b=qy3sKEf5; 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" X-Migadu-Queue-Id: 60FAE87AC X-Spam-Score: -2.48 X-Migadu-Scanner: scn1.migadu.com X-TUID: dPem85ebD5D7 Robert Weiner writes: > Hi Juan: > > I just tried your ':' technique for Hyperbole button activation with > Avy and it works well. But what is the advantage over just using Avy > to jump to the button and then pressing {M-RET}. With your technique, > you have to think about activating the button before you are there > versus when you are on it, as you normally do. Hi, Robert, Thanks for your comment. I agree with what you say. I'm afraid this action, as I proposed it, is impractical. The proof is that I haven't used it too much :-). Avy also includes some factory keys where the action is performed on the target without losing focus or cursor position. For example, to copy a "distant" word and paste at point. This would be a more reasonable use case. Taking inspiration from Avy's code for these actions, I've defined this new version: (add-to-list 'avy-dispatch-alist '(?: . (lambda (pt) (goto-char pt) (hkey-either) (let ((dat (ring-ref avy-ring 0))) (select-frame-set-input-focus (window-frame (cdr dat))) (select-window (cdr dat)) (goto-char (car dat)))))) Now hkey-either would run without losing the current focus and cursor position. An example of use that occurs to me: for my translation of the Odyssey into Spanish I have defined some implicit buttons that do the following: if they are activated in a certain positions of the verse (for example, at the beginning of the verse), it is shown in a temporary postframe: a) the verse translated by me if the action is performed on the original Greek verse and b) the original Greek verse if the action is on the translated verse. I think that is better seen in this short video: https://cloud.disroot.org/s/4c7ZFCAPTercgMS Best regards, Juan Manuel