bugGNU Octave - Bugs: bug #44522, Right-click in Qt plot prints...

 
 

bug #44522: Right-click in Qt plot prints warning in command window

Submitter:  Rik <rik5>
Submitted:  Thu 12 Mar 2015 05:15:08 PM UTC
   
 
Category:  Plotting with OpenGL Severity:  2 - Minor
Priority:  5 - Normal Item Group:  Other
Status:  Fixed Assigned to:  None
Originator Name:  Open/Closed:  * Closed
Release:  * 4.0.0 Operating System:  * GNU/Linux
Fixed Release:  None Planned Release:  None
* Mandatory Fields

Add a New Comment Rich Markup
   

Jump to the original submission

Tue 02 Jun 2015 04:34:48 PM UTC, comment #8: 

Retagging release from 4.0.0-rc1 to 4.0.0.

John W. Eaton <jwe>
Group administrator
Sun 22 Mar 2015 03:36:00 PM UTC, comment #7: 

Trying to right click in an FLTK window resulted in an error message saying that "alternate" is not an allowed value.
Fixed with this cset: http://hg.savannah.gnu.org/hgweb/octave/rev/f902855f870a

Pantxo Diribarne <pantxo>
Group Member
Fri 13 Mar 2015 08:44:25 PM UTC, comment #6: 
Rik <rik5>
Group administrator
Fri 13 Mar 2015 08:08:43 AM UTC, comment #5: 

Ok, I tested in ML 2013a and 'alternate' is definitely not an option:


>> figure
>> set (gcf, 'selectiontype')
[ normal | open | alt | extend ]
>> set (gcf, 'selectiontype', 'alternate')
Error using set
Bad property value found.
Object Name: figure
Property Name: 'SelectionType'.

>> set (gcf, 'selectiontype', 'alt')
>>


Pantxo Diribarne <pantxo>
Group Member
Thu 12 Mar 2015 06:19:08 PM UTC, comment #4: 

Their documentation uses both 'alt' and 'alternate' so was not clear what the actual code was using.  If you can verify with a newer copy of Matlab then I think we are safe to make the change in graphics.in.h.

Rik <rik5>
Group administrator
Thu 12 Mar 2015 06:03:19 PM UTC, comment #3: 

The output from a very old Matlab (installed in 2005, that's all I have at hand for the moment):  {'normal', 'open', 'alt', 'extend'}.

If I grep "alternate" in Octave code I don't see any occurrence of it in graphics related codes except in graphics.in.h. Simply replacing "alternate" by "alt" there should do the trick.

Pantxo Diribarne <pantxo>
Group Member
Thu 12 Mar 2015 05:51:51 PM UTC, comment #2: 

There are no implications since Octave is already matching "alt" to the long name of "alternate".  Could you check on Matlab and see what the allowable property names are?


close all;
hf = gcf;
set (hf, 'selectiontype')



Rik <rik5>
Group administrator
Thu 12 Mar 2015 05:42:01 PM UTC, comment #1: 

@Rik: it is in libgui/graphics/QtHandlesUtils.cc at line 149. If I change "alt" to "alternate" the warning goes away but I don't know the implications.

Pantxo Diribarne <pantxo>
Group Member
Thu 12 Mar 2015 05:15:08 PM UTC, original submission:  

Sample code


./run-octave -f --no-gui
graphics_toolkit qt
sombrero
# right-click in figure window
warning: set: allowing alt to match selectiontype value alternate


You can repeatedly generate the warning by a left click followed by a right click.  This only occurs when pan, rotate, or zoom are not selected.

The warning itself is pretty obvious.  Somewhere in the code there must be something of the form


set (hfig_handle, "selectiontype", "alt")


but according to graphics.in.h, the selectiontype property name is "alternate"


set (hfig_handle, 'selectiontype')
[ alternate | extend | {normal} | open ]


I used grep on selectiontype in the scripts directory and it does not appear in any of the m-files so it must be in the C++ source code.

Rik <rik5>
Group administrator

 

(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 jwe (Posted a comment)
  • -email is unavailable- added by pantxo (Posted a comment)
  • -email is unavailable- added by rik5 (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
    2015-06-02 jwe Release4.0.0-rc1 4.0.0
    2015-03-13 rik5 StatusNone Fixed
        Open/ClosedOpen Closed

    Back to the top

    Powered by Savane 3.13-caa5.
    Corresponding source code