CharacterRange class

Applies to: desktop apps only

A CharacterRange object specifies a range of character positions within a string.

CharacterRange has these types of members:

Constructors

The CharacterRange class has these constructors.

ConstructorDescription
CharacterRange::CharacterRange()

Creates a CharacterRange::CharacterRange object with the data members set to zero.

CharacterRange::CharacterRange(INT,INT)

Creates a CharacterRange::CharacterRange object and initializes the data members to the values specified.

 

Methods

The CharacterRange class has these methods.

MethodDescription
CharacterRange::operator=

The CharacterRange::operator= method sets this CharacterRange object equal to the specified CharacterRange object.

 

Data Members

The following table lists the members exposed by the CharacterRange object.

Data MembersTypeDescription
FirstINTSpecifies the first position of this range.
LengthINTSpecifies the number of positions in this range.

 

Remarks

A character range is a range of character positions within a string of text. The area of the display that is occupied by a group of characters that are specified by the character range is the bounding region. A character range is set by StringFormat::SetMeasurableCharacterRanges. The number of ranges that are currently set can be determined by calling StringFormat::GetMeasurableCharacterRangeCount. This number is also the number of regions expected to be obtained by the MeasureCharacterRanges method.

 

 

Send comments about this topic to Microsoft

Build date: 3/6/2012

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.