Wikipedia:Graphics Lab/Resources/PDF conversion to SVG: Difference between revisions
Content deleted Content added
→How to convert a PDF to SVG: adding more info on pdf2svg |
→Extracting part of a PDF: making instructions clearer |
||
(3 intermediate revisions by 3 users not shown) | |||
Line 37:
==== Conversion with dvisvgm ====
Large and complex PDFs such as some of the maps from the USGS are sometimes difficult for PDF2SVG or Inkscape to convert. For PDFs that are not able to be converted by these tools, <
To convert a PDF to SVG with dvisvgm, run the following command:
<
If you want to make your SVG smaller, you can add <
==== Convert a multiple page pdf to svg ====
Line 51:
#Get pdf2svg from [[Github]] [https://github.com/dawbarton/pdf2svg here], additional info [http://www.cityinthesky.co.uk/opensource/pdf2svg/ here]. If you are using Windows, Linux or FreeBSD or OSX, pdf2svg is installable via the package installer.
## '''Ubuntu/Debian/Chromebook with Linux support''': Use <
## '''Windows''': Binaries can be downloaded from [https://github.com/jalios/pdf2svg-windows here].
To convert a pdf:
#Convert the first page of a PDF file with <
#If necessary use Inkscape to edit the resulting SVG.
Line 64:
Inkscape often produces [[#BadSVG|unreasonably large]] SVG files from PDFs, especially if you are only trying to use a small part of the PDF (such as a single vector image or logo on a larger page). In order to reduce the size of the resulting image, it is almost always better to copy and paste the portion of interest into a new Inkscape document rather than try to delete the unwanted content and crop the canvas. To do this:
#Open the PDF in Inkscape
#Delete any backgrounds or surrounding text/images near the image you are trying to extract
#Select the entire image you are trying to extract by holding the SHIFT key and dragging
|