2D graphics classes

The 2D graphics classes and their referenced 2D geometry classes are shown in Figure 31. The graphics classes are wrappers for their referenced geometry classes. The graphics classes have functions that let you manipulate the geometry from within the graphic without accessing the geometry functions directly. The advantage to the wrapper architecture is that the 2D graphics classes bring together the functionality of the geometry classes and the highlevel functionality of the MGraphic class.

The 2D geometry classes are based on the 2D computational and point array classes described in Chapter 2. For convenience, the 2-S geometry classes are divided into path geometry and areaenclosing geometry classes. Path geometry is lineoriented geometry that can be framed, but not filled. Areaenclosing geometry forms a closed shape that can be framed and filled.


This chapter describes the MGraphic derived classes and some of the geometry classes shown in Figure 31. In cases where the MGraphic derived class has all of the same functions as its corresponding geometry class, only the MGraphic derived class is described.

Also described in this chapter is the TGGlyphRun geometry class. TGGlyphRun has no corresponding MGraphic derived class. To display a text string, use TTextDisplay and other related Text system classes. The TGGlyphRun is intended for localized text layout systems only. See the heading "Glyph Runs" on page 67 for informaiton on glyph runs.

To create your own 2-D graphic, derive from MGraphic directly or from one of the MGraphic derived classes. The 2D geometry classes are not intended to be derived from and customized. Information on how to create your own custom graphic is in Chapter 11.

Include files
Constructors
Areas
Curves
Ellipses
Glyph Runs
Images
Lines
Loops
Polygons
Polylines
Fill algorithm for loops and polygons
Curves, loops, and knot vectors

[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