Geometry Line Plotting Problem

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

Geometry Line Plotting Problem

Thomas D. Dean-2
I am using geometry 3.0.0.  The order of plotting effects 'linestyle'
property.

== case 1 Failure =====================================================
dx=0.4375/2;
dz=0.31;
dr=1.25/2;
L=0.995;

X = [-L -dz -dz 0 0 -dz -dz -L -L];
Y = [-dr -dr -dx -dx dx dx dr dr -dr];
line(X,Y);

X = [ -L  -L+0.250 -L+0.250 0 ]
Y = [ 0.250  0.250  3/8/2  3/8/2 ]
line(X,Y, 'linestyle','--');
Y = [ -0.250  -0.250  -3/8/2  -3/8/2 ]
line(X,Y, 'linestyle','--');

The line style property is not obeyed.  No dashed line is plotted.  The
2nd and 3rd calls to line seem to not change the plot.

== case 2 Success =====================================================
dx=0.4375/2;
dz=0.31;
dr=1.25/2;
L=0.995;

X = [ -L  -L+0.250 -L+0.250 0 ]
Y = [ 0.250  0.250  3/8/2  3/8/2 ]
line(X,Y, 'linestyle','--');
Y = [ -0.250  -0.250  -3/8/2  -3/8/2 ]
line(X,Y, 'linestyle','--');
X = [-L -dz -dz 0 0 -dz -dz -L -L];
Y = [-dr -dr -dx -dx dx dx dr dr -dr];
line(X,Y);

The dashed lines are plotted.

Tom Dean


Reply | Threaded
Open this post in threaded view
|

Re: Geometry Line Plotting Problem

Juan Pablo Carbajal-2
Use "drawLine" to draw lines that follow geometry's (matgeom's) line definition
Anyways, I can't reproduce your issues, both cases work as expected.
This might be due to Octave's version of the graphics toolkit, here:
> graphics_toolkit
ans = qt
> version
ans = 5.1.90


Reply | Threaded
Open this post in threaded view
|

Re: Geometry Line Plotting Problem

Thomas D. Dean-2
On 2020-01-04 15:22, Juan Pablo Carbajal wrote:
> Use "drawLine" to draw lines that follow geometry's (matgeom's) line definition
> Anyways, I can't reproduce your issues, both cases work as expected.
> This might be due to Octave's version of the graphics toolkit, here:
>> graphics_toolkit
> ans = qt
>> version
> ans = 5.1.90
>

octave:2> graphics_toolkit
ans = qt
octave:3> version
ans = 6.0.0
octave:4>

The problem is there.  If I plot the dashed lines first, the plot is
correct.  If I plot the dashed lines last, they do not appear.

Tom Dean


Reply | Threaded
Open this post in threaded view
|

Re: Geometry Line Plotting Problem

Thomas D. Dean-2
In reply to this post by Juan Pablo Carbajal-2
On 2020-01-04 15:22, Juan Pablo Carbajal wrote:
> Use "drawLine" to draw lines that follow geometry's (matgeom's) line definition
> Anyways, I can't reproduce your issues, both cases work as expected.
> This might be due to Octave's version of the graphics toolkit, here:
>> graphics_toolkit
> ans = qt
>> version
> ans = 5.1.90
>

It appears the problem is the graphics toolkit.

With graphicstoolkit('qt'), the problem exists.
With graphics_toolkit('gnuplot'), the plot is correct, either way.


Is this an Octave problem or a Qt problem?

Tom Dean


Reply | Threaded
Open this post in threaded view
|

Re: Geometry Line Plotting Problem

Juan Pablo Carbajal-2
I can't tell, testing with development version
> graphics_toolkit
ans = qt
octave-gui:11> version
ans = 6.0.0

I get both dashed lines in any case.


Reply | Threaded
Open this post in threaded view
|

Re: Geometry Line Plotting Problem

Juan Pablo Carbajal-2
Are you in windows?