Taxonomy Categories:
Member Functions:
Interface Category:
API.
Inherits From:
TLineStyle
Inherited By:
TDoubleUnderlineStyle
Purpose:
TUnderlineStyle, derived from TLineStyle, controls the placement and thickness of an underline. Units are assumed to be fractions of a point (approximately: 1/72 of an inch).
A TUnderlineStyle is positioned relative to the baseline and descent of the text. An offset factor of 0 positions the underline on the baseline, and an offset factor of 1 on the descent. See the description of TLineStyle for more information.
Instantiation:
Allocate on the heap or the stack.
Deriving Classes:
Derive classes to provide different types of underlining.
Concurrency:
Multithread safe.
Resource Use:
No special requirements.
Member Function: TUnderlineStyle::GetUnderlineName
virtual TToken & GetUnderlineName () const
Interface Category:
API.
Purpose:
Returns the name of this specific underlining class. Underlining classes have additional underline names identifying the type of underlining; they share the same style name because you cannot apply more than one type of underlining style to the same character.
Calling Context:
Call to get the underline name of this class, for example, when comparing object.
Parameters:
Return Value:
The underline name of this class as a TToken instance.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Multithread safe.
Other Considerations:
None.
virtual const TStyleName & GetName () const
Interface Category:
API.
Purpose:
Returns the style's internal name. This is not necessarily the class name. For example, there are related underlining styles that are each separate derived classes. However, because they are mutually exclusive, they share the same internal name.
Calling Context:
Called when the name associated with an object is needed; for example, when comparing objects.
Parameters:
Return Value:
The TToken for the associated name.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Multithread safe.
Other Considerations:
None.
virtual TStream & operator <<= (TStream & fromWhere)
Interface Category:
API.
Purpose:
Stream-in operator.
Calling Context:
Called to stream in data.
Parameters:
- TStream & fromWhere -The stream the object streams itself in from.
Return Value:
Returns a reference to the stream the object streams itself in from.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Multithread safe.
Other Considerations:
None.
virtual TStream & operator >>=(TStream & toWhere) const
Interface Category:
API.
Purpose:
Stream-out operator.
Calling Context:
Called to stream out data.
Parameters:
- TStream & toWhere -The stream the object streams itself out to.
Return Value:
Returns a reference to the stream the object streams itself out to.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Multithread safe.
Other Considerations:
None.
virtual bool operator ==(const TStyle & thatStyle) const
Interface Category:
API.
Purpose:
Equality operator.
Calling Context:
Called to compare two objects.
Parameters:
- const TStyle & thatStyle -The object to compare with this object.
Return Value:
Returns true if the objects are equal.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Multithread safe.
Other Considerations:
None.
virtual ~ TUnderlineStyle ()
Interface Category:
API.
Purpose:
Destructor.
Calling Context:
Called to destroy an object.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Multithread safe.
Other Considerations:
None.
- TUnderlineStyle ()
- TUnderlineStyle (const TUnderlineStyle &)
- TUnderlineStyle (GCoordinate offsetFromBaseline, GCoordinate thickness, bool coverSpaces =true, bool useCharacterBaseline =false)
- TUnderlineStyle (const TAttributeState & paint, GCoordinate offsetFromBaseline, GCoordinate thickness, bool coverSpaces =true, bool useCharacterBaseline =false)
- TUnderlineStyle (GCoordinate offsetIncrement, GCoordinate offsetFactor, GCoordinate thicknessIncrement, GCoordinate thicknessFactor, bool coverSpaces =true, bool useCharacterBaseline =false)
- TUnderlineStyle (const TAttributeState & paint, GCoordinate offsetIncrement, GCoordinate offsetFactor, GCoordinate thicknessIncrement, GCoordinate thicknessFactor, bool coverSpaces =true, bool useCharacterBaseline =false)
Interface Category:
API.
Purpose:
- Default constructor.
- Copy constructor.
- Constructs a style object with specific values.
- Constructs a style object with specific values.
- Constructs a style object with specific values.
- Constructs a style object with specific values.
Calling Context:
- Called by the stream-in operators and anyone who wants to create an underline style with default color (black), thickness (factor 0, increment 1) and offset (factor 0, increment 0). This puts a black underline, one pixel thick, on the text's baseline. The coverSpaces flag is set to true and the useCharacterBaseline flag to false.
- Called to copy an object.
- Call to construct a style object with specific values.
- Call to construct a style object with specific values.
- Call to construct a style object with specific values.
- Call to construct a style object with specific values.
Parameters:
- Takes no parameters.
- const TUnderlineStyle & -The object to copy.
- GCoordinate offsetIncrement -The offset increment (absolute value for positioning).
- GCoordinate thicknessIncrement -The thickness increment (absolute value of thickness).
- bool coverSpaces =true -Indicates if spaces also have the line drawn.
- bool useCharacterBaseline =false -Indicates if the line should be drawn wherever the character's baseline falls (for example, moving up and down with super- and subscripts).
- const TAttributeState & paint -The line's color.
- GCoordinate offsetIncrement -The offset increment (absolute value for positioning).
- GCoordinate thicknessIncrement -The thickness increment (absolute value of thickness).
- bool coverSpaces =true -Indicates if spaces also have the line drawn.
- bool useCharacterBaseline =false -Indicates if the line should be drawn wherever the character's baseline falls (for example, moving up and down with super- and subscripts).
- GCoordinate offsetIncrement -The offset increment (absolute value for positioning).
- GCoordinate offsetFactor -The offset factor (value for positioning as a multiple of the point size).
- GCoordinate thicknessIncrement -The thickness increment (absolute value of thickness).
- GCoordinate thicknessFactor -The thickness factor (thickness of the line as a multiple of the point size).
- bool coverSpaces =true -Indicates if spaces also have the line drawn.
- bool useCharacterBaseline =false -Indicates if the line should be drawn wherever the character's baseline falls (for example, moving up and down with super- and subscripts).
- const TAttributeState & paint -The line's color.
- GCoordinate offsetIncrement -The offset increment (absolute value for positioning).
- GCoordinate offsetFactor -The offset factor (value for positioning as a multiple of the point size).
- GCoordinate thicknessIncrement -The thickness increment (absolute value of thickness).
- GCoordinate thicknessFactor -The thickness factor (thickness of the line as a multiple of the point size).
- bool coverSpaces =true -Indicates if spaces also have the line drawn.
- bool useCharacterBaseline =false -Indicates if the line should be drawn wherever the character's baseline falls (for example, moving up and down with super- and subscripts).
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Multithread safe.
Other Considerations:
None.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.