PlotOval
int PlotOval (int panelHandle, int controlID, double x1, double y1, double x2, double y2, int color, int fillColor);
Purpose
Plots an oval onto a graph control.
Define the oval in terms of a rectangle that encloses it. You can define the rectangle by specifying two opposing corners, which you express in terms of x- and y-coordinates of the graph.
Supported Controls
You can use PlotOval with graph controls.
Parameters
Input | ||||||||||||||||||||||||||||||||||||||||||||
Name | Type | Description | ||||||||||||||||||||||||||||||||||||||||||
panelHandle | int | Specifier for a particular panel that is currently in memory. You can obtain this handle from functions such as LoadPanel and NewPanel. | ||||||||||||||||||||||||||||||||||||||||||
controlID | int | The defined constant, located in the .uir header file, that you assigned to the control in the User Interface Editor, or the ID returned by functions such as NewCtrl and DuplicateCtrl. | ||||||||||||||||||||||||||||||||||||||||||
x1 | double | Horizontal coordinate of one corner of the rectangle that encloses the oval. (X1,Y1) is one corner and (X2,Y2) is the opposing corner. |
||||||||||||||||||||||||||||||||||||||||||
y1 | double | Vertical coordinate of one corner of the rectangle that encloses the oval. (X1,Y1) is one corner and (X2,Y2) is the opposing corner. |
||||||||||||||||||||||||||||||||||||||||||
x2 | double | Horizontal coordinate of the opposing corner of the rectangle that encloses
the oval. (X1,Y1) is one corner and (X2,Y2) is the opposing corner. |
||||||||||||||||||||||||||||||||||||||||||
y2 | double | Vertical coordinate of the opposing corner of the rectangle that encloses the
oval. (X1,Y1) is one corner and (X2,Y2) is the opposing corner. |
||||||||||||||||||||||||||||||||||||||||||
color | int | Specifies the color of the data to plot. An RGB value is a 4-byte integer with the hexadecimal format 0x00RRGGBB. RR, GG, and BB are the respective red, green, and blue components of the color value. The first sixteen colors in the table are the sixteen standard colors.
You also can use the User Interface Library function, MakeColor, to create an RGB value from red, green, and blue color components. To enter user-defined color values, select Options»Toggle Control Style in the function panel and manually enter the color value. |
||||||||||||||||||||||||||||||||||||||||||
fillColor | int | The fill color of the figure. An RGB value is a 4-byte integer with the hexadecimal format 0x00RRGGBB. RR, GG, and BB are the respective red, green, and blue components of the color value. The first sixteen colors in the table are the sixteen standard colors.
You also can use the User Interface Library function, MakeColor, to create an RGB value from red, green, and blue color components. To enter user-defined color values, select Options»Toggle Control Style in the function panel and manually enter the color value. |
Return Value
Name | Type | Description | ||
plotHandle | int | The handle of the new plot that you can use in subsequent function calls to reference the plot. If the handle is positive, the new plot was successfully added to the graph. Negative values indicate that an error occurred.
|
Additional Information
Library: User Interface Library
Include file: userint.h
LabWindows/CVI compatibility: LabWindows/CVI 3.0 and later