bugGNU Octave - Bugs: bug #41142, change to legend deletes and...

 
 

bug #41142: change to legend deletes and recreates text objects

Submitted by:  Ben Abbott <bpabbott>
Submitted on:  Tue 07 Jan 2014 11:48:44 PM UTC  
 
Category: PlottingSeverity: 3 - Normal
Priority: 5 - NormalItem Group: Matlab Compatibility
Status: ConfirmedAssigned to: None
Originator Name: Ben AbbottOpen/Closed: Open
Release: devOperating System: Any

Add a New Comment(Rich Markup)
   

You are not logged in

Please log in, so followups can be emailed to you.

 

Thu 17 Nov 2016 10:40:41 AM UTC, comment #3:

This bug is still present in the current dev 4.3.0 (39f39eb4e476).

I filed task #14243 about rewriting legend.m

Pantxo Diribarne <pantxo>
Project Member
Thu 09 Jan 2014 12:47:17 AM UTC, comment #2:

I agree the legend code needs to be rewritten with Matlab compatibility in mind. Not a simple task.

Ben Abbott <bpabbott>
Project Member
Wed 08 Jan 2014 02:49:09 AM UTC, comment #1:

Matlab's legend function is really hard to mimic exactly. As you know, we use an axes object to represent the legend and the object has extra properties beyond a regular axes object such as fontsize. We add listener's on the axes object for these special properties so that if the legend object is changed all of the child objects are updated. So, one way to make this work is just to use this interface.

The other way to get this to work is to sort handles so that the axes objects are last.

We currently destroy the legend axes object when the fontsize changes because we need to re-calculate the size of the box which will fit the new text. If you can see a better way then we can implement it, but it looks daunting.

Rik <rik5>
Project Administrator
Tue 07 Jan 2014 11:48:44 PM UTC, original submission:

With Matlab, the example below does not throw an error

Ben Abbott <bpabbott>
Project Member

 

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

Attach File(s):
   
   
Comment:
   

No files currently attached

 

Depends on the following items: None found

Digest:
   bug dependencies.

 

Carbon-Copy List
  • -unavailable- added by pantxo (Posted a comment)
  • -unavailable- added by rik5 (Posted a comment)
  • -unavailable- added by bpabbott (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can click here to add your encouragement to it.
    This task has 0 encouragements so far.

    Only project members can vote.

     

    Please enter the title of George Orwell's famous dystopian book (it's a date):

     

     

    Follow 2 latest changes.

    Date Changed By Updated Field Previous Value => Replaced By
    Fri 08 Aug 2014 03:43:22 AM UTCrik5StatusNone=>Confirmed
    Fri 08 Aug 2014 03:42:30 AM UTCrik5Dependencies-=>bugs #42940 is dependent

    Back to the top


    Powered by Savane 3.1-cleanup1