Documentation de Gambas - /comp/gb.qt4/paint/ellipse

/comp/gb.qt4/paint/ellipse

# Paint.Ellipse (gb.qt4)

Static Sub Ellipse ( X As Float, Y As Float, Width As Float, Height As Float [ , Angle As Float, Length As Float, Pie As Boolean ] )

Adds an elliptic arc to the current path. The ellipse is defined by its (X, Y, Width, Height) bounding-box, begins at Angle and proceeds counter-clockwise during Length radians.

- X, Y, Width, Height : The bounding-box of the ellipse.

- Angle : the start angle, in radians.

- Length : the arc length, in radians.

- Pie : if a pie should be drawn instead of a chord. By default a chord is drawn.

If Length is negative, then the arc is drawn clockwise.

If Angle and Length are not specified, then a full ellipse is drawn.

If Angle is specified, but not Length, then nothing is drawn, and the current position is set to the point on the ellipse at the specified Angle.

Angles are measured in radians. An angle of `0.0` is in the direction of the positive X axis (in user space). An angle of `π/2.0` radians (`90` degrees) is in the direction of the positive Y axis (in user space). Angles increase in the direction from the positive X axis toward the positive Y axis. So with the default transformation matrix, angles increase in a clockwise direction.

To convert from degrees to radians, use the Rad function.