oaEvalText Class Reference

Inheritance diagram for oaEvalText:

oaText oaShape oaPinFig oaConnFig oaFig oaBlockObject oaDesignObject oaObject


Public Methods

oaEvalTextLinkgetLink () const
void getExpression (oaString &text) const
void getEvaluatorName (oaString &name) const
void setLink (oaEvalTextLink *linkIn)

Static Public Methods

oaEvalText * create (oaBlock *block, oaLayerNum layerNum, oaPurposeNum purposeNum, const oaString &text, const oaPoint &origin, oaTextAlign alignment, oaOrient orient, oaFont font, oaDist height, oaEvalTextLink *linkIn=NULL, oaBoolean overbar=false, oaBoolean visible=true, oaBoolean drafting=true)
oaEvalText * create (oaBlock *block, oaLayerNum layerNum, oaPurposeNum purposeNum, const oaString &text, const oaPoint &origin, oaTextAlign alignment, oaOrient orient, oaFont font, oaDist height, const oaString &linkName, oaBoolean overbar=false, oaBoolean visible=true, oaBoolean drafting=true)

Detailed Description

The oaEvalText class implements an oaEvalText shape that is used to display a piece of text. The shape is derived from oaText and is very similar. The difference is that an oaEvalText is evaluated to determine what text string it should display. The oaEvalText still has a text field, but this is evaluated to generate the actual displayed text string. To support this capability, an oaTextDataCallBack argument is used to process the evaluation.


Member Function Documentation

oaEvalText * oaEvalText::create oaBlock *    block,
oaLayerNum    layerNum,
oaPurposeNum    purposeNum,
const oaString &    text,
const oaPoint &    origin,
oaTextAlign    alignment,
oaOrient    orient,
oaFont    font,
oaDist    height,
const oaString &    cbName,
oaBoolean    overbar = false,
oaBoolean    visible = true,
oaBoolean    drafting = true
[static]
 

This function creates an evaluated text object with the specified attributes using a dataObserver name as input. The corresponding oaTextDataObserver object does not have to exist. The observer object can be instantiated at any time.

Parameters:
block The block in which to create the evalText
layerNum The number of the layer on which the evalText is created
purposeNum The purpose number with which the evalText is created
text The text string to evaluate
origin The location of the origin of the evalText
alignment The horizontal and vertical alignment of the display text with respect to the origin
orient The orientation of the text
font The font style with which the text is displayed
height The height of the display text in user-units
cbName The name of the dataObserver to pass to the create function
overbar A boolean value that indicates if an overbar is used in the display of this value; the default is false
visible A boolean value that indicates if this evalText is displayed; the default is true (this value allows an application to turn ON or OFF the evalText display without having to delete it from the database)
drafting A boolean value that indicates if the text for this evalText should always be drawn left-to-right or top-to-bottom; the default is true (if drafting is true and the orientation of this evalText is mirrored, the text is drawn backwards)

oaEvalText * oaEvalText::create oaBlock *    block,
oaLayerNum    layerNum,
oaPurposeNum    purposeNum,
const oaString &    text,
const oaPoint &    origin,
oaTextAlign    alignment,
oaOrient    orient,
oaFont    font,
oaDist    height,
oaEvalTextLink *    linkIn = NULL,
oaBoolean    overbar = false,
oaBoolean    visible = true,
oaBoolean    drafting = true
[static]
 

This function creates an evaluated text object with the specified attributes.

Parameters:
block The block in which to create the evalText
layerNum The number of the layer on which the evalText is created
purposeNum The purpose number with which the evalText is created
text The text string to evaluate
origin The location of the origin of the evalText
alignment The horizontal and vertical alignment of the display text with respect to the origin
orient The orientation of the text
font The font style with which the text is displayed
height The height of the display text in user-units
linkIn This is the oaEvalTextLink for the evalText evaluator
overbar A boolean value that indicates if an overbar is used in the display of this value; the default is false
visible A boolean value that indicates if this evalText is displayed; the default is true (this value allows an application to turn ON or OFF the evalText display without having to delete it from the database)
drafting A boolean value that indicates if the text for this evalText should always be drawn left-to-right or top-to-bottom; the default is true (if drafting is true and the orientation of this evalText is mirrored, the text is drawn backwards)
Note: The specified oaEvalTextLink is a link to an application-provided evalText evaluator implementing the IEvalText class, which is used to interpret the text.

void oaEvalText::getEvaluatorName oaString &    name const
 

This function returns the name of the IEvalText used by this text object.

Parameters:
name the returned name of this text object's evaluator.

void oaEvalText::getExpression oaString &    text const
 

This function fills out the value text with the non-evaluated text of this oaEvalText object. To get the evaluated text, use the oaText::getText() API. The base oaText class function evaluates the text.

oaEvalTextLink * oaEvalText::getLink   const
 

This function returns the oaEvalTextLink used by this text object if it's evaluated.

void oaEvalText::setLink oaEvalTextLink *    linkIn
 

This function sets the oaEvalTextLink used by this text object to interpret the text string. If the interface is NULL, the text will not be interpreted.

Parameters:
linkIn The link to an application-provided evalText evaluator implementing the IEvalText class, which is used to interpret the text.


The documentation for this class was generated from the following files:

Return to top of page