From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp12.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms5.migadu.com with LMTPS id yIf4OXq6WGOE2QAAbAwnHQ (envelope-from ) for ; Wed, 26 Oct 2022 06:41:31 +0200 Received: from aspmx1.migadu.com ([2001:41d0:2:4a6f::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp12.migadu.com with LMTPS id GLm9OXq6WGMk6gAAauVa8A (envelope-from ) for ; Wed, 26 Oct 2022 06:41:30 +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 9E7E9175B1 for ; Wed, 26 Oct 2022 06:41:30 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1onYDn-0000Qn-FD; Wed, 26 Oct 2022 00:40:55 -0400 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 1onYDm-0000N4-7Y for emacs-orgmode@gnu.org; Wed, 26 Oct 2022 00:40:54 -0400 Received: from mail-lj1-x230.google.com ([2a00:1450:4864:20::230]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1onYDj-0005Gd-TQ for emacs-orgmode@gnu.org; Wed, 26 Oct 2022 00:40:53 -0400 Received: by mail-lj1-x230.google.com with SMTP id z24so10193603ljn.4 for ; Tue, 25 Oct 2022 21:40:51 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=cc:to:subject:message-id:date:from:references:in-reply-to :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=TMabPU3tA8qMfLb4ModmYzb2RnJBn+NCQYJMGcKtaPU=; b=bmklaSvtbTgVHRDzSXwIjHJ9mEdTcbu/+elW1bPw0BcRsicPiHl7RfkbNubg/JYFjL 0ikV8t7NoBl/qvF/PFOeADT3aRgM3PGbTQLqgGjqjlYe9KFo+e3LtwtKP6hT09HrEiTt 5twkb3OrSxtJpSOP4AOVNNCzRJUFs96v0nyMkINUc5+4+lcuEvIeG552RKGFmP3G1boK u+DEH8RI+W24jlSRkkW6RgXCMQMnFbk95jpTeZ/+iwkAL0uTfbbTEnSFd6kZdNMroOsu ldhm+07AeiUNlOlIBe1dSSdeGQ/EE8nFy4RX1wBw//jTtuFp0v/glZ9BoPlMd3kJQ9dt B8fw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:subject:message-id:date:from:references:in-reply-to :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=TMabPU3tA8qMfLb4ModmYzb2RnJBn+NCQYJMGcKtaPU=; b=M+PENcIdA4rscG9wysS18Sc4qcz4bEVehtOdzSSgqLmXrVagPpY5NR6A1SYE060DA3 qBAP1Sw9iU/jAK9VdnBkfZcvzgfL3USS76y/i1mBf+NRMZAF6uWs7DKIWwbkNfZHIPan irJtS3/0bfsFj+UA36lkRVRDFzZUHWsL27A/wEgi9FeUwmMmVUHpB9WqGlcVng1GVRGI HsTE7Wks+imsu7f4Z+Sno42TwedmVfuZlgvjx+um65fHHLJ722JcxMgDTZpaCsYbDcdN c4hbMbMhzjpsUWc579ZIhsPORQOu0GXMJuRx/ErhEsdkKxM7HP/2DNHgIv+JzAD3iWYm bnTA== X-Gm-Message-State: ACrzQf1ZykTA6kQ4n2NiM8m16tD2CkBRx3ehA0MI/jmIEjXK+xqi1nzi +KA9vd5Sl9hFmjNARz08kiKziMidNjH8xd6RuKI= X-Google-Smtp-Source: AMsMyM5SEGrKcf2uGQrRIHCTKnljjjJB2qXE8NlVfADwDNJlDdMq+XyI0247s+I+4om2IH80T7RakWkg/kG/nOo5tdk= X-Received: by 2002:a05:651c:88e:b0:26d:dd92:73e7 with SMTP id d14-20020a05651c088e00b0026ddd9273e7mr15020031ljq.503.1666759249377; Tue, 25 Oct 2022 21:40:49 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a9a:4d08:0:b0:228:e569:9740 with HTTP; Tue, 25 Oct 2022 21:40:47 -0700 (PDT) In-Reply-To: References: <87tuw31iub.fsf@mm.st> <87r0zelo7e.fsf@posteo.net> From: Samuel Wales Date: Tue, 25 Oct 2022 21:40:47 -0700 Message-ID: Subject: Re: idea for capture anywhere in x To: Max Nikulin Cc: Org Mode List Content-Type: text/plain; charset="UTF-8" Received-SPF: pass client-ip=2a00:1450:4864:20::230; envelope-from=samologist@gmail.com; helo=mail-lj1-x230.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 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: , Sender: "Emacs-orgmode" Errors-To: emacs-orgmode-bounces+larch=yhetil.org@gnu.org 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=1666759290; 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=TMabPU3tA8qMfLb4ModmYzb2RnJBn+NCQYJMGcKtaPU=; b=Pezn6AHtz7dPSJlGHMU8Ztk5fWFdC0tPRduF150C+ZgqGV0rq2iN1Nn5jyevJ3vvIYB/26 B4ajTrJw9AZLxRyumsJldTHZI7q9KM0jYKcSp4z3nxMU8gmLb+QJnv6uwJFltV0E1BynR8 3Vv/HtmTkutqc4Z9Qxd4GicfsB3thba0zWRlacOHLbo178ws6CaHN+1phKsR31wVpJSpcn a8Ku+5iYzv4TEyO2EXPUMdO1HEBeh+ZO1TFuuKoBuvnXfiU+0lygx51/CTLeqpG9YQNMHr jsMRTy7uWj177ms2jjvgKfZp2Tl1C57ceUwlougVgvBlxz0+Lj0678ravZrgfQ== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1666759290; a=rsa-sha256; cv=none; b=rbIxDFYDyfLgbMIxYE95LXa/GX//LfX2ckCMlUCUb2ze8OqcFtI7GKLPqMa7yvhIxqyHwc FtPa6M8Y80ABnrgW//IwlQdl8V5uwrBHuaisfjW7VkX2zKgYqAK/ysB6Lxz3NWLRYEjo0w uAp7kEplkN90hliN6xiQVPeuyXuw9NH2ZhBHRWcDQCbXYzd+95inAw3yKBJuGrrBx5ECJG Jylq++RdXx8f+mCm5a5EphVKBHZgdcFskANAcmIE8BZ/WJWREOxFHMM5R5ZYY+r1eH70U0 C/4Ncwt7asSU0NDyREjGO/rlWizllNSo2Qlp8gsdFo74p/6KZHzkgDcMQXNmQw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=bmklaSvt; 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: -7.21 Authentication-Results: aspmx1.migadu.com; dkim=pass header.d=gmail.com header.s=20210112 header.b=bmklaSvt; 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: 9E7E9175B1 X-Spam-Score: -7.21 X-Migadu-Scanner: scn0.migadu.com X-TUID: Bz/5XkmK/mhz hi max, thanks. more below. On 10/14/22, Max Nikulin wrote: > Samuel, I assume that you are quite happy with org-capture Firefox > extension. yes i rely on it and adore it. although i always fear it breaking or silently failing, as i have emacs in the bg behind ff when i run it and do not want to do more mousing and inspecting to find out if worked each time. i think last time it broke was some kind of mime stuff. i know it also has glitches of some kind but forgot what they were. e.g. something about it not having enough of a firefox api to distinguish whether you have changed tabs or some such. but i ahve not noticed any issues latelyu. but then i do not look for them. > > Have you managed to setup capturing text from other applications? From > my point of view all necessary moving parts have been discussed in this > or later threads. Have you assembled them to a working solution suitable > for you? no, oi have not yet. for unrelated reasons, it takes me a lot of time to do things. the most critical application to catpreu from is firefox itself for which i have above org capture extension. it looks like i can do: > > - Window manager menu item and shortcut calling > emacsclient --eval '(org-capture nil "c")' this as an item in .fluxbox/menu, for non-emacs apps. > - Capture template that fetches X PRIMARY_SELECTION or CLIPBOARD. with a capture template that has percents for th3ese or so? [n.b. i still have a mysterious capture bug where it puts newlines above capturd entries. could be me, or version issue, or both.] btw on occasion i wnt to capture from emacs using mouse only, but not all modes have mouse context menu. i am always either using keybaord or using mouse never both. emacs would be second application for capturing via mouse. other applications are pdf displayers, deluge, urxvt, console. other stuff is rare. > - Optionally try to get formatted text and convert it from HTML to Org > using pandoc. which is intruiguing but i will keep my expectations and needs and priority low here but would want this to be using firefox cli/emacs api or .mozilla files rather than e.g. a curl call for privacy. i will assume not doing this but curious about it. > - Perhaps try to get window title of the active application. interesting! perhaps org-capture could run lisp to call one of those xdo type tools or so. it would take a bit ot of me to do. > > What I have not tried yet is if drag&drop API may provide more details > than X selection, but I am unsure if such workflow is suitable for you. intresting idea re details. however, drag and drop per se is impossible for me among apps as i always maximize and it irritates me so much within that i trid to turn off due to the effects of mistaken mouse movements or slwo machine. > > Probably it is better to discuss code in the context of particular > applications. Despite you wish a general approach, amount of information > exposed by applications may vary. Some code may depend on Emacs version good point. i'm assuming a little tweaking here and there might be usful where possible for url/title or equivalent or any other stuff. huh, gathering such might make a nce package if anybody had the same idea and wanted to do it. maybe spookfox will get more development and include some features like this. or the above. merely brainstorming. one of th reasons i suggestd this anywhere in x idea was to act as a fallback should org-capture break. > an I am unsure which one you are using currently. > old as the hills. hoping to try if poss to upgrade over next few months/years to 26 27 28+. [perhaps one day i will natively compile! i have super-modern lexical binding and don't use (` bq. :) oh and although i realy like ido/ido-hacks/id-clever-match very much i sort of eye embark and its inter-operable gang. someday in the futre.] -- The Kafka Pandemic A blog about science, health, human rights, and misopathy: https://thekafkapandemic.blogspot.com