VectorImage::AddLine
Adds a straight line to the VectorImage.
GSErrCode AddLine ( short pen, short pattern, short layer, short drwIndex, double x1, double y1, double x2, double y2 );
Parameters
- pen
- The drawing pen of the line.
- pattern
- The index of the used line type attribute.
- layer
- The containing layer of the line It should range from 1 to 16.
- drwIndex
- The drawing index of the line. It influences the drawing order of the item.
- x1
- The x co-ordinate of the start of the line in the model in meters.
- y1
- The y co-ordinate of the start of the line in the model in meters.
- x2
- The x co-ordinate of the end of the line in the model in meters.
- y2
- The y co-ordinate of the end of the line in the model in meters.
Return value
If the function succeeds, the return value is NoError. If the function fails, the return value is the error code.
Description
Addition always merges the new item to the end of the primitives list but drawing order can differ from placing order.
Requirements
- Version:API 10.0 or later, ModelerGraphics 8 or later
- Library:ModelerGraphicsImp.lib (Win) or ModelerGraphics.framework (Mac)
- Header:VectorImage.hpp