emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] externals/eev e9996db 3/4: Added a section about `find-pdf-links'


From: Stefan Monnier
Subject: [elpa] externals/eev e9996db 3/4: Added a section about `find-pdf-links' to (find-eev-quick-intro).
Date: Mon, 10 Jun 2019 19:15:04 -0400 (EDT)

branch: externals/eev
commit e9996db94bb9a2864cb50f8a2a1d8a6ecc539098
Author: Eduardo Ochs <address@hidden>
Commit: Eduardo Ochs <address@hidden>

    Added a section about `find-pdf-links' to (find-eev-quick-intro).
---
 VERSION       |  4 ++--
 eev-elinks.el |  2 ++
 eev-intro.el  | 61 +++++++++++++++++++++++++++++++++++++++++++----------------
 3 files changed, 49 insertions(+), 18 deletions(-)

diff --git a/VERSION b/VERSION
index e5fa07e..d4bd991 100644
--- a/VERSION
+++ b/VERSION
@@ -1,2 +1,2 @@
-Mon Jun 10 05:19:24 GMT 2019
-Mon Jun 10 02:19:24 -03 2019
+Mon Jun 10 05:57:06 GMT 2019
+Mon Jun 10 02:57:06 -03 2019
diff --git a/eev-elinks.el b/eev-elinks.el
index 4c96b7c..0c399be 100644
--- a/eev-elinks.el
+++ b/eev-elinks.el
@@ -967,6 +967,8 @@ See: (find-pdf-like-intro)
     (apply 'find-elinks `(
       (find-pdflike-page-links ,page ,bufname ,offset ,@rest)
       (find-efunction 'find-pdflike-page-links)
+      (find-eev-quick-intro "10.4. Generating short hyperlinks to PDFs")
+      (find-eev-quick-intro "11.1. `find-pdf-links'")
       ""
       ,@(ee-pdflike-page-links page bufname offset)
       ) rest)
diff --git a/eev-intro.el b/eev-intro.el
index 621f878..6ed227e 100644
--- a/eev-intro.el
+++ b/eev-intro.el
@@ -19,7 +19,7 @@
 ;;
 ;; Author:     Eduardo Ochs <address@hidden>
 ;; Maintainer: Eduardo Ochs <address@hidden>
-;; Version:    2019jun05
+;; Version:    2019jun10
 ;; Keywords:   e-scripts
 ;;
 ;; Latest version: <http://angg.twu.net/eev-current/eev-intro.el>
@@ -1572,11 +1572,10 @@ trick uses the second link. Run this,
 
 mark a piece of text in it - for example, the \"no punishment\"
 in the end of the first paragraph - and copy it to the kill ring
-with `M-w'. Then type `M-h M-p' (`find-pdflike-page-links'); note
-that `M-h M-h' won't work here because `find-here-links' is not
-smart enough to detect that we are on a PDF converted to text.
-You will get an \"*Elisp hyperlinks*\" buffer that contains these
-links:
+with `M-w'. Then type `M-h M-p' (`find-pdf-links'); note that
+`M-h M-h' won't work here because `find-here-links' is not smart
+enough to detect that we are on a PDF converted to text. You will
+get an \"*Elisp hyperlinks*\" buffer that contains these links:
 
   # (find-livesofanimalspage 24)
   # (find-livesofanimalstext 24)
@@ -1596,6 +1595,7 @@ Remember that we called `code-pdf-page' and 
`code-pdf-text' as:
 The extra argument \"-110\" to `code-pdf-text' tells `M-h M-p' to
 used \"-110\" as the offset.
 
+See the section 11.1 for more on `M-h M-p'.
 
 
 
@@ -1630,20 +1630,49 @@ We will only discuss here the other way.
 
 
 
-11.1. `find-code-c-d-links'
----------------------------
+11.1. `find-pdf-links'
+----------------------
+Let's call a pair of lines like this,
+
+  (code-pdf-page \"asy\" 
\"/usr/local/texlive/2019/texmf-dist/doc/asymptote/asymptote.pdf\")
+  (code-pdf-text \"asy\" 
\"/usr/local/texlive/2019/texmf-dist/doc/asymptote/asymptote.pdf\")
 
-11.2. `find-code-pdf-links'
----------------------------
-Let's call a pair of lines like the ones above, in which we have
-a call to `code-pdf-page' and a call to `code-pdf-text', both
-pointing to the same PDF file, a \"code-pdf pair\". One quick way
-to generate a code-pdf pair is to visit the directory where your
-PDF file is, put the point on the line of the PDF, and run `M-x
-find-code-pdf-links'. Try it here:
+in which we have a call to `code-pdf-page' and a call to
+`code-pdf-text', both pointing to the same PDF file, a \"code-pdf
+pair\". One quick way to generate a code-pdf pair is to visit the
+directory where your PDF file is, put the point on the line of
+the PDF, and type `M-h M-p' (`find-pdf-links'). Try it here:
 
   (find-fline \"$S/https/tannerlectures.utah.edu/_documents/a-to-z/c/\")
 
+The exact action of `M-h M-p' depends on the major mode. If
+you're in dired mode then it supposes that you want links to the
+PDF on the current line, including a code-pdf pair, and it runs
+`find-code-pdf-links'. The first line of the buffer will be
+something like:
+
+  ;; (find-code-pdf-links 
\"$S/https/tannerlectures.utah.edu/_documents/a-to-z/c/Coetzee99.pdf\" \"{c}\")
+
+where the \"{c}\" is something that you have to adjust by hand
+and then execute the first line again to regenerate the buffer -
+like in `find-latex-links', that was described in section 7.5.
+
+If you're not it dired mode then `find-pdf-links' supposes that
+you're in a buffer generated by a short hyperlink to the text of
+a PDF file, and it runs the function `find-pdflike-page-links'.
+Try `M-h M-p' in the buffer generated by the sexp below:
+
+  (find-livesofanimalstext (+ -110 134))
+
+`find-pdflike-page-links' is not very smart. It has to guess the
+stem (\"livesofanimals\"), the offset (-110), the current page,
+and the string that you want to use in the pos-spec. It takes the
+stem and the offset from the global variables `ee-page-c' and
+`ee-page-offset', that probably were set by the last call to a
+function of the form `find-___text', and it guesses the current
+page by counting formfeeds, and guesses that the pos-spec string
+is in the top of the kill ring.
+
 
 
 



reply via email to

[Prev in Thread] Current Thread [Next in Thread]