unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: Tassilo Horn <tassilo@member.fsf.org>
To: help-gnu-emacs@gnu.org
Subject: Re: doc-view.el now allows searching
Date: Fri, 31 Aug 2007 22:16:40 +0200	[thread overview]
Message-ID: <87d4x3bgt3.fsf@baldur.tsdh.de> (raw)
In-Reply-To: mailman.123.1188587537.18990.help-gnu-emacs@gnu.org

Peter Dyballa <Peter_Dyballa@Web.DE> writes:

Hi Pete,

>> First, I thought it might have something to do with the size of the
>> pdf file or blank pages not being counted; however, searches of the
>> sicp.pdf book all seemed to produce correct results, so I'm not sure
>> why the search functionality doesn't work properly in some instances.
>
> The reason is probably that pdftotext is used with the -raw option,
> which deletes all empty lines leading white space. There is another
> option: -layout.

I use -raw here and don't have any problems.  Both versions have 528
occurences of ^J and that's what doc-view uses for counting pages.

> I think doc-view should check the number of pages first (pdfinfo
> <file> | grep -i pages | awk '{print $NF}'). If the number is greater
> 1 than -layout should be more appropriate ...

I don't like -layout, because then the context of the search matches
contain those whitespaces, too.

Maybe you use an older (buggy) pdftotext version?

> BTW, -layout is bit faster!

Not here:

heimdall@baldur ~/t/test> time pdftotext -raw practicalcommonlisp.pdf pcl.txtraw
21.11user 0.21system 0:21.60elapsed 98%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (0major+1135minor)pagefaults 0swaps
heimdall@baldur ~/t/test> time pdftotext -layout practicalcommonlisp.pdf pcl.txtlayout
21.84user 0.22system 0:22.34elapsed 98%CPU (0avgtext+0avgdata 0maxresident)k
0inputs+0outputs (0major+1400minor)pagefaults 0swaps

Bye,
Tassilo
-- 
Chuck Norris is the only man who has, literally, beaten the odds. With his fists. 

  parent reply	other threads:[~2007-08-31 20:16 UTC|newest]

Thread overview: 66+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <87wsvnfoyp.fsf@baldur.tsdh.de>
2007-08-22 20:28 ` doc-view.el --- View PDF/PostStript/DVI files in Emacs Reiner Steib
     [not found] ` <mailman.5132.1187810757.32220.gnu-emacs-sources@gnu.org>
     [not found]   ` <87zm0i6gq2.fsf@gnu.org>
     [not found]     ` <87d4xe6f6z.fsf@gnu.org>
     [not found]       ` <mailman.5174.1187854510.32220.gnu-emacs-sources@gnu.org>
     [not found]         ` <87zm0hq6kz.fsf@gnu.org>
     [not found]           ` <87hcmoc1tg.fsf@baldur.tsdh.de>
     [not found]             ` <m0ir7448cj.fsf@gmail.com>
     [not found]               ` <87d4xcoxyn.fsf@baldur.tsdh.de>
     [not found]                 ` <mailman.5331.1188079187.32220.gnu-emacs-sources@gnu.org>
2007-08-26  5:18                   ` Stefan Monnier
2007-08-26  6:34                     ` Bill Clementson
2007-08-26 13:49                     ` Martin Rubey
2007-08-26 16:55                       ` Tassilo Horn
     [not found]                 ` <m0ejhr46ol.fsf@gmail.com>
     [not found]                   ` <878x7ylhdk.fsf@baldur.tsdh.de>
     [not found]                     ` <m0y7fyjhwv.fsf@gmail.com>
     [not found]                       ` <87fy26gn55.fsf@baldur.tsdh.de>
     [not found]                         ` <m0tzqmjev6.fsf@gmail.com>
     [not found]                           ` <m04pilk28l.fsf@gmail.com>
     [not found]                             ` <874pil8f2m.fsf@baldur.tsdh.de>
2007-08-27 16:07                               ` Bill Clementson
     [not found]                                 ` <mailman.5478.1188334117.32220.help-gnu-emacs@gnu.org>
2007-08-29  7:06                                   ` Tassilo Horn
2007-08-29 14:41                                     ` Bill Clementson
     [not found]                                 ` <45D3FC07-69EB-471D-9502-BF208EAFBC79@Web.DE>
     [not found]                                   ` <m0bqcsejqq.fsf@gmail.com>
2007-08-29 23:42                                     ` Xavier Maillard
     [not found]                                     ` <mailman.36.1188431692.18990.help-gnu-emacs@gnu.org>
2007-08-30  7:16                                       ` Tassilo Horn
     [not found]                               ` <mailman.5410.1188230840.32220.help-gnu-emacs@gnu.org>
     [not found]                                 ` <87odgsjef5.fsf@baldur.tsdh.de>
     [not found]                                   ` <slrnfd7sum.ucr.joostkremers@j.kremers4.news.arnhem.chello.nl>
     [not found]                                     ` <87absbg53e.fsf@baldur.tsdh.de>
2007-08-29 16:25                                       ` Joost Kremers
2007-08-29 19:36                                         ` Tassilo Horn
2007-08-29 21:44                                           ` Joost Kremers
2007-08-30  7:14                                             ` Tassilo Horn
2007-08-30  9:37                                               ` Joost Kremers
2007-08-30 11:52                                                 ` doc-view.el now allows searching (was: doc-view.el --- View PDF/PostStript/DVI files in Emacs) Tassilo Horn
2007-08-30 17:25                                                   ` Bill Clementson
2007-08-30 22:02                                                     ` doc-view.el blog posting Bill Clementson
2007-09-02  1:00                                                       ` Xavier Maillard
2007-09-02  5:09                                                         ` Bill Clementson
2007-09-03  1:00                                                           ` Xavier Maillard
     [not found]                                                         ` <mailman.159.1188709811.18990.help-gnu-emacs@gnu.org>
2007-09-02  8:32                                                           ` Tassilo Horn
2007-09-03  0:41                                                             ` Bill Clementson
2007-09-03 11:15                                                               ` Peter Dyballa
2007-09-03 18:58                                                                 ` Bill Clementson
2007-09-03 21:00                                                                   ` Peter Dyballa
2007-09-03 23:04                                                                     ` Bill Clementson
2007-09-05  1:10                                                                       ` Bill Clementson
2007-09-03  1:00                                                             ` Xavier Maillard
     [not found]                                                     ` <mailman.77.1188511380.18990.help-gnu-emacs@gnu.org>
2007-08-31  7:47                                                       ` Tassilo Horn
2007-08-31  1:00                                                   ` doc-view.el now allows searching (was: doc-view.el --- View PDF/PostStript/DVI files in Emacs) Xavier Maillard
     [not found]                                                   ` <mailman.83.1188525985.18990.help-gnu-emacs@gnu.org>
2007-08-31  7:42                                                     ` doc-view.el now allows searching Tassilo Horn
2007-09-02  8:21                                                       ` Xavier Maillard
2007-08-31 11:55                                                   ` doc-view.el now allows searching (was: doc-view.el --- View PDF/PostStript/DVI files in Emacs) Joost Kremers
2007-08-31 14:42                                                     ` doc-view.el now allows searching Tassilo Horn
2007-08-31 15:27                                                       ` Joost Kremers
2007-08-31 15:38                                                       ` Joost Kremers
2007-08-31 17:15                                                         ` Tassilo Horn
     [not found]                                                   ` <mailman.72.1188494731.18990.help-gnu-emacs@gnu.org>
2007-08-31  7:55                                                     ` Tassilo Horn
2007-08-31 16:44                                                       ` Bill Clementson
2007-08-31 13:02                                                     ` Tassilo Horn
2007-08-31 16:38                                                       ` Bill Clementson
2007-08-31 19:06                                                         ` Peter Dyballa
2007-08-31 20:56                                                           ` Bill Clementson
     [not found]                                                         ` <mailman.123.1188587537.18990.help-gnu-emacs@gnu.org>
2007-08-31 20:16                                                           ` Tassilo Horn [this message]
     [not found]                                                       ` <mailman.117.1188578356.18990.help-gnu-emacs@gnu.org>
2007-08-31 17:46                                                         ` Tassilo Horn
2007-08-31 20:29                                                           ` Bill Clementson
     [not found]                                                           ` <mailman.124.1188592219.18990.help-gnu-emacs@gnu.org>
2007-08-31 21:54                                                             ` Tassilo Horn
2007-09-01  0:28                                                               ` Bill Clementson
     [not found]                                                               ` <mailman.128.1188606528.18990.help-gnu-emacs@gnu.org>
2007-09-01  8:32                                                                 ` Tassilo Horn
2007-09-01 17:45                                                                   ` Bill Clementson
     [not found]                                                                   ` <mailman.135.1188668772.18990.help-gnu-emacs@gnu.org>
2007-09-01 21:59                                                                     ` Tassilo Horn
2007-09-02  0:42                                                                       ` Bill Clementson
     [not found]                                                                       ` <mailman.146.1188693912.18990.help-gnu-emacs@gnu.org>
2007-09-02  8:58                                                                         ` Tassilo Horn
2007-09-03  0:30                                                                           ` Bill Clementson
2007-09-03  1:00                                                                           ` Xavier Maillard
     [not found]                                                                           ` <mailman.203.1188785343.18990.help-gnu-emacs@gnu.org>
2007-09-03 11:12                                                                             ` Tassilo Horn
2007-09-04  1:00                                                                               ` Xavier Maillard
2007-08-29 21:50                                           ` doc-view.el --- View PDF/PostStript/DVI files in Emacs Bill Clementson
     [not found]                                           ` <mailman.20.1188424257.18990.help-gnu-emacs@gnu.org>
2007-08-30  7:09                                             ` Tassilo Horn
2007-08-30  7:51                                               ` Tassilo Horn
2007-08-30 17:15                                               ` Daniel Jensen
2007-08-30 17:34                                                 ` Tassilo Horn
2007-08-29 23:42                                       ` Xavier Maillard
     [not found]                                       ` <mailman.35.1188431691.18990.help-gnu-emacs@gnu.org>
2007-08-30  0:14                                         ` Joost Kremers
2007-08-31  1:00                                           ` Xavier Maillard

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.gnu.org/software/emacs/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87d4x3bgt3.fsf@baldur.tsdh.de \
    --to=tassilo@member.fsf.org \
    --cc=help-gnu-emacs@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.
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).