Skip to content
GitLab
Projects Groups Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in / Register
  • P poppler
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 664
    • Issues 664
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 46
    • Merge requests 46
  • CI/CD
    • CI/CD
    • Pipelines
    • Jobs
    • Schedules
  • Deployments
    • Deployments
    • Environments
    • Releases
  • Packages and registries
    • Packages and registries
    • Container Registry
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • CI/CD
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar
  • poppler
  • poppler
  • Issues
  • #497
Closed
Open
Issue created Mar 09, 2014 by Bugzilla Migration User@bugzilla-migration

PDF links -> SVG

Submitted by rdt..@..il.com

Assigned to poppler-bugs

Link to original bug (#75953)

Description

I'm using pdf2svg from http://www.cityinthesky.co.uk/opensource/pdf2svg/ toconvert PDF pages to SVG images. The key steps are as follows:

// Open the SVG file
surface = cairo_svg_surface_create(svgFilename, width, height);
drawcontext = cairo_create(surface);

// Render the PDF file into the SVG file
poppler_page_render(page, drawcontext);
cairo_show_page(drawcontext);

For my purposes, this works well, with one exception: clickable links in the PDF page are not converted into links in the SVG image.

SVG supports simple xlinks and cairo has a function cairo_surface_set_mime_data with CAIRO_MIME_TYPE_URI as a supported mime type. I believe links on a PDF page are available using poppler_page_get_link_mapping.

Seems like this would be a useful enhancement to poppler_page_render for an svg_surface.

To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Time tracking