diff --git a/make-includes/standard_rules.make b/make-includes/standard_rules.make index 258c777..16e331c 100755 --- a/make-includes/standard_rules.make +++ b/make-includes/standard_rules.make @@ -112,30 +112,19 @@ ps2eps --ignoreBB --nohires --loose < $< | ps2pdf -dEPSCrop - $(IMGDIR)/$@ # # PDF from SVG (via Inkscape) -# We remove the intermediate file manually rather than through the tidy/clean -# mechanism. We don't use Inkscape's --export-area-drawing option to crop, -# because it crops slightly too closely. +# The --export-area-drawing option now appears to behave correctly with +# PDFs (previously it over-cropped slightly). # %.pdf %-print.pdf: %.svg - inkscape --file=$< --without-gui --export-pdf=$(IMGDIR)/$@ - pdfcrop $(IMGDIR)/$@ $(IMGDIR)/$*-crop.pdf - -mv $(IMGDIR)/$*-crop.pdf $(IMGDIR)/$@ + inkscape --file=$< --without-gui --export-area-drawing --export-pdf=$(IMGDIR)/$@ # # PNG from SVG (via Inkscape) -# This is weird: --export-pdf writes the output image exactly where you tell -# it, whereas --export-png seems to write it relative to the original image?? -# So if the original is in images/foo.svg, then --export-pdf=images/foo.pdf -# will create images/foo.pdf, but --export-png=images/foo.png looks like it's -# trying to create images/images/foo.png. --export-png=foo.png will create -# images/foo.png. -# -# ?!?!?! Argh. Bug report submitted to Inkscape. # %.png %-print.png %-web.png: %.svg - inkscape --file=$< --without-gui --export-area-drawing --export-background-opacity=1.0 --export-dpi=96 --export-png=$@ + inkscape --file=$< --without-gui --export-area-drawing --export-background-opacity=1.0 --export-dpi=96 --export-png=$(IMGDIR)/$@ %-web-zoom.png: %.svg - inkscape --file=$< --without-gui --export-area-drawing --export-background-opacity=1.0 --export-dpi=144 --export-png=$@ + inkscape --file=$< --without-gui --export-area-drawing --export-background-opacity=1.0 --export-dpi=144 --export-png=$(IMGDIR)/$@ # # PNG from PNG (change the name) #