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)?
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:
This should result in something like this:
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: