From: Sebastian Rose <sebastian_rose@gmx.de>
To: Memnon Anon <gegendosenfleisch@googlemail.com>
Cc: emacs-orgmode@gnu.org
Subject: Re: Re: Yet another way to use maps --- the light way
Date: Thu, 23 Sep 2010 22:10:10 +0200 [thread overview]
Message-ID: <8762xw8bml.fsf@gmx.de> (raw)
In-Reply-To: <8762xwcls6.fsf@mean.albasani.net> (Memnon Anon's message of "Thu, 23 Sep 2010 19:30:02 +0000 (UTC)")
Memnon Anon <gegendosenfleisch@googlemail.com> writes:
> Hi,
>
> Sebastian Rose <sebastian_rose@gmx.de> writes:
>
>> there is a light and easy way to use google and openstreetmap.org maps
>> if you define them as a custom link type:
>>
>> (setq org-link-abbrev-alist
>> '(("gmap"
>> . "http://maps.google.com/maps?q=%s")
>> ("omap"
>> . "http://nominatim.openstreetmap.org/search?q=%s&polygon=1")))
>>
>> Now
>> [[gmap:Falkenstr 10, Hannover, Germany][Falkenstraße]]
>>
>> and
>> [[omap:Falkenstr 10, Hannover, Germany]]
> [...]
>
> This works fine for viewing in an external browser like conkeror or ff,
> but fails for me in emacs w3m.
>
> Memnon
Yes. For this to work, you'd to do something like this (untested):
(defun org-follow-gmap-link (path)
"Follow a google-map link when clicked."
(browse-url-mozilla
(concat "http://maps.google.com/maps?q=" path)))
(org-add-link-type "gmap" 'org-follow-gmap-link nil)
(defun org-follow-omap-link (path)
"Follow a osm-map link when clicked."
(browse-url-mozilla
(concat
"http://nominatim.openstreetmap.org/search?q="
path "&polygon=1")))
(org-add-link-type "omap" 'org-follow-omap-link nil)
HTH
Sebastian
next prev parent reply other threads:[~2010-09-23 20:10 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-09-23 8:17 Yet another way to use maps --- the light way Sebastian Rose
2010-09-23 12:14 ` Carsten Dominik
2010-09-23 19:30 ` Memnon Anon
2010-09-23 20:10 ` Sebastian Rose [this message]
2010-09-24 7:18 ` Carsten Dominik
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=8762xw8bml.fsf@gmx.de \
--to=sebastian_rose@gmx.de \
--cc=emacs-orgmode@gnu.org \
--cc=gegendosenfleisch@googlemail.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).