HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
UT_Unicode::iterator Class Reference

#include <UT_Unicode.h>

Public Member Functions

 iterator ()
 
 iterator (const utf8 *start, const utf8 *end=0, const UT_Unicode::transform *transform=0)
 
 iterator (const UT_StringView &str, const UT_Unicode::transform *transform=0)
 
 iterator (const UT_String &str, const UT_Unicode::transform *transform=0)
 
 iterator (const UT_StringRef &str, const UT_Unicode::transform *transform=0)
 
void reset (const utf8 *to=0)
 
bool advance ()
 
bool retreat ()
 
const utf8at () const
 
const utf8next () const
 
utf32 getCP () const
 
utf32 getNextCP () const
 
bool atEnd () const
 
iteratoroperator++ ()
 
iteratoroperator-- ()
 

Detailed Description

Simple string iterator to iterate over an UTF-8 string and peel off the code points in sequence. This iterator can always get the 'next' code point, which is useful for function which require sequential code point pairs, such as kerning. The iterator terminates when the current character is nil, invalid, or at the 'end' pointer.

Definition at line 198 of file UT_Unicode.h.

Constructor & Destructor Documentation

UT_Unicode::iterator::iterator ( void  )
inline

Definition at line 631 of file UT_UnicodeImpl.h.

UT_Unicode::iterator::iterator ( const utf8 start,
const utf8 end = 0,
const UT_Unicode::transform transform = 0 
)
inline

Definition at line 636 of file UT_UnicodeImpl.h.

UT_Unicode::iterator::iterator ( const UT_StringView str,
const UT_Unicode::transform transform = 0 
)
inline

Definition at line 642 of file UT_UnicodeImpl.h.

UT_Unicode::iterator::iterator ( const UT_String str,
const UT_Unicode::transform transform = 0 
)
inline

Definition at line 648 of file UT_UnicodeImpl.h.

UT_Unicode::iterator::iterator ( const UT_StringRef str,
const UT_Unicode::transform transform = 0 
)
inline

Definition at line 654 of file UT_UnicodeImpl.h.

Member Function Documentation

bool UT_Unicode::iterator::advance ( )
inline

Definition at line 714 of file UT_UnicodeImpl.h.

const utf8* UT_Unicode::iterator::at ( ) const
inline

Returns the pointer to the current UTF-8 sequence. Valid if atEnd is not false.

Definition at line 222 of file UT_Unicode.h.

bool UT_Unicode::iterator::atEnd ( ) const
inline

Definition at line 235 of file UT_Unicode.h.

utf32 UT_Unicode::iterator::getCP ( ) const
inline

Definition at line 229 of file UT_Unicode.h.

utf32 UT_Unicode::iterator::getNextCP ( ) const
inline

Definition at line 233 of file UT_Unicode.h.

const utf8* UT_Unicode::iterator::next ( ) const
inline

Definition at line 226 of file UT_Unicode.h.

iterator& UT_Unicode::iterator::operator++ ( )
inline

Definition at line 237 of file UT_Unicode.h.

iterator& UT_Unicode::iterator::operator-- ( )
inline

Definition at line 238 of file UT_Unicode.h.

void UT_Unicode::iterator::reset ( const utf8 to = 0)
inline

Definition at line 681 of file UT_UnicodeImpl.h.

bool UT_Unicode::iterator::retreat ( )
inline

Definition at line 740 of file UT_UnicodeImpl.h.


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