From: Samuel Wales <samologist@gmail.com>
To: Max Nikulin <manikulin@gmail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: capturing and filling
Date: Fri, 14 Apr 2023 18:36:33 -0700 [thread overview]
Message-ID: <CAJcAo8syPQRmN91HyqhgoqdY_Pcmmj=raiWhHtzo17ztC4DyYg@mail.gmail.com> (raw)
In-Reply-To: <u0o9ck$pm2$1@ciao.gmane.io>
i am very sorry, i got myself in over my head. i do not undestrand
what you are suggesting. if a change on the ff side i cannot do it,
bu perhaps you are suggesting making emac pop up an x seector that
chooses the filing option.
for yers i have used an unsophisticated heursitic in the template
simiilar to your teplate suggestion.
but now the problem is htat this essential ff extension is completely
broen for me. i upgraded firefox, and now it is popping up a window
asking [unselectable text paraphrasing] whether i want emacsclient
oprning protocol iink.
i affirm but no capture occurs.
so no capture at all, never mind a choice of filling.
On 4/6/23, Max Nikulin <manikulin@gmail.com> wrote:
> On 07/04/2023 11:40, Samuel Wales wrote:
>>
>> On 4/6/23, Max Nikulin wrote:
>>> Samuel, in your case, it is your requirement to have non-distracting
>>> single-click capture.
>>
>> ... but one icon for prose/filling and one for lines/nonfilling would
>> be great for me. or even the existing single icon for whichever one i
>> use most, with a right-click menu for other options. maybe other
>> templates.
>
> An extension can not add 2 buttons. It may define context menu for right
> click or it may open a popup with menu (implemented as an HTML page) on
> simple (left) click.
>
> Till it is not implemented you may use an org-protocol handler that
> displays menu from e.g. a shell script:
>
> printf 'Prose\nCode\n' |
> zenity --list --title "Capture template" \
> --text "Capture type" --column Template
>
> or
>
> zenity --question --title "Capture template" --text "Capture type" \
> --ok-label Prose --cancel-label Code
>
>>> A workaround is to define 2 capture template: for prose text and for
>>> code. Browser extension should not add template=x query parameter to
>>
>> i am guessing you mean s/should not/should/ here?
>
> If template is not passed then script can just append &template=x to the
> URI, otherwise it may call e.g. sed to replace existing parameter.
>
>>> %(insert (shell-command-to-string "xclip -t text/html -o | pandoc
>>> -f html -t org -"))
>>>
>> i selected one line and it printed that line. i selected your above
>> lines and got Error: target text/html not available.
>
> Select some text on a web page in Firefox (or similar application
> supporting rich text copy, e.g. libreoffice writer) and try
>
> xclip -t TARGETS -o
>
> I have realized that `insert' should not be added to template, the code
> above is more suitable for evaluation by M-:
>
> Next revision (with escaped quote characters)
>
> "* %:description
> <%:link>
>
> %(shell-command-to-string \"xclip -t text/html -o | pandoc -f html -t
> org -\")
> "
>
>
>
>
>
--
The Kafka Pandemic
A blog about science, health, human rights, and misopathy:
https://thekafkapandemic.blogspot.com
next prev parent reply other threads:[~2023-04-15 1:37 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-04-07 3:29 capturing and filling Samuel Wales
2023-04-07 4:12 ` Max Nikulin
2023-04-07 4:40 ` Samuel Wales
2023-04-07 5:23 ` Max Nikulin
2023-04-15 1:36 ` Samuel Wales [this message]
2023-04-15 3:37 ` Max Nikulin
2023-04-17 7:00 ` Max Nikulin
2023-04-10 4:39 ` Max Nikulin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.orgmode.org/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to='CAJcAo8syPQRmN91HyqhgoqdY_Pcmmj=raiWhHtzo17ztC4DyYg@mail.gmail.com' \
--to=samologist@gmail.com \
--cc=emacs-orgmode@gnu.org \
--cc=manikulin@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).