Documentation

This is machine translation

Translated by Microsoft
Mouse over text to see original. Click the button below to return to the English verison of the page.

Graphics Object Identification

Finding, copying, and deleting graphics objects

Functions

gca Current axes handle
gcf Current figure handle
gcbf Handle of figure containing object whose callback is executing
gcbo Handle of object whose callback is executing
gco Handle of current object
groot Graphics root object
ancestor Ancestor of graphics object
allchild Find all children of specified objects
findall Find all graphics objects
findobj Locate graphics objects with specific properties
findfigs Find visible offscreen figures
gobjects Initialize array for graphics objects
isgraphics True for valid graphics object handles
ishandle Test for valid graphics or Java object handle
copyobj Copy graphics objects and their descendants
delete Delete files or objects

Examples and How To

Find Objects

The findobj function can scan the object hierarchy to obtain the handles of objects that have specific property values.

Copy Objects

Copy objects from one parent to another using the copyobj function.

Delete Graphics Objects

Remove graphics objects with the delete function.

Concepts

Special Object Identifiers

MATLAB® provides functions that return important object handles so that you can obtain these handles whenever you require them.

Was this topic helpful?