GETARCINFO

Graphics Function: Determines the endpoints (in viewport coordinates) of the most recently drawn arc or pie.

Module: USE DFLIB

Syntax

result = GETARCINFO (pstart, pend, ppaint)

pstart
(Output) Derived type xycoord. Viewport coordinates of the starting point of the arc.


pend
(Output) Derived type xycoord. Viewport coordinates of the end point of the arc.


ppaint
(Output) Derived type xycoord. Viewport coordinates of the point at which the fill begins.

Results:

The result is of type INTEGER(2). The result is nonzero if successful. The result is zero if neither the ARC nor the PIE function has been successfully called since the last time CLEARSCREEN or SETWINDOWCONFIG was successfully called, or since a new viewport was selected.

GETARCINFO updates the pstart and pend xycoord derived types to contain the endpoints (in viewport coordinates) of the arc drawn by the most recent call to the ARC or PIE functions. The xycoord derived type, defined in DFLIB.F90 (in the \DF98\INCLUDE subdirectory), is:

TYPE xycoord
  INTEGER(2) xcoord
  INTEGER(2) ycoord
END TYPE xycoord

The returned value in ppaint specifies a point from which a pie can be filled. You can use this to fill a pie in a color different from the border color. After a call to GETARCINFO, change colors using SETCOLORRGB. Use the new color, along with the coordinates in ppaint, as arguments for the FLOODFILLRGB function.

Compatibility

STANDARD GRAPHICS QUICKWIN GRAPHICS LIB

See Also: ARC, FLOODFILLRGB, GETCOLORRGB, GRSTATUS, PIE, SETCOLORRGB

Example

USE DFLIB
INTEGER(2) status, x1, y1, x2, y2, x3, y3, x4, y4
TYPE (xycoord) xystart, xyend, xyfillpt
x1 = 80; y1 = 50
x2 = 240; y2 = 150
x3 = 120; y3 = 80
x4 = 90; y4 = 180

status = ARC(x1, y1, x2, y2, x3, y3, x4, y4)
status = GETARCINFO(xystart, xyend, xyfillpt)
END