Graphics Object Properties

Properties for the graphics object in OML.

Root Properties

Property Name
Description/Values
children
A vector of figure handles, which are children of the root.
currentfigure
The handle of the current figure.
handle
The handle of the root, which is 0.
0
parent
The parent handle; null for the root object.
0
type
The type of the root object.
'root'
units
Units of measurement.
'pixels' | 'normalized'

Figure Properties

Property Name
Description/Values
bottomlabel
Handle of the label that is placed on the bottom area of the figure.
Note: Use the set command to set the contents of the label.
Type: string | cell.
children
A vector of axes handles, which are the children of the figure.
currentaxes
Handle of the current axes of the figure.
handle
Handle of the figure object.
Integer.
leftlabel
Handle of the label that is placed on the left area of the figure.
Note: Use the set command to set the contents of the label.
Type: string | cell.
parent
Parent handle, which is always 0 (root).
0
position
Location and size of the figure.
The location is specified by the upper-left point, and the size is specified by the width and height.
Note: This property is only valid for floating figure. If you change this property for a docked figure, there will be no effect, but after undocking the figure, the size/position will be updated accordingly.
[left top width height]
rightlabel
Handle of the label that is placed on the right area of the figure.
Note: Use the set command to set the contents of the label.
Type: string | cell.
toplabel
Handle of the label that is placed on the top area of the figure.
Note: Use the set command to set the contents of the label.
Type: string | cell.
type
Type of figure object.
'figure'
units
Units of measurement.
'pixels' | 'normalized'
uicontextmenu
Handle of the uicontextmenu object associated with this figure, if it exists.
visible
Visibility of the figure.
'on' | 'off'

Axes Properties

Property Name
Description/Values
bargap (2D bar plot only)
Gap between bars.
Integer
barlabels (2D bar chart plot only)
Show the value over each bar.
'off' | 'on'
barlabelsfontangle (2D bar chart plot only)
Font angle for the bar labels.
'regular' | 'italic'
barlabelsfontname (2D bar chart plot only)
Font name for the bar labels.
Any available font from the system.
barlabelsfontsize (2D bar chart plot only)
Font size for the bar labels.
Integer
barlabelsfontweight (2D bar chart plot only)
Font weight for the bar labels.
'normal' | 'bold'
barorientation (2D bar chart plot only)
Orientation of the bars.
'horizontal' | 'vertical'
children
A vector of handles, which are the children of the axes.
color
Background color of the axes.
1*3 matrix of RGB | colorname
colorbarscale
Scale of the colorbar values.
'linear' | 'log' | 'db10' | 'db20'
colorlevels
The colorbar values.
Note: The set command for this property accepts either an integer or a real vector. Use a real vector to set custom values to the colorbar. Use an integer to define the number of colors in the colorbar. In this case, the range and values of the colorbar are automatically calculated. The maximum number of colors is 32.
Integer or real vector.
contourtype
Type of contour.
'blended' | 'discrete' | 'none'
fontangle
Font angle of the axes.
'regular' | 'italic'
fontname
Axes font name.
Any available font from the system.
fontsize
Font size of the axes.
Integer
fontweight
Font weight of the axes.
'normal' | 'bold'
handle
Handle of the axes object.
Double
mouseclickcallback
Callback function triggered by a mouse click on a 2D plot.
Function handle
parent
Handle of the parent figure.
plottiptotail (polar plot only)
Enable creation of a tip-to-tail curve.
'off' | 'on'
polarmethod (polar plot only)
The polar method of the plot.
'phasevsmag' | 'vector' | 'radar'
position
Location and size of the axes in the figure.
Location is specified by the upper-left point; size is specified by the width and height
[left top width height]
title
Handle of the title, which is a text object.
type
Type of axes object.
'axes'
units
Units of measurement.
'normalized' | 'pixels'
visible
Visibility of the axes.
'on' | 'off'
xcategories (bar chart plots only)
Labels for the x category axis of a bar plot.
Cell
xcolor
Color of the x axis.
1*3 matrix of RGB | colorname
xgrid
Status of the x axis grid lines.
'off' | 'on'
xlabel
Handle of the label of the x axis, which is a text object.
xminorgrid
Status of the x axis minor grid lines.
'off' | 'on'
xnumericformat
Displays the format of the x axis values.
'auto' | 'fixed' | 'scientific'
xnumericprecision
Number of digits following the decimal point of the x axis values.
Integer
xscale
Scale of the x axis.
'linear' | 'log' | 'db10' | 'db20'
xtick
Number of tics on the x axis.
Note: If the axis scale is logarithmic, decibels, or dB10, this property refers to tics per decade. The accepted values are:
  • 0, 1, 2, 5, 9 or 18 for logarithmic.
  • 0, 1, 2, 4, 10 or 20 for decibels.
  • 0, 1, 2, 4 or 10 for dB10.
Integer
xtickmethod
The method for calculating the number of tics for the x axis.
'increment' | 'ticks'
ycategories (3D bar chart plots only)
Labels for the y category axis of a 3D bar chart plot.
Cell
ycolor
Color of the y axis.
1*3 matrix of RGB | colorname
ygrid
Status of the y axis grid lines.
'off' | 'on'
ylabel
Handle of the label of y axis, which is a text object.
yminorgrid
Status of the y axis minor grid lines.
'off' | 'on'
ynumericformat
Display format of the y axis values.
'auto' | 'fixed' | 'scientific'
ynumericprecision
Number of digits following the decimal point of the y axis values.
Integer
yscale
Scale of the y axis.
'linear' | 'log' | 'db10' | 'db20'
ytick
Number of tics on the y axis.
Note: If the axis scale is logarithmic, decibels, or dB10, this property refers to tics per decade and the accepted values are:
  • 0, 1, 2, 5, 9 or 18 for logarithmic.
  • 0, 1, 2, 4, 10 or 20 for decibels.
  • 0, 1, 2, 4 or 10 for dB10.
Integer
ytickmethod
The method for calculating the number of tics for the y axis.
'increment' | 'ticks'
zcolor
Color of the z axis.
1*3 matrix of RGB | colorname
zgrid
Status of the z axis grid lines.
'off' | 'on'
zlabel
Handle of the label of z axis, which is a text object.
zminorgrid
Status of the z axis minor grid lines.
'off' | 'on'
znumericformat
Display format of the z axis values.
'auto' | 'fixed' | 'scientific'
znumericprecision
Number of digits following the decimal point of the z axis values.
Integer
zscale
Scale of the z axis.
'linear' | 'log' | 'db10' | 'db20'
ztick
Number of tics on the z axis.
Note: If the axis scale is logarithmic, decibels, or dB10, this property refers to tics per decade and the accepted values are:
  • 0, 1, 2, 5, 9 or 18 for logarithmic.
  • 0, 1, 2, 4, 10 or 20 for decibels.
  • 0, 1, 2, 4 or 10 for dB10.
Integer
ztickmethod
The method for calculating the number of tics for the z axis.
'increment' | 'ticks'

Y-axis Properties

Property Name
Description/Values
children
A vector of handles, which are the children of the axis.
fontangle
Font angle of the axis.
'regular' | 'italic'
fontname
Font name of the axis.
Any available font from system.
fontsize
Font size of the axis.
Integer
fontweight
Font weight of the axis.
'normal' | 'bold'
handle
Axis object handle.
Double
parent
Parent axis object handle.
tag
A tag attached to the axis.
String
type
Type of the axis object.
'axes'
units
Units of measurement.
'normalized' | 'pixels'
visible
Visibility of the axis.
'on' | 'off'
ycolor
Axis color.
1*3 matrix of RGB | colorname
ylabel
Handle of the axis label, which is a text object.
yscale
Axis scale.
'linear' | 'log' | 'db10' | 'db20'
ytick
Number of ticks on the axis.
Integer

Line Properties

Property Name
Description/Values
children
Children of the line object, currently an empty matrix.
color
Line color.
1*3 matrix of RGB | colorname
dataxoffset
Shifts the data along the x axis.
Double
datayoffset
Shifts the data along the y axis.
Double
datazoffset
Shifts the data along the z axis.
Double
dataxscale
Scales the data in the x axis.
Double
datayscale
Scales the data in the y axis.
Double
datazscale
Scales the data in the z axis.
Double
handle
Handle of the line object.
linestyle
The line style.
'-' | '--' | '-.' | ':' | 'none'
linewidth
Width of the line.
Integer
marker
Line marker.
's' | 'square' | '^' | 'v' | 'x' | 'o' | 'd' | 'diamond' | '+' | '*' | '.' | 'none'
markerevery
Frequency of line markers.
Integer
markerfacecolor
Color of the line marker.
1*3 matrix of RGB | colorname
markersize
Size of the marker.
Integer
parent
Handle of the parent axes.
0
tiptotail (polar plot only)
Enables participation of the line in the tip-to-tail curve.
'on' | 'off'
type
The type of line object.
'line'
units
Units of measurement.
'pixels' | 'normalized'
visible
Visibility of the line.
'on' | 'off'

Surface Properties

Property Name
Description/Values
children
Children of the surface object, currently an empty matrix.
color
Surface color.
1*3 matrix of RGB | colorname
handle
Handle of the surface object.
meshlines
Visibility of the surface mesh lines.
'on' | 'off'
parent
Handle of the parent axes.
0
type
Surface object type.
'surface'
units
Units of measurement.
'pixels' | 'normalized'
visible
Visibility of the surface.
'on' | 'off'

Text Properties

Property Name
Description/Values
borderwidth
The width of the text's border line.
Integer
children
Children of the text object, currently an empty matrix.
color
The text color.
1*3 matrix of RGB | colorname
fontangle
The font angle of the text.
'regular' | 'italic'
fontname
The text's font name.
Any available fonts from the system.
fontsize
The text's font size.
Integer
fontweight
The font weight of the text.
'normal' | 'bold'
handle
The handle of the text object.
Double
horizontalalignment
The horizontal alignment of the text box relative to the given x,y coordinate. Supported in 2D plots only.
'center' | 'left' | 'right'
offset
The distance between the given x,y coordinate and the text box. Supported in 2D plots only.
Double
parent
The handle of the parent object.
Double
string
The content of the text object.
type
The text object type.
'text'
units
The units of measurement.
'pixels' | 'normalized'
verticalalignment
The vertical alignment of the text box relative to the given x,y coordinate. Supported in 2D plots only.
'middle' | 'top' | 'bottom'
visible
Visibility of the text object.
'on' | 'off'

uicontextmenu Properties

Property Name
Description/Values
callback
Callback function of the uicontextmenu object.
Function handle, string or cell reprepresenting the callback.
children
Children of the uicontextmenu object, which are the added uicontextmenuitem objects.
Real vector.
enable
Indicates if uicontextmenu object is enabled, default value being 'on'
'on' (default) | 'off'
handle
Handle of the uicontextmenu object.
parent
Handle of the parent object.
position
Index the uicontextmenu in the parent.
Positive integer.
separator
Indicates if there needs to be a separator added before the uicontextmenuitem object, if applicable.
'off' (default) | 'on'
tag
User-defined string to tag graphical control objects.
String
type
The type of the uicontextmenu object.
'uicontextmenu'
userdata
User-defined matrix data
visible
Specifies if uicontextmenu object is visible
'on'(default) | 'off'

uicontextmenuitem Properties

Property Name
Description/Values
callback
Callback function of the uicontextmenuitem object.
Function handle, string or cell reprepresenting the callback.
children
Children of the uicontextmenuitem object.
Real vector.
enable
Indicates if uicontextmenuitem is enabled.
'on' (default) | 'off'
handle
Handle of the uicontextmenuitem object.
parent
Handle of the uicontextmenu/uicontextmenuitem parent object.
position
Index of the uicontextmenuitem object in the parent.
Positive integer.
separator
Indicates if there needs to be a separator added before the uicontextmenuitem object, if applicable.
'off' (default) | 'on'
tag
User-defined string to tag graphical objects.
String
type
The type of the object.
'uicontextmenuitem'
userdata
User-defined matrix data
visible
Specifies if uitabgroup is visible
'on'(default) | 'off'

uicontrol Properties

Property Name
Description/Values
backgroundcolor
Background color of the object.
String or real vector.
callback
Callback function of the user interface control (uicontrol) object.
Function handle or string.
children
The children of the uicontrol object, currently an empty matrix.
fontangle
The font angle of the uicontrol.
'regular' | 'italic'
fontname
The font name of the uicontrol.
Any available font from the system.
fontsize
The font size of the uicontrol.
Integer
fontweight
The font weight of the uicontrol.
'normal' | 'bold'
handle
The handle of the uicontrol object.
max
The maximum value for the uicontrol.
Integer
min
The minimal value of the uicontrol.
Integer
parent
The handle of the parent object.
Scalar
position
Location and size of the uicontrol in the figure.
Location is specified by the upper-left point; size is specified by the width and height.
[left top width height]
string
Label displayed on the uicontrol object.
tag
User-defined string to the uicontrol object.
String
tooltipstring
Tooltip string displayed when mouse moves over the uicontrol object.
String
type
The uicontrol object type, which is read-only .
'uicontrol'
uicontextmenu
Handle of the uicontextmenu object associated with this object, if it is applicable for this style and if it exists.
units
Units of measurement.
'pixels' | 'normalized'
value
Current value of the uicontrol.
Integer

uimenu Properties

Property Name
Description/Values
children
Children of the uimenu object, which are the added uimenuitem objects.
Real vector.
enable
Indicates if uimenu object is enabled, default value being 'on'
'on' (default) | 'off'
handle
Handle of the uimenu object.
label
Label of the uimenu object.
String.
parent
Handle of the parent object.
position
Index the uimenu in the parent menubar.
Positive integer.
tag
User-defined string to tag graphical control objects.
String
type
The type of the uimenu object.
'uimenu'
userdata
User-defined matrix data

uimenuitem Properties

Property Name
Description/Values
callback
Callback function of the uimenuitem object.
Function handle, string or cell reprepresenting the callback.
children
Children of the uimenuitem object.
Real vector.
enable
Indicates if uicmenuitem is enabled.
'on' (default) | 'off'
handle
Handle of the uimenuitem object.
Double
label
Label of the uimenuitem object.
String
parent
Handle of the uimenu/uimenuitem parent object.
Double
position
Index of the uimenuitem object in the parent.
Positive integer.
separator
Indicates if there needs to be a separator added before the uimenuitem object, if applicable.
'off' (default) | 'on'
tag
User-defined string to tag graphical objects.
String
type
The type of the object.
'uimenuitem'
userdata
User-defined matrix data
visible
Specifies if uimenuitem is visible
'on'(default) | 'off'

uipanel Properties

Property Name
Description/Values
aspectratio
Specifies if the aspect ratio of a background image is ignored ('off') or kept ('on').
'off' (default) | 'on'
backgroundcolor
Background color of the object.
String or real vector.
backgroundimage
Path to a valid image file which is shown in the background of the uipanel object.
String.
children
The children of the uipanel object; defaults to an empty matrix.
fontangle
Specifies the angle of the displayed font.
'regular' | 'italic'
fontname
Specifies name of the displayed font.
String
fontsize
Specifies the size of the displayed font.
Scalar
fontweight
Specifies the weight of the displayed font.
'normal' | 'bold'
Scalar
handle
The handle of the uipanel object.
parent
The handle of the parent object.
Scalar
position
Location and size of the object in the figure.
Location is specified by the upper-left point; size is specified by the width and height.
[left, top, width, height]
string
Label displayed on the uicontrol object.
tag
User-defined string to the uipanel object.
String
type
The object type.
'uipanel'
units
Specifies units of measurement.
'pixels' | 'normalized'
userdata
User-defined numerical data.
Any complex, matrix, or scalar values.
visible
Specifies if the object is visible or not.
'on' | 'off'

uitab Properties

Property Name
Description/Values
children
Children of the uitab object.
Real vector.
enable
Indicates if uitab is enabled.
'on' (default) | 'off'
fontangle
Font angle; applies to all uitabs in this group.
'regular' (default) | 'italic'
fontname
Font name; applies to all uitabs in this group.
Any available font from the system.
fontsize
Font size; applies to all uitabs in this group.
Integer
fontweight
Font weight; applies to all uitabs in this group.
'normal' (default) | 'bold'
handle
Handle of the uitab object.
parent
Handle of the uitabgroup parent object.
position
Location and size of the uitab object.
The location is specified by the upper-left point; size is specified by the width and height.
[left top width height]
tag
User-defined string to tag graphical control objects.
String
tooltipstring
Tooltip string displayed when the mouse moves over the uitab object.
String
title
Title of the uitab object.
String
type
The type of the uitabgroup object.
'uitab'
uicontextmenu
Handle of the uicontextmenu object associated with this tab, if it exists.
units
Units of measurement.
'pixels' | 'normalized'
userdata
User-defined matrix data.
visible
Specifies if uitabgroup is visible.
'on'(default) | 'off'

uitabgroup Properties

Property Name
Description/Values
children
Children of the uitabgroup object, which are the added uitabs.
Real vector.
enable
Indicates if uitabgroup is enabled; default value is 'on'.
'on' (default) | 'off'
fontangle
Font angle of the uitabgroup; applies to all uitabs in this group.
'regular' (default) | 'italic'
fontname
Font name of the uitabgroup; applies to all uitabs in this group.
Any available font from the system.
fontsize
Font size of the uitabgroup; applies to all uitabs in this group.
Integer
fontweight
Font weight of the uitabgroup; applies to all uitabs in this group.
'normal' (default) | 'bold'
handle
Handle of the uitabgroup object.
parent
Handle of the parent object.
position
Location and size of the uitabgroup in the parent.
The location is specified by the upper-left point; size is specified by the width and height.
[left top width height]
selectedtab
Handle of the uitab child object that needs to be selected.
Scalar
tag
User-defined string to tag graphical control objects.
String
tooltipstring
Tooltip string displayed when the mouse moves over the uitabgroup object.
String
type
The type of the uitabgroup object.
'uitabgroup'
units
Units of measurement.
'pixels' | 'normalized'
userdata
User-defined matrix data.
visible
Specifies if uitabgroup is visible.
'on'(default) | 'off'

uitable Properties

Property Name
Description/Values
backgroundcolor
Background color of the object.
String or real vector.
celleditcallback
Callback function when the value of a cell is changed in uitable.
Function handle or string.
children
The children of the uipanel object; defaults to an empty matrix.
columneditable
true or false, indicating which column(s) are editable.
columnformat
A cell with values of 'char', 'numeric' or [] indicating the format for the specific column for aligning the text.
columnname
Column names.
'numbered'(default) | cell of label(s).
columnwidth
Width of the table column(s) or 'auto', which is the default.
data
Table contents.
enable
Indicates if the table is enabled; default value is 'on'.
fontangle
Specifies the angle of the displayed font.
'regular' | 'italic'
fontname
Specifies the name of the displayed font.
String
fontsize
Specifies the size of the displayed font.
Scalar
fontweight
Specifies the weight of the displayed font.
'normal' | 'bold'
Scalar
handle
The handle of the uitable object.
parent
The handle of the parent object.
Scalar
position
Location and size of the object in the figure.
Location is specified by the upper-left point; size is specified by the width and height.
[left, top, width, height]
rowheight
Height of the table row(s) or 'auto', which is the default.
rowname
Row label(s).
'numbered'(default) | cell of label(s).
tag
User-defined string to the uipanel object.
String
tooltipstring
Tooltip string displayed when the mouse moves over the uitable object.
String
type
The object type.
'uitable'
units
Specifies units of measurement.
'pixels' | 'normalized'
userdata
User-defined numerical data.
Any complex, matrix, or scalar values.
visible
Specifies if the object is visible or not.
'on' | 'off'

Hggroup Properties

Property Name
Description/Values
areagroup (area plot only)
A vector of handles, which point to area groups.
basevalue (area plot only)
Base value of the shading.
Double
bargroup (bar chart plot only)
A vector of handles, which point to bar groups.
barlayout (bar chart plot only)
The bar layout style.
'grouped' | 'stacked'
barstyle (bar chart plot only)
The bar style.
Integer in the range [0,4]
barwidth (bar chart plot only)
The width of the bars.
Integer
dataxoffset
Shifts the data along the x axis.
Double
datayoffset
Shifts the data along the y axis.
Double
datazoffset
Shifts the data along the z axis.
Double
dataxscale
Scales the data in the x axis.
Double
datayscale
Scales the data in the y axis.
Double
datazscale
Scales the data in the z axis.
Double
imgrid (imagesc plot only)
Visibility of the image grid.
'off' | 'on'
marker (scatter plot only)
marker style
's' | 'square' | '^' | 'v' | 'x' | 'o' | 'd' | 'diamond' | '+' | '*' | '.' | 'none'
markerfacecolor (scatter plot only)
The marker color.
1*3 matrix of RGB | colorname
children
The children of the hggroup object.
facecolor
The object color.
1*3 matrix of RGB | colorname
handle
The handle of the hggroup object.
parent
The handle of the parent axes.
0
type
The type of the hggroup object.
'hggroup'
units
The units of measurement, currently not used.
'pixels' | 'normalized'
visible
Visibility of the hggroup object.
'on' | 'off'

Image Properties

Property Name
Description/Values
children
The children of the image object, currently an empty matrix.
filepath
The filepath.
handle
The handle of the image object.
parent
The handle of the parent object.
0
position
The location and size of the image in the figure. The location is specified by the upper-left point, and the size is specified by the width and height.
[left top width height]
type
The image object type.
'image'
units
Units of measurement (not yet used).
'pixels' | 'normalized'

Shape Properties

Property Name
Description/Values
children
Children of the shape object; an empty matrix for now.
curvature
Curvature for the horizontal and vertical edge.
[h-curvature v-curvature]
edgecolor
Color of the shape's border.
1*3 matrix of RGB | colorname
facecolor
Color to fill the shape.
1*3 matrix of RGB | colorname
handle
Handle of the shape object.
Double
linestyle
Edge style.
'-' | '--' | '-.' | ':' | 'none'
linewidth
Edge width.
Integer
parent
handle of the parent object, which is a handle of the figure.
Integer
position
Location and size of the shape in the figure. Location is specified by the upper-left point, size is specified by the width and height.
[left top width height]
tag
A tag attached to the shape.
String
type
Shape object type.
'hggroug'
units
Units of measurement, (currently not used).
'pixels' | 'normalized'
visible
Shape visibility.
'on' | 'off'