From fd830279725081d95e3f08f768ed6879c92fe838 Mon Sep 17 00:00:00 2001 From: Mike Buland Date: Tue, 12 Nov 2019 06:02:12 -0800 Subject: 32bit --- src/unstable/text.h | 13 +++++-------- 1 file changed, 5 insertions(+), 8 deletions(-) (limited to 'src/unstable/text.h') diff --git a/src/unstable/text.h b/src/unstable/text.h index 1d623ff..1154a50 100644 --- a/src/unstable/text.h +++ b/src/unstable/text.h @@ -27,11 +27,6 @@ namespace Bu * multilpe code points. In addition, a code point can also represent * formatting or display inforamtion. * - * Internally all data is stored in UTF-16, which is a fair compromise for - * mose text. All characters from all modern natural languages fit within - * the Basic Multilingual Plane, which requires only a single 16 bit value - * to represent it. However, when iterating through or addressing data - * in the Text object all work is done on a code point basis. */ class Text { @@ -43,20 +38,22 @@ namespace Bu public: Text(); Text( const Text &rSrc ); + Text( const TextBuilder &rSrc ); virtual ~Text(); bool isEmpty() const; bool isBmpOnly() const; int32_t getSize() const; int32_t getSizeInBytes() const; + CodePoint operator[]( int32_t iIndex ) const; - uint16_t *getRawData() const; + CodePoint *getData() const; // Text transform( (CodePoint *)(*pCallback)( CodePoint * ) ); private: - uint16_t *pData; + CodePoint *pData; + bool bIsBmpOnly; int32_t iSize; - int32_t iCodePoints; }; typedef Text::CodePoint CodePoint; } -- cgit v1.2.3