octave-maintainers
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: gnuplot and dashed lines


From: Daniel J Sebald
Subject: Re: gnuplot and dashed lines
Date: Fri, 21 Dec 2012 01:38:07 -0600
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.24) Gecko/20111108 Fedora/3.1.16-1.fc14 Thunderbird/3.1.16

On 12/21/2012 12:39 AM, Daniel J Sebald wrote:
On 12/20/2012 09:02 PM, Daniel J Sebald wrote:
On 12/20/2012 08:51 PM, Ben Abbott wrote:

[snip]
Also, I looked at the "test" plots for x11. I don't see any dashed
lines there.

I sent the list a note and I've isolated the dates for which the X11
terminal test is failing.

Dan

I've figured out how to activate the X11 dashed lines, which I'll
explain. How to set this up for users when they install could be
challenging.

What we could do is come up with the dash patterns to go along with the '--', ':' (i.e., slightly alter the lines below, although they are already pretty close), then put that in the README.gnuplot documentation file and perhaps put a note on the webpage of where to locate the information. I don't think there is much sense to trying to write a configure/install script for this sort of thing.

Dan



gnuplot utilizes the standard X11 defined settings interface. This is
explained in gnuplot under

gnuplot> help set term x11 line_resources

Basically, one puts the definitions for the dash patterns inside a local
.Xdefaults file. For example

! gnuplot settings
gnuplot*dashed: on
gnuplot*borderDashes: 0
gnuplot*axisDashes: 16
gnuplot*line1Dashes: 0
gnuplot*line2Dashes: 42
gnuplot*line3Dashes: 13
gnuplot*line4Dashes: 44
gnuplot*line5Dashes: 15
gnuplot*line6Dashes: 4441
gnuplot*line7Dashes: 42
gnuplot*line8Dashes: 13

and then at the shell command line type

shell> xrdb -merge .Xdefaults

I've put the above command in my shell script resource file. (Try xrdb
-query if you run into problems.)

Given that, the "test" pattern in gnuplot should look reasonable. Octave
line patterns come out reasonable as well.

As for the Qt terminal, I'm able to replicate what you are seeing, i.e.,
the gnuplot test pattern looks reasonable, but nothing seems to happen
when Octave attempts dashed lines. I have noticed that Qt terminal
doesn't work exactly the same inside gnuplot as does the x11 terminal.
Where commands like

gnuplot> set term x11 dashed
Terminal type set to 'x11'
Options are ' nopersist dashed'
gnuplot> plot x with lines linestyle 2 linecolor 4
gnuplot> plot x with lines linestyle 2 linecolor 5
gnuplot> plot x with lines linestyle 3 linecolor 5

appear to control the line style and color separately for x11, the same
commands in Qt terminal don't:

gnuplot> set term qt dashed
Terminal type set to 'qt'
Options are '0 font "Sans,9" dashed'
gnuplot> plot x with lines linestyle 2 linecolor 4
gnuplot> plot x with lines linestyle 2 linecolor 5
gnuplot> plot x with lines linestyle 3 linecolor 5

The Qt terminal just picks whatever number was set last for the line
style (which has its own set color).

So, I understand this now. I'll notify gnuplot developers.

Dan

--

Dan Sebald
email: daniel(DOT)sebald(AT)ieee(DOT)org
URL: http://www(DOT)dansebald(DOT)com


reply via email to

[Prev in Thread] Current Thread [Next in Thread]