Modify ↓
Opened 16 years ago
Last modified 6 years ago
#5163 new defect
htmldoc needs --jpeg to create usable size pdfs
Reported by: | anonymous | Owned by: | |
---|---|---|---|
Priority: | normal | Component: | TracWikiToPdfPlugin |
Severity: | normal | Keywords: | |
Cc: | felix@… | Trac Release: | 0.11 |
Description
I have a trac Page with 4 images.
[root@s100 ~]# ls -l /srv/trac/psuc/attachments/wiki/BilderDoku/ -h total 728K -rw-r--r-- 1 apache apache 191K 2009-04-29 20:06 2009042....jpg -rw-r--r-- 1 apache apache 175K 2009-04-29 20:12 20090429...f.jpg -rw-r--r-- 1 apache apache 162K 2009-04-29 20:05 20090429...t.jpg -rw-r--r-- 1 apache apache 179K 2009-04-29 20:04 verf...keit.jpg
Exporting this page as pdf results in a 17MB pdf.
I reproduced this on the commandline.
[root@s100 ~]# htmldoc test.html --jpeg=90 --format pdf14 --webpage -f jpeg.pdf PAGES: 4 BYTES: 1217910 [root@s100 ~]# htmldoc test.html --format pdf14 --webpage -f raw.pdf PAGES: 4 BYTES: 17382511 [root@s100 ~]# ll jpeg.pdf raw.pdf -h -rw-r--r-- 1 root root 1.2M 2009-04-30 12:52 jpeg.pdf -rw-r--r-- 1 root root 17M 2009-04-30 12:54 raw.pdf
I'd suggest to add the --jpeg option by default.
Attachments (0)
Change History (3)
comment:1 Changed 16 years ago by
comment:2 Changed 16 years ago by
Eish, This is not how my HTMLDoc works... If you don't specify --jpeg it includes the image files vanilla.
You can add:
jpeg =
to the wikitopdf-admin and wikitopdf-page sections in your trac.ini file. This will then add a --jpeg parameter.
or in your sample's case add:
jpeg = 90
comment:3 Changed 6 years ago by
Owner: | Diorgenes Felipe Grzesiuk deleted |
---|
Note: See
TracTickets for help on using
tickets.
I am happy with the following patch.