From: Alex Lane <alexpgp@imap.cc>
To: emacs-orgmode@gnu.org
Subject: org-protocol encoding issue
Date: Mon, 04 Mar 2013 13:19:14 -0600 [thread overview]
Message-ID: <5134F3B2.7090608@imap.cc> (raw)
I am having an encoding problem with org-protocol. Here is my setup:
1. Windows 7 running emacs 24.2 and org-mode 7.8.
2. An Opera bookmark with location:
javascript:location.href=
'org-protocol://capture://w/'+
encodeURIComponent(location.href)+'/'+
encodeURIComponent(document.title)+'/'+
encodeURIComponent(window.getSelection())
3. The following code in my .emacs:
(setq org-capture-templates
`(("w" "Capture snippet" entry (
file+headline "~/org/snip.org" "Snips:")
,(concat "* Fact: '%i' :"
(format "%s" org-drill-question-tag)
":\n:PROPERTIES:\n
:DATE_ADDED: %u\n
:SOURCE_LINK: %c\n:END:\n")
:empty-lines 1
:immediate-finish t)
[...]))
4. The file snip.org starts out encoded as UTF-8.
When I highlight English text and click the bookmark, the highlighted
text is added to the file without any problem.
When I highlight Cyrillic text and click the bookmark, the highlighted
text is apparently added, but I get a warning to the effect that
utf-8-dos had been used in unsuccessfully trying to encode said text.
Accepting the default does not obtain a readable result. Furthermore,
attempts to select more text and create other snippets no longer appear
to work.
In both cases, what had started out as a file encoded in UTF-8 ends up
saved as a file encoded in ANSI.
I was not able to make much sense of posts from a couple of years ago
that appear to address the same or related issue. Can anyone help?
Cheers...
--
Alex Lane <alexpgp@imap.cc>
reply other threads:[~2013-03-04 19:19 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5134F3B2.7090608@imap.cc \
--to=alexpgp@imap.cc \
--cc=emacs-orgmode@gnu.org \
/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 external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.