Constructors

All MGraphic derived classes have a default constructor, a copy constructor, and a constructor that takes the corresponding geometry and an attribute bundle. For example, the overloaded constructors for a TArea are as follows:

      TArea();
      TArea( const TArea& anArea );
      TArea( const TGArea& anArea, TGrafBundle* adoptBundle );
The geometry classes have overloaded constructors that provide many ways to create a geometric shape. The constructors for a TGArea are the following:

      TGArea();
      TGArea( const TGRect& rectangle );
      TGArea( const TGEllipse& ellipse );
      TGArea( const TGLoop& loop );
      TGArea( const TGPolygon& polygon );
      TGARea( const TGGlyphRun& glyph );
      TGArea( const TGArea& area );
and the constructors for a TGEllipse are the following:

      TGEllipse();
      TGEllipse( const TGEllipse ellipse );
      TGEllipse( const TGRect rectangle );
      TGEllipse( const TGPoint& center, GCoordinate radius );
      TGEllipse( const TGPoint& center, GCoordinate xRadius, GCoordinate yRadius );
The graphics classes inherit MGraphic functions and accessor functions that let you manage the geometry data from within the graphic. The headings below list the 2D graphics classes and their member functions to give you an idea of the functionality that is available. All 2D graphics functions listed in these tables have default implementations that do not need to be overridden. See the online Class and Member function descriptions for parameter lists and information on how to use constructors and functions.


[Contents] [Previous] [Next]
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.

Generated with WebMaker