

A tool that converts PDFs to SVG, built using PDF.js - async5
http://pramodhkp.github.io/pdf2svg/

======
rcfox
I've used `pdftocairo -svg` (it's part of the Poppler[0] utilities) to do this
in the past, but Cairo insists on converting all of the text to shapes. (They
are/were planning to fix that, so maybe it's already fixed.) You've got all of
the text there, so you're a step closer to what I wanted, but I noticed that
the spaces are all missing. I'm actually pretty impressed that SVG can render
properly without the spaces for the text.

[0] [http://poppler.freedesktop.org/](http://poppler.freedesktop.org/)

------
NaNaN
The fonts are not kept. Any real use case?

~~~
async5
What does "the fonts are not kept" mean?
[http://pramodhkp.github.io/pdf2svg/svgdump/tracemonkey-1.svg](http://pramodhkp.github.io/pdf2svg/svgdump/tracemonkey-1.svg)
looks as original PDF page and the SVG contains embedded fonts.

~~~
NaNaN
Oh, thanks. Sorry, I've just notice the CSS style for web browsers. So I
should ask what is the use case for the web? Replacing PDF files for embedding
without special viewers? And to add some custom styles if we want? seems
great.

------
PointerReaper
I really wonder about the utility of something like this tool. I enjoy and
encourage building new things "just because" but I can help but think the
point to PDFs is to have complete visual control of layout and formatting
while providing the textual and tagging information layers is critical to
transform and adapt the information for artificial intelligent agents and
people with disabilities that rely upon assistive technologies such as screen
readers.

------
ericthegoodking
I would be interested in knowing about the Sizes of SVG produced by this tool.
Some of the SVGs converted by poppler utility tool 'pdftocairo' are just too
large i.e few MB's which is absolutely unacceptable as these large SVG'S tends
to crash the mobile browsers.

~~~
async5
Original PDF - 1.0M, SVGs - 7.7M, gzip'ed SVGs - 1.7M. I think the latter is a
preferable format for the web, so you are looking 70% increase for this types
of documents, but bare in mind that you may send only certain pages.

------
rpedela
When would one need a SVG version of a PDF instead of just using pdf.js by
itself?

~~~
nurbl
I've had several cases where a drawing I want to edit is only available as
PDF. There are various ways to convert between the formats (e.g. inkscape) but
so far I haven't found one that always works.

~~~
samstave
Highlight a PDF to copy to inkscape and convert to elements would be pretty
damn bad ass.

------
fizz_ed
What about something that goes the other way?

