Examples

The polygons shown in Figure 94 are drawn with the special purpose attribute bundles created in the code fragment below. To keep the code fragment concise, creating the polygon geometry and calling the Draw functions are not shown, and transfer modes are not used.


    1  TFrameBundle frameBundle( TRGBColor( 0,0,0 ), 5.0 );
    2  TFillBundle fillBundle( TRGBColor( .75,.25,.25 ) );
    3  TFillAndFrameBundle fillFrameBundle(    TRGBColor( .75, .25, .25 ),
    4                                          TRGBColor( 0, 0, 0 ),
    5                                          5.0, TPen::kOutsetFrame );
    6  THairlineFrameBundle hairFrameBundle( TRGBColor( 0, 0, 0 ) );
    7  TFillAndHairlineFrameBundle hairFillFrameBundle(TRGBColor( .75, .75, .75 ), 
    8                                                  TRGBColor( 0, 0, 0 ) ); 
Line 1: Frame bundle with black frame, 5.0 world-coordinate unit pen width, and the default, kCenterFrame, pen balance to center the frame over the geometry border.

Line 2: Fill bundle that defines a red fill. There is no frame specification.

Lines 3 through 5: Fill and frame bundle with a red fill, black frame, 5.0 worldcoordinate unit pen width, and kOutsetFrame pen balance to put the frame on the outer edge of the fill.

Line 6: Hairline frame bundle with a black hairline frame that efficiently draws a thin, centered frame.

Line 7: Fill and hairline frame bundle with a light gray fill (to make the frame visible) and a black hairline frame.


[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