Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.user > #191271

Re: How to create a PDF-Printer from the command line

From David Wright <deblis@lionunicorn.co.uk>
Newsgroups linux.debian.user
Subject Re: How to create a PDF-Printer from the command line
Date 2018-01-18 17:00 +0100
Message-ID <v9kLE-7y5-5@gated-at.bofh.it> (permalink)
References (5 earlier) <v93B8-4zG-19@gated-at.bofh.it> <v93KN-4D5-5@gated-at.bofh.it> <v93KN-4D5-3@gated-at.bofh.it> <v9eZz-3Iw-3@gated-at.bofh.it> <v9hNL-5HD-11@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Thu 18 Jan 2018 at 12:40:10 (+0000), Brian wrote:
> On Thu 18 Jan 2018 at 09:44:51 +0000, Curt wrote:
> 
> > On 2018-01-17, Chris Ramsden <chris.ramsden@gmail.com> wrote:
> > > On 17/01/18 21:42, Ben Caradoc-Davies wrote:
> > >> On 18/01/18 10:37, Joel Wirāmu Pauling wrote:
> > >>> Works fine for txt, although as it rasterizes things it's not going to be
> > >>> optimized for size.
> > >>
> > >> Yes, typically, but for large fonts and low resolution outputs with few pages, rasterised pages may be smaller.
> > >>
> > >> Kind regards,
> > >>
> > > If I feed it a text file, it gives me an error:
> > >
> > > convert: improper image header `self_spam.txt' @ error/txt.c/ReadTXTImage/439.
> > >
> > > What's the trick to making it work with a text file as input?
> > 
> > I ran into the same error (fixed in later versions, apparently, though I
> > am in the dark as to what version you are using and how late is later).
> > 
> > I read an explicit 
> > 
> > convert text:mytext.txt mytext.pdf
> > 
> > works.
> > 
> > But it doesn't work here.
> > 
> > Also: all roads lead to Rome, but some may be more suitable for wagons than others.
> 
> As is obvious, I hadn't realised imagemagick converted text to pdf.
> However, the command you give works for me on stable and unstable.
> It gives unsearchable PDFs.

It serves more as a reminder of convert's way of specifying the
contents of the file than much else. Adding -font unicode also dredges
up the awful-looking ttf font. But given that the PDF produced is so
blurry, that font is probably no worse looking than any other.

The PDF is unsearchable because it's really just an image wrapped in
a PDF container (like the output from some scanners). Being an image,
there's no concept of wrapping long lines either.

I can't really be bothered to figure out what's missing on those
systems of mine that say:

$ convert -font unifont text:/etc/default/grub /tmp/grubby.pdf
convert: not authorized `/etc/default/grub' @ error/constitute.c/ReadImage/412.
convert: no images defined `/tmp/grubby.pdf' @ error/convert.c/ConvertImageCommand/3210.
$ 

Cheers,
David.

Back to linux.debian.user | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

How to create a PDF-Printer from the command line Jason <electron@emypeople.net> - 2018-01-06 04:20 +0100
  Re: How to create a PDF-Printer from the command line Gene Heskett <gheskett@shentel.net> - 2018-01-06 05:50 +0100
  Re: How to create a PDF-Printer from the command line john doe <johndoe65534@mail.com> - 2018-01-06 06:00 +0100
    Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-06 21:20 +0100
      Re: How to create a PDF-Printer from the command line john doe <johndoe65534@mail.com> - 2018-01-06 22:00 +0100
        Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-07 21:10 +0100
          Re: How to create a PDF-Printer from the command line john doe <johndoe65534@mail.com> - 2018-01-07 21:50 +0100
            Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-07 22:00 +0100
              Re: How to create a PDF-Printer from the command line john doe <johndoe65534@mail.com> - 2018-01-08 11:50 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-08 12:30 +0100
      Re: How to create a PDF-Printer from the command line Curt <curty@free.fr> - 2018-01-06 22:10 +0100
        Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-07 01:20 +0100
          Re: How to create a PDF-Printer from the command line Erik Christiansen <dvalin@internode.on.net> - 2018-01-07 03:30 +0100
            Re: How to create a PDF-Printer from the command line Erik Christiansen <dvalin@internode.on.net> - 2018-01-07 03:50 +0100
          Re: How to create a PDF-Printer from the command line Curt <curty@free.fr> - 2018-01-07 12:10 +0100
            Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-07 13:40 +0100
            Re: How to create a PDF-Printer from the command line David Wright <deblis@lionunicorn.co.uk> - 2018-01-07 17:10 +0100
      Re: How to create a PDF-Printer from the command line davidson <davidson@freevolt.org> - 2018-01-09 07:30 +0100
        Re: How to create a PDF-Printer from the command line Ionel Mugurel Ciobîcă <I.M.Ciobica@upcmail.nl> - 2018-01-09 10:30 +0100
          Re: How to create a PDF-Printer from the command line <tomas@tuxteam.de> - 2018-01-09 10:40 +0100
          Re: How to create a PDF-Printer from the command line Curt <curty@free.fr> - 2018-01-09 11:30 +0100
            Re: How to create a PDF-Printer from the command line Curt <curty@free.fr> - 2018-01-09 14:10 +0100
              Re: How to create a PDF-Printer from the command line David Wright <deblis@lionunicorn.co.uk> - 2018-01-09 14:40 +0100
                Re: How to create a PDF-Printer from the command line Ionel Mugurel Ciobîcă <I.M.Ciobica@upcmail.nl> - 2018-01-09 16:10 +0100
                Re: How to create a PDF-Printer from the command line Curt <curty@free.fr> - 2018-01-09 16:40 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-09 20:20 +0100
                Re: How to create a PDF-Printer from the command line Curt <curty@free.fr> - 2018-01-09 20:50 +0100
                Re: How to create a PDF-Printer from the command line David Wright <deblis@lionunicorn.co.uk> - 2018-01-09 21:10 +0100
                Re: How to create a PDF-Printer from the command line <tomas@tuxteam.de> - 2018-01-09 23:30 +0100
                Re: How to create a PDF-Printer from the command line David Wright <deblis@lionunicorn.co.uk> - 2018-01-10 00:10 +0100
                Re: How to create a PDF-Printer from the command line <tomas@tuxteam.de> - 2018-01-10 00:50 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-09 21:40 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-09 21:50 +0100
                Re: How to create a PDF-Printer from the command line Curt <curty@free.fr> - 2018-01-09 22:00 +0100
                Re: How to create a PDF-Printer from the command line David Wright <deblis@lionunicorn.co.uk> - 2018-01-09 23:40 +0100
                Re: How to create a PDF-Printer from the command line Curt <curty@free.fr> - 2018-01-10 10:10 +0100
                Re: How to create a PDF-Printer from the command line <tomas@tuxteam.de> - 2018-01-10 10:50 +0100
                Re: How to create a PDF-Printer from the command line Ionel Mugurel Ciobîcă <I.M.Ciobica@upcmail.nl> - 2018-01-10 14:20 +0100
                Re: How to create a PDF-Printer from the command line David Wright <deblis@lionunicorn.co.uk> - 2018-01-10 16:40 +0100
                Re: How to create a PDF-Printer from the command line <tomas@tuxteam.de> - 2018-01-10 17:20 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-10 20:20 +0100
                Re: How to create a PDF-Printer from the command line <tomas@tuxteam.de> - 2018-01-10 21:10 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-17 19:30 +0100
                Re: How to create a PDF-Printer from the command line <tomas@tuxteam.de> - 2018-01-17 21:10 +0100
                Re: How to create a PDF-Printer from the command line Joel Wirāmu Pauling <joel@aenertia.net> - 2018-01-17 22:20 +0100
                Re: How to create a PDF-Printer from the command line Joel Wirāmu Pauling <joel@aenertia.net> - 2018-01-17 22:40 +0100
                Re: How to create a PDF-Printer from the command line Chris Ramsden <chris.ramsden@gmail.com> - 2018-01-17 22:50 +0100
                Re: How to create a PDF-Printer from the command line Dan Ritter <dsr@randomstring.org> - 2018-01-17 23:10 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-18 00:00 +0100
                Re: How to create a PDF-Printer from the command line Curt <curty@free.fr> - 2018-01-18 10:50 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-18 13:50 +0100
                Re: How to create a PDF-Printer from the command line David Wright <deblis@lionunicorn.co.uk> - 2018-01-18 17:00 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-18 20:20 +0100
                Re: How to create a PDF-Printer from the command line Ben Caradoc-Davies <ben@transient.nz> - 2018-01-17 22:50 +0100
                Re: How to create a PDF-Printer from the command line Ben Caradoc-Davies <ben@transient.nz> - 2018-01-17 22:40 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-18 00:00 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-17 23:50 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-10 11:40 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-10 20:30 +0100
              Re: How to create a PDF-Printer from the command line Ionel Mugurel Ciobîcă <I.M.Ciobica@upcmail.nl> - 2018-01-09 15:00 +0100
  Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-06 16:30 +0100
    Re: How to create a PDF-Printer from the command line Jason <electron@emypeople.net> - 2018-01-07 03:50 +0100
      Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-07 11:20 +0100
        Re: How to create a PDF-Printer from the command line rhkramer@gmail.com - 2018-01-07 13:50 +0100
          Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-07 19:20 +0100
            Re: How to create a PDF-Printer from the command line rhkramer@gmail.com - 2018-01-07 21:30 +0100
              Re: How to create a PDF-Printer from the command line rhkramer@gmail.com - 2018-01-08 13:30 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-08 20:00 +0100
                Re: How to create a PDF-Printer from the command line rhkramer@gmail.com - 2018-01-08 20:20 +0100
            Re: How to create a PDF-Printer from the command line David Wright <deblis@lionunicorn.co.uk> - 2018-01-08 04:20 +0100
              Re: How to create a PDF-Printer from the command line Curt <curty@free.fr> - 2018-01-08 10:40 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-08 19:20 +0100
                Re: How to create a PDF-Printer from the command line David Wright <deblis@lionunicorn.co.uk> - 2018-01-09 02:30 +0100
                Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-10 01:40 +0100
              Re: How to create a PDF-Printer from the command line Brian <ad44@cityscape.co.uk> - 2018-01-08 20:20 +0100
        [SOLVED]Re: How to create a PDF-Printer from the command line Jason <electron@emypeople.net> - 2018-01-09 04:20 +0100

csiph-web