bugGNU Octave - Bugs: bug #48161, printing a plotyy plot only shows...

 
 

bug #48161: printing a plotyy plot only shows the second axes

Submitter:  None
Submitted:  Tue 07 Jun 2016 12:02:31 PM UTC
   
 
Category:  Plotting with OpenGL Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Incorrect Result
Status:  Fixed Assigned to:  None
Originator Name:  Originator Email:  -email is unavailable-
Open/Closed:  * Closed Release:  * dev
Operating System:  * GNU/Linux Fixed Release:  None
Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Sat 11 Jun 2016 04:27:16 AM UTC, comment #6: 

@Pantxo: I pushed your patch for plotyy here (http://hg.savannah.gnu.org/hgweb/octave/rev/ec3adcec1337).

Fixed, closing report.

Rik <rik5>
Group administrator
Thu 09 Jun 2016 02:45:31 PM UTC, comment #5: 

So I had the following tested in ML 2016a:


x = linspace (0, 2*pi, 100);
plot (x, sin (x))
set (gca, 'Color', 'g')
print -depsc toto.eps
set (gca, 'Color', 'none')
print -depsc toto2.eps


I imported the eps files in Inkscape and saw that indeed when the axes background is not 'none' ML changes it to white for printing (as stated in the documentation); but when the background is none then it is not drawn.

Also, playing with "plotyy" in ML I saw that only the second axes has its background color "none", whereas in Octave it is "none" for both.

Something like the attached patch should work and be ML compatible.



(file #37439)

Pantxo Diribarne <pantxo>
Group Member
Tue 07 Jun 2016 08:35:08 PM UTC, comment #4: 

Setting "inverthardcopy" to "off" solves the issue. By default "inverthardcopy" forces a white background when printing for figures but also for axes, see:

http://hg.savannah.gnu.org/hgweb/octave/rev/030d4d6c2b58

Is ML also changing the axes background color? This seams odd.

Pantxo Diribarne <pantxo>
Group Member
Tue 07 Jun 2016 06:02:14 PM UTC, comment #3: 

Changing version to dev.  This works fine for me on 4.0.2 with all 3 backends.  It fails on the development version for all of the backends.

Rik <rik5>
Group administrator
Tue 07 Jun 2016 04:51:49 PM UTC, comment #2: 

It works as expected on mine 4.0.2 (with all 3 backends), but fails on 4.1.0+ with any backend.

Dmitri.
--

Dmitri A. Sergatskov <dasergatskov>
Tue 07 Jun 2016 04:33:04 PM UTC, comment #1: 

Thanks for the bug report. Confirmed on the default branch as well.

Mike Miller <mtmiller>
Group Member
Tue 07 Jun 2016 12:02:31 PM UTC, original submission:  

Using graphics_toolkit qt


x=linspace(0,10);
plotyy (x, sin(x), x, cos(x))
print out.png


The resulting out.png only shows cos(x)

Anonymous

 

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

Attach Files:
   
   
Comment:
   

Attached Files
file #37439:  plotyy.patch added by pantxo (1KiB - text/x-diff)
file #37422:  out.png added by None (28KiB - image/png)

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by pantxo (Posted a comment)
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by dasergatskov (Posted a comment)
  • -email is unavailable- added by mtmiller (Posted a comment)
  •  

    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 8 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2016-06-11 rik5 StatusConfirmed Fixed
        Open/ClosedOpen Closed
    2016-06-09 pantxo Attached File- Added plotyy.patch, #37439
    2016-06-07 rik5 Release4.0.2 dev
    2016-06-07 mtmiller CategoryNone Plotting with OpenGL
        Item GroupNone Incorrect Result
        StatusNone Confirmed
    2016-06-07 None Attached File- Added out.png, #37422

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code