Colorbar's colormap not updating when also adding a label to the bar
<p>Below's some code that generates a figure that has a colorbar with a custom label:</p>

<pre><code>function q41269479
% Create an axes:
figure();
% Display an image:
hIm = imagesc(peaks);
% Adjust colormap and colorbar:
h = colorbar; colormap(gray);
ylabel(h, '\Delta', 'Rotation', 0, 'Units', 'Normalized', 'Position', [0.48 1.05]);
</code></pre>

<p>What I <strong>expect to get</strong>:
<a href="https://i.stack.imgur.com/xWYNB.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/xWYNB.png" alt="Expected result"></a></p>

<p>What I <strong>actually get</strong>:
<a href="https://i.stack.imgur.com/r5Z6V.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/r5Z6V.png" alt="enter image description here"></a></p>

<p>Notice that the <code>colorbar</code> is still <code>parula</code> (the default) and not <code>gray</code> as I asked it politely to be.</p>

<p>The natural way to solve some graphical glitch like this is by "invalidating" the figure... Unfortunately, the popular commands <code>drawnow</code> and <code>refresh</code>, executed after the figure is at the shown state, do not remedy this situation. </p>

<p>It should be noted that exporting the figure results in the correct colors.</p>

<p><strong>Question:</strong> Does anybody have an idea why this happens and how to fix it (preferably without workarounds / hacks)?</p>

<p>I'm running R2016b, on Win 7. As far as I know, this does not happen on Octave 4.0.3.</p>