bugGNU Octave - Bugs: bug #58336, Missing properties for axes...

 
 

bug #58336: Missing properties for axes graphics objects

Submitter:  Markus Mützel <mmuetzel>
Submitted:  Fri 08 May 2020 08:36:36 PM UTC
   
 
Category:  Plotting Severity:  3 - Normal
Priority:  5 - Normal Item Group:  Matlab Compatibility
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
   

Jump to the original submission

Mon 18 May 2020 08:04:24 PM UTC, comment #21: 

I agree.  I think this bug is complete. Marking as fixed and closing report.

Rik <rik5>
Group administrator
Mon 18 May 2020 06:14:20 PM UTC, comment #20: 

@Rik: Thanks for the suggestions.
I made the proposed changes and pushed here:
https://hg.savannah.gnu.org/hgweb/octave/rev/8245b890b6b0

I think that concludes the changes here.
Marking as ready for test.

Markus Mützel <mmuetzel>
Group administrator
Mon 18 May 2020 04:37:40 PM UTC, comment #19: 

Instead of "synonymous to" I would write "equivalent to".  I like the word "synonymous", but there are many non-native English speakers who use Octave and "equivalent" is probably easier to understand.

You use "(not yet fully implemented)" to describe a number of properties.  Is "fully" accurate?  That implies that there is partial implementation.  It might be better to say "(not yet implemented)" if the only thing that can happen is that a user can change the property value.

Rik <rik5>
Group administrator
Mon 18 May 2020 04:16:28 PM UTC, comment #18: 

The attached patch adds some notes about the new properties to the NEWS file. I'm not sure about format and language.

(file #49115)

Markus Mützel <mmuetzel>
Group administrator
Mon 18 May 2020 12:59:48 PM UTC, comment #17: 

And another change that fixes loading figure files that have been saved before "positionconstraint" was added:
https://hg.savannah.gnu.org/hgweb/octave/rev/f9b5357f4a7e

(Savannah is very irresponsive for me today. So I'm not sure if that change actually made it into the repo.)

Markus Mützel <mmuetzel>
Group administrator
Mon 18 May 2020 11:24:08 AM UTC, comment #16: 

@Kai: Thanks for the info. That makes sense, and also explains why I don't see the same errors during a local compilation.

I checked in the following change that replaces "activepositionproperty" (which is a hidden property now) with "positionconstraint":
https://hg.savannah.gnu.org/hgweb/octave/rev/1379ebcb00c3

Let's wait and see what the buildbots will say.

Markus Mützel <mmuetzel>
Group administrator
Mon 18 May 2020 09:35:07 AM UTC, comment #15: 

comment #14:

> I wasn't aware that gnuplot is used for printing the graphics for the manual even if Octave was configured with Qt. Is this intentional?


During the 5.2.0 release I stumbled over that one too.  If no X server is available, even configured with qt, gnuplot is taken to build the documentation images.  For buildbot slaves this might always be the case.

Kai Torben Ohlhus <siko1056>
Group Member
Mon 18 May 2020 07:11:14 AM UTC, comment #14: 

I wasn't aware that gnuplot is used for printing the graphics for the manual even if Octave was configured with Qt. Is this intentional?

Anyhow, I'll have a look at how to fix printing with gnuplot.

Markus Mützel <mmuetzel>
Group administrator
Mon 18 May 2020 01:06:44 AM UTC, comment #13: 

Buildbots seems to be complaining about "activepositionproperty".  This works with OpenGL toolkits, but it seems like some work might need to be done for gnuplot toolkit.

Rik <rik5>
Group administrator
Sun 17 May 2020 10:25:35 PM UTC, comment #12: 

This is all looking nice now.  I think it would be a good idea to announce the added new properties in the NEWS file.

Rik <rik5>
Group administrator
Sun 17 May 2020 07:42:51 PM UTC, comment #11: 

And another one for the positionconstraint property here:
https://hg.savannah.gnu.org/hgweb/octave/rev/af912e78ce43

It should probably be followed by a changeset that replaces "activepositionconstraint" with "positionconstraint" in all .m files.

Markus Mützel <mmuetzel>
Group administrator
Sun 17 May 2020 05:05:16 PM UTC, comment #10: 

I pushed a changeset that implements the "innerposition" property (i.e. mirror the value of the "position" property) here:
https://hg.savannah.gnu.org/hgweb/octave/rev/1f5ec8c025bc

Markus Mützel <mmuetzel>
Group administrator
Sat 16 May 2020 05:25:33 PM UTC, comment #9: 

I shouldn't have added "contextmenu" to the axes and scatter properties. Instead it should have been a base property from the beginning. I fixed that and also let "uicontextmenu" be mirroring the new "contextmenu" property here:
https://hg.savannah.gnu.org/hgweb/octave/rev/e55ff14249c3

Markus Mützel <mmuetzel>
Group administrator
Tue 12 May 2020 01:14:59 PM UTC, comment #8: 

There is already bug #50652 that would probably be a good place to implement the numericruler class.

Markus Mützel <mmuetzel>
Group administrator
Sun 10 May 2020 06:10:54 PM UTC, comment #7: 

@Rik: "nextseriesindex" and the other two "*index" properties have to be handled differently. "nextseriesindex" is a read-only property (not just temporary but also in Matlab). The other two can be set in .m files.
The new scatter object already uses the "nextseriesindex" axes property. I think there is no need to do anything in the axes object directly other than holding the value.

Additionally to "uicontextmenu" -> "contextmenu", there are also "position" -> "innerposition" and "activepositionproperty" -> "positionconstraint" that need similar changes. The latter with the small difference that also the value names changed. But the meaning is the same.

Markus Mützel <mmuetzel>
Group administrator
Sun 10 May 2020 05:49:26 PM UTC, comment #6: 

Code for "nextseriesindex" probably looks similar to what exists for "colororderindex" and "linestyleorderindex".  Might be possible to just grab that code and adapt it.

Rik <rik5>
Group administrator
Sun 10 May 2020 05:28:12 PM UTC, comment #5: 

@Markus: Thanks for tackling this.  Matlab is always changing their API, sometimes for good reasons, but sometimes it feels like they are just doing it for the sake of change.

I agree that "ruler" objects and any other big changes to the graphics system need their own bug report, or maybe it is a project either on the Tasks or Patches lists on Savannah.

The renaming of the property "uicontextmenu" to "contextmenu" is a classic Matlab make-work project.  Given how many decades of code people have this will be a slow transition.  Still, it should be pretty easy to write a small updater routine that gets called when someone accesses the contextmenu property and either reads or writes the uicontextmenu property.

Rik <rik5>
Group administrator
Sun 10 May 2020 09:25:56 AM UTC, comment #4: 

The tasks that the new functions added in the patch from comment #2 do are so trivial that I no longer think we need that interface at all.
I'll upload an updated patch to bug #58282 that no longer needs these functions.

Some of the changes that would be needed to implement the functionality for the new properties are quite complex (e.g. the "*ruler" objects). So I think they'd deserve their own bug reports.

Others need only more or less trivial changes (like the new properties that aren't much more than renamed established properties). They could be implemented here, imho.

So I'll leave the report open for now.

Markus Mützel <mmuetzel>
Group administrator
Sun 10 May 2020 08:59:37 AM UTC, comment #3: 

I added a few more FIXME notes to the patch from comment #1 and (temporarily) set some properties to read-only that don't have any functionality yet. I did the latter to prevent having to deal with loading figure files which otherwise could contain invalid content in these properties.
I pushed the modified patch here:
https://hg.savannah.gnu.org/hgweb/octave/rev/044cea7947db

Markus Mützel <mmuetzel>
Group administrator
Fri 08 May 2020 10:16:43 PM UTC, comment #2: 

The attached patch applies on top of the one from comment #1. It adds an interface for other graphics objects to manipulate "nextseriesindex".
This patch is necessary for the next patch I'm going to upload for bug #58282.

(file #49046)

Markus Mützel <mmuetzel>
Group administrator
Fri 08 May 2020 08:38:54 PM UTC, comment #1: 

The attached patch just adds the missing properties. It doesn't supply them with any functionality.

(file #49044)

Markus Mützel <mmuetzel>
Group administrator
Fri 08 May 2020 08:36:36 PM UTC, original submission:  

Matlab's "axes" graphics objects have several properties that Octave doesn't have yet. [1]

I'll attach a patch adding these new properties as soon as I have a bug number.

[1]: https://de.mathworks.com/help/matlab/ref/matlab.graphics.axis.axes-properties.html

Markus Mützel <mmuetzel>
Group administrator

 

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

Attach Files:
   
   
Comment:
   

Attached Files
file #49115:  bug58336_NEWS.patch added by mmuetzel (2KiB - application/octet-stream)
file #49046:  bug58336_nextseriesindex.patch added by mmuetzel (1005B - application/octet-stream)
file #49044:  bug58336_axes_properties.patch added by mmuetzel (5KiB - application/octet-stream)

 

Depends on the following items: None found

Digest:
   bug dependencies.

 

Carbon-Copy List
  • -email is unavailable- added by siko1056 (Posted a comment)
  • -email is unavailable- added by rik5 (Posted a comment)
  • -email is unavailable- added by mmuetzel (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
    2020-05-18 rik5 StatusReady For Test Fixed
        Open/ClosedOpen Closed
    2020-05-18 mmuetzel StatusIn Progress Ready For Test
    2020-05-18 mmuetzel Attached File- Added bug58336_NEWS.patch, #49115
    2020-05-10 mmuetzel StatusNone In Progress
    2020-05-08 mmuetzel Attached File- Added bug58336_nextseriesindex.patch, #49046
    2020-05-08 mmuetzel Dependencies- bugs #58282 is dependent
    2020-05-08 mmuetzel Attached File- Added bug58336_axes_properties.patch, #49044

    Back to the top

    Powered by Savane 3.13-02a9.
    Corresponding source code