5.2-svn: psxy -Sqn:+g with transparency?

Added by Kristof over 5 years ago

I have several annotated lines which overlap several other features in my plot. The labels of the annotated lines become unreadable if other lines/things are beneath them. I tried the psxy -Sqn:+g option but found the solid box hiding too much detail of the features beneath the label. As I found no way to add transparency to the solid background I tried to fake the transparency by plotting the underlying features twice.

First the overlapped line in a lighter hue, then the overlaying annotated line with clipping activated, then the overlapped line with the regular color prior to ending the clipping. As I have 11 layers overlaying each other this is a rather complicated venture. Therefore my question if someone has a better idea to achieve the desired effect? The smoothest way seems to be something like -Sqn:+gwhite-t75%. Any ideas?

Edit: I found another way to (almost) achieve my desired result by plotting the overlaying line twice and adding transparency to the first plot. However I get an undesired line running through the label. Please see attached PDF where the left variant is the original fake described above, the one in the middle is the "new" version and the one on the right is just a regular transparent label.

All the best,

screenshot_labels.png - left side shows the desired result (46.3 KB)

testcase_1.pdf - Output of test script (9.8 KB)

testcase_1.sh Magnifier - Test Script for all three variants (1.85 KB)

Replies (2)

RE: 5.2-svn: psxy -Sqn:+g with transparency? - Added by Paul over 5 years ago

It is true that the +g<color> does not use any transparency specified. E.g., if you say +gred@75 it will process what you gave it but the PSL code only sets the color. I will have a look at how to change this.

RE: 5.2-svn: psxy -Sqn:+g with transparency? - Added by Kristof over 5 years ago

Thank you Paul! I added feature request #681 to the tracker (basically a copy of my initial posting).