CamielBouchier / cb_thunderlink

thunderlink replacement: Clickable, durable links to specific messages inside Thunderbird.
Mozilla Public License 2.0
71 stars 15 forks source link

Added possibility to use selected text #38

Closed tbruckmaier closed 2 years ago

tbruckmaier commented 2 years ago

Hi,

in order to reference mails from orgmode, I often found myself using the link via thunderlink, and additionally copying part of the message into a quote block:

#+source: [[thunderlink://messageid=123][mail from foo]]
#+begin_quote
... some content from the mail ...
#+end_quote

This CR adds a new placeholder $selected_text$, which contains the selected text by the user. A "link" can be configured like this:

#+source: [[thunderlink://messageid=$msgid$][$subject_filtered$ $author$]]\n#+begin_quote\n$selected_text$\n#+end_quote\n

I have added the cb_thunderlink menu additionally to the right click menu in tabs, as only then we can access the current selection.

Some things I stumbled upon while implementing:

CamielBouchier commented 2 years ago

Hi, Looks good at first glance. However, currently too short of time to have a decent look. Just wanted to ack though that I will have a look (and merge probably). Camiel B.

CamielBouchier commented 2 years ago

Hi thanks a lot for your contribution. I finally found some time to review and merge. Good stuff! Concerning your questions: I did not find an answer that addresses those issues with limited code (and thus low maintenance). None of it is critical though for using your functionality. It does the job more than decently. Thanks again. Camiel B.