logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

Ellipse, S_Ellipse, F_Ellipse, SF_Ellipse, S_Circle, F_Circle, SF_Circle - abstract base class and

Description

       Ellipse is an abstract base class for  elliptical  structured  graphics  objects.   It  stores  geometric
       information  that such graphics require and provides helper functions for calculating extents and for hit
       detection.  Predefined subclasses include S_Ellipse,  F_Ellipse,  and  SF_Ellipse,  which  draw  stroked,
       filled,  and  stroked-filled  ellipses,  respectively;  and S_Circle, F_Circle, and SF_Circle, which draw
       stroked, filled, and stroked-filled circles, respectively.  The stroked subclasses store a  PSBrush,  the
       filled subclasses store a PSPattern, and the stroked-filled subclasses store one of each.

Ellipse Protected Operations

Ellipse(Coordx,Coordy,intrx,intry,Graphic*=nil)
              The constructor is protected to disallow instantiation of the abstract base class.   An  ellipse's
              geometry is defined in terms of its center and its horizontal and vertical radii.  The constructor
              also takes an optional graphic from which to obtain an initial set of graphics state.

       voids_getExtent(float&,float&,float&,float&,float&,Graphic*)voidf_getExtent(float&,float&,float&,float&,float&,Graphic*)booleans_contains(PointObj&,Graphic*)booleanf_contains(PointObj&,Graphic*)booleans_intersects(BoxObj&,Graphic*)booleanf_intersects(BoxObj&,Graphic*)
              Helper  functions  that return extent and hit detection information based on the bounding box that
              the ellipse defines.  s_getExtent, s_contains, and s_intersects return information  that  accounts
              for  the  width  of  a  brush, as would be necessary if the ellipse is stroked, while f_getExtent,
              f_contains, and f_intersects  assumes  that  the  ellipse  is  filled.   Subclasses  can  use  the
              operations to help implement their getExtent, contains, and intersects operations.

Ellipse Public Operations

voidGetOriginal(Coord&x,Coord&y,int&rx,int&ry)
              Return  the  ellipse's  geometry.  (x,y) defines the ellipse's center, while rx and ry define its
              horizontal and vertical radii, respectively.

Name

       Ellipse,  S_Ellipse,  F_Ellipse,  SF_Ellipse,  S_Circle,  F_Circle,  SF_Circle  - abstract base class and
       predefined subclasses for elliptical structured graphics

See Also

Graphic(3U), geomobjs(3U), pspaint(3U)

Unidraw                                          2 February 1991                                    ellipses(3U)

Subclass Public Operations

S_Ellipse(Coordx,Coordy,intrx,intry,Graphic*=nil)F_Ellipse(Coordx,Coordy,intrx,intry,Graphic*=nil)SF_Ellipse(Coordx,Coordy,intrx,intry,Graphic*=nil)S_Circle(Coordx,Coordy,intradius,Graphic*=nil)F_Circle(Coordx,Coordy,intradius,Graphic*=nil)SF_Circle(Coordx,Coordy,intradius,Graphic*=nil)
              Constructors for the various predefined Ellipse subclasses.

Synopsis

#include<Unidraw/Graphic/ellipses.h>

See Also