From: Joe Riel <joer@san.rr.com>
To: nicholas.dokos@hp.com
Cc: emacs-orgmode@gnu.org
Subject: Re: Specify page number in hyperlink [to pdf]
Date: Fri, 30 Apr 2010 10:23:06 -0700 [thread overview]
Message-ID: <4BDB11FA.9070105@san.rr.com> (raw)
In-Reply-To: <15830.1272643394@gamaville.dokosmarshall.org>
Nick Dokos wrote:
> Joe Riel <joer@san.rr.com> wrote:
>
>
>> That is fine, though I'll apply the patch. There does appear to
>> be another bug, or my misunderstanding. That is, even
>> without the link,
>>
>> [[file:/home/joe/sample.pdf]]
>>
>> does not work properly. That is, clicking on it (mouse 1)
>> opens the pdf inside emacs rather than in a standalone pdf reader.
>> Previously
>> that wasn't the case (if memory serves). Using
>>
>> [[file:/home/joe/sample.pdf::1]]
>>
>> for the link opens it in a standalone reader.
>>
>>
>>
>
> Probably because you have an explicit setting for the latter in
> org-file-apps (as Jan suggested) but not for the former. There are many
> twisty passages here, but I think that in the end emacs looks at your
> mailcap: if it finds no match there then it opens it itself.
>
> I have
>
> application/pdf; xpdf -q %s
>
> in my ~/.mailcap and indeed the link opens in xpdf.
>
>
My /etc/mailcap defines an appropriate application for pdfs.
The problem is that I replaced the existing entry
for pdf in org-file-apps, so that without the page tag there is no match.
Doing
(setq org-file-apps '((auto-mode . emacs)
("\\.mm\\'" . default)
("\\.x?html?\\'" . default)
("\\.pdf::\\([0-9]+\\)\\'" . "evince \"%s\" -p %1")
("\\.pdf\\'" . default) ;; this was the original
))
allows links to pdf's without the page tag to open in an external
application.
prev parent reply other threads:[~2010-04-30 17:23 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-04-28 18:30 Specify page number in hyperlink [to pdf] Joe Riel
2010-04-29 19:22 ` Jan Böcker
2010-04-30 4:27 ` Joe Riel
2010-04-30 4:43 ` Joe Riel
2010-04-30 8:10 ` Nick Dokos
2010-04-30 13:05 ` Jan Böcker
2010-04-30 15:24 ` Nick Dokos
2010-04-30 15:28 ` Carsten Dominik
2010-04-30 14:28 ` Joe Riel
2010-04-30 16:03 ` Nick Dokos
2010-04-30 17:23 ` Joe Riel [this message]
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=4BDB11FA.9070105@san.rr.com \
--to=joer@san.rr.com \
--cc=emacs-orgmode@gnu.org \
--cc=nicholas.dokos@hp.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 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.