bugGNU Octave - Bugs: bug #48469, 'linewidth' 0 is the same as no...

 
 

bug #48469: 'linewidth' 0 is the same as no linewidth option

Submitter:  Francesco Potortì <pot>
Submitted:  Mon 11 Jul 2016 04:37:15 PM UTC
   
 
Category:  Plotting Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Inaccurate Result
Status:  Duplicate Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * dev Operating System:  * Any
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Tue 12 Jul 2016 04:41:40 PM UTC, comment #7: 

See bug #34143, already discussed and confirmed that linewidth must be a positive number.

Matlab says:


>> set (h, 'linewidth', 0);
??? Error using ==> set
Value must be finite and greater than zero


Mike Miller <mtmiller>
Group Member
Tue 12 Jul 2016 04:41:06 PM UTC, comment #6: 

See bug #34143, already discussed and confirmed that linewidth must be a positive number.

Matlab says:


>> set (h, 'linewidth', 0);
??? Error using ==> set
Value must be finite and greater than zero


Mike Miller <mtmiller>
Group Member
Tue 12 Jul 2016 03:03:55 PM UTC, comment #5: 

WWMD?

Dmitri A. Sergatskov <dasergatskov>
Tue 12 Jul 2016 02:43:28 PM UTC, comment #4: 

Maybe doing the most obvious thing and trating linewidth==0 as no line?

Francesco Potortì <pot>
Mon 11 Jul 2016 10:45:27 PM UTC, comment #3: 

Thank you, then I think this can be closed as a duplicate of task #11311.

Mike Miller <mtmiller>
Group Member
Mon 11 Jul 2016 10:07:10 PM UTC, comment #2: 

@Mike: task #11311 is about validating graphics properties values

Pantxo Diribarne <pantxo>
Group Member
Mon 11 Jul 2016 07:07:08 PM UTC, comment #1: 

Confirmed on default. Setting the linewidth property to 0.1 works and draws a very faint lint. Setting the linewidth property to 0 seems to draw the line with the default value. The property is stored as 0.

Actually the linewidth property doesn't seem to have any validation on it, I can enter a linewidth of -12 and it also renders the same as the default linewidth.

I suspect the right way to solve this would be to throw an "invalid value for property linewidth" error if the value is not a positive scalar.

Mike Miller <mtmiller>
Group Member
Mon 11 Jul 2016 04:37:15 PM UTC, original submission:  

In both fltk and gnuplot, this draws no line:

> plot(1:2, 'linestyle', 'none')


while this draws a line:

> plot(1:2, 'linewidth', 0)


This is a bug, or a missing documentation about a possible special meaning of linewidth of 0.

Francesco Potortì <pot>

 

(Note: upload size limit is set to 16384 kB, after insertion of the required escape characters.)

Attach Files:
   
   
Comment:
   

No files currently attached

 

Carbon-Copy List
  • -email is unavailable- added by dasergatskov (Posted a comment)
  • -email is unavailable- added by pantxo (Posted a comment)
  • -email is unavailable- added by mtmiller (Posted a comment)
  • -email is unavailable- added by pot (Submitted the item)
  •  

    There are 0 votes so far. Votes easily highlight which items people would like to see resolved in priority, independently of the priority of the item set by tracker managers.

    Only group members can vote.

     

    Follow 7 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2016-07-12 mtmiller Dependencies- Depends on task #11311
    2016-07-12 mtmiller Dependencies- Depends on bugs #34143
    2016-07-11 mtmiller StatusConfirmed Duplicate
        Open/ClosedOpen Closed
    2016-07-11 mtmiller StatusNone Confirmed
        Release4.0.2 dev
        Operating SystemGNU/Linux Any

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code