octave-maintainers
[Top][All Lists]
Advanced

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

Re: print -dashed fails with gnuplot backend


From: Ben Abbott
Subject: Re: print -dashed fails with gnuplot backend
Date: Thu, 11 Nov 2010 08:34:15 +0800

On Nov 11, 2010, at 1:29 AM, Jarno Rajahalme wrote:

> On Nov 10, 2010, at 18:28 , ext Ben Abbott wrote:
> 
>> On Nov 11, 2010, at 12:08 AM, Jarno Rajahalme wrote:
>> 
>>> On Nov 10, 2010, at 17:38 , ext Ben Abbott wrote:
>>>> 
>>>> I've attached a demo changeset that fixes the crash for me.
>>>> 
>>>> If this approach is acceptable, I'll need to handle other print options in 
>>>> a similar manner.
>>>> 
>>> 
>>> This worked for me as well. However, I need the capability to plot multiple 
>>> lines with legend that allows the lines to be identified also when printed 
>>> on black and white. Before the recent printing changes this was the default 
>>> behavior. It was implemented by enumerating the different linestyles 
>>> available with gnuplot for the plotted lines. Would it be difficult to have 
>>> this back, maybe in the form of using a different gnuplot linestyle for 
>>> each dashed line of different color, i.e. mapping the color number (if such 
>>> exists) to linestyle number (2 and above) for lines with Octave linestyle 
>>> '--'?
>>> 
>>> On screen the different colors obviously work better, but I need the above 
>>> for eps plots.
>>> 
>>> Regards,
>>> 
>>> Jarno
>> 
>> I don't have an objection, but also don't immediately see a convenient way 
>> to do that. If some one else does, please make a suggestion.
>> 
>> An alternative would be to use linestyleorder.
>> 
>>      close all
>>      set (0, "DefaultAxesLineStyleOrder", {"-", "--",":", "-."})
>>      set (0, "DefaultAxesColorOrder", [0 0 0])
>>      yvals = [1:8;1:8]
>>      plot (yvals)
>>      axis ([1 2 0 size(yvals,2)+1])
>>      print -dpdfwrite test.pdf
>> 
>> Is this the desired result when "-dashed" is included?
>> 
> 
> If the "-dashed" is included, then all become like "--". However, without 
> "-dashed" there are now 3 different dash styles, whereas I recently used 6. 
> Are the three dash styles all that exist in Octave? (Is it the same in 
> Matlab?)
> 
>  Jarno

Yes, both Matlab and Octave only support four linestyles {"_", ":", "-'", "--"}

There are 13 markers as well.

Ben



reply via email to

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