bugGNU Octave - Bugs: bug #49215, gnuplot toolkit window position...

 
 

bug #49215: gnuplot toolkit window position jumps with colormap() upon first draw

Submitter:  Dan Sebald <sebald>
Submitted:  Wed 28 Sep 2016 06:32:39 PM UTC
   
 
Category:  Plotting with gnuplot Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Inaccurate Result
Status:  Fixed 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 13 Dec 2017 09:26:03 PM UTC, comment #3: 

I pushed the comment change here (http://hg.savannah.gnu.org/hgweb/octave/rev/a51a92186a1f).  Closing report.

Rik <rik5>
Group administrator
Wed 13 Dec 2017 09:13:26 PM UTC, comment #2: 

I'm not seeing that jump now.  It appears to draw only once, which is good.  The diff below was simply to change the comment to reflect it is generally any gnuplot window (not just X11/Windows) for which the position can be set.

Dan Sebald <sebald>
Wed 13 Dec 2017 08:53:35 PM UTC, comment #1: 

I can't reproduce this.  Has the window jumping problem been resolved by other changes?

Rik <rik5>
Group administrator
Wed 28 Sep 2016 06:32:39 PM UTC, original submission:  

There was recently a "position" option added to qt and wxt terminals in gnuplot.  That's nice, but the consequence is that sometimes the window is initially drawn in the default gnuplot location then jumps immediately to the prescribed position.  For example, with gnuplot/qt-term I am using imshow(), and imshow() calls the following:

colormap(gray());

Similary,

figure();

will cause a jump as well.  Try something like

[exit]
[launch]
colormap(gray());

So, I'm wondering if we can take out some initial draw or add some missing position property at the start that will get rid of that window jump.

As a side note, the fact that position applies to X11, Windows, (and now) qt, wxt is already noted at one location in the code, so the following redundancy can be removed.


diff --git a/scripts/plot/util/__gnuplot_drawnow__.m b/scripts/plot/util/__gnuplot_drawnow__.m
--- a/scripts/plot/util/__gnuplot_drawnow__.m
+++ b/scripts/plot/util/__gnuplot_drawnow__.m
@@ -237,8 +237,8 @@ function enhanced = gnuplot_set_term (pl
               set (0, "units", units);
             end_unwind_protect
             if (all (screen_size > 0))
-              ## For X11/Windows, set the figure positon as well as the size
-              ## gnuplot position is UL, Octave's is LL (same for screen/window)
+              ## Set the figure positon as well as the size gnuplot position
+              ## is UL, Octave's is LL (same for screen/window)
               gnuplot_pos(2) = screen_size(2) - gnuplot_pos(2) - gnuplot_size(2);
               gnuplot_pos = max (gnuplot_pos, 1);
               size_str = sprintf ("%s position %d,%d", size_str,


Dan Sebald <sebald>

 

(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

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by sebald (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 3 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2017-12-13 rik5 StatusWorks For Me Fixed
        Open/ClosedOpen Closed
    2017-12-13 rik5 StatusNone Works For Me

    Back to the top

    Powered by Savane 3.13-bb6a.
    Corresponding source code