octave-bug-tracker
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Octave-bug-tracker] [bug #54757] Applying colormap to axes does not upd


From: anonymous
Subject: [Octave-bug-tracker] [bug #54757] Applying colormap to axes does not update the legend
Date: Sun, 30 Sep 2018 05:47:55 -0400 (EDT)
User-agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/64.0.3282.140 Safari/537.36 Edge/17.17134

URL:
  <https://savannah.gnu.org/bugs/?54757>

                 Summary: Applying colormap to axes does not update the legend
                 Project: GNU Octave
            Submitted by: None
            Submitted on: Sun 30 Sep 2018 09:47:53 AM UTC
                Category: None
                Severity: 3 - Normal
                Priority: 5 - Normal
              Item Group: None
                  Status: None
             Assigned to: None
         Originator Name: Philip Yip
        Originator Email: 
             Open/Closed: Open
         Discussion Lock: Any
                 Release: 4.4.1
        Operating System: Microsoft Windows

    _______________________________________________________

Details:

In the following code the legend of the figure is not updated to include the
new colormap (in MATLAB it is):

% orange shades
orange=[237/255,112/255,20/255];
tangerine=[249/255,130/255,40/255];
merigold=[253/255,174/255,29/255];
cider=[181/255,103/255,39/255];
data=ones(4,1);
figure
pie(data);
colormap(gca,[orange;tangerine;merigold;cider]);
labels={'orange';'tangerine';'merigold';'cider'};
legend(labels,'Location','eastoutside');
title('orange shade wheel');

If the line:
colormap(gca,[orange;tangerine;merigold;cider]);
Is modified to:
colormap([orange;tangerine;merigold;cider]);
Then the colormap will be updated to update the legend.
However if subplots are used, it applies the last specified colormap to every
subplot in the plot.






    _______________________________________________________

Reply to this item at:

  <https://savannah.gnu.org/bugs/?54757>

_______________________________________________
  Message sent via Savannah
  https://savannah.gnu.org/




reply via email to

[Prev in Thread] Current Thread [Next in Thread]