copyobj
Copy graphics objects and their children
Description
creates a copy of the specified graphics object, assigns it to the specified new parent, and
returns the new object. If newobj
= copyobj(obj
,parent
)obj
has children,
copyobj
copies them as well.
copyobj
does not copy properties or child objects that depend on
their original context, including callback properties or any application data associated
with the original object. For more information, see What Is Not Copied.
Examples
Input Arguments
Output Arguments
More About
Tips
When copying a legend or a colorbar, you must also copy the associated axes.
When building a user interface, do not call
copyobj
ortextwrap
(which callscopyobj
) inside a creation function. Copying a user interface control object calls the creation function repeatedly, exceeding the recursion limit and therefore causing an error.
Version History
Introduced before R2006a