Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
P
poppler
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 613
    • Issues 613
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 40
    • Merge Requests 40
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Packages & Registries
    • Packages & Registries
    • Container Registry
  • Analytics
    • Analytics
    • CI / CD
    • Repository
    • Value Stream
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • poppler
  • poppler
  • Issues
  • #76

Closed
Open
Opened Dec 21, 2016 by Bugzilla Migration User@bugzilla-migration

do not create duplicates of the same objects

Submitted by Trevor Spiteri

Assigned to poppler-bugs

Link to original bug (#99167)

Description

Created attachment 128605 The pdf document used in the example output.

When I separate a pdf into pages and then unite it again, fonts are duplicated. The attached document a.pdf uses a regular font in page 1, and in page 2 it uses the same regular font as well as a bold font. After separating and uniting, the united file contains two copies of the regular font. It would be nice if the tools removed the identical duplicated fonts.

Details of an example are included below. Note that in the output to pdffonts, I removed the following columns which were common to all fonts:

type encoding emb sub uni


Type 1 Custom yes yes no

File sizes and font information:

$ wc -c a.pdf; pdffonts a.pdf 14244 a.pdf name object ID


ULOTVD+NimbusRomNo9L-Regu 4 0 EBGCWF+NimbusRomNo9L-Medi 10 0

$ pdfseparate a.pdf b%d.pdf

$ wc -c b1.pdf; pdffonts b1.pdf 8404 b1.pdf name object ID


ULOTVD+NimbusRomNo9L-Regu 4 0

$ wc -c b2.pdf; pdffonts b2.pdf 15120 b2.pdf name object ID


ULOTVD+NimbusRomNo9L-Regu 4 0 EBGCWF+NimbusRomNo9L-Medi 10 0

$ pdfunite b1.pdf b2.pdf c.pdf

$ wc -c c.pdf; pdffonts c.pdf 22916 c.pdf name object ID


ULOTVD+NimbusRomNo9L-Regu 4 0 ULOTVD+NimbusRomNo9L-Regu 23 0 EBGCWF+NimbusRomNo9L-Medi 29 0

$ pdfseparate c.pdf d%d.pdf

$ wc -c d1.pdf; pdffonts d1.pdf 8061 d1.pdf name object ID


ULOTVD+NimbusRomNo9L-Regu 4 0

$ wc -c d2.pdf; pdffonts d2.pdf 14778 d2.pdf name object ID


ULOTVD+NimbusRomNo9L-Regu 23 0 EBGCWF+NimbusRomNo9L-Medi 29 0

$ pdfunite d1.pdf d2.pdf e.pdf

$ wc -c e.pdf; pdffonts e.pdf 23296 e.pdf name object ID


ULOTVD+NimbusRomNo9L-Regu 4 0 ULOTVD+NimbusRomNo9L-Regu 42 0 EBGCWF+NimbusRomNo9L-Medi 48 0

Attachment 128605, "The pdf document used in the example output.":
a.pdf

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking
None
Due date
None
Reference: poppler/poppler#76