bugGNU Octave - Bugs: bug #40333, Changing the fontsize of a legend...

 
 

bug #40333: Changing the fontsize of a legend modifies axes position

Submitted by:  Stefan Mahr <dac922>
Submitted on:  Mon Oct 21 19:10:28 2013  
 
Category: PlottingSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Regression
Status: ConfirmedAssigned to: None
Originator Name: Open/Closed: Open
Release: devOperating System: GNU/Linux

Add a New Comment (Rich MarkupRich Markup):
   

You are not logged in

Please log in, so followups can be emailed to you.

 

(Jump to the original submission Jump to the original submission)

Thu Nov 17 18:57:19 2016, comment #20:

The following is enough to trigger the bug

Retitling the report.

Pantxo Diribarne <pantxo>
Project Member
Thu Nov 17 17:17:37 2016, comment #19:

If the root cause is the behavior of legend, then it is a legend bug and you should re-title this.

Rik <rik5>
Project Administrator
Thu Nov 17 10:42:46 2016, comment #18:

This bug is still present in the current dev 4.3.0 (39f39eb4e476).

It is not directly related to printing, should I file a new report or retitle this one and make it yet another bug about legend?

I filed task #14243 about rewriting legend.m

Pantxo Diribarne <pantxo>
Project Member
Fri Feb 26 21:44:15 2016, comment #17:

@Ben: Changed bug category and summary as you suggested.

Rik <rik5>
Project Administrator
Wed Dec 30 02:09:56 2015, comment #16:

@Rik,

Should the summary be changed to remove the reference to gnuplot?

The category as well?

Ben Abbott <bpabbott>
Project Member
Sun Feb 15 05:33:30 2015, comment #15:

Some things have improved over the last year. I don't see the originally reported error of a shrinking axis/figure when using print with a legend. On the other hand, the bug described in comment #12 with FLTK is still present. This won't gate the 4.0 release.

Rik <rik5>
Project Administrator
Thu Nov 14 19:10:11 2013, comment #14:

The results in comment #13 hold for my linux-system (ubuntu 12.04 64 bit). On windows (XP 32 bit, mxe-build cross compiled on linux) I get the following printing a figure with -depslatex:

  • gnuplot
    • gnuplot.exe in octave/bin: empty eps-file and an incomplete tex-file ending with \begin{picture}
    • externally installed gnuplot: complete eps-file and tex-file
  • fltk: print ignores -S parameter, only a part of the figure is printed, or nothing happens at all; I was not able to find out how to reproduce the single effects.
Torsten <ttl>
Project Member
Wed Nov 13 21:39:40 2013, comment #13:

Currently (hg id b602014eeb54 tip @) I can use gnuplot to correctly print the whole figure (with -depslatex) whereas fltk only prints a part of it (as described in comment #12)

Torsten <ttl>
Project Member
Thu Oct 24 17:09:15 2013, comment #12:

fltk is also affected when adding the -F option:

The resulting print_test.eps is attached. Also attached a test with -depslatex (same result).

(file #29461, file #29462)

Torsten <ttl>
Project Member
Thu Oct 24 16:19:16 2013, comment #11:

Actually, it may be time to raise the priority
of the FLTK bug (cannot print without display)
so that FLTK can be used for the Manual.

Michael Godfrey <godfrey>
Thu Oct 24 16:12:46 2013, comment #10:

Well, as long the docs can't be build with FLTK, I think gnuplot should have the same priority. For example: Look for 'interpderiv2.eps' or figure 29.1 in octave.pdf.

Stefan Mahr <dac922>
Thu Oct 24 15:44:27 2013, comment #9:

I'm re-opening the bug report for gnuplot. gnuplot is no longer the default plotting engine so this won't gate the 3.8 release.

The shrinking problem is due to the fact that legend.m has to do even more weird contortions than for FLTK to support them.

I tried the size option "-S" with octave-3.6.4 and it produced awful results, different from what I get now, but still really bad. I'm not sure this feature has ever worked very well with gnuplot.

Rik <rik5>
Project Administrator
Thu Oct 24 11:04:57 2013, comment #8:

Rik, did you try the gnuplot example below? I can confirm that the bug is fixed for fltk, but with gnuplot the bug still occurs.

I can confirm Torstens bug. Attached the resulting .eps file. In addition a screenshot (.png) of the plot after the print command.

(file #29456, file #29457)

Stefan Mahr <dac922>
Thu Oct 24 10:14:27 2013, comment #7:

I still have problems when printing with the "size"-options but I am not sure if this is related to this bug.
Steps to reproduce:

The eps-file only contains the lower left part of the figure. When printig without legend or using fltk everything works as expected.

Torsten <ttl>
Project Member
Thu Oct 24 00:48:03 2013, comment #6:

Thanks Rik. The bug was my fault. I had reversed the order of restoring the properties thinking that would restore things to their original state .... looks like I got it backwards

Ben Abbott <bpabbott>
Project Member
Thu Oct 24 00:17:32 2013, comment #5:

I think I've fixed the problem with this changeset (http://hg.savannah.gnu.org/hgweb/octave/rev/4e225f952885). At any rate, the test script no longer shrinks the axes.

Rik <rik5>
Project Administrator
Tue Oct 22 16:22:33 2013, comment #4:

Confirmed with hg id 132d9f543cc5. The problem is going to be in legend.m. There has always been issues returning the size of the axes to the original values when deleting or re-creating the legend object (such as for a fontsize change).

Rik <rik5>
Project Administrator
Tue Oct 22 15:18:54 2013, comment #3:

I can confirm this with default 132d9f543cc5 (after fix of bug 40334)

Andreas Weber <andy1978>
Project Member
Mon Oct 21 20:55:15 2013, comment #2:

Erm, https://savannah.gnu.org/bugs/?40334

Stefan Mahr <dac922>
Mon Oct 21 20:43:18 2013, comment #1:

This bug seems somehow related to this bug https://savannah.gnu.org/bugs/?40333

If using print with setting font size (that returns with an error), the position of the axis changes like with gnuplot.

Stefan Mahr <dac922>
Mon Oct 21 19:10:28 2013, original submission:

If plot and print are executed within a loop without closing the figure each time, the axes get smaller and smaller.

Stefan Mahr <dac922>

 

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

Attach File(s):
   
   
Comment:
   

Attached Files
file #29461:  print_test-inc.eps added by ttl (5kB - image/x-eps)
file #29462:  print_test.eps added by ttl (5kB - image/x-eps)
file #29456:  print_test.png added by dac922 (9kB - image/png)
file #29457:  print_test.eps added by dac922 (23kB - image/x-eps)

 

Depends on the following items: None found

Items that depend on this one

Digest:
   task dependencies.

 

Carbon-Copy List
  • -unavailable- added by pantxo (Posted a comment)
  • -unavailable- added by godfrey (Posted a comment)
  • -unavailable- added by ttl (Posted a comment)
  • -unavailable- added by bpabbott (Posted a comment)
  • -unavailable- added by rik5 (Posted a comment)
  • -unavailable- added by andy1978 (Posted a comment)
  • -unavailable- added by dac922 (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 15 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Thu Nov 17 18:57:19 2016pantxoSummaryprint with legend modifies axis position=>Changing the fontsize of a legend modifies axes position
    Fri Feb 26 21:44:15 2016rik5CategoryPlotting with gnuplot=>Plotting
      Summaryprint with legend modifies axis position (gnuplot)=>print with legend modifies axis position
    Thu Oct 24 17:09:15 2013ttlAttached File-=>Added print_test-inc.eps, #29461
      Attached File-=>Added print_test.eps, #29462
    Thu Oct 24 15:44:27 2013rik5CategoryPlotting=>Plotting with gnuplot
      StatusFixed=>Confirmed
      Open/ClosedClosed=>Open
      Summaryprint with legend modifies axis position=>print with legend modifies axis position (gnuplot)
    Thu Oct 24 11:04:57 2013dac922Attached File-=>Added print_test.png, #29456
      Attached File-=>Added print_test.eps, #29457
    Thu Oct 24 00:17:32 2013rik5StatusNone=>Fixed
      Open/ClosedOpen=>Closed
    Tue Oct 22 15:18:54 2013andy1978CategoryPlotting with gnuplot=>Plotting
      Item GroupNone=>Regression

    Back to the top


    Powered by Savane 3.1-cleanup