#include <bidi.h>
Inheritance diagram for BiDi::
Public Methods | |
BiDi () | |
@memo Default constructor, calls ubidi_open(). More... | |
BiDi (UErrorCode &rErrorCode) | |
@memo Constructor, calls ubidi_open(). More... | |
BiDi (int32_t maxLength, int32_t maxRunCount, UErrorCode &rErrorCode) | |
@memo Preallocating constructor, calls ubidi_openSized(). More... | |
~BiDi () | |
@memo Destructor, calls ubidi_close(). More... | |
void | setInverse (UBool isInverse) |
Modify the operation of the BiDi algorithm such that it approximates an "inverse BiDi" algorithm. More... | |
UBool | isInverse () |
Is this BiDi object set to perform the inverse BiDi algorithm? More... | |
BiDi & | setPara (const UChar *text, int32_t length, UBiDiLevel paraLevel, UBiDiLevel *embeddingLevels, UErrorCode &rErrorCode) |
@memo Set this object for one paragraph's text. More... | |
BiDi & | setLine (const BiDi &rParaBiDi, int32_t start, int32_t limit, UErrorCode &rErrorCode) |
@memo Set this object for one line of the paragraph object's text. More... | |
UBiDiDirection | getDirection () const |
@memo Get the directionality of the text. More... | |
const UChar * | getText () const |
@memo Get the pointer to the text. More... | |
int32_t | getLength () const |
@memo Get the length of the text. More... | |
UBiDiLevel | getParaLevel () const |
@memo Get the paragraph level of the text. More... | |
UBiDiLevel | getLevelAt (int32_t charIndex) const |
@memo Get the level for one character. More... | |
const UBiDiLevel * | getLevels (UErrorCode &rErrorCode) |
@memo Get an array of levels for each character. More... | |
void | getLogicalRun (int32_t logicalStart, int32_t &rLogicalLimit, UBiDiLevel &rLevel) const |
@memo Get a logical run. More... | |
int32_t | countRuns (UErrorCode &rErrorCode) |
@memo Get the number of runs. More... | |
UBiDiDirection | getVisualRun (int32_t runIndex, int32_t &rLogicalStart, int32_t &rLength) |
@memo Get one run's logical start, length, and directionality, which can be 0 for LTR or 1 for RTL. More... | |
int32_t | getVisualIndex (int32_t logicalIndex, UErrorCode &rErrorCode) |
@memo Get the visual position from a logical text position. More... | |
int32_t | getLogicalIndex (int32_t visualIndex, UErrorCode &rErrorCode) |
@memo Get the logical text position from a visual position. More... | |
void | getLogicalMap (int32_t *indexMap, UErrorCode &rErrorCode) |
@memo Get a logical-to-visual index map (array) for the characters in the UBiDi (paragraph or line) object. More... | |
void | getVisualMap (int32_t *indexMap, UErrorCode &rErrorCode) |
@memo Get a visual-to-logical index map (array) for the characters in the UBiDi (paragraph or line) object. More... | |
int32_t | writeReordered (UChar *dest, int32_t destSize, uint16_t options, UErrorCode &rErrorCode) |
Use the BiDi object containing the reordering information for one paragraph or line of text as set by setPara() or setLine() and write a reordered string to the destination buffer. More... | |
virtual UClassID | getDynamicClassID () const |
ICU "poor man's RTTI", returns a UClassID for the actual class. More... | |
Static Public Methods | |
void | reorderLogical (const UBiDiLevel *levels, int32_t length, int32_t *indexMap) |
@memo Same as ubidi_reorderLogical(). More... | |
void | reorderVisual (const UBiDiLevel *levels, int32_t length, int32_t *indexMap) |
@memo Same as ubidi_reorderVisual(). More... | |
void | invertMap (const int32_t *srcMap, int32_t *destMap, int32_t length) |
@memo Same as ubidi_invertMap(). More... | |
int32_t | writeReverse (const UChar *src, int32_t srcLength, UChar *dest, int32_t destSize, uint16_t options, UErrorCode &rErrorCode) |
Reverse a Right-To-Left run of Unicode text. More... | |
UClassID | getStaticClassID () |
ICU "poor man's RTTI", returns a UClassID for this class. More... | |
Protected Attributes | |
UBiDi * | pBiDi |
Static Private Attributes | |
const char | fgClassID |
The address of this static class variable serves as this class's ID for ICU "poor man's RTTI". More... |
Use the C API with the UBiDi type and ubidi_... functions. The BiDi class was just a pure 1:1 wrapper for the ubidi_ API.
Old documentation:
BiDi is a C++ wrapper class for UBiDi. You need one BiDi object in place of one UBiDi object. For details on the API and implementation of the Unicode BiDi algorithm, see ubidi.h.
Definition at line 44 of file bidi.h.
|
@memo Default constructor, calls ubidi_open().
|
|
@memo Constructor, calls ubidi_open().
|
|
@memo Preallocating constructor, calls ubidi_openSized().
|
|
@memo Destructor, calls ubidi_close().
|
|
@memo Get the number of runs.
|
|
@memo Get the directionality of the text.
|
|
ICU "poor man's RTTI", returns a UClassID for the actual class.
Reimplemented from UObject. |
|
@memo Get the length of the text.
|
|
@memo Get the level for one character.
|
|
@memo Get an array of levels for each character.
|
|
@memo Get the logical text position from a visual position.
|
|
@memo Get a logical-to-visual index map (array) for the characters in the UBiDi (paragraph or line) object.
|
|
@memo Get a logical run.
|
|
@memo Get the paragraph level of the text.
|
|
ICU "poor man's RTTI", returns a UClassID for this class.
|
|
@memo Get the pointer to the text.
|
|
@memo Get the visual position from a logical text position.
|
|
@memo Get a visual-to-logical index map (array) for the characters in the UBiDi (paragraph or line) object.
|
|
@memo Get one run's logical start, length, and directionality, which can be 0 for LTR or 1 for RTL.
|
|
@memo Same as ubidi_invertMap().
|
|
Is this BiDi object set to perform the inverse BiDi algorithm?
|
|
@memo Same as ubidi_reorderLogical().
|
|
@memo Same as ubidi_reorderVisual().
|
|
Modify the operation of the BiDi algorithm such that it approximates an "inverse BiDi" algorithm.
This function must be called before
|
|
@memo Set this object for one line of the paragraph object's text.
|
|
@memo Set this object for one paragraph's text.
|
|
Use the
|
|
Reverse a Right-To-Left run of Unicode text.
|
|
The address of this static class variable serves as this class's ID for ICU "poor man's RTTI".
|
|
Definition at line 250 of file bidi.h. Referenced by setLine().
|