X-Git-Url: https://git.saurik.com/apple/icu.git/blobdiff_plain/b75a7d8f3b4adbae880cab104ce2c6a50eee4db2..729e4ab9bc6618bc3d8a898e575df7f4019e29ca:/icuSources/layout/IndicLayoutEngine.h?ds=sidebyside diff --git a/icuSources/layout/IndicLayoutEngine.h b/icuSources/layout/IndicLayoutEngine.h index f7213343..ff0b83cf 100644 --- a/icuSources/layout/IndicLayoutEngine.h +++ b/icuSources/layout/IndicLayoutEngine.h @@ -1,8 +1,7 @@ /* - * @(#)IndicLayoutEngine.h 1.4 00/03/15 * - * (C) Copyright IBM Corp. 1998-2003 - All Rights Reserved + * (C) Copyright IBM Corp. 1998-2009 - All Rights Reserved * */ @@ -19,11 +18,10 @@ #include "GlyphDefinitionTables.h" #include "GlyphPositioningTables.h" -#include - U_NAMESPACE_BEGIN class MPreFixups; +class LEGlyphStorage; /** * This class implements OpenType layout for Indic OpenType fonts, as @@ -49,6 +47,7 @@ public: * @param scriptCode - the script * @param langaugeCode - the language * @param gsubTable - the GSUB table + * @param success - set to an error code if the operation fails * * @see LayoutEngine::layoutEngineFactory * @see OpenTypeLayoutEngine @@ -57,7 +56,7 @@ public: * @internal */ IndicOpenTypeLayoutEngine(const LEFontInstance *fontInstance, le_int32 scriptCode, le_int32 languageCode, - const GlyphSubstitutionTableHeader *gsubTable); + le_int32 typoFlags, le_bool version2, const GlyphSubstitutionTableHeader *gsubTable, LEErrorCode &success); /** * This constructor is used when the font requires a "canned" GSUB table which can't be known @@ -66,13 +65,15 @@ public: * @param fontInstance - the font * @param scriptCode - the script * @param langaugeCode - the language + * @param success - set to an error code if the operation fails * * @see OpenTypeLayoutEngine * @see ScriptAndLangaugeTags.h for script and language codes * * @internal */ - IndicOpenTypeLayoutEngine(const LEFontInstance *fontInstance, le_int32 scriptCode, le_int32 languageCode); + IndicOpenTypeLayoutEngine(const LEFontInstance *fontInstance, le_int32 scriptCode, le_int32 languageCode, + le_int32 typoFlags, LEErrorCode &success); /** * The destructor, virtual for correct polymorphic invocation. @@ -84,16 +85,16 @@ public: /** * ICU "poor man's RTTI", returns a UClassID for the actual class. * - * @draft ICU 2.2 + * @stable ICU 2.8 */ - virtual inline UClassID getDynamicClassID() const { return getStaticClassID(); } + virtual UClassID getDynamicClassID() const; /** * ICU "poor man's RTTI", returns a UClassID for this class. * - * @draft ICU 2.2 + * @stable ICU 2.8 */ - static inline UClassID getStaticClassID() { return (UClassID)&fgClassID; } + static UClassID getStaticClassID(); protected: @@ -108,12 +109,11 @@ protected: * @param offset - the index of the first character to process * @param count - the number of characters to process * @param max - the number of characters in the input context - * @param rightToLeft - true if the characters are in a right to left directional run + * @param rightToLeft - TRUE if the characters are in a right to left directional run + * @param glyphStorage - the glyph storage object. The glyph and character index arrays will be set. + * the auxillary data array will be set to the feature tags. * * Output parameters: - * @param outChars - the output character arrayt - * @param charIndices - the output character index array - * @param featureTags - the output feature tag array * @param success - set to an error code if the operation fails * * @return the output character count @@ -121,7 +121,7 @@ protected: * @internal */ virtual le_int32 characterProcessing(const LEUnicode chars[], le_int32 offset, le_int32 count, le_int32 max, le_bool rightToLeft, - LEUnicode *&outChars, le_int32 *&charIndices, const LETag **&featureTags, LEErrorCode &success); + LEUnicode *&outChars, LEGlyphStorage &glyphStorage, LEErrorCode &success); /** * This method does character to glyph mapping, applies the GSUB table and applies @@ -137,12 +137,11 @@ protected: * @param offset - the index of the first character to process * @param count - the number of characters to process * @param max - the number of characters in the input context - * @param rightToLeft - true if the characters are in a right to left directional run + * @param rightToLeft - TRUE if the characters are in a right to left directional run * @param featureTags - the feature tag array + * @param glyphStorage - the glyph storage object. The glyph and char index arrays will be set. * * Output parameters: - * @param glyphs - the output glyph index array - * @param charIndices - the output character index array * @param success - set to an error code if the operation fails * * @return the number of glyphs in the output glyph index array @@ -153,17 +152,14 @@ protected: * @internal */ virtual le_int32 glyphProcessing(const LEUnicode chars[], le_int32 offset, le_int32 count, le_int32 max, le_bool rightToLeft, - const LETag **featureTags, LEGlyphID *&glyphs, le_int32 *&charIndices, LEErrorCode &success); + LEGlyphStorage &glyphStorage, LEErrorCode &success); -private: + le_bool fVersion2; - /** - * The address of this static class variable serves as this class's ID - * for ICU "poor man's RTTI". - */ - static const char fgClassID; +private: MPreFixups *fMPreFixups; + }; U_NAMESPACE_END