VectorImage::AddText
Adds a text to the VectorImage.
GSErrCode AddText ( short pen, short layer, short drwIndex, bool nonBreaking, long styleind, double x, double y, double width, double angle, unsigned char paramInd, long ind1, long ind2, double dScale, bool useDScale, char* text );
Parameters
- pen
- The drawing pen of the text.
- layer
- The containing layer of the text It should range from 1 to 16.
- drwIndex
- The drawing index of the text. It influences the drawing order of the item.
- nonBreaking
- True, if the text should be break at CR only. False if the text should break at the boundary of the enclosing rectangle.
- styleind
- The index of the font style.
- x
- The x co-ordinate of the anchor point.
- y
- The y co-ordinate of the anchor point.
- width
- The width of the enclosing box.
- angle
- The deflection of the baseline.
- paramInd
- Reserved, should be 0.
- ind1
- Reserved, should be 0.
- ind2
- Reserved, should be 0.
- dScale
- The default scale. 100 for the 1:100 scaling.
- useDScale
- Should we take into account the above dScale parameter.
- text
- The text contents.
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