Documentation Center

  • Trial Software
  • Product Updates

restack

Restack objects within map axes

restack will be removed in a future release. Use uistack instead.

Syntax

restack(h,position)

Description

restack(h,position) changes the stacking position of the object h within the axes. h can be a handle, a vector of handles to graphics objects, or a name string recognized by handlem. Recognized position strings are 'top', 'bottom', 'bot', 'up', or 'down'.

Examples

Restack the great lakes to lie on top of conus:

figure; axesm miller
load conus
h = geoshow(gtlakelat, gtlakelon,...
    'DisplayType', 'polygon', 'FaceColor', 'cyan');
geoshow(uslat, uslon,...
    'DisplayType', 'polygon', 'FaceColor', [0.6 0.3 0.8])
% The great lakes were plotted first but need to be on top
% Cast handle to great lakes object to double in call to RESTACK
restack(double(h),'top')

More About

expand all

Tips

This function is the command line equivalent of the stacking buttons in the mobjects graphical user interface. The stacking order is the order of the children of the axes.

See Also

Was this topic helpful?