Bug introduced in 8 or earlier and fixed in 13.0.1
Although Mathematica has some nice plotting capabilities, there are some things which are annoying me.
I like to export a Graphics
to PDF for use in $\LaTeX$. I like to a have an ImageSize
of the PDF file, which corresponds to the image size in my document (e.g. 6 cm). I don't like to scale my image in $\LaTeX$.
When exporting to PDF the PlotRangeClipping
does not work as expected (especially when having a small ImageSize
):
cm=72/2.54;
p1 = Graphics[{EdgeForm[{Red, Thickness[.1]}], FaceForm[], Disk[]},
Frame -> True,
PlotRange -> {{0, 1}, {0, 1}},
PlotRangeClipping -> True,
ImageSize -> 6 cm]
Export["p1.pdf", p1]
p2 = Graphics[{EdgeForm[{Red, Thickness[.1]}], FaceForm[], Disk[]},
Frame -> True,
PlotRange -> {{0, 1}, {0, 1}},
PlotRangeClipping -> True,
ImageSize -> 26 cm]
Export["p2.pdf", p2]
While the PlotRangeClipping
for in the second generated file (p2.pdf) is more or less okay (not perfect),
there are serious problems in p1.pdf:
Is this a bug?
Is there a way to have an acceptable PlotRangePadding
with a small ImageSize
?