MathGroup Archive 2010

[Date Index] [Thread Index] [Author Index]

Search the Archive

Exporting Plot with Customized Legend to PDF

  • To: mathgroup at smc.vnet.net
  • Subject: [mg109141] Exporting Plot with Customized Legend to PDF
  • From: "Gehricht at googlemail.com" <gehricht at googlemail.com>
  • Date: Mon, 19 Apr 2010 04:10:32 -0400 (EDT)

Dear Mathgroup!

I have the following problem. I want to use a customized legend for
Plot. Unfortunately, when exporting to pdf, the legend is not
displayed in its correct size (i.e. it overlays the whole plot).
An example for this:

MyLegend =
  Inset[Framed[
    GraphicsGrid[{{Graphics[{Black, Thickness[0.05],
         Line[{{0, 0}, {3, 0}}]}],
       mystyle["109.5\[Degree]"]}, {Graphics[{Dashed, Red,
         Thickness[0.05], Line[{{0, 0}, {3, 0}}]}],
       mystyle["116\[Degree]"]}, {Graphics[{DotDashed, Blue,
         Thickness[0.05], Line[{{0, 0}, {3, 0}}]}],
       mystyle["120\[Degree]"]}}, AspectRatio -> 1,
     Spacings -> {0, 0}], FrameMargins -> 0, FrameStyle -> Gray], {4,
    0.4}, {0, 0}, 3, Background -> White];
Export["1.pdf",Plot[1/x, {x, 0, 10}, Epilog -> MyLegend]]

With many thanks in advance!
Yours Wolfgang


  • Prev by Date: Re: ListPlot with two horizontal axes
  • Next by Date: Re: Bug in Sum?
  • Previous by thread: Missing Posts
  • Next by thread: Re: Exporting Plot with Customized Legend to PDF