emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Alan Schmitt <alan.schmitt@polytechnique.org>
To: Dmitri Makarov <dmakarov@alumni.stanford.edu>
Cc: emacs-orgmode@gnu.org
Subject: Re: [PATCH] org-mac-link.el: Handle links to/from Adobe Acrobat.
Date: Wed, 09 Sep 2015 16:11:26 +0200	[thread overview]
Message-ID: <m2d1xrznqp.fsf@charm-ecran.irisa.fr> (raw)
In-Reply-To: <CANLX=WiKvM4nMn5zEyNvhqzSj_-Kd3iiPUNDh8Jz_d8L4-Ci+A@mail.gmail.com> (Dmitri Makarov's message of "Wed, 9 Sep 2015 12:42:06 +0200")

[-- Attachment #1: Type: text/plain, Size: 1248 bytes --]

Hello,

On 2015-09-09 12:42, Dmitri Makarov <dmakarov@alumni.stanford.edu> writes:

> This is my second attempt to submit a patch that enables grabbing
> links from Adobe Acrobat Pro.

I do not have Acrobat to test, but I have a small comment.

> +(defun org-mac-acrobat-get-page ()
> +  (interactive)
> +  (message "Applescript: Getting Acrobat page link...")
> +  (let* ((descriptor (as-get-acrobat-page-link))
> +         (components (split-string descriptor "::"))
> +         (path (car components))
> +         (title (nth 1 components))
> +         (page (nth 2 components))
> +         (label (nth 3 components))
> +         (link (concat "acrobat:" path "::" page))
> +         (description (concat title ", p." label))
> +         (org-link))
> +    (when (not (string= link ""))
> +      (setq org-link (org-make-link-string link description)))
> +    (kill-new org-link)
> +    org-link))

Could you reuse `org-mac-paste-applescript-links' for this? For that,
you need to add the "acrobat:" and the ", p." bits in the AppleScript
(as is done for Skim).

Best,

Alan

-- 
OpenPGP Key ID : 040D0A3B4ED2E5C7
Last week athmospheric CO₂ average (Updated September 6, 2015, Mauna Loa Obs.):
377.86 ppm

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 472 bytes --]

  reply	other threads:[~2015-09-09 14:11 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-09-09 10:42 [PATCH] org-mac-link.el: Handle links to/from Adobe Acrobat Dmitri Makarov
2015-09-09 14:11 ` Alan Schmitt [this message]
2015-09-09 15:59   ` Dmitri Makarov
2015-09-10  9:28     ` Alan Schmitt
2015-09-10  9:37       ` Dmitri Makarov
2015-09-10  9:57         ` Nicolas Goaziou
2015-09-10 10:26           ` Dmitri Makarov
2015-09-10 11:16             ` Alan Schmitt
  -- strict thread matches above, loose matches on Subject: below --
2015-06-24 11:43 Dmitri Makarov

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=m2d1xrznqp.fsf@charm-ecran.irisa.fr \
    --to=alan.schmitt@polytechnique.org \
    --cc=dmakarov@alumni.stanford.edu \
    --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 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).