Maker Pro
Maker Pro

OT: Copying text from a PDF

T

Terry Pinnell

Rich Grise said:
Barely a day goes by that Slackware doesn't pleasantly surprise me!
It seems I got xpdf along with it, and lo and behold:
------------------------
30A, 50V, 0.040 Ohm, N-Channel Power
MOSFET
This is an N-Channel enhancement mode silicon gate power field effect
transistor designed for applications such as switching regulators,
switching converters, motor drivers, relay drivers and drivers for high
power bipolar switching transistors requiring high speed and low gate
drive power. This type can be operated directly from integrated circuits.
Formerly developmental type TA9771.
Ordering Information
PART NUMBER PACKAGE BRAND
BUZ11 TO-220AB BUZ11
NOTE: When ordering, use the entire part number.

Features
· 30A, 50V
· rDS(ON) = 0.040
· SOA is Power Dissipation Limited
· Nanosecond Switching Speeds
· Linear Transfer Characteristics
· High Input Impedance
· Majority Carrier Device
· Related Literature
- TB334 "Guidelines for Soldering Surface Mount
Components to PC Boards"
Symbol
D
G
S

Thanks for the text paste.

Must say I'm a bit lost on that site
http://www.foolabs.com/xpdf/home.html
Can you help me locate specifically the PDF to text converter please?
I'm wallowing in files with off-putting and Windows-alien names like
't1lib-1.3.tar.gz'.
 
R

Rich Grise

Thanks for the text paste.

Must say I'm a bit lost on that site
http://www.foolabs.com/xpdf/home.html
Can you help me locate specifically the PDF to text converter please?
I'm wallowing in files with off-putting and Windows-alien names like
't1lib-1.3.tar.gz'.

Click "Download" to get to http://www.foolabs.com/xpdf/download.html ,
then scroll down to "Precompiled binaries" and it's probably either
xpdf-3.00pl3-win32.zip (1142558 bytes) for Win32 or
xpdf-3.00pl3-dos6.zip (1775202 bytes) for DOS.

Here's a chunk of the README for the win32 version, copied without
permission:
--------<begin excerpt>----------
Xpdf
====

version 3.00
2004-jan-22

The Xpdf software and documentation are
copyright 1996-2004 Glyph & Cog, LLC.

Email: [email protected]
WWW: http://www.foolabs.com/xpdf/

The PDF data structures, operators, and specification are
copyright 1985-2003 Adobe Systems Inc.


What is Xpdf?
-------------

Xpdf is an open source viewer for Portable Document Format (PDF)
files. (These are also sometimes also called 'Acrobat' files, from
the name of Adobe's PDF software.) The Xpdf project also includes a
PDF text extractor, PDF-to-PostScript converter, and various other
utilities.

Xpdf runs under the X Window System on UNIX, VMS, and OS/2. The non-X
components (pdftops, pdftotext, etc.) also run on Win32 systems and
should run on pretty much any system with a decent C++ compiler.

Xpdf is designed to be small and efficient. It can use Type 1 or
TrueType fonts.


Distribution
------------

Xpdf is licensed under the GNU General Public License (GPL), version
2. In my opinion, the GPL is a convoluted, confusing, ambiguous mess.
But it's also pervasive, and I'm sick of arguing. And even if it is
confusing, the basic idea is good.

In order to cut down on the confusion a little bit, here are some
informal clarifications:

- I don't mind if you redistribute Xpdf in source and/or binary form,
as long as you include all of the documentation: README, man pages
(or help files), and COPYING. (Note that the README file contains a
pointer to a web page with the source code.)

- Selling a CD-ROM that contains Xpdf is fine with me, as long as it
includes the documentation. I wouldn't mind receiving a sample
copy, but it's not necessary.

- If you make useful changes to Xpdf, please make the source code
available -- post it on a web site, email it to me, whatever.

If you're interested in commercial licensing, please see the Glyph &
Cog web site:

http://www.glyphandcog.com/


Compatibility
-------------

Xpdf is developed and tested on a Linux 2.4 x86 system.

In addition, it has been compiled by others on Solaris, AIX, HP-UX,
Digital Unix, Irix, and numerous other Unix implementations, as well
as VMS and OS/2. It should work on pretty much any system which runs
X11 and has Unix-like libraries. You'll need ANSI C++ and C compilers
to compile it.

The non-X components of Xpdf (pdftops, pdftotext, pdfinfo, pdffonts,
pdftoppm, and pdfimages) can also be compiled on Win32 systems. See
the Xpdf web page for details.

If you compile Xpdf for a system not listed on the web page, please
let me know. If you're willing to make your binary available by ftp
or on the web, I'll be happy to add a link from the Xpdf web page. I
have decided not to host any binaries I didn't compile myself (for
disk space and support reasons).

If you can't get Xpdf to compile on your system, send me email and
I'll try to help.

Xpdf has been ported to the Acorn, Amiga, BeOS, and EPOC. See the
Xpdf web page for links.


Getting Xpdf
------------

The latest version is available from:

http://www.foolabs.com/xpdf/

or:

ftp://ftp.foolabs.com/pub/xpdf/

Source code and several precompiled executables are available.

Announcements of new versions are posted to several newsgroups
(comp.text.pdf, comp.os.linux.announce, and others) and emailed to a
list of people. If you'd like to receive email notification of new
versions, just let me know.


Running Xpdf
------------

To run xpdf, simply type:

xpdf file.pdf

To generate a PostScript file, hit the "print" button in xpdf, or run
pdftops:

pdftops file.pdf

To generate a plain text file, run pdftotext:

pdftotext file.pdf

There are four additional utilities (which are fully described in
their man pages):

pdfinfo -- dumps a PDF file's Info dictionary (plus some other
useful information)
pdffonts -- lists the fonts used in a PDF file along with various
information for each font
pdftoppm -- converts a PDF file to a series of PPM/PGM/PBM-format
bitmaps
pdfimages -- extracts the images from a PDF file

Command line options and many other details are described in the man
pages (xpdf.1, etc.) and the VMS help files (xpdf.hlp, etc.).
-------<end excerpt>-----

Good Luck!
Rich
 
T

Terry Pinnell

Rich Grise said:
Click "Download" to get to http://www.foolabs.com/xpdf/download.html ,
then scroll down to "Precompiled binaries" and it's probably either
xpdf-3.00pl3-win32.zip (1142558 bytes) for Win32 or
xpdf-3.00pl3-dos6.zip (1775202 bytes) for DOS.
[snip useful extract]
Good Luck!
Rich

Thanks, got it, and it works a treat. Particularly impressed with its
speed. Glad you introduced me to it.

Mind you, I'm never too keen on leaving the GUI and getting into a DOS
Command Prompt window <g>. Seem to be two ways of doing it:

1) Open the DOS window in the XPDF program folder and then (assuming
defaults are OK) enter:

pdftotext "D:\long path\probably with some blanks\so needs
quotes\filename.pdf"


2) Open the DOS window in the folder containing the PDF file and
enter:

"D:\Program Files\xpdf-3.00pl3\pdftotext" filename.pdf

Am I right? Any other methods?
 
Terry Pinnell said:
Rich Grise said:

Glad you introduced me to it.
Ahem...

Am I right? Any other methods?

3 and 4 let you just type "pdftotext" no matter what directory you're
in:

3) Put "D:\Program Files\xpdf-3.00pl3\" in your $PATH.

4) Copy pdftotext.exe to c:\windows or c:\winnt (which are already in
your $PATH).

5) Install the "Command Prompt Here" powertoy (Google it) which will
allow you to navigate to the folder in Exploder, then get a command
prompt starting in that directory.

6) format c:, then install Linux or FreeBSD. Caution: this process may
lose data.

Matt Roberds
 
T

Terry Pinnell

Terry Pinnell said:
Rich Grise said:

Glad you introduced me to it.

Ahem...

Sorry said:
3 and 4 let you just type "pdftotext" no matter what directory you're
in:

3) Put "D:\Program Files\xpdf-3.00pl3\" in your $PATH.

Presumably that would mean adding a PATH statement as the sole entry
in an autoexec.bat file in C:\? It seems I long ago got rid of that
file, as I thought it was an archaism now frowned upon?
4) Copy pdftotext.exe to c:\windows or c:\winnt (which are already in
your $PATH).

That looks great. Will try later today.
5) Install the "Command Prompt Here" powertoy (Google it) which will
allow you to navigate to the folder in Exploder, then get a command
prompt starting in that directory.

Yep, got that already thanks. That's what I used earlier, but then
needs pasting in the filename and putting quotes around it.
6) format c:, then install Linux or FreeBSD. Caution: this process may
lose data.

Think I'll pass on that for now, thanks!

Ideally, I'd like to be able to r-click the PDF filename, wherever it
is, and choose PDFtoTEXT from a context menu. Is that possible somehow
please? Even maybe deploying a keyboard macro utility to enter some
keystrokes at the appropriate stage?
 
B

budgie

Terry Pinnell said:
Rich Grise said:

Glad you introduced me to it.
Ahem...

Am I right? Any other methods?

3 and 4 let you just type "pdftotext" no matter what directory you're
in:

3) Put "D:\Program Files\xpdf-3.00pl3\" in your $PATH.

4) Copy pdftotext.exe to c:\windows or c:\winnt (which are already in
your $PATH).

5) Install the "Command Prompt Here" powertoy (Google it) which will
allow you to navigate to the folder in Exploder, then get a command
prompt starting in that directory.

6) format c:, then install Linux or FreeBSD. Caution: this process may
lose data.

Matt Roberds

As you seem familiar with the product, and to save me downloading and testing to
find out, would you consider it - or part of the suite - might work on the
following:

..pdf file, 100MB, all text (a large database snapshot printout)

Security settings of note:
.. Printing - fully allowed
.. Content copying or extraction - not allowed
.. Content accessibility enabled - allowed

I don't want to print 22930 pages and run them through the OCR machine :-(
 
Terry Pinnell said:
Presumably that would mean adding a PATH statement as the sole entry
in an autoexec.bat file in C:\? It seems I long ago got rid of that
file, as I thought it was an archaism now frowned upon?

Putting it in autoexec.bat might work. You can also set environment
variables one one of the tabs in Control Panel->System. I don't
remember which one, and it might be hiding behind an "advanced" button.
Think I'll pass on that for now, thanks!

Get a cheap second computer and try it. Alternatively, download Knoppix,
which runs a Linux system entirely from CD and doesn't touch your hard
drive, and try it out on your main computer.
Ideally, I'd like to be able to r-click the PDF filename, wherever it
is, and choose PDFtoTEXT from a context menu. Is that possible somehow
please?

I don't know. Googling "command prompt here" yielded
http://www.petri.co.il/add_command_prompt_here_shortcut_to_windows_explorer.htm
which describes how to manually add things to the context menu.

Matt Roberds
 
R

Rich Grise

Rich Grise said:
Click "Download" to get to http://www.foolabs.com/xpdf/download.html ,
then scroll down to "Precompiled binaries" and it's probably either
xpdf-3.00pl3-win32.zip (1142558 bytes) for Win32 or
xpdf-3.00pl3-dos6.zip (1775202 bytes) for DOS.
[snip useful extract]

Thanks, got it, and it works a treat. Particularly impressed with its
speed. Glad you introduced me to it.

Actually, I don't deserve credit for it at all - it was someone else,
just up-thread a bit ... Matt Roberds said:
Mind you, I'm never too keen on leaving the GUI and getting into a DOS
Command Prompt window <g>. Seem to be two ways of doing it:

1) Open the DOS window in the XPDF program folder and then (assuming
defaults are OK) enter:

pdftotext "D:\long path\probably with some blanks\so needs
quotes\filename.pdf"

2) Open the DOS window in the folder containing the PDF file and
enter:

"D:\Program Files\xpdf-3.00pl3\pdftotext" filename.pdf

Am I right? Any other methods?

Danged if I know. I'm using Linux, so I just open a console window or
a one-line command line ("Run Command" in Kde) and type "xpdf filename.pdf".
You could probably do that with Doze Start/Run... (type command as above).
I can open xpdf all by itself, but it seems to not have any menus - they
seem to have put their programming effort into actually getting the job
done. :) I'm sure I could make it more automatic by tweaking my menus
and my file browser and stuff, but for the number of times I need to
actually copy/paste text from a pdf, it's not worth the effort.

You do know that if you have your folder options set to "display full
path in address bar" in windows explorer, that you can copy and paste the
full path without typing the whole dang thing?

Cheers!
Rich
 
R

Rich Grise

On Fri, 03 Jun 2005 21:42:40 +0800, budgie wrote:
[about xpdf ]
As you seem familiar with the product, and to save me downloading and testing to
find out, would you consider it - or part of the suite - might work on the
following:

.pdf file, 100MB, all text (a large database snapshot printout)

Security settings of note:
. Printing - fully allowed
. Content copying or extraction - not allowed
. Content accessibility enabled - allowed

I don't want to print 22930 pages and run them through the OCR machine :-(

Well, if you can't capture the page as a graphic, you could do a screen
snap; at least that way you wouldn't have to print it to paper - just do
the OCR on the graphic.

But I do admit I'm just guessing here.

Good Luck!
Rich
 
T

Terry Pinnell

Rich Grise said:
Rich Grise said:
Click "Download" to get to http://www.foolabs.com/xpdf/download.html ,
then scroll down to "Precompiled binaries" and it's probably either
xpdf-3.00pl3-win32.zip (1142558 bytes) for Win32 or
xpdf-3.00pl3-dos6.zip (1775202 bytes) for DOS.
[snip useful extract]

Thanks, got it, and it works a treat. Particularly impressed with its
speed. Glad you introduced me to it.

Actually, I don't deserve credit for it at all - it was someone else,
just up-thread a bit ... Matt Roberds, in <l9dne.38478$Gp.36280@fed1read04>.

Yes, I've duly apologised to Matt!
Danged if I know. I'm using Linux, so I just open a console window or
a one-line command line ("Run Command" in Kde) and type "xpdf filename.pdf".
You could probably do that with Doze Start/Run... (type command as above).
I can open xpdf all by itself, but it seems to not have any menus - they
seem to have put their programming effort into actually getting the job
done. :) I'm sure I could make it more automatic by tweaking my menus
and my file browser and stuff, but for the number of times I need to
actually copy/paste text from a pdf, it's not worth the effort.

You do know that if you have your folder options set to "display full
path in address bar" in windows explorer, that you can copy and paste the
full path without typing the whole dang thing?

I usually use R-click>Send To>Clipboard As Name. It's a pity that
'DOS' (more accurately WinXP Command Prompt) doesn't accept names with
blanks, necessitating quotes (or use of the old 8-character names).
 
T

Ted Edwards

budgie said:
Terry Pinnell said:
Click "Download" to get to http://www.foolabs.com/xpdf/download.html ,
[...]

Glad you introduced me to it.
Ahem...


Am I right? Any other methods?

3 and 4 let you just type "pdftotext" no matter what directory you're
in:

3) Put "D:\Program Files\xpdf-3.00pl3\" in your $PATH.

4) Copy pdftotext.exe to c:\windows or c:\winnt (which are already in
your $PATH).

5) Install the "Command Prompt Here" powertoy (Google it) which will
allow you to navigate to the folder in Exploder, then get a command
prompt starting in that directory.

6) format c:, then install Linux or FreeBSD. Caution: this process may
lose data.

Matt Roberds


As you seem familiar with the product, and to save me downloading and testing to
find out, would you consider it - or part of the suite - might work on the
following:

.pdf file, 100MB, all text (a large database snapshot printout)

Security settings of note:
. Printing - fully allowed
. Content copying or extraction - not allowed
. Content accessibility enabled - allowed

I don't want to print 22930 pages and run them through the OCR machine :-(

Elsewhere I suggested creating a virtual postscript printer. I have
done this myself. _Anything_ that will let me print can be directed to
that printer and thus to a file. It can then converted with Ghost
script to other forms.

Ted
 
B

budgie

budgie said:
Click "Download" to get to http://www.foolabs.com/xpdf/download.html ,
[...]

Glad you introduced me to it.

Ahem...


Am I right? Any other methods?

3 and 4 let you just type "pdftotext" no matter what directory you're
in:

3) Put "D:\Program Files\xpdf-3.00pl3\" in your $PATH.

4) Copy pdftotext.exe to c:\windows or c:\winnt (which are already in
your $PATH).

5) Install the "Command Prompt Here" powertoy (Google it) which will
allow you to navigate to the folder in Exploder, then get a command
prompt starting in that directory.

6) format c:, then install Linux or FreeBSD. Caution: this process may
lose data.

Matt Roberds


As you seem familiar with the product, and to save me downloading and testing to
find out, would you consider it - or part of the suite - might work on the
following:

.pdf file, 100MB, all text (a large database snapshot printout)

Security settings of note:
. Printing - fully allowed
. Content copying or extraction - not allowed
. Content accessibility enabled - allowed

I don't want to print 22930 pages and run them through the OCR machine :-(

Elsewhere I suggested creating a virtual postscript printer. I have
done this myself. _Anything_ that will let me print can be directed to
that printer and thus to a file. It can then converted with Ghost
script to other forms.

Thanks. I will explore that route.
 
B

budgie

On Fri, 03 Jun 2005 21:42:40 +0800, budgie wrote:
[about xpdf ]
As you seem familiar with the product, and to save me downloading and testing to
find out, would you consider it - or part of the suite - might work on the
following:

.pdf file, 100MB, all text (a large database snapshot printout)

Security settings of note:
. Printing - fully allowed
. Content copying or extraction - not allowed
. Content accessibility enabled - allowed

I don't want to print 22930 pages and run them through the OCR machine :-(

Well, if you can't capture the page as a graphic, you could do a screen
snap; at least that way you wouldn't have to print it to paper - just do
the OCR on the graphic.

But I do admit I'm just guessing here.

Good Luck!

I'll need a lot more than luck, with 22930 pages :-(
 
J

JeffM

A Russion guy who wrote a PDF decryptor visited the Black Hat conference
and was arrested and *locked away* for violating the DMCA.
Even though the PDFs were plainly readable on the screen...
Clifford Heath

You got the nationality right in the Dmitry Sklyarov case
and he was held incommunicado in violation of the US Constitution,
but you got the format wrong:
http://www.google.com/search?q=from...+the-more-common-Portable-Document-Format-PDF

your legal system is truly stuffed.
Yeah. The Digital Millennium Copyright Act--DMCA (pronounced Dumb-ka)
is an incredibly stupid law.
Another part of it is struck down nearly monthly.
The wheels of justice grind slowly.
 
Top