bugGNU Octave - Bugs: bug #46654, Quirks with closing Figures and...

 
 

bug #46654: Quirks with closing Figures and updating Figure sizes (gnuplot)

Submitter:  Ceral Paquet <octavebugs>
Submitted:  Thu 10 Dec 2015 02:21:45 PM UTC
   
 
Category:  Plotting with gnuplot Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Incorrect Result
Status:  Wont Fix 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
   

Wed 16 Dec 2015 01:49:58 AM UTC, comment #4: 

I discussed the topic of providing size/position control of gnuplot's figures with the developers several years ago. The conclusion was that it may be possible to inquire about the position of the figures, but changing the position was essentially a show stopper.

I'm not expecting Octave's support of gnuplot to disappear anytime soon. It is very useful for latex related graphics.

Ben Abbott <bpabbott>
Group Member
Wed 16 Dec 2015 01:36:30 AM UTC, comment #3: 

Has there been an attempt to get the Gnuplot folk to provide greater external control?

It is a shame to have too many competing open source projects for plotting, and I think that use by Octave has been a big driver for Gnuplot to be a good package.

$0.02

Lachlan Andrew <lachlan>
Sun 13 Dec 2015 02:01:39 AM UTC, comment #2: 

These are both features of using gnuplot. Octave has no direct control over gnuplot figure windows after they have been created. This lacking was a major motivation for introducing native OpenGL graphics toolkits.

For case 1, closing a gnuplot window by clicking [X] is not an event that Octave is able to detect. Thus, figure (1) still exists (as far as Octave knows. Thus,


close all
figure
% close figure 1 using mouse
figure
findobj (0, 'type', 'figure')


Is equivalent to


close all
figure
figure
findobj (0, 'type', 'figure')


In each case, Octave still has two figures open and the findobj() command will return


ans =
2
1


For case 2, there is no mechanism for Octave to resize a gnpuplot window after it has been created. It is also not possible for Octave to determine the size of gnuplot windows. Meaning that if the mouse is used to resize the gnuplot window, Octave will be unaware of the change.

It is possible to specify a window's position and size when it is created. This can be done by specifying the figure's "position" when it is created.


close (1)
figure (1, "position", [x, y, w, h])


This behavior is OS independent and has been addressed by the introduction of the OpenGL toolkits. Thus, I'm marking this as "won't fix".

Ben Abbott <bpabbott>
Group Member
Thu 10 Dec 2015 04:30:06 PM UTC, comment #1: 

Confirmed with gnuplot, these are both gnuplot-specific issues. Opening, closing, and resizing figures works correctly for me with fltk or qt.

Mike Miller <mtmiller>
Group Member
Thu 10 Dec 2015 02:21:45 PM UTC, original submission:  

Case 1.

close all; figure;

This opens "Figure 1".
Now close the figure with [x] and type figure again.
The new figure is "Figure 2". Typing figure(1) does not bring the original figure back but close(1); figure(1) does.

Problem: [x] should behave the same as close;


Case 2.

close all
h=figure(1); set(h,'Position', [60, 600, 400, 330]);
plot(1:10)
h=figure(1); set(h,'Position', [60, 600, 1400, 330]);
plot(1:20)

The figure size is not updated to the larger width 1400.

Problem: once a figure is created, it can't be resized.



BTW my graphics backend is gnuplot. I know this is legacy but I can't use the newer graphics on this computer - the libraries seem to conflict with the GPU (way beyond my skill level).

octave:84> graphics_toolkit
ans = gnuplot

Ceral Paquet <octavebugs>

 

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

Attach Files:
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Digest:
   bug dependencies.

 

Carbon-Copy List
  • -email is unavailable- added by lachlan (Posted a comment)
  • -email is unavailable- added by bpabbott (Posted a comment)
  • -email is unavailable- added by mtmiller (Posted a comment)
  • -email is unavailable- added by octavebugs (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 8 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2018-05-14 mtmiller Dependencies- bugs #53888 is dependent
    2015-12-16 bpabbott Open/ClosedOpen Closed
    2015-12-13 bpabbott StatusConfirmed Wont Fix
        Operating SystemGNU/Linux Any
    2015-12-10 mtmiller CategoryNone Plotting with gnuplot
        Item GroupNone Incorrect Result
        StatusNone Confirmed
        Release4.0.0 dev

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code