Sun 12 Jun 2016 08:59:04 AM UTC, comment #10:
Hi,
The patch has been merged upstream. The fix will be part of the next version of gl2ps.
|
Sat 11 Jun 2016 04:48:38 AM UTC, comment #9:
I fixed the other bug, Octave was drawing parts of legend objects even when "visible" was "off", in this cset (http://hg.savannah.gnu.org/hgweb/octave/rev/f2b5499e8662).
|
Fri 10 Jun 2016 07:20:08 PM UTC, comment #8:
@Rik: Sure, go ahead, I'll post a comment here anyway when I have news from gl2ps.
|
Fri 10 Jun 2016 04:06:02 PM UTC, comment #7:
Can we mark this as an upstream bug then and close this report?
Actually, there is the separate issue that setting "visibility" to "off" on a legend object should completely hide the legend. I know roughly where in gl-render.cc this fix belongs and hope to get to it this weekend.
|
Fri 10 Jun 2016 03:06:43 PM UTC, comment #6:
Hi,
This is definitely a bug in gl2ps. I proposed a very simple patch there.
|
Tue 07 Jun 2016 11:42:48 AM UTC, comment #5:
I also obtain the same results as Philip on R2016a. Note however that legend object don't behave like axes objects in this regard: when setting "visible" to "off" on axes objects, only the axes lines, the tick labels and the "x/y/zlabel" and "title" are hidden. The other children objects (lines, patches ...) are drawn.
So Octave behaves exactly as ML for axes objects and not for legend objects.
In ML you need to use "legend boxoff" to hide only the legend box, not the whole legend. This also works in Octave
Now about the missing legend labels in Octave printout when you hide the box, if you look carefully (in Rik's example) you'll see that the text is drawn but white. FWIW this doesn't happen with the svg format:
works as expected.
I checked in gl2ps-print.cc that the correct color is set prior to calling "gl2psTextOpt". It looks like a bug in gl2ps when using multiple viewports but I have no real clue ATM.
|
Tue 07 Jun 2016 11:06:36 AM UTC, comment #4:
Here we go w. r2014a; the screenshot + the printed figure (file).
(file #37419, file #37420)
|
Mon 06 Jun 2016 04:48:42 PM UTC, comment #3:
I've attached two png figures which shows what box "on"/"off" should look like for a simple plot. It's doing the right thing for me.
We will need to get someone with access to Matlab to test the following:
(file #37410, file #37411)
|
Mon 06 Jun 2016 04:31:26 PM UTC, comment #2:
I do not have access to matlab.
The box option is not working form me under fltk or qt. It does work under gnuplot.
invisible is not hiding the content of the axes, only the axes. If I do
set(gca,"visible",'off')
only the axes disappear under gnuplot, fltk and qt.
|
Mon 06 Jun 2016 04:17:04 PM UTC, comment #1:
I think there are different issues at work here. If you change the visibility of a graphics object to "off" it, shouldn't all of it's children disappear as well? This certainly works with
which causes the entire figure to disappear. It also works this way with hggroup.
If you have access to Matlab, could you test what happens to the legend on screen when you make it invisible?
The set command for box works for me.
This turns off the box, but remember that a legend is made from an axes object. Turning off the box won't turn off the x and y axes. You will do better to hack it by changing the axes colors to the color of the background, usually white.
|
Mon 06 Jun 2016 03:03:24 PM UTC, original submission:
This might be related with bug #40334
This prints a png without the legend labels. This is not the case in 4.0.0
note that it is due to title since this works fine
btw, I set the legend invisible to remove the box since set (.., "box", "off") does't have any effect.
|