Search code examples
plotxmgrace

Is it possible to rotate the legend box in xmgrace?


This may be useful if the legend text is long and the graph has some empty vertical space on one side. Can the legend be in the green box with text going vertically (see figure below)?


Solution

  • No, it's not possible. However, there is a workaround you can use. It's quite the cumbersome procedure, but I don't think there are other options:

    1. Set " " (a single space) as the legend
    2. Move it where you want
    3. Move the "Window -> Drawing objects..." dialog
    4. Add the real legend as text, set "rotation" to 90 or 270
    5. Click on "move object" and move it just below the (empty) legend

    This should result in something like this:

    enter image description here

    If you want to have a vertical line then you have to do it yourself by adding a line (from the same dialog) and giving it the right colour. This is the end result:

    enter image description here