sl@0: // Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies). sl@0: // All rights reserved. sl@0: // This component and the accompanying materials are made available sl@0: // under the terms of "Eclipse Public License v1.0" sl@0: // which accompanies this distribution, and is available sl@0: // at the URL "http://www.eclipse.org/legal/epl-v10.html". sl@0: // sl@0: // Initial Contributors: sl@0: // Nokia Corporation - initial contribution. sl@0: // sl@0: // Contributors: sl@0: // sl@0: // Description: sl@0: // This is a unit test module which defines the test code that sl@0: // exercise CFont::GetCharacterPosition() functionality. sl@0: // sl@0: // sl@0: sl@0: /** sl@0: @file sl@0: @test sl@0: @internalComponent sl@0: */ sl@0: sl@0: sl@0: // sl@0: // -- INCLUDE FILES --------------------------------------------------------- sl@0: // sl@0: sl@0: sl@0: #include sl@0: #include sl@0: #include sl@0: #include sl@0: #include sl@0: #include "GlyphSel.h" sl@0: #include "TGlyphSel.h" sl@0: #include sl@0: #include sl@0: sl@0: sl@0: // sl@0: // -- CONSTANTS ------------------------------------------------------------- sl@0: // sl@0: sl@0: /** sl@0: This define when set introduces a delay to start up to allow Glowcode to sl@0: be set up to collect statistics. sl@0: */ sl@0: //#define _GLOWCODE_LAUNCH_DELAY 1 sl@0: sl@0: sl@0: /** RTest object for unit test output */ sl@0: //RTest TEST(_L("TGlyphSel - CFont Glyph Selection")); sl@0: sl@0: /** Thread name for test cases involving a new thread. */ sl@0: _LIT(KThread2NameFirst, "GlyphSelPanicTest_First"); sl@0: _LIT(KThread2NameSecond, "GlyphSelPanicTest_Second"); sl@0: sl@0: /*Beginning of Indic language font file constants declaration*/ sl@0: sl@0: _LIT16(KTestHindiFontFile, "C:\\TNR_Dev_OT.ttf"); sl@0: _LIT16(KTestHindiFontFaceName, "Devanagari OT Eval"); sl@0: sl@0: //_LIT16(KTestIndicFontFile, "C:\\s60ssb_v435.ttf"); sl@0: _LIT16(KTestIndicFontFile, "C:\\s60ssb_v500.ttf"); sl@0: _LIT16(KTestIndicFontFaceName, "Series 60 Sans"); sl@0: sl@0: //_LIT16(KTestTeluguFontFile, "C:\\s60ssb_v500.ttf"); sl@0: //_LIT16(KTestTeluguFontFaceName, "Series 60 Sans"); sl@0: sl@0: _LIT16(KTestGB18030FontFile, "C:\\TestExtB.ttf"); sl@0: _LIT16(KTestGB18030FontFaceName, "Test Font for CJK ExtB"); sl@0: sl@0: /*End of Indic language font file constants declaration*/ sl@0: // sl@0: // -- THAI TEST DATA -------------------------------------------------------- sl@0: // sl@0: sl@0: sl@0: /** sl@0: An array of Thai characters each of which is individually passed into sl@0: GetCharacterPosition() for testing. sl@0: */ sl@0: LOCAL_D const TText16 Thai_SimpleChars[] = { sl@0: // Digits test 0..9 sl@0: 0x0E50, 0x0E51, 0x0E52, 0x0E53, 0x0E54, sl@0: 0x0E55, 0x0E56, 0x0E57, 0x0E58, 0x0E59, sl@0: sl@0: // Consonants sl@0: 0x0E01, 0x0E02, 0x0E03, 0x0E04, 0x0E05, 0x0E06, 0x0E07, sl@0: 0x0E08, 0x0E09, 0x0E0A, 0x0E0B, 0x0E0C, 0x0E0D, 0x0E0E, 0x0E0F, sl@0: 0x0E10, 0x0E11, 0x0E12, 0x0E13, 0x0E14, 0x0E15, 0x0E16, 0x0E17, sl@0: 0x0E18, 0x0E19, 0x0E1A, 0x0E1B, 0x0E1C, 0x0E1D, 0x0E1E, 0x0E1F, sl@0: 0x0E20, 0x0E21, 0x0E22, 0x0E23, 0x0E24, 0x0E25, 0x0E26, 0x0E27, sl@0: 0x0E28, 0x0E29, 0x0E2A, 0x0E2B, 0x0E2C, 0x0E2D, 0x0E2E, sl@0: sl@0: // Independent vowels sl@0: 0x0E30, 0x0E32, // 0x0E33, Sara Am decomposed, not simple sl@0: 0x0E40, 0x0E41, 0x0E42, 0x0E43, 0x0E44, sl@0: sl@0: // Independent signs sl@0: 0x0E2F, 0x0E3F, 0x0E45, 0x0E46, 0x0E4F, 0x0E5A, 0x0E5B, sl@0: sl@0: // Array end sl@0: 0xFFFF, sl@0: }; sl@0: sl@0: /** sl@0: Data structure used to hold the in and out data of one invoke sl@0: of the CFont::GetCharacterPosition() API. sl@0: */ sl@0: struct TTestInput_PositionParam sl@0: { sl@0: TInt iTextLen; sl@0: TText16 iText[4]; sl@0: TInt iPosInText; sl@0: TInt oPosInText; sl@0: TInt oOutputLen; sl@0: TText16 oOutput[CFont::TPositionParam::EMaxOutputGlyphs]; sl@0: }; sl@0: sl@0: /** sl@0: This array of structs is used in the test routine sl@0: CTGlyphSelection::TestThai_ValidGlyphClusters() for verifying sl@0: GetCharacterPosition() constructs Thai PUA glyph clusters correctly. sl@0: */ sl@0: LOCAL_D const TTestInput_PositionParam Thai_ValidGlyphClusters[] = { sl@0: // --INPUT---------------- --OUTPUT---------------------- sl@0: sl@0: // TEST A1..A8 handled in Thai_SimpleChars table. sl@0: sl@0: //0.TEST A9 - Decomposed SARA AM sl@0: { 2, {0x0E01, 0x0E33}, 1, 2, 1, {0x0E33}}, sl@0: { 2, {0x0E1B, 0x0E33}, 1, 2, 2, {0xF711, 0x0E32}}, sl@0: { 2, {0x0E41, 0x0E33}, 1, 2, 2, {KUnicodeDottedCircle, 0x0E33}}, sl@0: { 1, {0x0E33}, 0, 1, 2, {KUnicodeDottedCircle, 0x0E33}}, sl@0: { 3, {0x0E19, 0x0E49, 0x0E33}, 0, 3, 4, {0x0E19, 0x0E4D, 0x0E49, 0x0E32}}, sl@0: sl@0: //5.TEST A9.1 - SARA AM exlcuded from cluster when vowel present sl@0: { 3, {0x0E19, 0x0E35, 0x0E33}, 0, 2, 2, {0x0E19, 0x0E35}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E33}, 0, 2, 2, {0x0E19, 0x0E39}}, sl@0: { 4, {0x0E19, 0x0E35, 0x0E48, 0x0E33}, 0, 3, 3, {0x0E19, 0x0E35, 0x0E48}}, sl@0: sl@0: //8.TEST B1 - Normal right aligned vowel/sign above short consonant sl@0: { 2, {0x0E04, 0x0E35}, 0, 2, 2, {0x0E04, 0x0E35}}, sl@0: { 2, {0x0E01, 0x0E4D}, 0, 2, 2, {0x0E01, 0x0E4D}}, sl@0: sl@0: //10.TEST B2 - Left aligned vowel/sign above tall consonant sl@0: { 2, {0x0E1B, 0x0E34}, 0, 2, 2, {0x0E1B, 0xF701}}, sl@0: { 2, {0x0E1D, 0x0E35}, 0, 2, 2, {0x0E1D, 0xF702}}, sl@0: { 2, {0x0E1F, 0x0E36}, 0, 2, 2, {0x0E1F, 0xF703}}, sl@0: { 2, {0x0E2C, 0x0E37}, 0, 2, 2, {0x0E2C, 0xF704}}, sl@0: { 2, {0x0E1B, 0x0E31}, 0, 2, 2, {0x0E1B, 0xF710}}, sl@0: { 2, {0x0E1D, 0x0E4D}, 0, 2, 2, {0x0E1D, 0xF711}}, sl@0: { 2, {0x0E1F, 0x0E47}, 0, 2, 2, {0x0E1F, 0xF712}}, sl@0: sl@0: //17.TEST B3 - Normal right aligned vowel below short consonant sl@0: { 2, {0x0E2C, 0x0E3A}, 0, 2, 2, {0x0E2C, 0x0E3A}}, sl@0: { 2, {0x0E0C, 0x0E38}, 0, 2, 2, {0x0E0C, 0x0E38}}, sl@0: sl@0: //19.TEST B4 - Vowel below consonant with joint decender sl@0: { 2, {0x0E0E, 0x0E38}, 0, 2, 2, {0x0E0E, 0xF718}}, sl@0: { 2, {0x0E0F, 0x0E39}, 0, 2, 2, {0x0E0F, 0xF719}}, sl@0: { 2, {0x0E0F, 0x0E3A}, 0, 2, 2, {0x0E0F, 0xF71A}}, sl@0: { 2, {0x0E24, 0x0E38}, 0, 2, 2, {0x0E24, 0xF718}}, sl@0: { 2, {0x0E26, 0x0E39}, 0, 2, 2, {0x0E26, 0xF719}}, sl@0: sl@0: //24.TEST B5 - Vowel below consonant with disjoint decender sl@0: { 2, {0x0E10, 0x0E38}, 0, 2, 2, {0xF700, 0x0E38}}, sl@0: { 2, {0x0E0D, 0x0E39}, 0, 2, 2, {0xF70F, 0x0E39}}, sl@0: { 2, {0x0E10, 0x0E3A}, 0, 2, 2, {0xF700, 0x0E3A}}, sl@0: sl@0: //27.TEST C1 - Tone mark/sign above short consonant sl@0: { 2, {0x0E14, 0x0E48}, 0, 2, 2, {0x0E14, 0xF70A}}, sl@0: { 2, {0x0E16, 0x0E49}, 0, 2, 2, {0x0E16, 0xF70B}}, sl@0: { 2, {0x0E17, 0x0E4A}, 0, 2, 2, {0x0E17, 0xF70C}}, sl@0: { 2, {0x0E19, 0x0E4B}, 0, 2, 2, {0x0E19, 0xF70D}}, sl@0: { 2, {0x0E20, 0x0E4C}, 0, 2, 2, {0x0E20, 0xF70E}}, sl@0: // with lower vowel char in between the two? sl@0: { 3, {0x0E16, 0x0E39, 0x0E49}, 0, 3, 3, {0x0E16, 0x0E39, 0xF70B}}, sl@0: sl@0: //33.TEST C2 - Upper Vowel & tone makr/sign above short consonant sl@0: { 3, {0x0E01, 0x0E34, 0x0E48}, 0, 3, 3, {0x0E01, 0x0E34, 0x0E48}}, sl@0: { 3, {0x0E02, 0x0E35, 0x0E49}, 0, 3, 3, {0x0E02, 0x0E35, 0x0E49}}, sl@0: { 3, {0x0E04, 0x0E36, 0x0E4A}, 0, 3, 3, {0x0E04, 0x0E36, 0x0E4A}}, sl@0: { 3, {0x0E08, 0x0E37, 0x0E4B}, 0, 3, 3, {0x0E08, 0x0E37, 0x0E4B}}, sl@0: { 3, {0x0E09, 0x0E34, 0x0E4C}, 0, 3, 3, {0x0E09, 0x0E34, 0x0E4C}}, sl@0: { 3, {0x0E11, 0x0E47, 0x0E4C}, 0, 2, 2, {0x0E11, 0x0E47}}, sl@0: sl@0: //39.TEST C2.1 - Lower Vowel & tone makr/sign above short consonant sl@0: { 3, {0x0E01, 0x0E38, 0x0E48}, 0, 3, 3, {0x0E01, 0x0E38, 0xF70A}}, sl@0: { 3, {0x0E02, 0x0E39, 0x0E49}, 0, 3, 3, {0x0E02, 0x0E39, 0xF70B}}, sl@0: { 3, {0x0E04, 0x0E38, 0x0E4A}, 0, 3, 3, {0x0E04, 0x0E38, 0xF70C}}, sl@0: { 3, {0x0E08, 0x0E39, 0x0E4B}, 0, 3, 3, {0x0E08, 0x0E39, 0xF70D}}, sl@0: { 3, {0x0E09, 0x0E38, 0x0E4C}, 0, 3, 3, {0x0E09, 0x0E38, 0xF70E}}, sl@0: { 3, {0x0E09, 0x0E39, 0x0E4C}, 0, 2, 2, {0x0E09, 0x0E39}}, sl@0: sl@0: //45.TEST C3 - Left aligned tone mark/sign above tall consonant sl@0: { 2, {0x0E1B, 0x0E48}, 0, 2, 2, {0x0E1B, 0xF705}}, sl@0: { 2, {0x0E1D, 0x0E49}, 0, 2, 2, {0x0E1D, 0xF706}}, sl@0: { 2, {0x0E1F, 0x0E4A}, 0, 2, 2, {0x0E1F, 0xF707}}, sl@0: { 2, {0x0E2C, 0x0E4B}, 0, 2, 2, {0x0E2C, 0xF708}}, sl@0: { 2, {0x0E1B, 0x0E4C}, 0, 2, 2, {0x0E1B, 0xF709}}, sl@0: sl@0: //50.TEST C4 - Left aligned vowel & tone mark/sign above tall consonant sl@0: { 3, {0x0E1B, 0x0E34, 0x0E48}, 0, 3, 3, {0x0E1B, 0xF701, 0xF713}}, sl@0: { 3, {0x0E1D, 0x0E35, 0x0E49}, 0, 3, 3, {0x0E1D, 0xF702, 0xF714}}, sl@0: { 3, {0x0E1F, 0x0E36, 0x0E4A}, 0, 3, 3, {0x0E1F, 0xF703, 0xF715}}, sl@0: { 3, {0x0E2C, 0x0E37, 0x0E4B}, 0, 3, 3, {0x0E2C, 0xF704, 0xF716}}, sl@0: { 3, {0x0E1B, 0x0E34, 0x0E4C}, 0, 3, 3, {0x0E1B, 0xF701, 0xF717}}, sl@0: sl@0: //55. INC043221 - Tone marks are not readable with tall consonants and Sara Am sl@0: // Test that the nikhahit part of a sara am causes the same effects as top sl@0: // vowels. sl@0: // Test 4 already does one suitable test. sl@0: { 3, {0x0E1B, 0x0E49, 0x0E33}, 0, 3, 4, {0x0E1B, 0xF711, 0xF714, 0x0E32}}, sl@0: sl@0: //56. INC127996 - Tone mark/diacritic displayed incorrectly when combinded sl@0: // with long tail consonanat and below vowel. Test that in context sl@0: // 'short consonanat + below vowel + Tone Mark/diacritic', mark/diacritic sl@0: // can be replaced by corresonding PUA code. sl@0: { 3, {0x0E0D, 0x0E39, 0x0E49}, 0, 3, 3, {0xF70F, 0x0E39, 0xF70B}}, sl@0: { 3, {0x0E0E, 0x0E38, 0x0E48}, 0, 3, 3, {0x0E0E, 0xF718, 0xF70A}}, sl@0: { 3, {0x0E0F, 0x0E39, 0x0E4A}, 0, 3, 3, {0x0E0F, 0xF719, 0xF70C}}, sl@0: { 3, {0x0E26, 0x0E39, 0x0E4B}, 0, 3, 3, {0x0E26, 0xF719, 0xF70D}}, sl@0: { 3, {0x0E24, 0x0E38, 0x0E49}, 0, 3, 3, {0x0E24, 0xF718, 0xF70B}}, sl@0: { 3, {0x0E10, 0x0E38, 0x0E4C}, 0, 3, 3, {0xF700, 0x0E38, 0xF70E}}, sl@0: sl@0: //62.TABLE END sl@0: { -1, {0}, -1, -1, 0, {0}} sl@0: }; sl@0: sl@0: /** sl@0: Data structure used to hold the in and out data of two invokes sl@0: of the CFont::GetCharacterPosition() API. sl@0: */ sl@0: struct TTestInput_Invoke sl@0: { sl@0: TInt iPosInText; sl@0: TInt oPosInText; sl@0: TInt oOutputLen; sl@0: TText16 oOutput[CFont::TPositionParam::EMaxOutputGlyphs]; sl@0: }; sl@0: sl@0: /** sl@0: Data structure used to hold the in and out data of two invokes sl@0: of the CFont::GetCharacterPosition() API. sl@0: */ sl@0: struct TTestInput_PositionParam2 sl@0: { sl@0: TInt iTextLen; sl@0: TText16 iText[4]; sl@0: TTestInput_Invoke oOut[2]; sl@0: }; sl@0: sl@0: /** sl@0: Data structure used to hold the in and out data of two invokes sl@0: of the CFont::GetCharacterPosition() API. sl@0: */ sl@0: struct TTestInput_PositionParam6 sl@0: { sl@0: TInt iTextLen; sl@0: TText16 iText[6]; sl@0: TTestInput_Invoke oOut[6]; sl@0: }; sl@0: sl@0: // {-1, 1, 1, {0} } } indicate end of sequence sl@0: // The most significant bit of glyph index is trimmed off when stored sl@0: LOCAL_D const TTestInput_PositionParam6 Indic_GurmukhiDigit[] = { sl@0: { 1, {0x0a66}, { {0, 1, 1, {0x12fe} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a67}, { {0, 1, 1, {0x12ff} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a68}, { {0, 1, 1, {0x1300} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a69}, { {0, 1, 1, {0x1301} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a6a}, { {0, 1, 1, {0x1302} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a6b}, { {0, 1, 1, {0x1303} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a6c}, { {0, 1, 1, {0x1304} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a6d}, { {0, 1, 1, {0x1305} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a6e}, { {0, 1, 1, {0x1306} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a6f}, { {0, 1, 1, {0x1307} }, {-1, 1, 1, {0} } } }, sl@0: // Consonant + digit sl@0: { 2, {0x0a15, 0x0a66}, { {0, 1, 1, {0x12cd}}, {1, 2, 1, {0x12fe}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a17, 0x0a67}, { {0, 1, 1, {0x12cf}}, {1, 2, 1, {0x12ff}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a19, 0x0a68}, { {0, 1, 1, {0x12d1}}, {1, 2, 1, {0x1300}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a25, 0x0a69}, { {0, 1, 1, {0x12dd}}, {1, 2, 1, {0x1301}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a27, 0x0a6a}, { {0, 1, 1, {0x12df}}, {1, 2, 1, {0x1302}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a28, 0x0a6b}, { {0, 1, 1, {0x12e0}}, {1, 2, 1, {0x1303}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a29, 0x0a6c}, { {0, 1, 1, {0x0000}}, {1, 2, 1, {0x1304}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a3a, 0x0a6d}, { {0, 1, 1, {0x0000}}, {1, 2, 1, {0x1305}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a3b, 0x0a6e}, { {0, 1, 1, {0x0000}}, {1, 2, 1, {0x1306}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a3c, 0x0a6f}, { {0, 1, 2, {0x058f, 0x12ee}}, {1, 2, 1, {0x1307}}, {-1, 1, 1, {0} } } }, sl@0: // Modifier + digit sl@0: { 2, {0x0a3e, 0x0a66}, { {0, 1, 2, {0x058f, 0x12ef}}, {1, 2, 1, {0x12fe}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a3e, 0x0a67}, { {0, 1, 2, {0x058f, 0x12ef}}, {1, 2, 1, {0x12ff}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a3e, 0x0a68}, { {0, 1, 2, {0x058f, 0x12ef}}, {1, 2, 1, {0x1300}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a3e, 0x0a69}, { {0, 1, 2, {0x058f, 0x12ef}}, {1, 2, 1, {0x1301}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a3e, 0x0a6a}, { {0, 1, 2, {0x058f, 0x12ef}}, {1, 2, 1, {0x1302}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a3e, 0x0a6b}, { {0, 1, 2, {0x058f, 0x12ef}}, {1, 2, 1, {0x1303}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a3e, 0x0a6c}, { {0, 1, 2, {0x058f, 0x12ef}}, {1, 2, 1, {0x1304}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a3e, 0x0a6d}, { {0, 1, 2, {0x058f, 0x12ef}}, {1, 2, 1, {0x1305}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a3e, 0x0a6e}, { {0, 1, 2, {0x058f, 0x12ef}}, {1, 2, 1, {0x1306}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a3e, 0x0a6f}, { {0, 1, 2, {0x058f, 0x12ef}}, {1, 2, 1, {0x1307}}, {-1, 1, 1, {0} } } }, sl@0: // Vowel + digit sl@0: { 2, {0x0a73, 0x0a66}, { {0, 1, 1, {0x130b}}, {1, 2, 1, {0x12fe}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a67}, { {0, 1, 1, {0x130b}}, {1, 2, 1, {0x12ff}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a68}, { {0, 1, 1, {0x130b}}, {1, 2, 1, {0x1300}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a69}, { {0, 1, 1, {0x130b}}, {1, 2, 1, {0x1301}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a6a}, { {0, 1, 1, {0x130b}}, {1, 2, 1, {0x1302}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a6b}, { {0, 1, 1, {0x130b}}, {1, 2, 1, {0x1303}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a6c}, { {0, 1, 1, {0x130b}}, {1, 2, 1, {0x1304}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a6d}, { {0, 1, 1, {0x130b}}, {1, 2, 1, {0x1305}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a6e}, { {0, 1, 1, {0x130b}}, {1, 2, 1, {0x1306}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a6f}, { {0, 1, 1, {0x130b}}, {1, 2, 1, {0x1307}}, {-1, 1, 1, {0} } } }, sl@0: // Virama + digit sl@0: { 2, {0x0a4d, 0x0a66}, { {0, 1, 2, {0x058f, 0x12f8}}, {1, 2, 1, {0x12fe}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a4d, 0x0a67}, { {0, 1, 2, {0x058f, 0x12f8}}, {1, 2, 1, {0x12ff}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a4d, 0x0a68}, { {0, 1, 2, {0x058f, 0x12f8}}, {1, 2, 1, {0x1300}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a4d, 0x0a69}, { {0, 1, 2, {0x058f, 0x12f8}}, {1, 2, 1, {0x1301}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a4d, 0x0a6a}, { {0, 1, 2, {0x058f, 0x12f8}}, {1, 2, 1, {0x1302}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a4d, 0x0a6b}, { {0, 1, 2, {0x058f, 0x12f8}}, {1, 2, 1, {0x1303}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a4d, 0x0a6c}, { {0, 1, 2, {0x058f, 0x12f8}}, {1, 2, 1, {0x1304}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a4d, 0x0a6d}, { {0, 1, 2, {0x058f, 0x12f8}}, {1, 2, 1, {0x1305}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a4d, 0x0a6e}, { {0, 1, 2, {0x058f, 0x12f8}}, {1, 2, 1, {0x1306}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a4d, 0x0a6f}, { {0, 1, 2, {0x058f, 0x12f8}}, {1, 2, 1, {0x1307}}, {-1, 1, 1, {0} } } }, sl@0: // Consonant + digit + Matra sl@0: { 3, {0x0a15, 0x0a66, 0x0a3e}, { {0, 1, 1, {0x12cd}}, {1, 2, 1, {0x12fe}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a16, 0x0a67, 0x0a3e}, { {0, 1, 1, {0x12ce}}, {1, 2, 1, {0x12ff}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a17, 0x0a68, 0x0a3e}, { {0, 1, 1, {0x12cf}}, {1, 2, 1, {0x1300}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a18, 0x0a69, 0x0a3e}, { {0, 1, 1, {0x12d0}}, {1, 2, 1, {0x1301}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a19, 0x0a6a, 0x0a3e}, { {0, 1, 1, {0x12d1}}, {1, 2, 1, {0x1302}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a25, 0x0a6b, 0x0a3e}, { {0, 1, 1, {0x12dd}}, {1, 2, 1, {0x1303}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a2a, 0x0a6c, 0x0a3e}, { {0, 1, 1, {0x12e1}}, {1, 2, 1, {0x1304}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a2d, 0x0a6d, 0x0a3e}, { {0, 1, 1, {0x12e4}}, {1, 2, 1, {0x1305}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a30, 0x0a6e, 0x0a3e}, { {0, 1, 1, {0x12e7}}, {1, 2, 1, {0x1306}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a33, 0x0a6f, 0x0a3e}, { {0, 1, 1, {0x12e9}}, {1, 2, 1, {0x1307}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { -1, {0}, -1, -1, 0, {0}} sl@0: }; sl@0: sl@0: sl@0: LOCAL_D const TTestInput_PositionParam6 Indic_MalayalamDigit[] = { sl@0: { 1, {0x0d66}, { {0, 1, 1, {0x123e} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d67}, { {0, 1, 1, {0x123f} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d68}, { {0, 1, 1, {0x1240} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d69}, { {0, 1, 1, {0x1241} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d6a}, { {0, 1, 1, {0x1242} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d6b}, { {0, 1, 1, {0x1243} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d6c}, { {0, 1, 1, {0x1244} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d6d}, { {0, 1, 1, {0x1245} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d6e}, { {0, 1, 1, {0x1246} }, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d6f}, { {0, 1, 1, {0x1247} }, {-1, 1, 1, {0} } } }, sl@0: // Consonant + digit sl@0: { 2, {0x0d15, 0x0d66}, { {0, 1, 1, {0x120a}}, {1, 2, 1, {0x123e}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d15, 0x0d67}, { {0, 1, 1, {0x120a}}, {1, 2, 1, {0x123f}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d17, 0x0d68}, { {0, 1, 1, {0x120c}}, {1, 2, 1, {0x1240}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d19, 0x0d69}, { {0, 1, 1, {0x120e}}, {1, 2, 1, {0x1241}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d25, 0x0d6a}, { {0, 1, 1, {0x121a}}, {1, 2, 1, {0x1242}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d26, 0x0d6b}, { {0, 1, 1, {0x121b}}, {1, 2, 1, {0x1243}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d15, 0x0d6c}, { {0, 1, 1, {0x120a}}, {1, 2, 1, {0x1244}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d30, 0x0d6d}, { {0, 1, 1, {0x1224}}, {1, 2, 1, {0x1245}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d31, 0x0d6e}, { {0, 1, 1, {0x1225}}, {1, 2, 1, {0x1246}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d32, 0x0d6f}, { {0, 1, 1, {0x1226}}, {1, 2, 1, {0x1247}}, {-1, 1, 1, {0} } } }, sl@0: // Modifier + digit sl@0: { 2, {0x0d03, 0x0d66}, { {0, 1, 2, {0x058f, 0x11fb}}, {1, 2, 1, {0x123e}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d03, 0x0d67}, { {0, 1, 2, {0x058f, 0x11fb}}, {1, 2, 1, {0x123f}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d03, 0x0d68}, { {0, 1, 2, {0x058f, 0x11fb}}, {1, 2, 1, {0x1240}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d03, 0x0d69}, { {0, 1, 2, {0x058f, 0x11fb}}, {1, 2, 1, {0x1241}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d03, 0x0d6a}, { {0, 1, 2, {0x058f, 0x11fb}}, {1, 2, 1, {0x1242}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d02, 0x0d6b}, { {0, 1, 2, {0x058f, 0x11fa}}, {1, 2, 1, {0x1243}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d02, 0x0d6c}, { {0, 1, 2, {0x058f, 0x11fa}}, {1, 2, 1, {0x1244}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d02, 0x0d6d}, { {0, 1, 2, {0x058f, 0x11fa}}, {1, 2, 1, {0x1245}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d02, 0x0d6e}, { {0, 1, 2, {0x058f, 0x11fa}}, {1, 2, 1, {0x1246}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d02, 0x0d6f}, { {0, 1, 2, {0x058f, 0x11fa}}, {1, 2, 1, {0x1247}}, {-1, 1, 1, {0} } } }, sl@0: // Vowel + digit sl@0: { 2, {0x0d3e, 0x0d66}, { {0, 1, 2, {0x058f, 0x122e}}, {1, 2, 1, {0x123e}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d3f, 0x0d67}, { {0, 1, 2, {0x058f, 0x122f}}, {1, 2, 1, {0x123f}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d40, 0x0d68}, { {0, 1, 2, {0x058f, 0x1230}}, {1, 2, 1, {0x1240}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d41, 0x0d69}, { {0, 1, 2, {0x058f, 0x1231}}, {1, 2, 1, {0x1241}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d42, 0x0d6a}, { {0, 1, 2, {0x058f, 0x1232}}, {1, 2, 1, {0x1242}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d43, 0x0d6b}, { {0, 1, 2, {0x058f, 0x1233}}, {1, 2, 1, {0x1243}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d46, 0x0d6c}, { {0, 1, 2, {0x1234, 0x058f}}, {1, 2, 1, {0x1244}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d47, 0x0d6d}, { {0, 1, 2, {0x1235, 0x058f}}, {1, 2, 1, {0x1245}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d48, 0x0d6e}, { {0, 1, 2, {0x1236, 0x058f}}, {1, 2, 1, {0x1246}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d4c, 0x0d6f}, { {0, 1, 2, {0x058f, 0x123b}}, {1, 2, 1, {0x1247}}, {-1, 1, 1, {0} } } }, sl@0: // Virama + digit sl@0: { 2, {0x0d4d, 0x0d66}, { {0, 1, 2, {0x058f, 0x123a}}, {1, 2, 1, {0x123e}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d4d, 0x0d67}, { {0, 1, 2, {0x058f, 0x123a}}, {1, 2, 1, {0x123f}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d4d, 0x0d68}, { {0, 1, 2, {0x058f, 0x123a}}, {1, 2, 1, {0x1240}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d4d, 0x0d69}, { {0, 1, 2, {0x058f, 0x123a}}, {1, 2, 1, {0x1241}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d4d, 0x0d6a}, { {0, 1, 2, {0x058f, 0x123a}}, {1, 2, 1, {0x1242}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d4d, 0x0d6b}, { {0, 1, 2, {0x058f, 0x123a}}, {1, 2, 1, {0x1243}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d4d, 0x0d6c}, { {0, 1, 2, {0x058f, 0x123a}}, {1, 2, 1, {0x1244}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d4d, 0x0d6d}, { {0, 1, 2, {0x058f, 0x123a}}, {1, 2, 1, {0x1245}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d4d, 0x0d6e}, { {0, 1, 2, {0x058f, 0x123a}}, {1, 2, 1, {0x1246}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d4d, 0x0d6f}, { {0, 1, 2, {0x058f, 0x123a}}, {1, 2, 1, {0x1247}}, {-1, 1, 1, {0} } } }, sl@0: // Consonant + digit + Matra sl@0: { 3, {0x0d15, 0x0d66, 0x0d3e}, { {0, 1, 1, {0x120a}}, {1, 2, 1, {0x123e}}, {2, 3, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d20, 0x0d67, 0x0d3f}, { {0, 1, 1, {0x1215}}, {1, 2, 1, {0x123f}}, {2, 3, 2, {0x058f, 0x122f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d22, 0x0d68, 0x0d40}, { {0, 1, 1, {0x1217}}, {1, 2, 1, {0x1240}}, {2, 3, 2, {0x058f, 0x1230}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d27, 0x0d69, 0x0d41}, { {0, 1, 1, {0x121c}}, {1, 2, 1, {0x1241}}, {2, 3, 2, {0x058f, 0x1231}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d28, 0x0d6a, 0x0d42}, { {0, 1, 1, {0x121d}}, {1, 2, 1, {0x1242}}, {2, 3, 2, {0x058f, 0x1232}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d2A, 0x0d6b, 0x0d43}, { {0, 1, 1, {0x121e}}, {1, 2, 1, {0x1243}}, {2, 3, 2, {0x058f, 0x1233}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d2D, 0x0d6c, 0x0d46}, { {0, 1, 1, {0x1221}}, {1, 2, 1, {0x1244}}, {2, 3, 2, {0x1234, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d32, 0x0d6d, 0x0d47}, { {0, 1, 1, {0x1226}}, {1, 2, 1, {0x1245}}, {2, 3, 2, {0x1235, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d34, 0x0d6e, 0x0d48}, { {0, 1, 1, {0x1228}}, {1, 2, 1, {0x1246}}, {2, 3, 2, {0x1236, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d39, 0x0d6f, 0x0d4a}, { {0, 1, 1, {0x122d}}, {1, 2, 1, {0x1247}}, {2, 3, 3, {0x1234, 0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { -1, {0}, -1, -1, 0, {0}} sl@0: }; sl@0: sl@0: LOCAL_D const TTestInput_PositionParam6 Indic_GurmukhiAndLatin[] = { sl@0: // Gurmukhi sequence + Latin sl@0: { 3, {0x0a05, 0x0a70, 0x0077}, { {0, 2, 2, {0x12c3, 0x1308}}, {1, 2, 1, {0x1308}}, {2, 3, 1, {0x0077}}, {-1, 1, 1, {0} } } }, sl@0: // Latin + Gurmukhi sequence sl@0: { 3, {0x0063, 0x0a19, 0x0a48}, { {0, 1, 1, {0x0063}}, {1, 3, 2, {0x12d1, 0x12f5}}, {2, 3, 1, {0x12f5}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0064, 0x0a3f, 0x0a71}, { {0, 1, 1, {0x0064}}, {1, 2, 2, {0x12f0, 0x058f}}, {2, 3, 2, {0x058f, 0x1309}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0066, 0x0a69, 0x0a3e}, { {0, 1, 1, {0x0066}}, {1, 2, 1, {0x1301}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0068, 0x0a6a, 0x0a3e}, { {0, 1, 1, {0x0068}}, {1, 2, 1, {0x1302}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x002e, 0x0a6b, 0x0a3e}, { {0, 1, 1, {0x0772}}, {1, 2, 1, {0x1303}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0074, 0x0a6c, 0x0a3e}, { {0, 1, 1, {0x0074}}, {1, 2, 1, {0x1304}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x002c, 0x0a6d, 0x0a3e}, { {0, 1, 1, {0x0770}}, {1, 2, 1, {0x1305}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0078, 0x0a6e, 0x0a3e}, { {0, 1, 1, {0x0078}}, {1, 2, 1, {0x1306}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x007a, 0x0a6f, 0x0a3e}, { {0, 1, 1, {0x007a}}, {1, 2, 1, {0x1307}}, {2, 3, 2, {0x058f, 0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a6f, 0x0a3e, 0x0078}, { {0, 1, 1, {0x1307}}, {1, 2, 2, {0x058f, 0x12ef}}, {2, 3, 1, {0x0078}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a6f, 0x0a3e, 0x002e}, { {0, 1, 1, {0x1307}}, {1, 2, 2, {0x058f, 0x12ef}}, {2, 3, 1, {0x0772}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a6f, 0x0a3e, 0x0066}, { {0, 1, 1, {0x1307}}, {1, 2, 2, {0x058f, 0x12ef}}, {2, 3, 1, {0x0066}}, {-1, 1, 1, {0} } } }, sl@0: { -1, {0}, -1, -1, 0, {0}} sl@0: }; sl@0: sl@0: sl@0: LOCAL_D const TTestInput_PositionParam6 Indic_MalayalamAndLatin[] = { sl@0: // Malayalam sequence + Latin sl@0: //{ 3, {0x0d05, 0x0d70, 0x0077}, { {0, 1, 1, {0x11fc}}, {1, 2, 1, {0x0000}}, {2, 3, 1, {0x0077}}, {-1, 1, 1, {0} } } }, sl@0: // Latin + Malayalam sequence sl@0: { 3, {0x0063, 0x0d19, 0x0d48}, { {0, 1, 1, {0x0063}}, {1, 3, 2, {0x1236, 0x120e}}, {2, 3, 1, {0x1236}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0066, 0x0d69, 0x0d3e}, { {0, 1, 1, {0x0066}}, {1, 2, 1, {0x1241}}, {2, 3, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0068, 0x0d6a, 0x0d3e}, { {0, 1, 1, {0x0068}}, {1, 2, 1, {0x1242}}, {2, 3, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x002e, 0x0d6b, 0x0d3e}, { {0, 1, 1, {0x0c87}}, {1, 2, 1, {0x1243}}, {2, 3, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0074, 0x0d6c, 0x0d3e}, { {0, 1, 1, {0x0074}}, {1, 2, 1, {0x1244}}, {2, 3, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x002c, 0x0d6d, 0x0d3e}, { {0, 1, 1, {0x0c85}}, {1, 2, 1, {0x1245}}, {2, 3, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0078, 0x0d6e, 0x0d3e}, { {0, 1, 1, {0x0078}}, {1, 2, 1, {0x1246}}, {2, 3, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x007a, 0x0d6f, 0x0d3e}, { {0, 1, 1, {0x007a}}, {1, 2, 1, {0x1247}}, {2, 3, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { -1, {0}, -1, -1, 0, {0}} sl@0: }; sl@0: sl@0: sl@0: LOCAL_D const TTestInput_PositionParam6 Indic_GurmukhiModifierAfterConsonantViramaZWJ[] = { sl@0: // Consonant + Virama + ZWJ + Modifier sl@0: { 4, {0x0a15, 0x0a4d, 0x200d, 0x0A01}, { {0, 4, 2, {0x1335, 0x12c0}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x12c0}}, {3, 4, 1, {0x12c0}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0a16, 0x0a4d, 0x200d, 0x0A02}, { {0, 4, 2, {0x1336, 0x12c1}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x12c1}}, {3, 4, 1, {0x12c1}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0a17, 0x0a4d, 0x200d, 0x0A03}, { {0, 4, 2, {0x1337, 0x12c2}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x12c2}}, {3, 4, 1, {0x12c2}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0a18, 0x0a4d, 0x200d, 0x0A70}, { {0, 4, 2, {0x1338, 0x1308}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x1308}}, {3, 4, 1, {0x1308}}, {-1, 1, 1, {0} } } }, sl@0: { -1, {0}, -1, -1, 0, {0}} sl@0: }; sl@0: sl@0: sl@0: LOCAL_D const TTestInput_PositionParam6 Indic_MalayalamModifierAfterConsonantViramaZWJ[] = { sl@0: // Consonant + Virama + ZWJ + Modifier sl@0: { 4, {0x0d15, 0x0d4d, 0x200d, 0x0d02}, { {0, 4, 2, {0x1248, 0x11fa}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x11fa}}, {3, 4, 1, {0x11fa}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d25, 0x0d4d, 0x200d, 0x0d02}, { {0, 4, 2, {0x1258, 0x11fa}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x11fa}}, {3, 4, 1, {0x11fa}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d33, 0x0d4d, 0x200d, 0x0d03}, { {0, 3, 1, {0x1275}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x11fb}}, {3, 4, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d34, 0x0d4d, 0x200d, 0x0d03}, { {0, 4, 2, {0x1266, 0x11fb}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x11fb}}, {3, 4, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: { -1, {0}, -1, -1, 0, {0}} sl@0: }; sl@0: sl@0: LOCAL_D const TTestInput_PositionParam6 Indic_GurmukhiConsonantLeading[] = { sl@0: // Consonant + Nukta sl@0: { 2, {0x0a17, 0x0A3C}, { {0, 2, 1, {0x12fa}}, {-1, 1, 1, {0} } } }, sl@0: // Consonant + dependent vowel, two sequences to check context shaping sl@0: { 2, {0x0a15, 0x0A4C}, { {0, 2, 2, {0x12cd, 0x12f7}}, {1, 2, 1, {0x12f7}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A4C}, { {0, 2, 2, {0x12ce, 0x12f7}}, {1, 2, 1, {0x12f7}}, {-1, 1, 1, {0} } } }, sl@0: // Consonant + Matra /i/, and other Matras sl@0: { 2, {0x0a16, 0x0A3f}, { {0, 2, 2, {0x12f0, 0x12ce}}, {1, 2, 1, {0x12f0}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A3e}, { {0, 2, 2, {0x12ce, 0x12ef}}, {1, 2, 1, {0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A40}, { {0, 2, 2, {0x12ce, 0x12f1}}, {1, 2, 1, {0x12f1}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A41}, { {0, 2, 2, {0x12ce, 0x12f2}}, {1, 2, 1, {0x12f2}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A42}, { {0, 2, 2, {0x12ce, 0x12f3}}, {1, 2, 1, {0x12f3}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A43}, { {0, 1, 1, {0x12ce}}, {1, 2, 1, {0x0000}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A44}, { {0, 1, 1, {0x12ce}}, {1, 2, 1, {0x0000}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A45}, { {0, 1, 1, {0x12ce}}, {1, 2, 1, {0x0000}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A46}, { {0, 1, 1, {0x12ce}}, {1, 2, 1, {0x0000}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A47}, { {0, 2, 2, {0x12ce, 0x12f4}}, {1, 2, 1, {0x12f4}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A48}, { {0, 2, 2, {0x12ce, 0x12f5}}, {1, 2, 1, {0x12f5}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A49}, { {0, 1, 1, {0x12ce}}, {1, 2, 1, {0x0000}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A4a}, { {0, 1, 1, {0x12ce}}, {1, 2, 1, {0x0000}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A4b}, { {0, 2, 2, {0x12ce, 0x12f6}}, {1, 2, 1, {0x12f6}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a16, 0x0A4c}, { {0, 2, 2, {0x12ce, 0x12f7}}, {1, 2, 1, {0x12f7}}, {-1, 1, 1, {0} } } }, sl@0: //0d24 + 0d4d + 0d30 sl@0: //0d28 + 0d4d + //0d24 + 0d4d + 0d30 sl@0: //0d38 + 0d4d + //0d15 + 0d4d + 0d30 sl@0: // Consonant + Virama + HA(RA/VA/YA) sl@0: { 3, {0x0a15, 0x0a4d, 0x0a39}, { {0, 3, 2, {0x12cd, 0x1331}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x1331}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a15, 0x0a4d, 0x0a30}, { {0, 3, 1, {0x13e7}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a15, 0x0a4d, 0x0a35}, { {0, 3, 2, {0x1399, 0x1333}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x1333}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a15, 0x0a4d, 0x0a2f}, { {0, 3, 2, {0x12cd, 0x1373}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x1373}}, {-1, 1, 1, {0} } } }, sl@0: // Consonant + Addak sl@0: { 2, {0x0a16, 0x0A71}, { {0, 2, 2, {0x12ce, 0x1309}}, {1, 2, 1, {0x1309}}, {-1, 1, 1, {0} } } }, sl@0: // Consonant + bindi sl@0: { 2, {0x0a16, 0x0A02}, { {0, 2, 2, {0x12ce, 0x12c1}}, {1, 2, 1, {0x12c1}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a16, 0x0a40, 0x0A02}, { {0, 3, 2, {0x12ce, 0x13f0}}, {1, 2, 1, {0x13f0}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a16, 0x0a4b, 0x0A02}, { {0, 3, 2, {0x12ce, 0x13f3}}, {1, 2, 1, {0x13f3}}, {-1, 1, 1, {0} } } }, sl@0: // Consonant + Tippi sl@0: { 2, {0x0a25, 0x0A70}, { {0, 2, 2, {0x12dd, 0x1308}}, {1, 2, 1, {0x1308}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a25, 0x0a3f, 0x0A70}, { {0, 3, 3, {0x12f0, 0x12dd, 0x1308}}, {1, 2, 1, {0x12f0}}, {2, 3, 1, {0x1308}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0a25, 0x0a41, 0x0A70}, { {0, 3, 3, {0x12dd, 0x12f2, 0x1308}}, {1, 2, 1, {0x12f2}}, {2, 3, 1, {0x1308}}, {-1, 1, 1, {0} } } }, sl@0: // Nukta, corresponding consonant, Nukta pair sl@0: { 1, {0x0a33}, { {0, 1, 1, {0x12e9}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a32, 0x0A3c}, { {0, 2, 1, {0x12e9}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a36}, { {0, 1, 1, {0x12eb}},{-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a38, 0x0A3c}, { {0, 2, 1, {0x12eb}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a59}, { {0, 1, 1, {0x12f9}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0aa1, 0x0A3c}, { {0, 1, 1, {0x096e}}, {1, 2, 2, {0x058f, 0x12ee}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a5a}, { {0, 1, 1, {0x12fa}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a17, 0x0A3c}, { {0, 2, 1, {0x12fa}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a5b}, { {0, 1, 1, {0x12fb}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a1c, 0x0A3c}, { {0, 2, 1, {0x12fb}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a5e}, { {0, 1, 1, {0x12fd}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a2b, 0x0A3c}, { {0, 2, 1, {0x12fd}}, {-1, 1, 1, {0} } } }, sl@0: { -1, {0}, -1, -1, 0, {0}} sl@0: }; sl@0: sl@0: sl@0: sl@0: LOCAL_D const TTestInput_PositionParam6 Indic_MalayalamConsonantLeading[] = { sl@0: // Consonant, and its split representation sl@0: { 2, {0x0d15, 0x0d14}, { {0, 1, 1, {0x120a}}, {1, 2, 1, {0x1209}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d15, 0x0d12, 0x0d57}, { {0, 1, 1, {0x120a}}, {1, 3, 3, {0x1207, 0x058f, 0x123b}}, {2, 3, 2, {0x058f, 0x123b}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: { 2, {0x0d15, 0x0d4a}, { {0, 2, 3, {0x1234, 0x120a, 0x122e}}, {1, 2, 2, {0x1234, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d15, 0x0d46, 0x0d3e}, { {0, 3, 3, {0x1234, 0x120a, 0x122e}}, {1, 2, 1, {0x1234}}, {2, 3, 1, {0x122e}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: { 2, {0x0d17, 0x0d4b}, { {0, 2, 3, {0x1235, 0x120c, 0x122e}}, {1, 2, 2, {0x1235, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d17, 0x0d47, 0x0d3e}, { {0, 3, 3, {0x1235, 0x120c, 0x122e}}, {1, 2, 1, {0x1235}}, {2, 3, 1, {0x122e}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: { 2, {0x0d19, 0x0d4c}, { {0, 2, 2, {0x120e, 0x123b}}, {1, 2, 1, {0x123b}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d19, 0x0d46, 0x0d57}, { {0, 3, 2, {0x120e, 0x123b}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x123b}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // Consonant + dependent vowel, two sequences to check context shaping sl@0: { 2, {0x0d15, 0x0d0a}, { {0, 1, 1, {0x120a}}, {1, 2, 1, {0x1201}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d16, 0x0d0a}, { {0, 1, 1, {0x120b}}, {1, 2, 1, {0x1201}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // Consonant + Matra /-e/, /-ee/, /-ai/ sl@0: { 2, {0x0d16, 0x0d46}, { {0, 2, 2, {0x1234, 0x120b}}, {1, 2, 1, {0x1234}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d17, 0x0d47}, { {0, 2, 2, {0x1235, 0x120c}}, {1, 2, 1, {0x1235}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d18, 0x0d48}, { {0, 2, 2, {0x1236, 0x120d}}, {1, 2, 1, {0x1236}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // Consonant and Matras /-o/, /-oo/, /-au/ to shaper sl@0: // Consonant and 0x0d4c (first form of Matra /-au/ ) to shaper, sl@0: // Consonant, 0x0d46 and 0x0d57 (second form of Matra /-au/) to shaper002E sl@0: { 2, {0x0d16, 0x0d4A}, { {0, 2, 3, {0x1234, 0x120b, 0x122e}}, {1, 2, 2, {0x1234, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d17, 0x0d4B}, { {0, 2, 3, {0x1235, 0x120c, 0x122e}}, {1, 2, 2, {0x1235, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d18, 0x0d4C}, { {0, 2, 2, {0x120d, 0x123b}}, {1, 2, 1, {0x123b}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d15, 0x0d46, 0x0d57}, { {0, 3, 2, {0x120a, 0x123b}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x123b}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // Consonant + 0x0d4d + Consonant sl@0: { 3, {0x0d15, 0x0d4d, 0x0d15}, { {0, 3, 1, {0x1277}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d31, 0x0d4d, 0x0d31, 0x0d4d}, { {0, 4, 2, {0x12a7, 0x123a}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x123a}}, {3, 4, 1, {0x123a}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // Consonant (NNA, NA, RA, LA, LLA) + Virama + ZWJ to shaper sl@0: // KA + Virama + ZWJ to shaper. sl@0: // other Consonant + Virama + ZWJ to shaper. sl@0: { 3, {0x0d23, 0x0d4d, 0x200d}, { {0, 3, 1, {0x1272}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d28, 0x0d4d, 0x200d}, { {0, 3, 1, {0x1273}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d32, 0x0d4d, 0x200d}, { {0, 3, 1, {0x1276}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d33, 0x0d4d, 0x200d}, { {0, 3, 1, {0x1275}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d15, 0x0d4d, 0x200d}, { {0, 3, 1, {0x1248}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d16, 0x0d4d, 0x200d}, { {0, 3, 1, {0x1249}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // RA + Virama + ZWJ to shaper, sl@0: // RRA + Viram + ZWJ to shaper. sl@0: { 3, {0x0d30, 0x0d4d, 0x200d}, { {0, 3, 1, {0x1274}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d31, 0x0d4d, 0x200d}, { {0, 3, 1, {0x1263}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // Chillu and Modifier to shaper sl@0: // Chillu and Virama to shaper sl@0: { 4, {0x0d31, 0x0d4d, 0x200d, 0x0d05}, { {0, 3, 1, {0x1263}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 1, {0x11fc}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d15, 0x0d4d, 0x200d, 0x0d14}, { {0, 3, 1, {0x1248}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 1, {0x1209}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d31, 0x0d4d, 0x200d, 0x0d4d}, { {0, 3, 1, {0x1263}}, {1, 2, 0, {0x0000}}, {2, 4, 2, {0x058f, 0x123a}}, {3, 4, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d15, 0x0d4d, 0x200d, 0x0d4d}, { {0, 3, 1, {0x1248}}, {1, 2, 0, {0x0000}}, {2, 4, 2, {0x058f, 0x123a}}, {3, 4, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // AAR sl@0: { 3, {0x0d06, 0x0d4d, 0x200d}, { {0, 1, 1, {0x11fd}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d06, 0x0d4d}, { {0, 1, 1, {0x11fd}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // K.KA, K.TA, K.SSA, G.NA, G.MA, sl@0: // NG.KA, NG.NGA, J.JA, J.NYA, NY.NYA, TT.TTA, NN.MA, T.BHA, T.MA, sl@0: // T.SA, D.DA, D.DHA, sl@0: // N.TA, N.DA, N.DHA, N.NA, sl@0: // M.PA, M.MA, sl@0: // SH.CA, S.THA, sl@0: // H.NA, H.MA and LL.LLA sl@0: { 3, {0x0d15, 0x0d4d, 0x0d15}, { {0, 3, 1, {0x1277}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d15, 0x0d4d, 0x0d24}, { {0, 3, 1, {0x1278}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d15, 0x0d4d, 0x0d37}, { {0, 3, 1, {0x127b}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d17, 0x0d4d, 0x0d28}, { {0, 3, 1, {0x127e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d17, 0x0d4d, 0x0d2e}, { {0, 3, 1, {0x127d}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d19, 0x0d4d, 0x0d15}, { {0, 3, 1, {0x1280}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d19, 0x0d4d, 0x0d19}, { {0, 3, 1, {0x1281}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d1c, 0x0d4d, 0x0d1c}, { {0, 3, 1, {0x1284}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d1c, 0x0d4d, 0x0d1e}, { {0, 3, 1, {0x1285}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d1f, 0x0d4d, 0x0d1f}, { {0, 3, 1, {0x1288}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d23, 0x0d4d, 0x0d2e}, { {0, 3, 1, {0x128b}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d24, 0x0d4d, 0x0d2d}, { {0, 3, 1, {0x128e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d24, 0x0d4d, 0x0d2e}, { {0, 3, 1, {0x128f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d24, 0x0d4d, 0x0d38}, { {0, 3, 1, {0x1290}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d26, 0x0d4d, 0x0d26}, { {0, 3, 1, {0x1293}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d26, 0x0d4d, 0x0d27}, { {0, 3, 1, {0x1294}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d28, 0x0d4d, 0x0d24}, { {0, 3, 1, {0x129a}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d28, 0x0d4d, 0x0d26}, { {0, 3, 1, {0x1295}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d28, 0x0d4d, 0x0d27}, { {0, 3, 1, {0x1296}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d28, 0x0d4d, 0x0d28}, { {0, 3, 1, {0x1297}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d2e, 0x0d4d, 0x0d2a}, { {0, 3, 1, {0x12a4}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d2e, 0x0d4d, 0x0d2e}, { {0, 3, 1, {0x12a3}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d36, 0x0d4d, 0x0d1a}, { {0, 3, 1, {0x12ab}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d38, 0x0d4d, 0x0d25}, { {0, 3, 1, {0x12b1}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d39, 0x0d4d, 0x0d28}, { {0, 3, 1, {0x12b4}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d39, 0x0d4d, 0x0d2e}, { {0, 3, 1, {0x12b3}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d33, 0x0d4d, 0x0d23}, { {0, 3, 2, {0x1265, 0x1218}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x1218}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // One of (KA, GA, PA, BA, MA, LA, SHA, SA, HA), Virama and LA to shaper sl@0: { 3, {0x0d15, 0x0d4d, 0x0d32}, { {0, 3, 1, {0x127a}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d17, 0x0d4d, 0x0d32}, { {0, 3, 1, {0x127f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d2a, 0x0d4d, 0x0d32}, { {0, 3, 1, {0x129d}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d2c, 0x0d4d, 0x0d32}, { {0, 3, 1, {0x12a2}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d2e, 0x0d4d, 0x0d32}, { {0, 3, 1, {0x12a5}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d32, 0x0d4d, 0x0d32}, { {0, 3, 1, {0x12a8}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d36, 0x0d4d, 0x0d32}, { {0, 3, 1, {0x12ad}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d38, 0x0d4d, 0x0d32}, { {0, 3, 1, {0x12b2}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d39, 0x0d4d, 0x0d32}, { {0, 3, 1, {0x12b5}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // CA, Virama and CA to shaper sl@0: // BA, Virama and BA to shaper sl@0: // YA, Virama and YA to shaper sl@0: // VA, Virama and VA to shaper sl@0: // other Consonant, Virama and the same Consonant to shaper. sl@0: { 3, {0x0d1a, 0x0d4d, 0x0d1a}, { {0, 3, 1, {0x1282}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d2c, 0x0d4d, 0x0d2c}, { {0, 3, 1, {0x129f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d2f, 0x0d4d, 0x0d2f}, { {0, 3, 1, {0x12a6}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d35, 0x0d4d, 0x0d35}, { {0, 3, 1, {0x12aa}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d15, 0x0d4d, 0x0d15}, { {0, 3, 1, {0x1277}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // G.GA, C.CHA, K.TTA, SS.TTA, DD.DDA, NN.NNA, B.DA, B.DHA, P.PA, RR.RRA, SH.SHA, S.SA clusters to shaper sl@0: { 3, {0x0d17, 0x0d4d, 0x0d17}, { {0, 3, 1, {0x127c}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d2c, 0x0d4d, 0x0d26}, { {0, 3, 1, {0x12a0}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d1a, 0x0d4d, 0x0d1b}, { {0, 3, 1, {0x1283}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d2c, 0x0d4d, 0x0d27}, { {0, 3, 1, {0x12a1}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d15, 0x0d4d, 0x0d1f}, { {0, 3, 1, {0x1279}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d2a, 0x0d4d, 0x0d2a}, { {0, 3, 1, {0x129c}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d37, 0x0d4d, 0x0d1f}, { {0, 3, 1, {0x12ae}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d31, 0x0d4d, 0x0d31}, { {0, 3, 1, {0x12a7}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d21, 0x0d4d, 0x0d21}, { {0, 3, 1, {0x1289}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d36, 0x0d4d, 0x0d36}, { {0, 3, 1, {0x12ac}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d23, 0x0d4d, 0x0d23}, { {0, 3, 1, {0x128c}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d38, 0x0d4d, 0x0d38}, { {0, 3, 1, {0x12b0}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: sl@0: // Consonant clusters from REQ1.3.11 to shaper. sl@0: // Already covered in other sequence sl@0: // S.RR.RRA to shaper, sl@0: // N.RR.RRA to shaper sl@0: { 5, {0x0d38, 0x0d4d, 0x0d31, 0x0d4d, 0x0d31}, { {0, 5, 1, {0x12af}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d28, 0x0d4d, 0x0d31, 0x0d31}, { {0, 3, 2, {0x125b, 0x1225}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x1225}}, {3, 4, 1, {0x1225}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // N.RRA sl@0: { 4, {0x0d28, 0x0d4d, 0x200d, 0x0d31}, { {0, 4, 1, {0x1299}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // NA, Virama, ZWJ, RRA to shaper sl@0: // NA, Virama, ZWJ, ZWNJ, RRA to shaper sl@0: { 4, {0x0d28, 0x0d4d, 0x200d, 0x0d31}, { {0, 4, 1, {0x1299}}, {-1, 1, 1, {0} } } }, sl@0: { 5, {0x0d28, 0x0d4d, 0x200d, 0x200c, 0x0d31}, { {0, 3, 1, {0x1273}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 0, {0x0000}}, {4, 5, 1, {0x1225}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // Consonant cluster and YA to shaper sl@0: // Consonant cluster and VA to shaper sl@0: { 4, {0x0d15, 0x0d4d, 0x0d30, 0x0d3f}, { {0, 4, 3, {0x1271, 0x120a, 0x122f}}, {1, 2, 0, {0x0000}}, {2, 4, 2, {0x1271, 0x122f}}, {3, 4, 1, {0x122f}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d15, 0x0d4d, 0x0d30, 0x0d35}, { {0, 3, 2, {0x1271, 0x120a}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x1271}}, {3, 4, 1, {0x1229}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // YA, YAKAR to shaper sl@0: // VA, VAKAR to shaper sl@0: { 3, {0x0d15, 0x0d4d, 0x0d2f}, { {0, 3, 2, {0x120a, 0x126f}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x126f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d15, 0x0d4d, 0x0d35}, { {0, 3, 2, {0x120a, 0x1270}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x1270}}, {-1, 1, 1, {0} } } }, sl@0: { 5, {0x0d15, 0x0d4d, 0x0d30, 0x0d4d, 0x0d2f}, { {0, 5, 3, {0x1271, 0x120a, 0x126f}}, {1, 2, 0, {0x0000}}, {2, 5, 2, {0x1271, 0x126f}}, {3, 4, 0, {0x0000}}, {4, 5, 1, {0x126f}}, {-1, 1, 1, {0} } } }, sl@0: { 5, {0x0d15, 0x0d4d, 0x0d30, 0x0d4d, 0x0d35}, { {0, 5, 3, {0x1271, 0x120a, 0x1270}}, {1, 2, 0, {0x0000}}, {2, 5, 2, {0x1271, 0x1270}}, {3, 4, 0, {0x0000}}, {4, 5, 1, {0x1270}}, {-1, 1, 1, {0} } } }, sl@0: { 5, {0x0d15, 0x0d4d, 0x0d2f, 0x0d4d, 0x0d30}, { {0, 5, 3, {0x1248, 0x1271, 0x1223}}, {1, 2, 0, {0x0000}}, {2, 5, 2, {0x1271, 0x1223}}, {3, 4, 0, {0x0000}}, {4, 5, 1, {0x1271}}, {-1, 1, 1, {0} } } }, sl@0: { 5, {0x0d15, 0x0d4d, 0x0d35, 0x0d4d, 0x0d30}, { {0, 5, 3, {0x1248, 0x1271, 0x1229}}, {1, 2, 0, {0x0000}}, {2, 5, 2, {0x1271, 0x1229}}, {3, 4, 0, {0x0000}}, {4, 5, 1, {0x1271}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // one of (LLA, LLLA, RRA) and YA to shaper sl@0: // one of (LLA, LLLA, RRA) and VA to shaper sl@0: { 2, {0x0d33, 0x0d2f}, { {0, 1, 1, {0x1227}}, {1, 2, 1, {0x1223}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d34, 0x0d2f}, { {0, 1, 1, {0x1228}}, {1, 2, 1, {0x1223}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d31, 0x0d2f}, { {0, 1, 1, {0x1225}}, {1, 2, 1, {0x1223}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d33, 0x0d35}, { {0, 1, 1, {0x1227}}, {1, 2, 1, {0x1229}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d34, 0x0d35}, { {0, 1, 1, {0x1228}}, {1, 2, 1, {0x1229}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d31, 0x0d35}, { {0, 1, 1, {0x1225}}, {1, 2, 1, {0x1229}}, {-1, 1, 1, {0} } } }, sl@0: // KSSA sl@0: //0d15, 0d4d, 0d37 sl@0: // Consonant cluster and RA to shaper sl@0: { 4, {0x0d15, 0x0d4d, 0x0d30, 0x0d30}, { {0, 3, 2, {0x1271, 0x120a}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x1271}}, {3, 4, 1, {0x1224}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // one of (LLA, LLLA, RRA) and RA to shaper sl@0: { 2, {0x0d33, 0x0d30}, { {0, 1, 1, {0x1227}}, {1, 2, 1, {0x1224}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d34, 0x0d30}, { {0, 1, 1, {0x1228}}, {1, 2, 1, {0x1224}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d31, 0x0d30}, { {0, 1, 1, {0x1225}}, {1, 2, 1, {0x1224}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // YAKAR/VAKAR and RA to shaper. sl@0: { 4, {0x0d15, 0x0d4d, 0x0d2f, 0x0d30}, { {0, 3, 2, {0x120a, 0x126f}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x126f}}, {3, 4, 1, {0x1224}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d15, 0x0d4d, 0x0d35, 0x0d30}, { {0, 3, 2, {0x120a, 0x1270}}, {1, 2, 0, {0x0000}}, {2, 3, 1, {0x1270}}, {3, 4, 1, {0x1224}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // Chillu sl@0: // Chillu and Vowel to shaper sl@0: // Chillu and Consonant to shaper sl@0: // Chillu and Modifier to shaper sl@0: // Chillu and Virama to shaper sl@0: { 4, {0x0d06, 0x0d23, 0x0d4d, 0x200d}, { {0, 1, 1, {0x11fd}}, {1, 4, 1, {0x1272}}, {2, 3, 0, {0x058f, 0x123a}}, {3, 4, 0, {0x0d30}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d06, 0x0d28, 0x0d4d, 0x200d}, { {0, 1, 1, {0x11fd}}, {1, 4, 1, {0x1273}}, {2, 3, 0, {0x058f, 0x123a}}, {3, 4, 0, {0x0d30}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d06, 0x0d30, 0x0d4d, 0x200d}, { {0, 1, 1, {0x11fd}}, {1, 4, 1, {0x1274}}, {2, 3, 0, {0x058f, 0x123a}}, {3, 4, 0, {0x0d30}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d06, 0x0d32, 0x0d4d, 0x200d}, { {0, 1, 1, {0x11fd}}, {1, 4, 1, {0x1276}}, {2, 3, 0, {0x058f, 0x123a}}, {3, 4, 0, {0x0d30}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d06, 0x0d33, 0x0d4d, 0x200d}, { {0, 1, 1, {0x11fd}}, {1, 4, 1, {0x1275}}, {2, 3, 0, {0x058f, 0x123a}}, {3, 4, 0, {0x0d30}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: { 4, {0x0d23, 0x0d4d, 0x200d, 0x0d06}, { {0, 3, 1, {0x1272}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 1, {0x11fd}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d28, 0x0d4d, 0x200d, 0x0d09}, { {0, 3, 1, {0x1273}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 1, {0x1200}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d30, 0x0d4d, 0x200d, 0x0d0a}, { {0, 3, 1, {0x1274}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 1, {0x1201}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d32, 0x0d4d, 0x200d, 0x0d0f}, { {0, 3, 1, {0x1276}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 1, {0x1205}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d33, 0x0d4d, 0x200d, 0x0d13}, { {0, 3, 1, {0x1275}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 1, {0x1208}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: { 4, {0x0d23, 0x0d4d, 0x200d, 0x0d16}, { {0, 3, 1, {0x1272}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 1, {0x120b}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d28, 0x0d4d, 0x200d, 0x0d19}, { {0, 3, 1, {0x1273}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 1, {0x120e}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d30, 0x0d4d, 0x200d, 0x0d1a}, { {0, 3, 1, {0x1274}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 1, {0x120f}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d32, 0x0d4d, 0x200d, 0x0d1f}, { {0, 3, 1, {0x1276}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 1, {0x1214}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d33, 0x0d4d, 0x200d, 0x0d31}, { {0, 3, 1, {0x1275}}, {1, 2, 0, {0x0000}}, {2, 3, 0, {0x0000}}, {3, 4, 1, {0x1225}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: { 4, {0x0d23, 0x0d4d, 0x200d, 0x0d02}, { {0, 3, 1, {0x1272}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x11fa}}, {3, 4, 1, {0x11fa}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d28, 0x0d4d, 0x200d, 0x0d02}, { {0, 3, 1, {0x1273}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x11fa}}, {3, 4, 1, {0x11fa}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d30, 0x0d4d, 0x200d, 0x0d03}, { {0, 3, 1, {0x1274}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x11fb}}, {3, 4, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d32, 0x0d4d, 0x200d, 0x0d03}, { {0, 3, 1, {0x1276}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x11fb}}, {3, 4, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d33, 0x0d4d, 0x200d, 0x0d03}, { {0, 3, 1, {0x1275}}, {1, 2, 0, {0x0000}}, {2, 4, 1, {0x11fb}}, {3, 4, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: { 4, {0x0d23, 0x0d4d, 0x200d, 0x0d4d}, { {0, 3, 1, {0x1272}}, {1, 2, 0, {0x0000}}, {2, 4, 2, {0x058f, 0x123a}}, {3, 4, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d28, 0x0d4d, 0x200d, 0x0d4d}, { {0, 3, 1, {0x1273}}, {1, 2, 0, {0x0000}}, {2, 4, 2, {0x058f, 0x123a}}, {3, 4, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d30, 0x0d4d, 0x200d, 0x0d4d}, { {0, 3, 1, {0x1274}}, {1, 2, 0, {0x0000}}, {2, 4, 2, {0x058f, 0x123a}}, {3, 4, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d32, 0x0d4d, 0x200d, 0x0d4d}, { {0, 3, 1, {0x1276}}, {1, 2, 0, {0x0000}}, {2, 4, 2, {0x058f, 0x123a}}, {3, 4, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 4, {0x0d33, 0x0d4d, 0x200d, 0x0d4d}, { {0, 3, 1, {0x1275}}, {1, 2, 0, {0x0000}}, {2, 4, 2, {0x058f, 0x123a}}, {3, 4, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { -1, {0}, -1, -1, 0, {0}} sl@0: }; sl@0: sl@0: LOCAL_D const TTestInput_PositionParam6 Indic_GurmukhiVowelLeading[] = { sl@0: // ARA, IRI, URA, independent vowel to shaper sl@0: { 1, {0x0a05}, { {0, 1, 1, {0x12c3}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a06}, { {0, 1, 1, {0x12c4}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a07}, { {0, 1, 1, {0x12c5}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a08}, { {0, 1, 1, {0x12c6}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a09}, { {0, 1, 1, {0x12c7}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a0a}, { {0, 1, 1, {0x12c8}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a0b}, { {0, 1, 1, {0x0000}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a0c}, { {0, 1, 1, {0x0000}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a0d}, { {0, 1, 1, {0x0000}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a0e}, { {0, 1, 1, {0x0000}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a0f}, { {0, 1, 1, {0x12c9}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a10}, { {0, 1, 1, {0x12ca}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a11}, { {0, 1, 1, {0x0000}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a12}, { {0, 1, 1, {0x0000}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a13}, { {0, 1, 1, {0x12cb}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a14}, { {0, 1, 1, {0x12cc}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a72}, { {0, 1, 1, {0x130a}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0a73}, { {0, 1, 1, {0x130b}}, {-1, 1, 1, {0} } } }, sl@0: // Valid bear + vowel sl@0: { 2, {0x0a05, 0x0a3e}, { {0, 2, 2, {0x12c3, 0x12ef}}, {1, 2, 1, {0x12ef}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a05, 0x0a48}, { {0, 2, 2, {0x12c3, 0x12f5}}, {1, 2, 1, {0x12f5}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a05, 0x0a4c}, { {0, 2, 2, {0x12c3, 0x12f7}}, {1, 2, 1, {0x12f7}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a72, 0x0a3f}, { {0, 2, 2, {0x12f0, 0x130a}}, {1, 2, 1, {0x12f0}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a72, 0x0a40}, { {0, 2, 2, {0x130a, 0x12f1}}, {1, 2, 1, {0x12f1}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a72, 0x0a47}, { {0, 2, 2, {0x130a, 0x12f4}}, {1, 2, 1, {0x12f4}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a41}, { {0, 2, 1, {0x12c7}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a42}, { {0, 2, 1, {0x12c8}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a4b}, { {0, 2, 1, {0x12cb}}, {-1, 1, 1, {0} } } }, sl@0: // Invalid bear + vowel sequence sl@0: { 2, {0x0a72, 0x0a4b}, { {0, 1, 1, {0x130a}}, {1, 2, 2, {0x058f, 0x12f6}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a05, 0x0a4b}, { {0, 1, 1, {0x12c3}}, {1, 2, 2, {0x058f, 0x12f6}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0a73, 0x0a3f}, { {0, 1, 1, {0x130b}}, {1, 2, 2, {0x12f0, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { -1, {0}, -1, -1, 0, {0}} sl@0: }; sl@0: sl@0: sl@0: LOCAL_D const TTestInput_PositionParam6 Indic_MalayalamVowelLeading[] = { sl@0: // Vowel sl@0: { 1, {0x0d05}, { {0, 1, 1, {0x11fc}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d06}, { {0, 1, 1, {0x11fd}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d07}, { {0, 1, 1, {0x11fe}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d08}, { {0, 1, 1, {0x11ff}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d09}, { {0, 1, 1, {0x1200}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d0a}, { {0, 1, 1, {0x1201}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d0b}, { {0, 1, 1, {0x1202}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d60}, { {0, 1, 1, {0x123c}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d0c}, { {0, 1, 1, {0x1203}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d61}, { {0, 1, 1, {0x123d}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d0e}, { {0, 1, 1, {0x1204}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d0f}, { {0, 1, 1, {0x1205}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d10}, { {0, 1, 1, {0x1206}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d12}, { {0, 1, 1, {0x1207}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d13}, { {0, 1, 1, {0x1208}}, {-1, 1, 1, {0} } } }, sl@0: { 1, {0x0d14}, { {0, 1, 1, {0x1209}}, {-1, 1, 1, {0} } } }, sl@0: // Vowel + modifer sl@0: { 2, {0x0d05, 0x0d02}, { {0, 2, 2, {0x11fc, 0x11fa}}, {1, 2, 1, {0x11fa}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d06, 0x0d02}, { {0, 2, 2, {0x11fd, 0x11fa}}, {1, 2, 1, {0x11fa}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d07, 0x0d02}, { {0, 2, 2, {0x11fe, 0x11fa}}, {1, 2, 1, {0x11fa}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d08, 0x0d02}, { {0, 2, 2, {0x11ff, 0x11fa}}, {1, 2, 1, {0x11fa}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d09, 0x0d02}, { {0, 2, 2, {0x1200, 0x11fa}}, {1, 2, 1, {0x11fa}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0a, 0x0d02}, { {0, 2, 2, {0x1201, 0x11fa}}, {1, 2, 1, {0x11fa}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0b, 0x0d02}, { {0, 2, 2, {0x1202, 0x11fa}}, {1, 2, 1, {0x11fa}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d60, 0x0d02}, { {0, 2, 2, {0x123c, 0x11fa}}, {1, 2, 1, {0x11fa}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0c, 0x0d03}, { {0, 2, 2, {0x1203, 0x11fb}}, {1, 2, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d61, 0x0d03}, { {0, 2, 2, {0x123d, 0x11fb}}, {1, 2, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0e, 0x0d03}, { {0, 2, 2, {0x1204, 0x11fb}}, {1, 2, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0f, 0x0d03}, { {0, 2, 2, {0x1205, 0x11fb}}, {1, 2, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d10, 0x0d03}, { {0, 2, 2, {0x1206, 0x11fb}}, {1, 2, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d12, 0x0d03}, { {0, 2, 2, {0x1207, 0x11fb}}, {1, 2, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d13, 0x0d03}, { {0, 2, 2, {0x1208, 0x11fb}}, {1, 2, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d14, 0x0d03}, { {0, 2, 2, {0x1209, 0x11fb}}, {1, 2, 1, {0x11fb}}, {-1, 1, 1, {0} } } }, sl@0: // Vowel, Modifier, Matra sl@0: { 3, {0x0d05, 0x0d02, 0x0d3e}, { {0, 2, 2, {0x11fc, 0x11fa}}, {1, 2, 1, {0x11fa}}, {2, 3, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d06, 0x0d02, 0x0d3f}, { {0, 2, 2, {0x11fd, 0x11fa}}, {1, 2, 1, {0x11fa}}, {2, 3, 2, {0x058f, 0x122f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d07, 0x0d02, 0x0d40}, { {0, 2, 2, {0x11fe, 0x11fa}}, {1, 2, 1, {0x11fa}}, {2, 3, 2, {0x058f, 0x1230}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d08, 0x0d02, 0x0d41}, { {0, 2, 2, {0x11ff, 0x11fa}}, {1, 2, 1, {0x11fa}}, {2, 3, 2, {0x058f, 0x1231}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d09, 0x0d02, 0x0d42}, { {0, 2, 2, {0x1200, 0x11fa}}, {1, 2, 1, {0x11fa}}, {2, 3, 2, {0x058f, 0x1232}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d0a, 0x0d02, 0x0d43}, { {0, 2, 2, {0x1201, 0x11fa}}, {1, 2, 1, {0x11fa}}, {2, 3, 2, {0x058f, 0x1233}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d0b, 0x0d02, 0x0d46}, { {0, 2, 2, {0x1202, 0x11fa}}, {1, 2, 1, {0x11fa}}, {2, 3, 2, {0x1234, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d60, 0x0d02, 0x0d47}, { {0, 2, 2, {0x123c, 0x11fa}}, {1, 2, 1, {0x11fa}}, {2, 3, 2, {0x1235, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d0c, 0x0d03, 0x0d48}, { {0, 2, 2, {0x1203, 0x11fb}}, {1, 2, 1, {0x11fb}}, {2, 3, 2, {0x1236, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d61, 0x0d03, 0x0d4a}, { {0, 2, 2, {0x123d, 0x11fb}}, {1, 2, 1, {0x11fb}}, {2, 3, 3, {0x1234, 0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d0e, 0x0d03, 0x0d4b}, { {0, 2, 2, {0x1204, 0x11fb}}, {1, 2, 1, {0x11fb}}, {2, 3, 3, {0x1235, 0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d0f, 0x0d03, 0x0d4c}, { {0, 2, 2, {0x1205, 0x11fb}}, {1, 2, 1, {0x11fb}}, {2, 3, 2, {0x058f, 0x123b}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d10, 0x0d03, 0x0d3e}, { {0, 2, 2, {0x1206, 0x11fb}}, {1, 2, 1, {0x11fb}}, {2, 3, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d12, 0x0d03, 0x0d3f}, { {0, 2, 2, {0x1207, 0x11fb}}, {1, 2, 1, {0x11fb}}, {2, 3, 2, {0x058f, 0x122f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d13, 0x0d03, 0x0d40}, { {0, 2, 2, {0x1208, 0x11fb}}, {1, 2, 1, {0x11fb}}, {2, 3, 2, {0x058f, 0x1230}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d14, 0x0d03, 0x0d4c}, { {0, 2, 2, {0x1209, 0x11fb}}, {1, 2, 1, {0x11fb}}, {2, 3, 2, {0x058f, 0x123b}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // Vowel, Virama, sl@0: { 2, {0x0d05, 0x0d4d}, { {0, 1, 1, {0x11fc}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d06, 0x0d4d}, { {0, 1, 1, {0x11fd}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d07, 0x0d4d}, { {0, 1, 1, {0x11fe}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d08, 0x0d4d}, { {0, 1, 1, {0x11ff}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d09, 0x0d4d}, { {0, 1, 1, {0x1200}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0a, 0x0d4d}, { {0, 1, 1, {0x1201}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0b, 0x0d4d}, { {0, 1, 1, {0x1202}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d60, 0x0d4d}, { {0, 1, 1, {0x123c}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0c, 0x0d4d}, { {0, 1, 1, {0x1203}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d61, 0x0d4d}, { {0, 1, 1, {0x123d}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0e, 0x0d4d}, { {0, 1, 1, {0x1204}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0f, 0x0d4d}, { {0, 1, 1, {0x1205}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d10, 0x0d4d}, { {0, 1, 1, {0x1206}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d12, 0x0d4d}, { {0, 1, 1, {0x1207}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d13, 0x0d4d}, { {0, 1, 1, {0x1208}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d14, 0x0d4d}, { {0, 1, 1, {0x1209}}, {1, 2, 2, {0x058f, 0x123a}}, {-1, 1, 1, {0} } } }, sl@0: sl@0: // Vowel, Matra, sl@0: { 2, {0x0d05, 0x0d3e}, { {0, 1, 1, {0x11fc}}, {1, 2, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d06, 0x0d3f}, { {0, 1, 1, {0x11fd}}, {1, 2, 2, {0x058f, 0x122f}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d07, 0x0d40}, { {0, 1, 1, {0x11fe}}, {1, 2, 2, {0x058f, 0x1230}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d08, 0x0d41}, { {0, 1, 1, {0x11ff}}, {1, 2, 2, {0x058f, 0x1231}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d09, 0x0d42}, { {0, 1, 1, {0x1200}}, {1, 2, 2, {0x058f, 0x1232}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0a, 0x0d43}, { {0, 1, 1, {0x1201}}, {1, 2, 2, {0x058f, 0x1233}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0b, 0x0d46}, { {0, 1, 1, {0x1202}}, {1, 2, 2, {0x1234, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d60, 0x0d47}, { {0, 1, 1, {0x123c}}, {1, 2, 2, {0x1235, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0c, 0x0d48}, { {0, 1, 1, {0x1203}}, {1, 2, 2, {0x1236, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d61, 0x0d4a}, { {0, 1, 1, {0x123d}}, {1, 2, 3, {0x1234, 0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0e, 0x0d4b}, { {0, 1, 1, {0x1204}}, {1, 2, 3, {0x1235, 0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d0f, 0x0d4c}, { {0, 1, 1, {0x1205}}, {1, 2, 2, {0x058f, 0x123b}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d10, 0x0d3e}, { {0, 1, 1, {0x1206}}, {1, 2, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d12, 0x0d3f}, { {0, 1, 1, {0x1207}}, {1, 2, 2, {0x058f, 0x122f}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d13, 0x0d40}, { {0, 1, 1, {0x1208}}, {1, 2, 2, {0x058f, 0x1230}}, {-1, 1, 1, {0} } } }, sl@0: { 2, {0x0d14, 0x0d4c}, { {0, 1, 1, {0x1209}}, {1, 2, 2, {0x058f, 0x123b}}, {-1, 1, 1, {0} } } }, sl@0: // Vowel Virma, Matra sl@0: { 3, {0x0d05, 0x0d4d, 0x0d3e}, { {0, 1, 1, {0x11fc}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d06, 0x0d4d, 0x0d3f}, { {0, 1, 1, {0x11fd}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x058f, 0x122f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d07, 0x0d4d, 0x0d40}, { {0, 1, 1, {0x11fe}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x058f, 0x1230}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d08, 0x0d4d, 0x0d41}, { {0, 1, 1, {0x11ff}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x058f, 0x1231}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d09, 0x0d4d, 0x0d42}, { {0, 1, 1, {0x1200}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x058f, 0x1232}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d0a, 0x0d4d, 0x0d43}, { {0, 1, 1, {0x1201}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x058f, 0x1233}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d0b, 0x0d4d, 0x0d46}, { {0, 1, 1, {0x1202}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x1234, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d60, 0x0d4d, 0x0d47}, { {0, 1, 1, {0x123c}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x1235, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d0c, 0x0d4d, 0x0d48}, { {0, 1, 1, {0x1203}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x1236, 0x058f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d61, 0x0d4d, 0x0d4a}, { {0, 1, 1, {0x123d}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 3, {0x1234, 0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d0e, 0x0d4d, 0x0d4b}, { {0, 1, 1, {0x1204}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 3, {0x1235, 0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d0f, 0x0d4d, 0x0d4c}, { {0, 1, 1, {0x1205}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x058f, 0x123b}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d10, 0x0d4d, 0x0d3e}, { {0, 1, 1, {0x1206}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x058f, 0x122e}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d12, 0x0d4d, 0x0d3f}, { {0, 1, 1, {0x1207}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x058f, 0x122f}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d13, 0x0d4d, 0x0d40}, { {0, 1, 1, {0x1208}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x058f, 0x1230}}, {-1, 1, 1, {0} } } }, sl@0: { 3, {0x0d14, 0x0d4d, 0x0d4c}, { {0, 1, 1, {0x1209}}, {1, 2, 2, {0x058f, 0x123a}}, {2, 3, 2, {0x058f, 0x123b}}, {-1, 1, 1, {0} } } }, sl@0: { -1, {0}, -1, -1, 0, {0}} sl@0: }; sl@0: sl@0: /** sl@0: This array of structs is used in the test routine sl@0: CTGlyphSelection::TestThai_InvalidGlyphClusters() to verify that sl@0: GetCharacterPosition() correctly uses the dotted circle character sl@0: when it crosses a glyph cluster boundary and finds invalid combining sl@0: characters. sl@0: */ sl@0: LOCAL_D const TTestInput_PositionParam2 Thai_GlyphClusterBoundaries[] = { sl@0: // --TEXT---------------- --INVOKE 1--------------- --INVOKE 2---------------- sl@0: sl@0: //0.TEST D1 - Control character - skipped sl@0: sl@0: //0.TEST D2 - Non Thai letter sl@0: { 2, {0x0E3F, 0x0E5B}, {{0, 1, 1, {0x0E3F}}, {1, 2, 1, {0x0E5B}}}}, sl@0: { 2, {0x0041, 0x0E03}, {{0, 1, 1, {0x0041}}, {1, 2, 1, {0x0E03}}}}, sl@0: { 2, {0x0E2F, 0x0E40}, {{0, 1, 1, {0x0E2F}}, {1, 2, 1, {0x0E40}}}}, sl@0: { 2, {0x0E3F, 0x0E30}, {{0, 1, 1, {0x0E3F}}, {1, 2, 1, {0x0E30}}}}, sl@0: { 2, {0x0E46, 0x0E45}, {{0, 1, 1, {0x0E46}}, {1, 2, 1, {0x0E45}}}}, sl@0: { 2, {0x0E4F, 0x0E24}, {{0, 1, 1, {0x0E4F}}, {1, 2, 1, {0x0E24}}}}, sl@0: sl@0: { 2, {0x0E50, 0x0E38}, {{0, 1, 1, {0x0E50}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 2, {0x0E51, 0x0E39}, {{0, 1, 1, {0x0E51}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 2, {0x0E52, 0x0E3A}, {{0, 1, 1, {0x0E52}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 2, {0x0E55, 0x0E49}, {{0, 1, 1, {0x0E55}}, {1, 2, 2, {KUnicodeDottedCircle, 0xF70B}}}}, sl@0: { 2, {0x0E56, 0x0E4C}, {{0, 1, 1, {0x0E56}}, {1, 2, 2, {KUnicodeDottedCircle, 0xF70E}}}}, sl@0: { 2, {0x0E58, 0x0E47}, {{0, 1, 1, {0x0E58}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 2, {0x0E59, 0x0E4E}, {{0, 1, 1, {0x0E59}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 2, {0x0E5A, 0x0E34}, {{0, 1, 1, {0x0E5A}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 2, {0x0E5B, 0x0E31}, {{0, 1, 1, {0x0E5B}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 2, {0x005A, 0x0E37}, {{0, 1, 1, {0x005A}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //16.TEST D3 - Thai consonant sl@0: { 2, {0x0E01, 0x0E3F}, {{0, 1, 1, {0x0E01}}, {1, 2, 1, {0x0E3F}}}}, sl@0: { 2, {0x0E01, 0x0E03}, {{0, 1, 1, {0x0E01}}, {1, 2, 1, {0x0E03}}}}, sl@0: { 2, {0x0E02, 0x0E40}, {{0, 1, 1, {0x0E02}}, {1, 2, 1, {0x0E40}}}}, sl@0: { 2, {0x0E03, 0x0E30}, {{0, 1, 1, {0x0E03}}, {1, 2, 1, {0x0E30}}}}, sl@0: { 2, {0x0E04, 0x0E45}, {{0, 1, 1, {0x0E04}}, {1, 2, 1, {0x0E45}}}}, sl@0: { 2, {0x0E05, 0x0E24}, {{0, 1, 1, {0x0E05}}, {1, 2, 1, {0x0E24}}}}, sl@0: sl@0: { 2, {0x0E06, 0x0E38}, {{0, 2, 2, {0x0E06, 0x0E38}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E07, 0x0E39}, {{0, 2, 2, {0x0E07, 0x0E39}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E23, 0x0E3A}, {{0, 2, 2, {0x0E23, 0x0E3A}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E25, 0x0E49}, {{0, 2, 2, {0x0E25, 0xF70B}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E27, 0x0E4C}, {{0, 2, 2, {0x0E27, 0xF70E}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E28, 0x0E47}, {{0, 2, 2, {0x0E28, 0x0E47}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E29, 0x0E4E}, {{0, 2, 2, {0x0E29, 0x0E4E}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E2A, 0x0E34}, {{0, 2, 2, {0x0E2A, 0x0E34}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E2D, 0x0E31}, {{0, 2, 2, {0x0E2D, 0x0E31}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E2E, 0x0E37}, {{0, 2, 2, {0x0E2E, 0x0E37}}, {-1, -1, 0, {0}}}}, sl@0: sl@0: //32.TEST D4 - Thai leading vowel sl@0: { 2, {0x0E40, 0x0E3F}, {{0, 1, 1, {0x0E40}}, {1, 2, 1, {0x0E3F}}}}, sl@0: { 2, {0x0E41, 0x0E03}, {{0, 1, 1, {0x0E41}}, {1, 2, 1, {0x0E03}}}}, sl@0: { 2, {0x0E42, 0x0E40}, {{0, 1, 1, {0x0E42}}, {1, 2, 1, {0x0E40}}}}, sl@0: { 2, {0x0E43, 0x0E30}, {{0, 1, 1, {0x0E43}}, {1, 2, 1, {0x0E30}}}}, sl@0: { 2, {0x0E44, 0x0E45}, {{0, 1, 1, {0x0E44}}, {1, 2, 1, {0x0E45}}}}, sl@0: { 2, {0x0E44, 0x0E24}, {{0, 1, 1, {0x0E44}}, {1, 2, 1, {0x0E24}}}}, sl@0: sl@0: { 2, {0x0E40, 0x0E38}, {{0, 1, 1, {0x0E40}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 2, {0x0E41, 0x0E39}, {{0, 1, 1, {0x0E41}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 2, {0x0E42, 0x0E3A}, {{0, 1, 1, {0x0E42}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 2, {0x0E43, 0x0E49}, {{0, 1, 1, {0x0E43}}, {1, 2, 2, {KUnicodeDottedCircle, 0xF70B}}}}, sl@0: { 2, {0x0E44, 0x0E4C}, {{0, 1, 1, {0x0E44}}, {1, 2, 2, {KUnicodeDottedCircle, 0xF70E}}}}, sl@0: { 2, {0x0E40, 0x0E47}, {{0, 1, 1, {0x0E40}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 2, {0x0E41, 0x0E4E}, {{0, 1, 1, {0x0E41}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 2, {0x0E42, 0x0E34}, {{0, 1, 1, {0x0E42}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 2, {0x0E43, 0x0E31}, {{0, 1, 1, {0x0E43}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 2, {0x0E44, 0x0E37}, {{0, 1, 1, {0x0E44}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //48.TEST D5 - Thai following vowel 1 sl@0: { 2, {0x0E30, 0x0E3F}, {{0, 1, 1, {0x0E30}}, {1, 2, 1, {0x0E3F}}}}, sl@0: { 2, {0x0E32, 0x0E03}, {{0, 1, 1, {0x0E32}}, {1, 2, 1, {0x0E03}}}}, sl@0: { 2, {0x0E33, 0x0E40}, {{0, 1, 2, {KUnicodeDottedCircle, 0x0E33}},{1, 2, 1, {0x0E40}}}}, sl@0: { 2, {0x0E30, 0x0E30}, {{0, 1, 1, {0x0E30}}, {1, 2, 1, {0x0E30}}}}, sl@0: { 2, {0x0E32, 0x0E45}, {{0, 1, 1, {0x0E32}}, {1, 2, 1, {0x0E45}}}}, sl@0: { 2, {0x0E33, 0x0E24}, {{0, 1, 2, {KUnicodeDottedCircle, 0x0E33}},{1, 2, 1, {0x0E24}}}}, sl@0: sl@0: { 2, {0x0E30, 0x0E38}, {{0, 1, 1, {0x0E30}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 2, {0x0E32, 0x0E39}, {{0, 1, 1, {0x0E32}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 2, {0x0E33, 0x0E3A}, {{0, 1, 2, {KUnicodeDottedCircle, 0x0E33}},{1, 2, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 2, {0x0E30, 0x0E49}, {{0, 1, 1, {0x0E30}}, {1, 2, 2, {KUnicodeDottedCircle, 0xF70B}}}}, sl@0: { 2, {0x0E32, 0x0E4C}, {{0, 1, 1, {0x0E32}}, {1, 2, 2, {KUnicodeDottedCircle, 0xF70E}}}}, sl@0: { 2, {0x0E33, 0x0E47}, {{0, 1, 2, {KUnicodeDottedCircle, 0x0E33}},{1, 2, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 2, {0x0E30, 0x0E4E}, {{0, 1, 1, {0x0E30}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 2, {0x0E32, 0x0E34}, {{0, 1, 1, {0x0E32}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 2, {0x0E33, 0x0E31}, {{0, 1, 2, {KUnicodeDottedCircle, 0x0E33}},{1, 2, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 2, {0x0E30, 0x0E37}, {{0, 1, 1, {0x0E30}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //64.TEST D6 - Thai following vowel 2 sl@0: { 2, {0x0E45, 0x0E3F}, {{0, 1, 1, {0x0E45}}, {1, 2, 1, {0x0E3F}}}}, sl@0: { 2, {0x0E45, 0x0E03}, {{0, 1, 1, {0x0E45}}, {1, 2, 1, {0x0E03}}}}, sl@0: { 2, {0x0E45, 0x0E40}, {{0, 1, 1, {0x0E45}}, {1, 2, 1, {0x0E40}}}}, sl@0: { 2, {0x0E45, 0x0E30}, {{0, 1, 1, {0x0E45}}, {1, 2, 1, {0x0E30}}}}, sl@0: { 2, {0x0E45, 0x0E45}, {{0, 1, 1, {0x0E45}}, {1, 2, 1, {0x0E45}}}}, sl@0: { 2, {0x0E45, 0x0E24}, {{0, 1, 1, {0x0E45}}, {1, 2, 1, {0x0E24}}}}, sl@0: sl@0: { 2, {0x0E45, 0x0E38}, {{0, 1, 1, {0x0E45}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 2, {0x0E45, 0x0E39}, {{0, 1, 1, {0x0E45}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 2, {0x0E45, 0x0E3A}, {{0, 1, 1, {0x0E45}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 2, {0x0E45, 0x0E49}, {{0, 1, 1, {0x0E45}}, {1, 2, 2, {KUnicodeDottedCircle, 0xF70B}}}}, sl@0: { 2, {0x0E45, 0x0E4C}, {{0, 1, 1, {0x0E45}}, {1, 2, 2, {KUnicodeDottedCircle, 0xF70E}}}}, sl@0: { 2, {0x0E45, 0x0E47}, {{0, 1, 1, {0x0E45}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 2, {0x0E45, 0x0E4E}, {{0, 1, 1, {0x0E45}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 2, {0x0E45, 0x0E34}, {{0, 1, 1, {0x0E45}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 2, {0x0E45, 0x0E31}, {{0, 1, 1, {0x0E45}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 2, {0x0E45, 0x0E37}, {{0, 1, 1, {0x0E45}}, {1, 2, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //80.TEST D7 - Thai following vowel 3 sl@0: { 2, {0x0E24, 0x0E3F}, {{0, 1, 1, {0x0E24}}, {1, 2, 1, {0x0E3F}}}}, sl@0: { 2, {0x0E26, 0x0E03}, {{0, 1, 1, {0x0E26}}, {1, 2, 1, {0x0E03}}}}, sl@0: { 2, {0x0E24, 0x0E40}, {{0, 1, 1, {0x0E24}}, {1, 2, 1, {0x0E40}}}}, sl@0: { 2, {0x0E26, 0x0E30}, {{0, 1, 1, {0x0E26}}, {1, 2, 1, {0x0E30}}}}, sl@0: { 2, {0x0E24, 0x0E45}, {{0, 1, 1, {0x0E24}}, {1, 2, 1, {0x0E45}}}}, sl@0: { 2, {0x0E26, 0x0E24}, {{0, 1, 1, {0x0E26}}, {1, 2, 1, {0x0E24}}}}, sl@0: sl@0: { 2, {0x0E24, 0x0E38}, {{0, 2, 2, {0x0E24, 0xF718}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E26, 0x0E39}, {{0, 2, 2, {0x0E26, 0xF719}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E24, 0x0E3A}, {{0, 2, 2, {0x0E24, 0xF71A}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E26, 0x0E49}, {{0, 2, 2, {0x0E26, 0xF70B}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E24, 0x0E4C}, {{0, 2, 2, {0x0E24, 0xF70E}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E26, 0x0E47}, {{0, 2, 2, {0x0E26, 0x0E47}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E24, 0x0E4E}, {{0, 2, 2, {0x0E24, 0x0E4E}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E26, 0x0E34}, {{0, 2, 2, {0x0E26, 0x0E34}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E24, 0x0E31}, {{0, 2, 2, {0x0E24, 0x0E31}}, {-1, -1, 0, {0}}}}, sl@0: { 2, {0x0E26, 0x0E37}, {{0, 2, 2, {0x0E26, 0x0E37}}, {-1, -1, 0, {0}}}}, sl@0: sl@0: //96.TEST D8 - Thai NO NU & Below Vowel 1 sl@0: { 3, {0x0E19, 0x0E38, 0x0E3F}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 1, {0x0E3F}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E03}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 1, {0x0E03}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E40}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 1, {0x0E40}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E30}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 1, {0x0E30}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E45}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 1, {0x0E45}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E24}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 1, {0x0E24}}}}, sl@0: sl@0: { 3, {0x0E19, 0x0E38, 0x0E38}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E39}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E3A}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E49}, {{0, 3, 3, {0x0E19, 0x0E38, 0xF70B}}, {-1, -1, 0, {0}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E4C}, {{0, 3, 3, {0x0E19, 0x0E38, 0xF70E}}, {-1, -1, 0, {0}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E47}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E4E}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E34}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E31}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 3, {0x0E19, 0x0E38, 0x0E37}, {{0, 2, 2, {0x0E19, 0x0E38}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //112.TEST D9 - Thai NO NU & Below Vowel 2 sl@0: { 3, {0x0E19, 0x0E39, 0x0E3F}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 1, {0x0E3F}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E03}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 1, {0x0E03}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E40}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 1, {0x0E40}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E30}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 1, {0x0E30}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E45}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 1, {0x0E45}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E24}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 1, {0x0E24}}}}, sl@0: sl@0: { 3, {0x0E19, 0x0E39, 0x0E38}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E39}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E3A}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E49}, {{0, 3, 3, {0x0E19, 0x0E39, 0xF70B}}, {-1, -1, 0, {0}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E4C}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70E}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E47}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E4E}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E34}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E31}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 3, {0x0E19, 0x0E39, 0x0E37}, {{0, 2, 2, {0x0E19, 0x0E39}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //128.TEST D10 - Thai NO NU & Below Diacritic sl@0: { 3, {0x0E19, 0x0E3A, 0x0E3F}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 1, {0x0E3F}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E03}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 1, {0x0E03}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E40}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 1, {0x0E40}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E30}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 1, {0x0E30}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E45}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 1, {0x0E45}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E24}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 1, {0x0E24}}}}, sl@0: sl@0: { 3, {0x0E19, 0x0E3A, 0x0E38}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E39}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E3A}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E49}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70B}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E4C}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70E}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E47}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E4E}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E34}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E31}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 3, {0x0E19, 0x0E3A, 0x0E37}, {{0, 2, 2, {0x0E19, 0x0E3A}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //144.TEST D11 - Thai NO NU & Tone mark sl@0: { 3, {0x0E19, 0x0E48, 0x0E3F}, {{0, 2, 2, {0x0E19, 0xF70A}}, {2, 3, 1, {0x0E3F}}}}, sl@0: { 3, {0x0E19, 0x0E49, 0x0E03}, {{0, 2, 2, {0x0E19, 0xF70B}}, {2, 3, 1, {0x0E03}}}}, sl@0: { 3, {0x0E19, 0x0E4A, 0x0E40}, {{0, 2, 2, {0x0E19, 0xF70C}}, {2, 3, 1, {0x0E40}}}}, sl@0: { 3, {0x0E19, 0x0E4B, 0x0E30}, {{0, 2, 2, {0x0E19, 0xF70D}}, {2, 3, 1, {0x0E30}}}}, sl@0: { 3, {0x0E19, 0x0E48, 0x0E45}, {{0, 2, 2, {0x0E19, 0xF70A}}, {2, 3, 1, {0x0E45}}}}, sl@0: { 3, {0x0E19, 0x0E49, 0x0E24}, {{0, 2, 2, {0x0E19, 0xF70B}}, {2, 3, 1, {0x0E24}}}}, sl@0: sl@0: { 3, {0x0E19, 0x0E4A, 0x0E38}, {{0, 2, 2, {0x0E19, 0xF70C}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 3, {0x0E19, 0x0E4B, 0x0E39}, {{0, 2, 2, {0x0E19, 0xF70D}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 3, {0x0E19, 0x0E48, 0x0E3A}, {{0, 2, 2, {0x0E19, 0xF70A}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 3, {0x0E19, 0x0E49, 0x0E49}, {{0, 2, 2, {0x0E19, 0xF70B}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70B}}}}, sl@0: { 3, {0x0E19, 0x0E4A, 0x0E4C}, {{0, 2, 2, {0x0E19, 0xF70C}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70E}}}}, sl@0: { 3, {0x0E19, 0x0E4B, 0x0E47}, {{0, 2, 2, {0x0E19, 0xF70D}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 3, {0x0E19, 0x0E48, 0x0E4E}, {{0, 2, 2, {0x0E19, 0xF70A}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 3, {0x0E19, 0x0E49, 0x0E34}, {{0, 2, 2, {0x0E19, 0xF70B}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 3, {0x0E19, 0x0E4A, 0x0E31}, {{0, 2, 2, {0x0E19, 0xF70C}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 3, {0x0E19, 0x0E4B, 0x0E37}, {{0, 2, 2, {0x0E19, 0xF70D}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //160.TEST D12 - Thai NO NU & Above Diacritic 1 sl@0: { 3, {0x0E19, 0x0E4C, 0x0E3F}, {{0, 2, 2, {0x0E19, 0xF70E}}, {2, 3, 1, {0x0E3F}}}}, sl@0: { 3, {0x0E19, 0x0E4D, 0x0E03}, {{0, 2, 2, {0x0E19, 0x0E4D}}, {2, 3, 1, {0x0E03}}}}, sl@0: { 3, {0x0E19, 0x0E4C, 0x0E40}, {{0, 2, 2, {0x0E19, 0xF70E}}, {2, 3, 1, {0x0E40}}}}, sl@0: { 3, {0x0E19, 0x0E4D, 0x0E30}, {{0, 2, 2, {0x0E19, 0x0E4D}}, {2, 3, 1, {0x0E30}}}}, sl@0: { 3, {0x0E19, 0x0E4C, 0x0E45}, {{0, 2, 2, {0x0E19, 0xF70E}}, {2, 3, 1, {0x0E45}}}}, sl@0: { 3, {0x0E19, 0x0E4D, 0x0E24}, {{0, 2, 2, {0x0E19, 0x0E4D}}, {2, 3, 1, {0x0E24}}}}, sl@0: sl@0: { 3, {0x0E19, 0x0E4C, 0x0E38}, {{0, 2, 2, {0x0E19, 0xF70E}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 3, {0x0E19, 0x0E4D, 0x0E39}, {{0, 2, 2, {0x0E19, 0x0E4D}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 3, {0x0E19, 0x0E4C, 0x0E3A}, {{0, 2, 2, {0x0E19, 0xF70E}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 3, {0x0E19, 0x0E4D, 0x0E49}, {{0, 2, 2, {0x0E19, 0x0E4D}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70B}}}}, sl@0: { 3, {0x0E19, 0x0E4C, 0x0E4C}, {{0, 2, 2, {0x0E19, 0xF70E}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70E}}}}, sl@0: { 3, {0x0E19, 0x0E4D, 0x0E47}, {{0, 2, 2, {0x0E19, 0x0E4D}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 3, {0x0E19, 0x0E4C, 0x0E4E}, {{0, 2, 2, {0x0E19, 0xF70E}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 3, {0x0E19, 0x0E4D, 0x0E34}, {{0, 2, 2, {0x0E19, 0x0E4D}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 3, {0x0E19, 0x0E4C, 0x0E31}, {{0, 2, 2, {0x0E19, 0xF70E}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 3, {0x0E19, 0x0E4D, 0x0E37}, {{0, 2, 2, {0x0E19, 0x0E4D}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //176.TEST D13 - Thai NO NU & Above Diacritic 2 sl@0: { 3, {0x0E19, 0x0E47, 0x0E3F}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 1, {0x0E3F}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E03}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 1, {0x0E03}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E40}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 1, {0x0E40}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E30}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 1, {0x0E30}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E45}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 1, {0x0E45}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E24}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 1, {0x0E24}}}}, sl@0: sl@0: { 3, {0x0E19, 0x0E47, 0x0E38}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E39}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E3A}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E49}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70B}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E4C}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70E}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E47}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E4E}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E34}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E31}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 3, {0x0E19, 0x0E47, 0x0E37}, {{0, 2, 2, {0x0E19, 0x0E47}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //176.TEST D14 - Thai NO NU & Above Diacritic 3 sl@0: { 3, {0x0E19, 0x0E4E, 0x0E3F}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 1, {0x0E3F}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E03}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 1, {0x0E03}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E40}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 1, {0x0E40}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E30}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 1, {0x0E30}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E45}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 1, {0x0E45}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E24}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 1, {0x0E24}}}}, sl@0: sl@0: { 3, {0x0E19, 0x0E4E, 0x0E38}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E39}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E3A}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E49}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70B}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E4C}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70E}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E47}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E4E}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E34}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E31}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 3, {0x0E19, 0x0E4E, 0x0E37}, {{0, 2, 2, {0x0E19, 0x0E4E}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //192.TEST D15 - Thai NO NU & Above Vowel 1 sl@0: { 3, {0x0E19, 0x0E34, 0x0E3F}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 1, {0x0E3F}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E03}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 1, {0x0E03}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E40}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 1, {0x0E40}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E30}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 1, {0x0E30}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E45}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 1, {0x0E45}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E24}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 1, {0x0E24}}}}, sl@0: sl@0: { 3, {0x0E19, 0x0E34, 0x0E38}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E39}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E3A}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E49}, {{0, 3, 3, {0x0E19, 0x0E34, 0x0E49}}, {-1, -1, 0, {0}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E4C}, {{0, 3, 3, {0x0E19, 0x0E34, 0x0E4C}}, {-1, -1, 0, {0}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E47}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E4E}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E34}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E31}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 3, {0x0E19, 0x0E34, 0x0E37}, {{0, 2, 2, {0x0E19, 0x0E34}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //208.TEST D16 - Thai NO NU & Above Vowel 2 sl@0: { 3, {0x0E19, 0x0E31, 0x0E3F}, {{0, 2, 2, {0x0E19, 0x0E31}}, {2, 3, 1, {0x0E3F}}}}, sl@0: { 3, {0x0E19, 0x0E36, 0x0E03}, {{0, 2, 2, {0x0E19, 0x0E36}}, {2, 3, 1, {0x0E03}}}}, sl@0: { 3, {0x0E19, 0x0E31, 0x0E40}, {{0, 2, 2, {0x0E19, 0x0E31}}, {2, 3, 1, {0x0E40}}}}, sl@0: { 3, {0x0E19, 0x0E36, 0x0E30}, {{0, 2, 2, {0x0E19, 0x0E36}}, {2, 3, 1, {0x0E30}}}}, sl@0: { 3, {0x0E19, 0x0E31, 0x0E45}, {{0, 2, 2, {0x0E19, 0x0E31}}, {2, 3, 1, {0x0E45}}}}, sl@0: { 3, {0x0E19, 0x0E36, 0x0E24}, {{0, 2, 2, {0x0E19, 0x0E36}}, {2, 3, 1, {0x0E24}}}}, sl@0: sl@0: { 3, {0x0E19, 0x0E31, 0x0E38}, {{0, 2, 2, {0x0E19, 0x0E31}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 3, {0x0E19, 0x0E36, 0x0E39}, {{0, 2, 2, {0x0E19, 0x0E36}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 3, {0x0E19, 0x0E31, 0x0E3A}, {{0, 2, 2, {0x0E19, 0x0E31}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 3, {0x0E19, 0x0E36, 0x0E49}, {{0, 3, 3, {0x0E19, 0x0E36, 0x0E49}}, {-1, -1, 0, {0}}}}, sl@0: { 3, {0x0E19, 0x0E31, 0x0E4C}, {{0, 2, 2, {0x0E19, 0x0E31}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70E}}}}, sl@0: { 3, {0x0E19, 0x0E36, 0x0E47}, {{0, 2, 2, {0x0E19, 0x0E36}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 3, {0x0E19, 0x0E31, 0x0E4E}, {{0, 2, 2, {0x0E19, 0x0E31}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 3, {0x0E19, 0x0E36, 0x0E34}, {{0, 2, 2, {0x0E19, 0x0E36}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 3, {0x0E19, 0x0E31, 0x0E31}, {{0, 2, 2, {0x0E19, 0x0E31}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 3, {0x0E19, 0x0E36, 0x0E37}, {{0, 2, 2, {0x0E19, 0x0E36}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //240.TEST D17 - Thai NO NU & Above Vowel 3 sl@0: { 3, {0x0E19, 0x0E35, 0x0E3F}, {{0, 2, 2, {0x0E19, 0x0E35}}, {2, 3, 1, {0x0E3F}}}}, sl@0: { 3, {0x0E19, 0x0E37, 0x0E03}, {{0, 2, 2, {0x0E19, 0x0E37}}, {2, 3, 1, {0x0E03}}}}, sl@0: { 3, {0x0E19, 0x0E35, 0x0E40}, {{0, 2, 2, {0x0E19, 0x0E35}}, {2, 3, 1, {0x0E40}}}}, sl@0: { 3, {0x0E19, 0x0E37, 0x0E30}, {{0, 2, 2, {0x0E19, 0x0E37}}, {2, 3, 1, {0x0E30}}}}, sl@0: { 3, {0x0E19, 0x0E35, 0x0E45}, {{0, 2, 2, {0x0E19, 0x0E35}}, {2, 3, 1, {0x0E45}}}}, sl@0: { 3, {0x0E19, 0x0E37, 0x0E24}, {{0, 2, 2, {0x0E19, 0x0E37}}, {2, 3, 1, {0x0E24}}}}, sl@0: sl@0: { 3, {0x0E19, 0x0E35, 0x0E38}, {{0, 2, 2, {0x0E19, 0x0E35}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E38}}}}, sl@0: { 3, {0x0E19, 0x0E37, 0x0E39}, {{0, 2, 2, {0x0E19, 0x0E37}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E39}}}}, sl@0: { 3, {0x0E19, 0x0E35, 0x0E3A}, {{0, 2, 2, {0x0E19, 0x0E35}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E3A}}}}, sl@0: { 3, {0x0E19, 0x0E37, 0x0E49}, {{0, 3, 3, {0x0E19, 0x0E37, 0x0E49}}, {-1, -1, 0, {0}}}}, sl@0: { 3, {0x0E19, 0x0E35, 0x0E4C}, {{0, 2, 2, {0x0E19, 0x0E35}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70E}}}}, sl@0: { 3, {0x0E19, 0x0E37, 0x0E47}, {{0, 2, 2, {0x0E19, 0x0E37}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 3, {0x0E19, 0x0E35, 0x0E4E}, {{0, 2, 2, {0x0E19, 0x0E35}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E4E}}}}, sl@0: { 3, {0x0E19, 0x0E37, 0x0E34}, {{0, 2, 2, {0x0E19, 0x0E37}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E34}}}}, sl@0: { 3, {0x0E19, 0x0E35, 0x0E31}, {{0, 2, 2, {0x0E19, 0x0E35}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E31}}}}, sl@0: { 3, {0x0E19, 0x0E37, 0x0E37}, {{0, 2, 2, {0x0E19, 0x0E37}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E37}}}}, sl@0: sl@0: //256.TEST D18a - Test Thai combining marks stack over a dotted circle. sl@0: { 2, {0x0E36, 0x0E48}, {{0, 2, 3, {KUnicodeDottedCircle, 0x0E36, 0x0E48}}, {-1, -1, 0, {0}}}}, sl@0: sl@0: //257.TEST D18b - Test non-thai consonant preceding two tone/signs in a row sl@0: { 2, {0x0041, 0x0E48, 0x0E49}, {{1, 2, 2, {KUnicodeDottedCircle, 0xF70A}}, {2, 3, 2, {KUnicodeDottedCircle, 0xF70B}}}}, sl@0: sl@0: //258. TEST DEF038524 - Test WTT2.0 Rare 4 optional combinations 0xBE, 0xDE, 0xE7, 0xF7 sl@0: //3 Not supported, but render should degrade display to not overstrike at a minimum. 1 is supported. sl@0: { 3, {0x0E01, 0x0E35, 0x0E47}, {{0, 2, 2, {0x0E01, 0x0E35}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 3, {0x0E01, 0x0E37, 0x0E47}, {{0, 2, 2, {0x0E01, 0x0E37}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E47}}}}, sl@0: { 3, {0x0E01, 0x0E38, 0x0E4D}, {{0, 3, 3, {0x0E01, 0x0E38, 0x0E4D}}, {-1, -1, 0, {0}}}}, sl@0: { 3, {0x0E01, 0x0E34, 0x0E4D}, {{0, 2, 2, {0x0E01, 0x0E34}}, {2, 3, 2, {KUnicodeDottedCircle, 0x0E4D}}}}, sl@0: sl@0: //246.TABLE END sl@0: { -1, {0}, {{-1, -1, 0, {0}}, {-1, -1, 0, {0}}}} sl@0: }; sl@0: sl@0: sl@0: // sl@0: // --- CLASS CTGlyphSelection -------------------------------------------- sl@0: // sl@0: sl@0: sl@0: CTGlyphSelection::CTGlyphSelection(CTestStep* aStep) : sl@0: CTGraphicsBase(aStep), sl@0: iTestFont(NULL), sl@0: iTestGraphicsDevice(NULL), sl@0: iTestGraphicsContext(NULL) sl@0: { sl@0: } sl@0: sl@0: sl@0: CTGlyphSelection::~CTGlyphSelection() sl@0: /** sl@0: This method cleans up after testing is finished. It releases memory sl@0: allocated by the test obejct at a point before object destruction. sl@0: */ sl@0: { sl@0: delete iTestGraphicsContext; sl@0: delete iTestGraphicsDevice; sl@0: delete iTestFont; sl@0: iFs.Close(); sl@0: } sl@0: sl@0: void CTGlyphSelection::ConstructL() sl@0: { sl@0: CreateTestGraphicsContextL(); sl@0: User::LeaveIfError(iFs.Connect()); sl@0: } sl@0: sl@0: void CTGlyphSelection::CreateTestGraphicsContextL() sl@0: /** sl@0: This method sets-up the context data for the proceeding test cases. sl@0: */ sl@0: { sl@0: // Setup 400 pixel dummy graphics test device. sl@0: TSize windowSize(400, 400); sl@0: iTestGraphicsDevice = CTestGraphicsDevice::NewL(windowSize); sl@0: sl@0: // Create a dummy graphics test context. sl@0: CGraphicsContext* tContext = NULL; sl@0: TEST(iTestGraphicsDevice->CreateContext(tContext) == KErrNone); sl@0: iTestGraphicsContext = static_cast(tContext); sl@0: sl@0: // Allocate the dummy test font to be used. sl@0: iTestFont = new (ELeave) CTestFont; sl@0: } sl@0: sl@0: sl@0: LOCAL_C TInt TestApiBoundaries_TC2(TAny* aData) sl@0: /** sl@0: This is a root thread function which runs as part of the test case sl@0: CTGlyphSelection::TestApiBoundaries(). It tests a panic sl@0: is produced when an invalid text descriptor is supplied in the sl@0: TPositionParam argument. sl@0: */ sl@0: { sl@0: CTGlyphSelection* testPtr = (CTGlyphSelection*)aData; sl@0: sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: testPtr->iTestFont->GetCharacterPosition(param); sl@0: sl@0: // Line above panics if component in UDEB is working OK; sl@0: // should never get here if component is in UDEB. sl@0: sl@0: // If component is in UREL, then could reach here. sl@0: sl@0: return (0); sl@0: } sl@0: sl@0: sl@0: LOCAL_C TInt TestApiBoundaries_TC5(TAny* aData) sl@0: /** sl@0: This is a root thread function which runs as part of the test case sl@0: CTGlyphSelection::TestApiBoundaries(). It tests a panic sl@0: is produced when a negative text position is supplied in the sl@0: TPositionParam argument. sl@0: */ sl@0: { sl@0: CTGlyphSelection* testPtr = (CTGlyphSelection*)aData; sl@0: sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: _LIT16(KText_aaaa, "aaaa"); sl@0: param.iText.Set(KText_aaaa); sl@0: param.iPosInText = -10; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: testPtr->iTestFont->GetCharacterPosition(param); sl@0: sl@0: // Line above panics if component in UDEB is working OK; sl@0: // should never get here if component is in UDEB. sl@0: sl@0: // If component is in UREL, then could reach here. sl@0: sl@0: return (0); sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestApiBoundaries() sl@0: /** sl@0: This method is a test case to exercise GetCharacterPosition() with sl@0: parameter values at range boundaries and in some cases out-or-raange. sl@0: */ sl@0: { sl@0: TBool r; sl@0: TBuf<20> testText(0); sl@0: sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: // 1: Check input arguments in paramter not modified sl@0: testText = _L16("a"); sl@0: param.iText.Set(testText); sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iDirection == CFont::EHorizontal sl@0: && param.iFlags == CFont::TPositionParam::EFLogicalOrder sl@0: && param.iText.Ptr() == testText.Ptr()); sl@0: sl@0: // 2: Check invalid iText descriptor panics (when component in UDEB) sl@0: // When component built in UREL, behaviour is undefined, so do not test. sl@0: TRequestStatus threadStatus; sl@0: RThread thread; sl@0: TInt rc; sl@0: TBool jit; sl@0: jit = User::JustInTime(); sl@0: User::SetJustInTime(EFalse); sl@0: rc = thread.Create(KThread2NameFirst, TestApiBoundaries_TC2, sl@0: KDefaultStackSize, KMinHeapSize, KMinHeapSize*4, this); sl@0: TEST(KErrNone == rc); sl@0: thread.Logon(threadStatus); sl@0: thread.Resume(); sl@0: User::WaitForRequest(threadStatus); sl@0: sl@0: if (thread.ExitType() == EExitPanic) sl@0: { sl@0: TEST (thread.ExitReason() == EGdiPanic_InvalidInputParam); sl@0: INFO_PRINTF2(_L("Exit reason %d"), thread.ExitReason()); sl@0: TExitCategoryName exitCategory = thread.ExitCategory(); sl@0: INFO_PRINTF2(_L("Exit category %S"), &exitCategory); sl@0: } sl@0: else sl@0: { sl@0: // Function does not panic on invalid input; sl@0: // Warn that this is only valid behaviour if the GDI component being tested is built in UREL mode sl@0: // and there is a problem if the function has not panicked if the GDI component is build in UDEB mode sl@0: INFO_PRINTF1(_L("Warning: GetCharacterPosition() when given invalid iText descriptor has not panicked - this is only ok if the GDI component is built in UREL mode. If the GDI component is built in UDEB mode, then there is a problem.")); sl@0: } sl@0: thread.Close(); sl@0: User::SetJustInTime(jit); sl@0: sl@0: // 3: Zero length text descriptor sl@0: testText = _L(""); sl@0: param.iText.Set(testText); sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(!r && param.iPen.iX == 0 sl@0: && param.iOutputGlyphs == 0); sl@0: sl@0: // 4: Position in text beyond descriptor length sl@0: testText = _L16("a"); sl@0: param.iText.Set(testText); sl@0: param.iPosInText = 5; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(!r && param.iPen.iX == 0 sl@0: && param.iOutputGlyphs == 0); sl@0: sl@0: // 5: Position in text is negative, should panic (when component in UDEB) sl@0: // When component built in UREL, behaviour is undefined, so do not test. sl@0: jit = User::JustInTime(); sl@0: User::SetJustInTime(EFalse); sl@0: rc = thread.Create(KThread2NameSecond, TestApiBoundaries_TC5, sl@0: KDefaultStackSize, KMinHeapSize, KMinHeapSize*4, this); sl@0: TEST(KErrNone == rc); sl@0: thread.Logon(threadStatus); sl@0: thread.Resume(); sl@0: User::WaitForRequest(threadStatus); sl@0: sl@0: if (thread.ExitType() == EExitPanic) sl@0: { sl@0: TEST (thread.ExitReason() == EGdiPanic_InvalidInputParam); sl@0: INFO_PRINTF2(_L("Exit reason %d"), thread.ExitReason()); sl@0: TExitCategoryName exitCategory = thread.ExitCategory(); sl@0: INFO_PRINTF2(_L("Exit category %S"), &exitCategory); sl@0: } sl@0: else sl@0: { sl@0: // Function does not panic on invalid input; sl@0: // Warn that this is only valid behaviour if the GDI component being tested is built in UREL mode sl@0: // and there is a problem if the function has not panicked if the GDI component is build in UDEB mode sl@0: INFO_PRINTF1(_L("Warning: GetCharacterPosition() when given negative iPosInText has not panicked - this is only ok if the GDI component is built in UREL mode. If the GDI component is built in UDEB mode, then there is a problem.")); sl@0: } sl@0: sl@0: thread.Close(); sl@0: User::SetJustInTime(jit); sl@0: sl@0: // 6: Check 'No-char-data' condition handled sl@0: testText = _L16("A\033C"); sl@0: param.iText.Set(testText); sl@0: param.iPosInText = 1; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST( !r sl@0: && param.iPosInText == 2 sl@0: && param.iPen.iX == 0 sl@0: && param.iOutputGlyphs == 0); sl@0: sl@0: // 7: Check "Not-a-Char" condition handled sl@0: testText = _L16("\xFFFF\xFFFE\xFFFF\xFFFF\xFFFF\xFFFE\xFFFF\xFFFF\xFFFF\xFFFE\xFFFF\xFFFF"); sl@0: param.iText.Set(testText); sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST( r sl@0: && param.iPosInText == 1 sl@0: && param.iPen.iX == 0 sl@0: && param.iOutputGlyphs == 0); sl@0: sl@0: param.iPosInText = 5; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST( r sl@0: && param.iPosInText == 6 sl@0: && param.iPen.iX == 0 sl@0: && param.iOutputGlyphs == 0); sl@0: sl@0: // 8. Check that a cluster cannot be made from heterogeneous elements sl@0: // (in this case a 6 with a Hindi virama) sl@0: testText = _L16("6\x94D"); sl@0: param.iText.Set(testText); sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iOutputGlyphs == 1); sl@0: } sl@0: sl@0: inline TBool IsSupplementary(TUint aChar) sl@0: /** sl@0: @param aChar The 32-bit code point value of a Unicode character. sl@0: sl@0: @return True, if aChar is supplementary character; false, otherwise. sl@0: */ sl@0: { sl@0: return (aChar > 0xFFFF); sl@0: } sl@0: sl@0: inline TBool IsSurrogate(TText16 aInt16) sl@0: /** sl@0: @return True, if aText16 is high surrogate or low surrogate; false, otherwise. sl@0: */ sl@0: { sl@0: return (aInt16 & 0xF800) == 0xD800; sl@0: } sl@0: sl@0: inline TText16 GetHighSurrogate(TUint aChar) sl@0: /** sl@0: Retrieve the high surrogate of a supplementary character. sl@0: sl@0: @param aChar The 32-bit code point value of a Unicode character. sl@0: sl@0: @return High surrogate of aChar, if aChar is a supplementary character; sl@0: aChar itself, if aChar is not a supplementary character. sl@0: */ sl@0: { sl@0: return STATIC_CAST(TText16, 0xD7C0 + (aChar >> 10)); sl@0: } sl@0: sl@0: inline TText16 GetLowSurrogate(TUint aChar) sl@0: /** sl@0: Retrieve the low surrogate of a supplementary character. sl@0: sl@0: @param aChar The 32-bit code point value of a Unicode character. sl@0: sl@0: @return Low surrogate of aChar, if aChar is a supplementary character; sl@0: zero, if aChar is not a supplementary character. sl@0: */ sl@0: { sl@0: return STATIC_CAST(TText16, 0xDC00 | (aChar & 0x3FF)); sl@0: } sl@0: sl@0: void CTGlyphSelection::TestCodepoint(TUint aCodepoint, CFont* aFont) sl@0: /** sl@0: This helper routine is used by the test case sl@0: CTGlyphSelection::TestCtrlCharsIgnored(). sl@0: @param aCodepoint sl@0: The Unicode character to test. sl@0: @param aFont sl@0: The font to use in the test. sl@0: */ sl@0: { sl@0: TInt expectResultPosInText; sl@0: sl@0: const TInt KTestTextLen = 5; sl@0: TBuf<16> testText(KTestTextLen); sl@0: testText[0] = 'a'; sl@0: testText[1] = 'b'; sl@0: if (IsSupplementary(aCodepoint)) sl@0: { sl@0: testText[2] = GetHighSurrogate(aCodepoint); sl@0: testText[3] = GetLowSurrogate(aCodepoint); sl@0: expectResultPosInText = 4; sl@0: } sl@0: else sl@0: { sl@0: testText[2] = aCodepoint; sl@0: testText[3] = 'c'; sl@0: expectResultPosInText = 3; sl@0: } sl@0: testText[4] = 'd'; sl@0: sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: param.iText.Set(testText); sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: param.iPosInText = 2; sl@0: TBool r = aFont->GetCharacterPosition(param); sl@0: sl@0: TEST(r && param.iPosInText == expectResultPosInText sl@0: && param.iPen.iX == 0 sl@0: && param.iOutputGlyphs == 0); sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestCtrlCharsIgnored() sl@0: /** sl@0: This method is a test case to test GetCharacterPosition() copes sl@0: with formatting and control characters in the text supplied by sl@0: ignoring them. sl@0: */ sl@0: { sl@0: static const TUint testData[] = { sl@0: // 1: Formatting control codes Unicode3-p499&p500 sl@0: 0x200C, 0x200D, 0x200E, 0x200F, sl@0: 0x202A, 0x202B, 0x202C, 0x202D, 0x202E, sl@0: // 3: Non-character codes Unicode3-p846 U+FFFE? sl@0: // Original: sl@0: // 0xFFFF sl@0: // 4: Latin Ctrl codes U+0000..U+001F, U+007F Unicode3-p??? sl@0: // 5: Latin Supplement Ctrl code U+0080..U+009F Unicode3-p??? sl@0: // 6: Supplementary characters (scripts outside BMP still not supported) sl@0: }; sl@0: static const TUint testDataLength = sizeof(testData)/sizeof(testData[0]); sl@0: sl@0: for (TUint i = 0; i < testDataLength; i++) sl@0: TestCodepoint(testData[i], iTestFont); sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestLatinChars() sl@0: /** sl@0: This method is a test case to test GetCharacterPosition() correctly sl@0: processes characters from the Latin code page returning appropriate glyphs sl@0: codes. sl@0: */ sl@0: { sl@0: TBool r; sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: _LIT16(KText_aBc_1, "aBc 1"); sl@0: param.iText.Set(KText_aBc_1); sl@0: sl@0: // 1: Latin glyph at start of text sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 1 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 'a'); sl@0: sl@0: // 2: Latin glyph in middle of text sl@0: param.iPosInText = 1; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 2 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 'B'); sl@0: sl@0: // 3: Latin glyph at end of text sl@0: param.iPosInText = 4; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 5 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == '1'); sl@0: sl@0: // 4: Latin space glyph sl@0: param.iPosInText = 3; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 4 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == ' '); sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestSoftHyphen() sl@0: /** sl@0: This method is a test case to test GetCharacterPosition() correctly sl@0: processes soft hyphen chars by ignoring them if they are NOT at the sl@0: end of the text (aka end of the line). sl@0: */ sl@0: { sl@0: TBool r; sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: _LIT16(KText_DKNY, "DK\xadNY\xad"); sl@0: param.iText.Set(KText_DKNY); sl@0: sl@0: // 1: Invoke on char before hyphen position sl@0: // This test returns only the glyph of the char before the hyphen sl@0: // treating the hyphen as another base char which end scanning. sl@0: param.iPosInText = 1; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 2 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 'K'); sl@0: sl@0: // 2: Invoke on hyphen position sl@0: // This test should show it ignores and skips soft hyphens returning sl@0: // no hyphen glyph. This is because soft hyphen are not visible when sl@0: // in middle of lines. sl@0: param.iPosInText = 2; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 3 sl@0: && param.iPen.iX == 0 sl@0: && param.iOutputGlyphs == 0); sl@0: sl@0: // 3: Invoke on hyphen position when hyphen at end of text sl@0: // This test should result in the hyphen glyph being returned as it sl@0: // is expect to be visible when it is at the end of the text supplied. sl@0: param.iPosInText = 5; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 6 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x00AD); sl@0: sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestSurrogates() sl@0: /** sl@0: This method is a test case to test GetCharacterPosition() correctly sl@0: processes surrogate pairs. sl@0: */ sl@0: { sl@0: static const TUint validPairs[] = { sl@0: // Hi Lo Code Hi Lo Code Hi Lo Code sl@0: 0xD800, 0xDC00, 0x00010000, 0xD800, 0xDE9A, 0x0001029A, 0xD800, 0xDFFF, 0x000103FF, sl@0: 0xD89A, 0xDC00, 0x00036800, 0xD89A, 0xDE9A, 0x00036A9A, 0xD89A, 0xDFFF, 0x00036BFF, sl@0: 0xDBFF, 0xDC00, 0x0010FC00, 0xDBFF, 0xDE9A, 0x0010FE9A, 0xDBFF, 0xDFFF, 0x0010FFFF sl@0: }; sl@0: static const TUint validPairsLength = sizeof(validPairs)/sizeof(TText16); sl@0: sl@0: TBool r; sl@0: TBuf<20> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: // 1: Test valid surrogate pair chars sl@0: testText.SetLength(5); sl@0: testText[0] = 'a'; sl@0: testText[3] = 'D'; sl@0: testText[4] = '1'; sl@0: param.iText.Set(testText); sl@0: for (TUint i = 0; i < validPairsLength/3; i+=3) sl@0: { sl@0: testText[1] = (TText16) validPairs[i]; sl@0: testText[2] = (TText16) validPairs[i+1]; sl@0: param.iPosInText = 1; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 3 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == validPairs[i+2]); sl@0: } sl@0: sl@0: // 2: Test unpaired high surrogate chars sl@0: testText[1] = 0xD809; sl@0: testText[2] = 'a'; sl@0: param.iPosInText = 1; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 2 sl@0: && param.iPen.iX == 0 sl@0: && param.iOutputGlyphs == 0); sl@0: sl@0: // 3: Test unpaired low surrogate chars sl@0: testText[1] = 'a'; sl@0: testText[2] = 0xDC09; sl@0: param.iPosInText = 2; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 3 sl@0: && param.iPen.iX == 0 sl@0: && param.iOutputGlyphs == 0); sl@0: sl@0: // 4: Test latin/surrogate boundry ensuring surrogate not skipped! sl@0: testText[1] = (TText16) validPairs[0]; sl@0: testText[2] = (TText16) validPairs[1]; sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 1 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode =='a'); sl@0: } sl@0: sl@0: sl@0: /** sl@0: @SYMTestCaseID TI18N-GDI-CIT-4077 sl@0: @SYMTestCaseDesc Automated GDI testing for GB18030 ExtB sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to get glyph information for GB18030 ExtB characters. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode charactors must be returned sl@0: @SYMPREQ 2471: UTF-16 compliant text handling sl@0: */ sl@0: void CTGlyphSelection::TestNonBmpCharsInGB18030(CFbsFont* aFont) sl@0: { sl@0: INFO_PRINTF1(_L("Test GB18030 non-BMP Glyphs")); sl@0: // Do the testing sl@0: sl@0: TBool r; sl@0: TBuf<30> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: testText.SetLength(4); sl@0: sl@0: // 201AD = D840, DDAD sl@0: testText[0] = 0xD840; sl@0: testText[1] = 0xDDAD; sl@0: sl@0: // 253BB = D854, DFBB sl@0: testText[2] = 0xD854; sl@0: testText[3] = 0xDFBB; sl@0: sl@0: param.iText.Set(testText); sl@0: sl@0: RShapeInfo aShapeInfo; sl@0: sl@0: // Do the testing sl@0: sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param, aShapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 2 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x000201AD); sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping is %d %d %d 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 2; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param, aShapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 4 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x000253BB); sl@0: sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping is %d %d %d 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: // Close aShapeInfo which releases any memory it is occupying sl@0: if (aShapeInfo.IsOpen()) sl@0: aShapeInfo.Close(); sl@0: sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestCombiningLatinChars() sl@0: /** sl@0: This method is a test case to test GetCharacterPosition() correctly sl@0: processes regular latin characters with diacritics. sl@0: */ sl@0: { sl@0: TBool r; sl@0: TBuf<20> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: testText.SetLength(10); sl@0: testText[0] = 'A'; sl@0: testText[1] = ' '; sl@0: testText[2] = 'A'; sl@0: testText[3] = 0x0300; // Above Grave Acent sl@0: testText[4] = 'I'; sl@0: testText[5] = 0x0330; // Below Tidle sl@0: testText[6] = 'o'; sl@0: testText[7] = 0x0308; // Above Diaeresis sl@0: testText[8] = 0x032F; // Below Inverted Breve sl@0: testText[9] = 'M'; sl@0: param.iText.Set(testText); sl@0: sl@0: // 1: Latin base with following space sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 1 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 'A'); sl@0: sl@0: // 2: Latin base with 1 combining above diacritic sl@0: param.iPosInText = 2; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: // Will Compose A (0x41) followed by grave accent (0x300) into A grave (0xC0) sl@0: TEST(r && param.iPosInText == 4 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0xC0 sl@0: && param.iOutput[0].iBounds.iTl == TPoint(0,-10) sl@0: && param.iOutput[0].iBounds.iBr == TPoint(10,2)); sl@0: sl@0: // 3: Latin base with 1 combining below diacritic sl@0: param.iPosInText = 4; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: // Will compose I (0x49) with tilde below (0x330) into I with tilde below (0x1E2C) sl@0: TEST(r && param.iPosInText == 6 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x1E2C sl@0: && param.iOutput[0].iBounds.iTl == TPoint(0,-10) sl@0: && param.iOutput[0].iBounds.iBr == TPoint(10,2)); sl@0: sl@0: // 4: Latin base with 2 combining diacritic sl@0: param.iPosInText = 6; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 9 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 3 sl@0: && param.iOutput[0].iCode == 'o' sl@0: && param.iOutput[0].iBounds.iTl == TPoint(0,-10) sl@0: && param.iOutput[0].iBounds.iBr == TPoint(10,2) sl@0: && param.iOutput[1].iCode == 0x0308 sl@0: && param.iOutput[1].iBounds.iTl == TPoint(0,-23) sl@0: && param.iOutput[1].iBounds.iBr == TPoint(10,-11) sl@0: && param.iOutput[2].iCode == 0x032F sl@0: && param.iOutput[2].iBounds.iTl == TPoint(0,3) sl@0: && param.iOutput[2].iBounds.iBr == TPoint(10,15)); sl@0: sl@0: // 5: Latin base with 9 combining chars, should exceed max output! sl@0: testText[0] = 'a'; sl@0: testText[1] = 0x0300; // Above Grave Acent sl@0: testText[2] = 0x0330; // Below Tidle sl@0: testText[3] = 0x0308; // Above Diaeresis sl@0: testText[4] = 0x032F; // Below Inverted Breve sl@0: testText[5] = 0x0300; // Above Grave Acent sl@0: testText[6] = 0x0330; // Below Tidle sl@0: testText[7] = 0x0308; // Above Diaeresis sl@0: testText[8] = 0x032F; // Below Inverted Breve sl@0: testText[9] = 0x0300; // Above Grave Acent sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 8 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 8 sl@0: && param.iOutput[0].iCode == 'a' sl@0: && param.iOutput[7].iCode == 0x0308); sl@0: } sl@0: sl@0: /* sl@0: Used for cleanup of RImplInfoArray implementationArray below sl@0: This method is stolen from FbsTop.cpp sl@0: */ sl@0: sl@0: LOCAL_C void ResetAndDestroyRImplInfoPtrArray(TAny* aPtr) sl@0: { sl@0: RImplInfoPtrArray* array = reinterpret_cast (aPtr); sl@0: array->ResetAndDestroy(); sl@0: } sl@0: sl@0: LOCAL_C void LoadOpenFontLibraries(CFontStore* aFontStore) sl@0: { sl@0: sl@0: RImplInfoPtrArray implementationArray; sl@0: TCleanupItem cleanup(ResetAndDestroyRImplInfoPtrArray, &implementationArray); sl@0: CleanupStack::PushL(cleanup); sl@0: TInt error; sl@0: TInt ecomerror; sl@0: TInt ecomnotready; sl@0: TUid uid = {KUidOpenFontRasterizerPlunginInterface}; sl@0: sl@0: // Making sure that no race situation arises sl@0: // If ECom is not ready, give it another chance and try again. if it still doesn't work sl@0: // after the third try, then it just carries on quietly and fails... sl@0: for (ecomnotready =0; ecomnotready <3; ecomnotready++) sl@0: { sl@0: TRAP(ecomerror,REComSession::ListImplementationsL(uid,implementationArray)); sl@0: if (!ecomerror) sl@0: { sl@0: break; sl@0: } sl@0: else sl@0: { sl@0: ecomerror = 0; sl@0: User::After(0); sl@0: } sl@0: } sl@0: sl@0: const TInt availCount = implementationArray.Count(); sl@0: for (TInt count=0;countImplementationUid(); sl@0: // Create a rasterizer sl@0: COpenFontRasterizer* rasterizer=0; sl@0: TRAP(error,rasterizer = COpenFontRasterizer::NewL(rasterizerUid)); sl@0: if (!error) sl@0: { sl@0: // Install it in the font store. sl@0: TRAP(error,aFontStore->InstallRasterizerL(rasterizer)); sl@0: if (error) sl@0: delete rasterizer; sl@0: } sl@0: } sl@0: CleanupStack::PopAndDestroy(&implementationArray); sl@0: sl@0: } sl@0: sl@0: void CTGlyphSelection::TestIsolatedCombiningLatinChars() sl@0: /** sl@0: This method is a test case to test GetCharacterPosition() correctly sl@0: processes isloated combining marks. sl@0: */ sl@0: { sl@0: // Need to use a valid font so that GetCharacterPosition will be able to find the necessary glyph information. sl@0: _LIT16(KTestFontFile, "C:\\s60ssb_v500.ttf"); sl@0: _LIT16(KTestFontFaceName, "Series 60 Sans"); sl@0: sl@0: // create a font store for testing sl@0: CFontStore* fontStore = CFontStore::NewL(&User::Heap()); sl@0: //load all ecom implemented rasterizer dlls. installs the rasterizer. sl@0: LoadOpenFontLibraries(fontStore); sl@0: // test font preparation sl@0: fontStore->iKPixelWidthInTwips = 11860; //This value is default sl@0: //add any required font files sl@0: TUid err = fontStore->AddFileL(KTestFontFile); sl@0: TFontSpec testFontSpec(KTestFontFaceName,200); sl@0: sl@0: CFbsBitmap* bmp = new(ELeave) CFbsBitmap; sl@0: sl@0: TInt ret = bmp->Create(TSize(100,100),EGray2); sl@0: if (ret == KErrNotSupported) sl@0: return; sl@0: else sl@0: User::LeaveIfError(ret); sl@0: sl@0: CFbsBitmapDevice* device = NULL; sl@0: TRAPD(err2,device = CFbsBitmapDevice::NewL(bmp)); sl@0: TEST(err2 == KErrNone); sl@0: sl@0: CFbsBitGc* gc = NULL; sl@0: User::LeaveIfError(device->CreateContext(gc)); sl@0: // Font file Creation sl@0: CFbsFont* testFont = NULL; sl@0: User::LeaveIfError(device->GetNearestFontToDesignHeightInTwips(testFont,testFontSpec)); sl@0: gc->UseFont(testFont); sl@0: CleanupStack::PushL(testFont); sl@0: sl@0: // Now start the test case: sl@0: sl@0: TBool r; sl@0: TBuf<20> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: testText.SetLength(7); sl@0: testText[0] = 0x0323; //Below Dot sl@0: testText[1] = ' '; sl@0: testText[2] = 0x0300; //Above Grave Acent sl@0: testText[3] = ' '; sl@0: testText[4] = 0x0323; //Below Dot sl@0: testText[5] = 0x0300; //Above Grave Acent sl@0: testText[6] = 0x0301; //Above Acute Acent sl@0: param.iText.Set(testText); sl@0: sl@0: // 1: Test the bounds for combining below mark in isolation sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = testFont->GetCharacterPosition(param); sl@0: sl@0: TEST(r && param.iPosInText == 1 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x0323); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen == TPoint(0,0) sl@0: && param.iOutput[0].iBounds.iTl == TPoint(-6,1) sl@0: && param.iOutput[0].iBounds.iBr == TPoint(-4,3)); sl@0: #endif sl@0: sl@0: // 2: Test the bounds for combining above mark in isolation sl@0: param.iPosInText = 1; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = testFont->GetCharacterPosition(param); sl@0: sl@0: TEST(r && param.iPosInText == 3 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[1].iCode == 0x0300); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen == TPoint(4,0) sl@0: && param.iOutput[1].iBounds.iTl == TPoint(-2,-15) sl@0: && param.iOutput[1].iBounds.iBr == TPoint(2,-12)); sl@0: #endif sl@0: sl@0: // 3: Test the bounds for multiple combing marks in isolation sl@0: param.iPosInText = 3; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = testFont->GetCharacterPosition(param); sl@0: sl@0: TEST(r && param.iPosInText == 7 sl@0: && param.iOutputGlyphs == 4 sl@0: && param.iOutput[1].iCode == 0x0323 sl@0: && param.iOutput[2].iCode == 0x0300 sl@0: && param.iOutput[3].iCode == 0x0301); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen == TPoint(4,0) sl@0: && param.iOutput[1].iBounds.iTl == TPoint(-1,1) sl@0: && param.iOutput[1].iBounds.iBr == TPoint(1,3) sl@0: && param.iOutput[2].iBounds.iTl == TPoint(-2,-16) sl@0: && param.iOutput[2].iBounds.iBr == TPoint(2,-13) sl@0: && param.iOutput[3].iBounds.iTl == TPoint(-2,-20) sl@0: && param.iOutput[3].iBounds.iBr == TPoint(2,-17)); sl@0: #endif sl@0: sl@0: // Done with the font, pop it off. sl@0: CleanupStack::Pop(testFont); sl@0: sl@0: //Cleaning the memory sl@0: delete bmp; sl@0: delete device; sl@0: delete gc; sl@0: fontStore->RemoveFile(err); sl@0: delete fontStore; sl@0: REComSession::FinalClose(); sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestContextInShapeInfo() sl@0: /** sl@0: This method is a test case to test GetCharacterPosition2() correctly sl@0: handle context. sl@0: */ sl@0: { sl@0: TBool r; sl@0: TBuf<20> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: RShapeInfo shapeInfo; sl@0: sl@0: //test control characters which has not defined processFun in TTableEntry sl@0: testText.SetLength(7); sl@0: testText[0] = 0xffff; //control character, test for the range { 0xFFFE, 0xFFFF, 0} sl@0: testText[1] = '1'; sl@0: testText[2] = 0x200E; //control character, test for the range { 0x200C, 0x200F, 0} sl@0: testText[3] = '.'; sl@0: testText[4] = 'a'; sl@0: testText[5] = 0x202A; //control character, test for the range { 0x202A, 0x202E, 0} sl@0: testText[6] = ','; sl@0: sl@0: param.iText.Set(testText); sl@0: sl@0: // 1. Test '0xffff' as NULL context at position zero - sl@0: // 0xffff should not be taken as context, and character '1' can be rendered correctly sl@0: param.iPosInText = 1; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition2(param, shapeInfo); sl@0: TEST(r && param.iPosInText == 2 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 49); sl@0: sl@0: // 2. Test '0x200E' - 0x200E is not rendered, either not treated as context. sl@0: // character '.' and 'a' should be rendered correctly. sl@0: param.iPosInText = 2; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition2(param, shapeInfo); sl@0: TEST(r && param.iPosInText == 3 sl@0: && param.iOutputGlyphs == 0); sl@0: sl@0: param.iPosInText = 3; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition2(param, shapeInfo); sl@0: TEST(r && param.iPosInText == 4 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 46); sl@0: sl@0: param.iPosInText = 4; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition2(param, shapeInfo); sl@0: TEST(r && param.iPosInText == 5 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 'a'); sl@0: sl@0: // 3. Test '0x202A' - 0x202A is not rendered, either not treated as context. sl@0: // character ',' should be rendered correctly. sl@0: param.iPosInText = 5; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition2(param, shapeInfo); sl@0: TEST(r && param.iPosInText == 6 sl@0: && param.iOutputGlyphs == 0); sl@0: sl@0: param.iPosInText = 6; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition2(param, shapeInfo); sl@0: TEST(r && param.iPosInText == 7 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 44); sl@0: } sl@0: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-1580 sl@0: @SYMTestCaseDesc Automated GDI testing for Hindi sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid and invalid Hindi glyph clusters. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode charactors must be returned sl@0: @SYMPREQ 18: Hindi for Bravo sl@0: */ sl@0: void CTGlyphSelection::TestHindiChars(CFbsFont* aFont) sl@0: { sl@0: INFO_PRINTF1(_L("Test Hindi Glyphs")); sl@0: // Do the testing sl@0: sl@0: TBool r; sl@0: TBuf<30> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: testText.SetLength(30); sl@0: sl@0: testText[0] = 0x0930; sl@0: testText[1] = 0x093C; sl@0: testText[2] = 0x094D; sl@0: testText[3] = 0x0915; sl@0: sl@0: testText[4] = 0x0915; sl@0: testText[5] = 0x094D; sl@0: testText[6] = 0x0915; sl@0: sl@0: testText[7] = 0x0930; sl@0: testText[8] = 0x094D; sl@0: testText[9] = 0x0915; sl@0: sl@0: testText[10] = 0x0915; sl@0: testText[11] = 0x094D; sl@0: testText[12] = 0x0930; sl@0: sl@0: testText[13] = 0x0915; sl@0: testText[14] = 0x094D; sl@0: testText[15] = 0x0937; sl@0: sl@0: testText[16] = 0x0915; sl@0: testText[17] = 0x094D; sl@0: testText[18] = 0x0930; sl@0: testText[19] = 0x094D; sl@0: testText[20] = 0x092A; sl@0: sl@0: /* When the following character 0x0036 is shaped, the context will be taken into consideration when sl@0: determining the glyph for 0x0036 sl@0: The context for 0x0036 is the Devanagari character 0x092A at position (iPosInText) 20 sl@0: **/ sl@0: testText[21] = 0x0036; sl@0: testText[22] = 0x094D; sl@0: sl@0: testText[23] = 0x0020; sl@0: sl@0: // INC101103: Strings containing ZWJ do not get rendered properly for Hindi sl@0: testText[24] = 0x092E; sl@0: testText[25] = 0x094D; sl@0: testText[26] = 0x200D; sl@0: testText[27] = 0x092E; sl@0: testText[28] = 0x093F; sl@0: testText[29] = 0x200D; sl@0: sl@0: param.iText.Set(testText); sl@0: sl@0: RShapeInfo aShapeInfo; sl@0: sl@0: // Do the testing sl@0: sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param, aShapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 4 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000108 sl@0: && param.iOutput[1].iCode == 0x80000072); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 17); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping is %d %d %d 0x%x 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 4; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param, aShapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 7 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x800001C2); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping is %d %d %d 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 7; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param, aShapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 10 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000072 sl@0: && param.iOutput[1].iCode == 0x80000130); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 11); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping is %d %d %d 0x%x 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 10; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param, aShapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 13 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000136); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping is %d %d %d 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 13; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param, aShapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 16 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x800001BE); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping is %d %d %d 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 16; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param, aShapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 21 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x8000017A sl@0: && param.iOutput[1].iCode == 0x80000087); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 18); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping is %d %d %d 0x%x 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: /* The following shaping will consider the context when determining the glyph for 0x0036 Digit character sl@0: The context for 0x0036 is the Devanagari character 0x092A at position (iPosInText) 20 sl@0: **/ sl@0: param.iPosInText = 21; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param, aShapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 22 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000016); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 9); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping is %d %d %d 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: // INC101103: Strings containing ZWJ do not get rendered properly for Hindi sl@0: param.iPosInText = 24; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param, aShapeInfo); sl@0: // We are mainly testing the position in text after rendering, which should be at the end of the syllable sl@0: // that should include the ZWJ and any consonant that follows it sl@0: TEST(r && param.iPosInText == 29 sl@0: && param.iOutputGlyphs == 3 sl@0: && param.iOutput[0].iCode == 0x80000272 sl@0: && param.iOutput[1].iCode == 0x80000105 sl@0: && param.iOutput[2].iCode == 0x8000008B); sl@0: sl@0: // Close aShapeInfo which releases any memory it is occupying sl@0: if (aShapeInfo.IsOpen()) sl@0: aShapeInfo.Close(); sl@0: sl@0: } sl@0: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-3381 sl@0: @SYMTestCaseDesc Automated GDI testing for Kannada sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid and invalid Kannada glyph clusters. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 19: Kannada for Ogmha sl@0: */ sl@0: sl@0: void CTGlyphSelection::TestKannadaChars(CFbsFont* aFont) sl@0: { sl@0: INFO_PRINTF1(_L("Test Kannada Glyphs")); sl@0: sl@0: TBuf<79> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: testText.SetLength(79); sl@0: //Testdata for kannada Langauage sl@0: sl@0: testText[0] = 0x0C95; sl@0: testText[1] = 0x0CCD; sl@0: testText[2] = 0x0020; sl@0: sl@0: testText[3] = 0x0CAF; sl@0: testText[4] = 0x0CCD; sl@0: testText[5] = 0x0020; sl@0: sl@0: testText[6] = 0x0C99; sl@0: testText[7] = 0x0CCD; sl@0: testText[8] = 0x0020; sl@0: sl@0: testText[9] = 0x0CA3; sl@0: testText[10] = 0x0CCD; sl@0: testText[11] = 0x0020; sl@0: sl@0: testText[12] = 0x0C95; sl@0: testText[13] = 0x0CC3; sl@0: sl@0: testText[14] = 0x0CA4; sl@0: testText[15] = 0x0CC6; sl@0: sl@0: testText[16] = 0x0C9D; sl@0: testText[17] = 0x0CBE; sl@0: sl@0: testText[18] = 0x0C9E; sl@0: testText[19] = 0x0CBE; sl@0: sl@0: testText[20] = 0x0CA3; sl@0: testText[21] = 0x0CBE; sl@0: sl@0: testText[22] = 0x0CB3; sl@0: testText[23] = 0x0CC6; sl@0: sl@0: testText[24] = 0x0C9D; sl@0: testText[25] = 0x0CC6; sl@0: sl@0: testText[26] = 0x0CAC; sl@0: testText[27] = 0x0CC6; sl@0: sl@0: testText[28] = 0x0C9F; sl@0: testText[29] = 0x0CC6; sl@0: sl@0: testText[30] = 0x0C99; sl@0: testText[31] = 0x0CC6; sl@0: sl@0: testText[32] = 0x0CA3; sl@0: testText[33] = 0x0CC6; sl@0: sl@0: testText[34] = 0x0C95; sl@0: testText[35] = 0x0CBF; sl@0: sl@0: testText[36] = 0x0CB8; sl@0: testText[37] = 0x0CBF; sl@0: sl@0: testText[38] = 0x0CA1; sl@0: testText[39] = 0x0CBF; sl@0: sl@0: testText[40] = 0x0CA6; sl@0: testText[41] = 0x0CBF; sl@0: sl@0: testText[42] = 0x0C9D; sl@0: testText[43] = 0x0CBF; sl@0: sl@0: testText[44] = 0x0C9D; sl@0: testText[45] = 0x0CC1; sl@0: sl@0: testText[46] = 0x0CB5; sl@0: testText[47] = 0x0CC1; sl@0: sl@0: testText[48] = 0x0C95; sl@0: testText[49] = 0x0CC2; sl@0: sl@0: testText[50] = 0x0CAA; sl@0: testText[51] = 0x0CC2; sl@0: sl@0: testText[52] = 0x0CAE; sl@0: testText[53] = 0x0CCC; sl@0: sl@0: testText[54] = 0x0C95; sl@0: sl@0: testText[55] = 0x0CB0; sl@0: testText[56] = 0x200D; sl@0: testText[57] = 0x0CCD; sl@0: testText[58] = 0x0CAE; sl@0: sl@0: testText[59] = 0x0020; sl@0: sl@0: testText[60] = 0x0CB0; sl@0: testText[61] = 0x200D; sl@0: testText[62] = 0x0CCD; sl@0: testText[63] = 0x0CB0; sl@0: testText[64] = 0x200D; sl@0: testText[65] = 0x0CCD; sl@0: sl@0: sl@0: testText[66] = 0x0CB0; sl@0: testText[67] = 0x200D; sl@0: testText[68] = 0x0CCD; sl@0: testText[69] = 0x0CB0; sl@0: testText[70] = 0x0CCD; sl@0: testText[71] = 0x0CB0; sl@0: testText[72] = 0x0CCD; sl@0: testText[73] = 0x0CB0; sl@0: testText[74] = 0x0CCD; sl@0: testText[75] = 0x0CB0; sl@0: sl@0: // DEF103276: Kannada rendering: IcuLayoutEngine does not recongnise 0X0C8E as a vowel sl@0: testText[76] = 0x0020; sl@0: testText[77] = 0x0C8E; sl@0: testText[78] = 0x0C82; sl@0: // End of DEF103276: Kannada rendering: IcuLayoutEngine does not recongnise 0X0C8E as a vowel sl@0: sl@0: param.iText.Set(testText); sl@0: sl@0: // Do the testing sl@0: sl@0: TBool r; sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: RShapeInfo shapeInfo; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText ==2 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000839); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 16); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values of this shaping of Ka + Virama are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 3; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 5 sl@0: && param.iOutputGlyphs ==1 sl@0: && param.iOutput[0].iCode == 0x80000852 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 27); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values of this shaping Ya + Virama are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 6; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 8 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode ==0x8000083D); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 19); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for Nya + Virama iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 9; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 11 sl@0: && param.iOutputGlyphs ==1 sl@0: && param.iOutput[0].iCode == 0x80000847); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 20); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for NNA + Virama iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 12; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 14 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800007A8 sl@0: && param.iOutput[1].iCode == 0x800007D2); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping for Ka + Matra Vocalic R iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 14; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 16 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x8000088f); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 11); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for Ta + Matra AA iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 16; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 18 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x8000081E sl@0: && param.iOutput[1].iCode == 0x800007CD); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 29); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping for Jha + Matra AA iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 18; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 20 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800007b1 sl@0: && param.iOutput[1].iCode == 0x800007cd); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 23); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping for Nya + Matra AA iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: sl@0: param.iPosInText = 20; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 22 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000823 sl@0: && param.iOutput[1].iCode == 0x800007CD ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 21); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping for Nna + Matra AA iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 22; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 24 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x8000089C); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for LLa + Matra E iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 24; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 26 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000889); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 22); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for Jha + Matra E iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 26; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 28 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000896 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for Ba + Matra E iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 28; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 30 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x8000088a); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for Tta + Matra E iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 30; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 32 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800007ac sl@0: && param.iOutput[1].iCode == 0x800007d4 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 19); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping for Nya + Matra E iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 32; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 34 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x8000088e); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 14); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for Nna + Matra E iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 34; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 36 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000860 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for Ka + Matra I iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 36; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 38 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x8000087e ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 11); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for Sa + Matra I iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 38; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 40 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x8000086a); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for Dda + Matra I iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 40; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 42 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x8000086f); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for Va + Matra I iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 42; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 44 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000867 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 22); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of this shaping for Jha + Matra I iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 44; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 46 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800007b0 sl@0: && param.iOutput[1].iCode == 0x800007d0); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 28); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping for Jha + Matra U iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 46; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 48 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800007c6 sl@0: && param.iOutput[1].iCode == 0x800007d0); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 18); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping for Va + Matra U iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: sl@0: param.iPosInText = 48; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 50 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800007a8 sl@0: && param.iOutput[1].iCode == 0x800007d1 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 20); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping for Ka Matra UU iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode,param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 50; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 52 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800007bc sl@0: && param.iOutput[1].iCode == 0x800008a5); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 21); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping for Pa + Matra UU iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: sl@0: param.iPosInText = 52; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 54 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x8000082d sl@0: && param.iOutput[1].iCode == 0x800007d9); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 26); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping for Ma + Matra UU iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 55; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 59 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800007c2 sl@0: && param.iOutput[1].iCode == 0x80000809); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 17); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of this shaping for Ma + Matra UU iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[2].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 60; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: TEST(r && param.iPosInText == 64 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800007c2 sl@0: && param.iOutput[1].iCode == 0x8000080b); sl@0: INFO_PRINTF6(_L("Results are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x "), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 66; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: TEST(r && param.iPosInText == 75 sl@0: && param.iOutputGlyphs == 5 sl@0: && param.iOutput[0].iCode == 0x800007c2 sl@0: && param.iOutput[1].iCode == 0x8000080b sl@0: && param.iOutput[2].iCode == 0x800008db sl@0: && param.iOutput[3].iCode == 0x800008db sl@0: && param.iOutput[4].iCode == 0x800007da); sl@0: INFO_PRINTF7(_L("Results are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[2].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[2].iCode); sl@0: sl@0: // DEF103276: Kannada rendering: IcuLayoutEngine does not recongnise 0X0C8E as a vowel sl@0: param.iPosInText = 77; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: TEST(r && param.iPosInText == 79 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800007A2 sl@0: && param.iOutput[1].iCode == 0x80000798); sl@0: sl@0: INFO_PRINTF5(_L("DEF103276 Vowel E + Anusvara: iPosInText=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: //End of DEF103276: Kannada rendering: IcuLayoutEngine does not recongnise 0X0C8E as a vowel sl@0: sl@0: } sl@0: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-3360 sl@0: @SYMTestCaseDesc Automated GDI testing for Marathi sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid and invalid Marathi glyph clusters. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 19: Marathi for Ogmha sl@0: */ sl@0: sl@0: void CTGlyphSelection::TestMarathiChars(CFbsFont* aFont) sl@0: { sl@0: INFO_PRINTF1(_L("Test Marathi Glyphs")); sl@0: sl@0: TBool r; sl@0: TBuf<47> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: testText.SetLength(47); sl@0: sl@0: //Testdata sl@0: testText[0] = 0x0905; sl@0: testText[1] = 0x0945; sl@0: sl@0: testText[2] = 0x0931; sl@0: testText[3] = 0x094D; sl@0: testText[4] = 0x0915; sl@0: sl@0: testText[5] = 0x0930; sl@0: testText[6] = 0x094D; sl@0: testText[7] = 0x200D; sl@0: testText[8] = 0x0915; sl@0: sl@0: testText[9] = 0x0905; sl@0: testText[10] = 0x200D; sl@0: testText[11] = 0x0945; sl@0: sl@0: testText[12] = 0x0909; sl@0: testText[13] = 0x0945; sl@0: sl@0: testText[14] = 0x0915; sl@0: testText[15] = 0x200D; sl@0: testText[16] = 0x0945; sl@0: sl@0: // DEF102132: Marathi - Certain sequence of characters does not work correctly sl@0: testText[17] = 0x0905; sl@0: testText[18] = 0x0945; sl@0: testText[19] = 0x0901; sl@0: sl@0: testText[20] = 0x0905; sl@0: testText[21] = 0x200D; sl@0: testText[22] = 0x0945; sl@0: testText[23] = 0x0901; sl@0: // End of DEF102132: Marathi - Certain sequence of characters does not work correctly sl@0: sl@0: sl@0: // DEF102858: Marathi - State table does not allow explicit half forms followed by modifiers sl@0: testText[24] = 0x0020; sl@0: sl@0: testText[25] = 0x0930; sl@0: testText[26] = 0x094D; sl@0: testText[27] = 0x200D; sl@0: testText[28] = 0x0901; sl@0: // End of DEF102858: Marathi - State table does not allow explicit half forms followed by modifiers sl@0: sl@0: // INC104705 Marathi input: Incorrect movement of cursor with eyelash ra forming ligature. sl@0: testText[29] = 0x0020; sl@0: sl@0: testText[30] = 0x0930; sl@0: testText[31] = 0x094D; sl@0: testText[32] = 0x200D; sl@0: testText[33] = 0x0930; sl@0: testText[34] = 0x094D; sl@0: testText[35] = 0x200D; sl@0: testText[36] = 0x0930; sl@0: testText[37] = 0x094D; sl@0: testText[38] = 0x200D; sl@0: testText[39] = 0x0930; sl@0: testText[40] = 0x094D; sl@0: testText[41] = 0x200D; sl@0: testText[42] = 0x0930; sl@0: testText[43] = 0x094D; sl@0: testText[44] = 0x200D; sl@0: // End of INC104705 Marathi input: Incorrect movement of cursor with eyelash ra forming ligature. sl@0: sl@0: // INC116507: Halant get attached with an independent vowel. sl@0: testText[45] = 0x0905; sl@0: testText[46] = 0x094D; sl@0: // End of INC116507: Halant get attached with an independent vowel. sl@0: sl@0: //To Do sl@0: sl@0: param.iText.Set(testText); sl@0: sl@0: // Test CANDRA A: Independent Vowel A + CANDRA E sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: RShapeInfo shapeInfo; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 2 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000528 sl@0: && param.iOutput[1].iCode == 0x80000566); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of shaping CANDRA A is %d %d %d 0x%x 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: sl@0: // Test Eyelash RA post Unicode 3.0: RRA + VIRAMA + CONSONANT sl@0: param.iPosInText = 2 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 5 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800005d3 sl@0: && param.iOutput[1].iCode == 0x80000538); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 18); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of shaping post Unicode 3.0 Eyelash RA is %d %d %d 0x%x 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: // Test Eyelash RA pre Unicode 3.0: RA + VIRAMA + ZWJ + CONSONANT sl@0: param.iPosInText = 5; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 9 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800005d3 sl@0: && param.iOutput[1].iCode == 0x80000538); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 18); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of shaping pre Unicode 3.0 Eyelash RA is %d %d %d 0x%x 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: // Test second form of CANDRA A: Independent Vowel A + ZWJ + CANDRA E sl@0: param.iPosInText = 9; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 12 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000528 sl@0: && param.iOutput[1].iCode == 0x80000566 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The result of shaping second form of CANDRA A is %d %d %d 0x%x 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: // Test that CANDRA E does not join with any other independent vowel sl@0: param.iPosInText = 12; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 13 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x8000052c); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 9); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of shaping any other Independent Vowel + CANDRA E is %d %d %d 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: // Test that the second form of CANDRA A (i.e. using ZWJ) doesn't work for CONSONANTS (illegal) sl@0: param.iPosInText = 14; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 15 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000538); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 11); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The result of shaping CONSONANT + ZWJ + CANDRA E is %d %d %d 0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: // DEF102132: Marathi - Certain sequence of characters does not work correctly sl@0: param.iPosInText = 17; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 20 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000528 sl@0: && param.iOutput[1].iCode == 0x8000069d); sl@0: sl@0: sl@0: INFO_PRINTF5(_L("DEF102132 Independent Vowel A + CANDRA E + Vowel Modifier %d %d 0x%x 0x%x"), param.iPosInText, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 20; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 23 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000528 sl@0: && param.iOutput[1].iCode == 0x8000069d); sl@0: sl@0: INFO_PRINTF5(_L("DEF102132 Independent Vowel A + ZWJ + CANDRA E + Vowel Modifier %d %d 0x%x 0x%x"), param.iPosInText, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: // End of DEF102132: Marathi - Certain sequence of characters does not work correctly sl@0: sl@0: // DEF102858: Marathi - State table does not allow explicit half forms followed by modifiers sl@0: param.iPosInText = 25; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: TEST(r && param.iPosInText == 29 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800005D3 sl@0: && param.iOutput[1].iCode == 0x80000524); sl@0: sl@0: INFO_PRINTF5(_L("DEF102858 Ra + Virama + ZWJ + Modifier %d %d 0x%x 0x%x"), param.iPosInText, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: // End of DEF102858: Marathi - State table does not allow explicit half forms followed by modifiers sl@0: sl@0: // INC104705 Marathi input: Incorrect movement of cursor with eyelash ra forming ligature. sl@0: param.iPosInText = 30; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: TEST(r && param.iPosInText == 42 sl@0: && param.iOutputGlyphs == 5 sl@0: && param.iOutput[0].iCode == 0x800005D3 sl@0: && param.iOutput[1].iCode == 0x800005D3 sl@0: && param.iOutput[2].iCode == 0x800005B8 sl@0: && param.iOutput[3].iCode == 0x80000553 sl@0: && param.iOutput[4].iCode == 0x8000056E); sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(param.iPen.iX == 20); sl@0: #endif sl@0: sl@0: INFO_PRINTF7(_L("INC104705 Ra + Virama + ZWJ + Ra + Virama + ZWJ + Ra + Virama + ZWJ + Ra + Virama + ZWJ + Ra + Virama + ZWJ %d %d 0x%x 0x%x 0x%x 0x%x"), param.iPosInText, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[2].iCode, param.iOutput[3].iCode); sl@0: // End of INC104705 Marathi input: Incorrect movement of cursor with eyelash ra forming ligature. sl@0: sl@0: // INC116507: Halant get attached with an independent vowel. sl@0: param.iPosInText = 45; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 47 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x8000058F sl@0: && param.iOutput[1].iCode == 0x8000056E); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 21); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("INC116507: Independent Vowel A + Halant %d %d %d 0x%x 0x%x"), param.iPosInText, param.iOutputGlyphs, param.iPen.iX, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: // End of INC116507: Halant get attached with an independent vowel. sl@0: sl@0: } sl@0: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-3417 sl@0: @SYMTestCaseDesc Automated GDI testing for Gujarati sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid and invalid gujarati glyph clusters. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 19: Gujarati for Ogmha sl@0: */ sl@0: sl@0: sl@0: void CTGlyphSelection::TestGujaratiChars(CFbsFont* aFont) sl@0: { sl@0: INFO_PRINTF1(_L("Test Gujarati Glyphs")); sl@0: sl@0: // Do the testing sl@0: sl@0: TBool r; sl@0: TBuf<162> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: testText.SetLength(162); sl@0: //Testdata for gujarati Langauage sl@0: sl@0: testText[0] = 0x0AAC; sl@0: testText[1] = 0x0ACD; sl@0: testText[2] = 0x200D; sl@0: testText[3] = 0x0020; sl@0: sl@0: testText[4] = 0x0A96; sl@0: testText[5] = 0x0ACD; sl@0: testText[6] = 0x0A97; sl@0: testText[7] = 0x0ACD; sl@0: testText[8] = 0x0A98; sl@0: testText[9] = 0x0ACD; sl@0: testText[10] = 0x0A9A; sl@0: sl@0: testText[11] = 0x0A95; sl@0: testText[12] = 0x0ACD; sl@0: testText[13] = 0x0A9C; sl@0: testText[14] = 0x200D; sl@0: testText[15] = 0x0020; sl@0: sl@0: testText[16] = 0x0A99; sl@0: testText[17] = 0x0ACD; sl@0: testText[18] = 0x0A9B; sl@0: testText[19] = 0x0ACD; sl@0: testText[20] = 0x0A9F; sl@0: testText[21] = 0x0ACD; sl@0: testText[22] = 0x0AA0; sl@0: sl@0: //Requirement (GUJ003) sl@0: sl@0: testText[23] = 0x0A95; sl@0: testText[24] = 0x0ACD; sl@0: testText[25] = 0x0AB7; sl@0: sl@0: sl@0: testText[26] = 0x0A95; sl@0: testText[27] = 0x0ACD; sl@0: testText[28] = 0x0AB7; sl@0: testText[29] = 0x0ACD; sl@0: testText[30] = 0x0AA4; sl@0: sl@0: testText[31] = 0x0A9C; sl@0: testText[32] = 0x0ACD; sl@0: testText[33] = 0x0AB7; sl@0: testText[34] = 0x0ACD; sl@0: testText[35] = 0x0AA4; sl@0: sl@0: testText[36] = 0x0A9C; sl@0: testText[37] = 0x0ACD; sl@0: testText[38] = 0x0A9E; sl@0: testText[39] = 0x0ACD; sl@0: testText[40] = 0x0AA4; sl@0: sl@0: //Requirement (GUJ 005) sl@0: sl@0: testText[41] = 0x0AB0; sl@0: testText[42] = 0x0ACD; sl@0: testText[43] = 0x0A95; sl@0: sl@0: testText[44] = 0x0AB0; sl@0: testText[45] = 0x0ACD; sl@0: testText[46] = 0x0A95; sl@0: testText[47] = 0x0AC9; sl@0: sl@0: testText[48] = 0x0AB0; sl@0: testText[49] = 0x0ACD; sl@0: testText[50] = 0x0A95; sl@0: testText[51] = 0x0A82; sl@0: sl@0: testText[52] = 0x0AB0; sl@0: testText[53] = 0x0ACD; sl@0: testText[54] = 0x0A95; sl@0: testText[55] = 0x0AC9; sl@0: testText[56] = 0x0A82; sl@0: testText[57] = 0x0020; sl@0: sl@0: //Requirement (GUJ 006) sl@0: sl@0: testText[58] = 0x0A97; sl@0: testText[59] = 0x0ACD; sl@0: testText[60] = 0x0AB0; sl@0: sl@0: testText[61] = 0x0A9A; sl@0: testText[62] = 0x0ACD; sl@0: testText[63] = 0x0AB0; sl@0: sl@0: testText[64] = 0x0A97; sl@0: testText[65] = 0x0ACD; sl@0: testText[66] = 0x0AB0; sl@0: testText[67] = 0x0ACD; sl@0: testText[68] = 0x0AA4; sl@0: sl@0: testText[69] = 0x0A9A; sl@0: testText[70] = 0x0ACD; sl@0: testText[71] = 0x0AB0; sl@0: testText[72] = 0x0ACD; sl@0: testText[73] = 0x0AA4; sl@0: sl@0: //Requirement (GUJ 007) sl@0: sl@0: testText[74] = 0x0A95; sl@0: testText[75] = 0x0ACD; sl@0: testText[76] = 0x0AB0; sl@0: sl@0: testText[77] = 0x0A9C; sl@0: testText[78] = 0x0ACD; sl@0: testText[79] = 0x0AB0; sl@0: sl@0: testText[80] = 0x0A95; sl@0: testText[81] = 0x0ACD; sl@0: testText[82] = 0x0AB0; sl@0: testText[83] = 0x0ACD; sl@0: testText[84] = 0x0AA4; sl@0: sl@0: testText[85] = 0x0A9C; sl@0: testText[86] = 0x0ACD; sl@0: testText[87] = 0x0AB0; sl@0: testText[88] = 0x0ACD; sl@0: testText[89] = 0x0AA4; sl@0: sl@0: //Requirement (GUJ 008) sl@0: sl@0: testText[90] = 0x0A9B; sl@0: testText[91] = 0x0ACD; sl@0: testText[92] = 0x0AB0; sl@0: sl@0: testText[93] = 0x0AAF; sl@0: testText[94] = 0x0ACD; sl@0: testText[95] = 0x0AB0; sl@0: sl@0: testText[96] = 0x0A9B; sl@0: testText[97] = 0x0ACD; sl@0: testText[98] = 0x0AB0; sl@0: testText[99] = 0x0ACD; sl@0: testText[100]= 0x0AA4; sl@0: sl@0: testText[101] = 0x0AAF; sl@0: testText[102] = 0x0ACD; sl@0: testText[103] = 0x0AB0; sl@0: sl@0: testText[104] = 0x0AAF; sl@0: testText[105] = 0x0ACD; sl@0: testText[106] = 0x0AB0; sl@0: testText[107] = 0x0ACD; sl@0: testText[108] = 0x0AA4; sl@0: sl@0: testText[109] = 0x0AB0; sl@0: testText[110] = 0x0ACD; sl@0: testText[111] = 0x0AB0; sl@0: testText[112] = 0x0ACD; sl@0: testText[113] = 0x0AB0; sl@0: sl@0: //Requirement (GUJ 009) sl@0: sl@0: testText[114] = 0x0A9F; sl@0: testText[115] = 0x0ACD; sl@0: testText[116] = 0x0AAF; sl@0: sl@0: testText[117] = 0x0A9B; sl@0: testText[118] = 0x0ACD; sl@0: testText[119] = 0x0AAF; sl@0: sl@0: testText[120] = 0x0AA2; sl@0: testText[121] = 0x0ACD; sl@0: testText[122] = 0x0AAF; sl@0: sl@0: testText[123] = 0x0A97; sl@0: testText[124] = 0x0ACD; sl@0: testText[125] = 0x0AAF; sl@0: sl@0: //Requirement (GUJ 010) sl@0: sl@0: testText[126] = 0x0A9F; sl@0: testText[127] = 0x0ACD; sl@0: testText[128] = 0x0AA0; sl@0: sl@0: testText[129] = 0x0AA6; sl@0: testText[130] = 0x0ACD; sl@0: testText[131] = 0x0AB5; sl@0: sl@0: testText[132] = 0x0A9F; sl@0: testText[133] = 0x0ACD; sl@0: testText[134] = 0x0AA0; sl@0: testText[135] = 0x0ACD; sl@0: testText[136] = 0x0AA4; sl@0: sl@0: sl@0: testText[137] = 0x0AA6; sl@0: testText[138] = 0x0ACD; sl@0: testText[139] = 0x0AB5; sl@0: testText[140] = 0x0ACD; sl@0: testText[141] = 0x0AA4; sl@0: sl@0: //Requirement (GUJ 011) sl@0: sl@0: testText[142] = 0x0AB0; sl@0: testText[143] = 0x0AC2; sl@0: sl@0: testText[144] = 0x0AB9; sl@0: testText[145] = 0x0AC3; sl@0: sl@0: testText[146] = 0x0AA6; sl@0: testText[147] = 0x0AC3; sl@0: sl@0: testText[148] = 0x0A9C; sl@0: testText[149] = 0x0AC0; sl@0: sl@0: //Subscript ligutares sl@0: sl@0: sl@0: testText[150] = 0x0A95; sl@0: testText[151] = 0x0A81; sl@0: sl@0: testText[152] = 0x0A95; sl@0: testText[153] = 0x0ABE; sl@0: testText[154] = 0x0A81; sl@0: sl@0: testText[155] = 0x0A95; sl@0: testText[156] = 0x0AC1; sl@0: testText[157] = 0x0A81; sl@0: sl@0: testText[158] = 0x0A8D; sl@0: testText[159] = 0x0A81; sl@0: sl@0: testText[160] = 0x0A88; sl@0: testText[161] = 0x0A81; sl@0: sl@0: sl@0: sl@0: param.iText.Set(testText); sl@0: sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: RShapeInfo shapeInfo; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 3 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x800009ec); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 9); sl@0: #endif sl@0: sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 4; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 11 sl@0: && param.iOutputGlyphs == 4 sl@0: && param.iOutput[0].iCode == 0x800009d7 sl@0: && param.iOutput[1].iCode == 0x800009d8 sl@0: && param.iOutput[2].iCode == 0x800009d9 sl@0: && param.iOutput[3].iCode == 0x80000967 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 34); sl@0: #endif sl@0: sl@0: INFO_PRINTF7(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[2].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[2].iCode); sl@0: sl@0: param.iPosInText = 11; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 14 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800009d6 sl@0: && param.iOutput[1].iCode == 0x80000969 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 22); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 16; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 23 sl@0: && param.iOutputGlyphs == 3 sl@0: && param.iOutput[0].iCode == 0x800009da sl@0: && param.iOutput[1].iCode == 0x800009dc sl@0: && param.iOutput[2].iCode == 0x80000aad); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 30); sl@0: #endif sl@0: sl@0: sl@0: INFO_PRINTF7(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[2].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[2].iCode); sl@0: sl@0: param.iPosInText = 23; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 26 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x800009d2 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: sl@0: param.iPosInText = 26; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 31 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800009f8 sl@0: && param.iOutput[1].iCode == 0x80000971); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 18); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 31; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 36 sl@0: && param.iOutputGlyphs == 3 sl@0: && param.iOutput[0].iCode == 0x800009dd sl@0: && param.iOutput[1].iCode == 0x800009f5 sl@0: && param.iOutput[2].iCode == 0x80000971); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 30); sl@0: #endif sl@0: sl@0: INFO_PRINTF7(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[2].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[2].iCode); sl@0: sl@0: param.iPosInText = 36; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 41 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800009f9 sl@0: && param.iOutput[1].iCode == 0x80000971); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 17); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 41; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 44 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000962 sl@0: && param.iOutput[1].iCode == 0x800009d4); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 8); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 44; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 48 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000962 sl@0: && param.iOutput[1].iCode == 0x80000ae1 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 48; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 52 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000962 sl@0: && param.iOutput[1].iCode == 0x80000ae9); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 8); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 52; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 57 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000962 sl@0: && param.iOutput[1].iCode == 0x80000ae2); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 58; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 61 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000a1e ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 11); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 61; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 64 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000a21 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 64; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 69 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000a64 sl@0: && param.iOutput[1].iCode == 0x80000971 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 17); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 69; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 74 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000a67 sl@0: && param.iOutput[1].iCode == 0x80000971); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 16); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 74; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 77 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000a1c); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 8); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 77; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 80 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000a23); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 15); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 80; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 85 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000a62 sl@0: && param.iOutput[1].iCode == 0x80000971); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 17); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 85; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 90 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000a69 sl@0: && param.iOutput[1].iCode == 0x80000971); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 24); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText =90; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 93 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000a22 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 93; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 96 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000a35 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 96; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 101 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000a68 sl@0: && param.iOutput[1].iCode == 0x80000971); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 21); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 101; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 104 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000a35 ); sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 104; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 109 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000a7b sl@0: && param.iOutput[1].iCode == 0x80000971 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 16); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 109; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 114 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000a36 sl@0: && param.iOutput[1].iCode == 0x800009d4 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 7); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 114; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 117 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000aae); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 17); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 117; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 120 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000aab ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 21); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 120; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 123 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000ab5 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 18); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 123; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 126 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x800009d8 sl@0: && param.iOutput[1].iCode == 0x8000097b); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 17); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 126; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 129 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000aad); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 9); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 129; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 132 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000ac0 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText =132; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 137 sl@0: && param.iOutputGlyphs == 3 sl@0: && param.iOutput[0].iCode == 0x800009e0 sl@0: && param.iOutput[1].iCode == 0x800009e1 sl@0: && param.iOutput[2].iCode == 0x80000971); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 26); sl@0: #endif sl@0: sl@0: sl@0: INFO_PRINTF7(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[2].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[2].iCode); sl@0: sl@0: param.iPosInText = 137; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 142 sl@0: && param.iOutputGlyphs == 3 sl@0: && param.iOutput[0].iCode == 0x800009e7 sl@0: && param.iOutput[1].iCode == 0x800009f3 sl@0: && param.iOutput[2].iCode == 0x80000971); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 23); sl@0: #endif sl@0: sl@0: INFO_PRINTF7(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[2].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[2].iCode); sl@0: sl@0: param.iPosInText = 142; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 144 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000b04); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 7); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 144; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 146 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000b05); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 9); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 146; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 148 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000b02); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 7); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 148; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 150 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000aff); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 16); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 150; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 152 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000962 sl@0: && param.iOutput[1].iCode ==0x80000951); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 8); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 152; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 155 sl@0: && param.iOutputGlyphs == 3 sl@0: && param.iOutput[0].iCode == 0x80000962 sl@0: && param.iOutput[1].iCode == 0x80000986 sl@0: && param.iOutput[2].iCode == 0x80000951); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: sl@0: INFO_PRINTF7(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[2].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[2].iCode); sl@0: sl@0: param.iPosInText = 155; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 158 sl@0: && param.iOutputGlyphs == 3 sl@0: && param.iOutput[0].iCode == 0x80000962 sl@0: && param.iOutput[1].iCode == 0x80000989 sl@0: && param.iOutput[2].iCode == 0x80000951); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 8); sl@0: #endif sl@0: sl@0: sl@0: INFO_PRINTF7(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[2].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[2].iCode); sl@0: param.iPosInText = 158; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 160 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000aee); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 14); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 160; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 162 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000aed); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestBengaliChars(CFbsFont* aFont) sl@0: { sl@0: INFO_PRINTF1(_L("Test Bengali Glyphs")); sl@0: sl@0: // Do the testing sl@0: sl@0: TBool r; sl@0: TBuf<115> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: testText.SetLength(115); sl@0: // Make sure there is no garbage values in the memory we are using. sl@0: for (TInt i = 0; i < testText.Length(); i++) sl@0: testText[i]=0xFFFF; sl@0: sl@0: //Testdata for Bengali language sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4002")); sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4002 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various invalid Bengali glyph clusters to test the requirement. sl@0: If any part of stored text (e.g. received or downloaded document) is not properly encoded in logical order, the relevant text handling processes must treat that part as an invalid sequence of text and use appropriate fallback mechanisms. Invalid sequences of characters must be rendered as incomplete syllables and rendering engine must be able to handle invalid coding appropriately sl@0: @SYMTestExpectedResults Rendering engine will render as incomplete syllables sl@0: @SYMPREQ 1766 Bengali for Sphinx sl@0: @SYMREQ 8741 Bengali Text Rendering sl@0: */ sl@0: sl@0: // BEN002: Test invalid sequences sl@0: testText[0] = 0x09C7; sl@0: testText[1] = 0x0995; sl@0: testText[2] = 0x0995; sl@0: testText[3] = 0x09C1; sl@0: testText[4] = 0x09C1; sl@0: testText[5] = 0x0995; sl@0: testText[6] = 0x09CD; sl@0: testText[7] = 0x09C1; sl@0: testText[8] = 0x0995; sl@0: testText[9] = 0x0981; sl@0: testText[10] = 0x09C1; sl@0: sl@0: param.iText.Set(testText); sl@0: RShapeInfo shapeInfo; sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 1 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000ce5 sl@0: && param.iOutput[1].iCode == 0x8000058f); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 15); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 1; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 2 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000cbc); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 2; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 4 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000ebe); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 4; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 5 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x8000058f sl@0: && param.iOutput[1].iCode == 0x80000ce1 sl@0: ); sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 9); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 5; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 7 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000cbc sl@0: && param.iOutput[1].iCode == 0x80000ce9 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 7; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 8 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x8000058f sl@0: && param.iOutput[1].iCode == 0x80000ce1 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 9); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 8; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 10 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000cbc sl@0: && param.iOutput[1].iCode == 0x80000cad sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 10; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 11 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x8000058f sl@0: && param.iOutput[1].iCode == 0x80000ce1 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 9); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: TRAPD(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4003")); sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4003 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions sl@0: Passing both Bengali and Latin scripts simultaneously sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766 Bengali for Sphinx sl@0: @SYMREQ 8741 Bengali Text Rendering sl@0: */ sl@0: //BEN003 sl@0: testText[11] = 0x0995; sl@0: testText[12] = 0x0041; // Unicode value for A sl@0: testText[13] = 0x09E6; //Bengali digit 1 sl@0: sl@0: param.iPosInText = 11; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 12 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000cbc sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 12; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 13 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x41 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x "), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 13; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 14 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode ==0x80000cf3 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4004")); sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4004 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Bengali glyph clusters to test the reequirement. sl@0: Text rendering in Bengali must be based on syllables and the text rendering engine must be capable of handling the Bengali syllabic structure. If a single word is longer than one row, the line can only be broken at syllable border. sl@0: Invalid sequences of characters must be rendered as incomplete syllables sl@0: sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Bengali for Sphinx sl@0: @SYMREQ 8741: Bengali Text Rendering sl@0: */ sl@0: // BEN004: sl@0: testText[14] = 0x0985; sl@0: testText[15] = 0x09A4; sl@0: testText[16] = 0x09CD; sl@0: testText[17] = 0x09AF; sl@0: testText[18] = 0x09A8; sl@0: testText[19] = 0x09CD; sl@0: testText[20] = 0x09A4; sl@0: sl@0: param.iPosInText = 14; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 15 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000cb0 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 14); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 15; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 18 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode ==0x80000ccb sl@0: && param.iOutput[1].iCode ==0x80000d6e sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 16); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode,param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 18; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 21 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000e14 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4005")); sl@0: // BEN005 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4005 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Bengali glyph clusters to test the requirment sl@0: Text rendering must be able to display specified character sequences using ligatures and set of ligatures (stable/unstable) must be font dependent / configurable. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Bengali for Sphinx sl@0: @SYMREQ 8741: Bengali Text Rendering sl@0: */ sl@0: testText[21] = 0x0995; sl@0: testText[22] = 0x09CD; sl@0: testText[23] = 0x09B7; sl@0: sl@0: testText[24] = 0x09A4; sl@0: testText[25] = 0x09CD; sl@0: testText[26] = 0x09B0; sl@0: sl@0: testText[27] = 0x09A6; sl@0: testText[28] = 0x09CD; sl@0: testText[29] = 0x09A6; sl@0: sl@0: sl@0: param.iPosInText = 21; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 24 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000d25 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 15); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 24; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 27 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode ==0x80000d89 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 27; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 30 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000e0a sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4006")); sl@0: // BEN006 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4006 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Bengali glyph clusters to test sl@0: whether tamil digits are recongized as numerals. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Bengali for Sphinx sl@0: @SYMREQ 8741: Bengali Text Rendering sl@0: */ sl@0: testText[30] = 0x09E6; // Bengali 1 sl@0: testText[31] = 0x0030; //Basic Latin 0 sl@0: sl@0: sl@0: param.iPosInText = 30; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 31 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000cf3 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 31; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 32 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000774 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 8); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x "), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4007")); sl@0: //BEN 008 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4007 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid sl@0: All text handling processes ((rendering, editing, searching, sorting etc.) MUST treat the sequence of a base consonant and a nukta equivalently to Nukta consonants sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Bengali for Sphinx sl@0: @SYMREQ 8741: Bengali Text Rendering sl@0: */ sl@0: testText[32] = 0x09AF; sl@0: testText[33] = 0x09BC; sl@0: testText[34] = 0x09DF; sl@0: sl@0: param.iPosInText = 32; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 34 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000cee sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x "), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4008")); sl@0: // BEN011 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4008 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Bengali glyph clusters to test sl@0: Rendering engine must be capable of handling joining formatters. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Bengali for Sphinx sl@0: @SYMREQ 8741: Bengali Text Rendering sl@0: */ sl@0: testText[35] = 0x0995; sl@0: testText[36] = 0x09CD; sl@0: testText[37] = 0x09B7; sl@0: sl@0: testText[38] = 0x0995; sl@0: testText[39] = 0x09CD; sl@0: testText[40] = 0x200C; sl@0: testText[42] = 0x09B7; sl@0: sl@0: testText[43] = 0x0995; sl@0: testText[44] = 0x09CD; sl@0: testText[45] = 0x200D; sl@0: testText[46] = 0x09B7; sl@0: sl@0: sl@0: param.iPosInText = 35; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 38 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000d25 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 15); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 38; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 40 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000cbc sl@0: && param.iOutput[1].iCode == 0x80000ce9 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode,param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 43; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 47 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000d2a sl@0: && param.iOutput[1].iCode == 0x80000cd9 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 22); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4009")); sl@0: // BEN012 sl@0: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4009 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Bengali glyph clusters to test sl@0: If consonant /ya/, /ra/, /la/, /ma/, /na/ or /ba/, is the last element of a consonant cluster, the consonant assumes a phala form. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Bengali for Sphinx sl@0: @SYMREQ 8741: Bengali Text Rendering sl@0: */ sl@0: testText[47] = 0x09AA; sl@0: testText[48] = 0x09CD; sl@0: testText[49] = 0x09AF; sl@0: sl@0: testText[50] = 0x09AA; sl@0: testText[51] = 0x09CD; sl@0: testText[52] = 0x09A8; sl@0: sl@0: // Not working with Series60Sans font: sl@0: testText[53] = 0x09AA; sl@0: testText[54] = 0x09CD; sl@0: testText[55] = 0x09AE; sl@0: sl@0: param.iPosInText = 47; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 50 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000cd0 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 15); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 50; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 53 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000e25 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 11); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: // Not working with Series60Sans font: sl@0: param.iPosInText = 53; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 56 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000d3e sl@0: && param.iOutput[1].iCode == 0x80000cd4 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 19); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4010")); sl@0: // BEN013 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4010 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Bengali glyph clusters to tet sl@0: Sequence , i.e. ya-phala, MUST be allowed after independent vowels /a/ and /e/. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Bengali for Sphinx sl@0: @SYMREQ 8741: Bengali Text Rendering sl@0: */ sl@0: testText[56] = 0x0985; sl@0: testText[57] = 0x09CD; sl@0: testText[58] = 0x09AF; sl@0: testText[59] = 0x09BE; sl@0: sl@0: // Double ya -> Ya, ya-phala sl@0: testText[60] = 0x09AA; sl@0: testText[61] = 0x09CD; sl@0: testText[62] = 0x09AF; sl@0: testText[63] = 0x09CD; sl@0: testText[64] = 0x09AF; sl@0: sl@0: param.iPosInText = 56; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPosInText == 57 sl@0: && param.iPen.iX == 14 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000cb0 sl@0: ); sl@0: #elif defined __ARMCC__ sl@0: TEST(r && param.iPosInText == 57 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000cb0 sl@0: ); sl@0: #endif sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 57; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 58 sl@0: && param.iOutputGlyphs == 0 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 0); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 60; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 65 sl@0: && param.iOutputGlyphs == 3 sl@0: && param.iOutput[0].iCode == 0x80000d3e sl@0: && param.iOutput[1].iCode == 0x80000cd5 sl@0: && param.iOutput[2].iCode == 0x80000d6e sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 23); sl@0: #endif sl@0: sl@0: INFO_PRINTF7(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[2].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[2].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4011")); sl@0: // BEN014 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4011 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid and glyph clusters to test sl@0: When consonant /ga/, /nna/, /na/, /pa/, /la/, /sha/, /ssa/ or /sa/ is a dead consonant, and none of the other consonant cluster formation rules apply, the consonant MUST be rendered with a stemless half form. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Bengali for Sphinx sl@0: @SYMREQ 8741: Bengali Text Rendering sl@0: */ sl@0: testText[65] = 0x0997; sl@0: testText[66] = 0x09CD; sl@0: testText[67] = 0x099C; sl@0: sl@0: testText[68] = 0x09AA; sl@0: testText[69] = 0x09CD; sl@0: testText[70] = 0x099C; sl@0: sl@0: sl@0: param.iPosInText = 65; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 68 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000d2c sl@0: && param.iOutput[1].iCode == 0x80000cc3 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 21); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 68; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 71 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000d3e sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 23); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: sl@0: // BEN015 sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4012")); sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4012 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Bengali glyph clusters to test sl@0: When /ka/, /nga/, /ca/, /tta/, /dda/, /ta/ or /da/ is a dead consonant, and none of the other consonant cluster formation rules apply, the consonant MUST be rendered with a miniature half form. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Bengali for Sphinx sl@0: @SYMREQ 8741: Bengali Text Rendering sl@0: */ sl@0: testText[71] = 0x0995; sl@0: testText[72] = 0x09CD; sl@0: testText[73] = 0x099C; sl@0: sl@0: sl@0: param.iPosInText = 71; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 74 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000d2a sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 26); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4013")); sl@0: // BEN016 sl@0: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4013 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Bengali glyph clusters to test sl@0: The consonant pairs /k.ka/, /ng.kha/, /c.nya/, /nn.nna/, /n.tha/, /n.pha/, /m.ta/, /m.tha/, /m.pha/, /m.bha/, /l.ka/, /l.ga/, /l.pa/, /ss.ka/, /ss.pha/, /s.ka/, /s.kha/, /s.ta/, /s.tha/, /s.pha/, /h.nna/ MUST be representend as stacks of two consonants. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Bengali for Sphinx sl@0: @SYMREQ 8741: Bengali Text Rendering sl@0: */ sl@0: // Ma does not stack correctly on top with Series60Sans font, produces half form instead. Font defect. sl@0: testText[74] = 0x09AE; sl@0: testText[75] = 0x09CD; sl@0: testText[76] = 0x09A5; sl@0: sl@0: testText[77] = 0x09AE; sl@0: testText[78] = 0x09CD; sl@0: testText[79] = 0x09AB; sl@0: // Ma does not stack correctly on top, produces half form instead. sl@0: testText[80] = 0x09AE; sl@0: testText[81] = 0x09CD; sl@0: testText[82] = 0x0995; sl@0: sl@0: testText[83] = 0x09A8; sl@0: testText[84] = 0x09CD; sl@0: testText[85] = 0x09A5; sl@0: sl@0: sl@0: //Combination pa,virama,ma produces incorrect glyph mapping: Font defect. sl@0: sl@0: param.iPosInText = 74; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 77 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000d42 sl@0: && param.iOutput[1].iCode == 0x80000ccc sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 21); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: sl@0: param.iPosInText = 77; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 80 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000e30 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 19); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: // Ma does not stack correctly on top, produces half form instead. sl@0: param.iPosInText = 80; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 83 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000d42 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 22); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: sl@0: param.iPosInText = 83; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 86 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000e15 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4014")); sl@0: // BEN017 sl@0: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4014 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Bengali glyph clusters to test sl@0: Consonant pairs /k.tta/, /k.ta/, /k.ssa/, /k.sa/, /g.ga/, /g.dha/, /ng.ka/, /ng.ga/, /j.ja/, /j.jha/, /j.nya/, /ny.ca/, /ny.cha/, /ny.ja/, /ny.jha/, /tt.tta/, /nn.ttha/, /nn.dda/, /t.ta/, /t.tha/, /d.da/, /d.dha/, /d.ba/, /d.bha/, /n.ta/, /n.dha/, /p.ta/, /b.ja/, /b.da/, /b.dha/, /m.pa/, /ss.tta/, /ss.ttha/, /ss.nna/, /s.pa/, /h.na/ /h.ma/ MUST be displayed as ligatures, if they appear at the end of a consonant cluster. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Bengali for Sphinx sl@0: @SYMREQ 8741: Bengali Text Rendering sl@0: */ sl@0: testText[86] = 0x0995; sl@0: testText[87] = 0x09CD; sl@0: testText[88] = 0x099F; sl@0: sl@0: testText[89] = 0x0995; sl@0: testText[90] = 0x09CD; sl@0: testText[91] = 0x09A4; sl@0: sl@0: // Not sure if this is forming the correct ligature sl@0: testText[92] = 0x09AE; sl@0: testText[93] = 0x09CD; sl@0: testText[94] = 0x09AA; sl@0: sl@0: // Not sure if this is forming the correct ligature sl@0: testText[95] = 0x09B8; sl@0: testText[96] = 0x09CD; sl@0: testText[97] = 0x09AA; sl@0: sl@0: testText[98] = 0x09B9; sl@0: testText[99] = 0x09CD; sl@0: testText[100] = 0x09A8; sl@0: sl@0: param.iPosInText = 86; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 89 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000dd7 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 89; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 92 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000dd9 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 15); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 92; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 95 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000e2f sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 19); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 95; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 98 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000e56 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 20); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 98; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 101 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000e5d sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4015")); sl@0: // BEN020 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4015 sl@0: @SYMTestCaseDesc Automated GDI testing for Bengali sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Bengali glyph clusters to test that sl@0: If RA is the first consonant cluster, it must assume the form of Repha. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Bengali for Sphinx sl@0: @SYMREQ 8741: Bengali Text Rendering sl@0: */ sl@0: testText[101] = 0x09B0; sl@0: testText[102] = 0x09CD; sl@0: testText[103] = 0x0995; sl@0: sl@0: testText[104] = 0x09B0; sl@0: testText[105] = 0x200C; sl@0: testText[106] = 0x09CD; sl@0: testText[107] = 0x09AF; sl@0: sl@0: param.iPosInText = 101; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 104 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000cbc sl@0: && param.iOutput[1].iCode == 0x80000d27 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText =104; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 105 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000cd6 sl@0: ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 9); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestTamilChars(CFbsFont* aFont) sl@0: { sl@0: INFO_PRINTF1(_L("Test Tamil Glyphs")); sl@0: sl@0: TBool r; sl@0: TBuf<162> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: testText.SetLength(162); sl@0: // Make sure there is no garbage values in the memory we are using. sl@0: for (TInt i = 0; i < testText.Length(); i++) sl@0: testText[i]=0xFFFF; sl@0: param.iText.Set(testText); sl@0: RShapeInfo shapeInfo; sl@0: //Testdata for Tamil Langauage sl@0: TRAPD(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4016")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4016 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test sl@0: a)The Tamil alphabets are listed in contiguous Unicode range(U+0B80–U+0BFF), This also contains Tamil Numbers. sl@0: b)The Tamil alphabets are listed in contiguous Unicode range(U+0B80–U+0BFF), This also contains Tamil Numbers. sl@0: c)Internal data storage should always be in the logical order, but the rendering of it may be different to that of the logical order sl@0: d)Combination of Unicode sequences must be rendered as valid blocks. In Tamil some character sequences are invalid and therefore only the sequences which follow the logical order as described in Req 1.2.3 should be rendered properly sl@0: e)If the text being rendered contains a mixture of scripts, the text in each script should be rendered according to the rules of that particular script. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: testText[0] = 0x0B95; //Tamil Ka sl@0: testText[1] = 0x0B8E; //Tamil e sl@0: testText[2] = 0x0061; //Latin A sl@0: testText[3] = 0x0905; // Hindi Ka sl@0: testText[4] = 0x0020; sl@0: // Do the testing sl@0: param.iPosInText = 0 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 1 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000bf6); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 1 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 2 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000bf0); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 14); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 2 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 3 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x61 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: param.iPosInText = 3 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 4 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000528); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: /*Req 02 1.2.3, 1.3.21, 1.3.21.1, 1.3.21.2 1.3.21.3 sl@0: sl@0: 1.2.3 The attachment presents the logical order used to present Tamil text. In the schematic samples, square brackets are used to presents the components that may be omitted. sl@0: 1.3.21 If the text-rendering engine detects invalid sequences of characters, it should render the invalid sequences using an appropriate fallback rendering mechanism sl@0: Please see the attachment for examples sl@0: 1.3.21.1 For normal rendering, combining Tamil characters must be preceded by a valid base character. sl@0: 1.3.21.2 Combining Tamil characters that do not follow a valid base character must be rendered using an appropriate fallback rendering. sl@0: 1.3.21.3 Device must not hang or crash because of unexpected character sequences.*/ sl@0: sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4017")); sl@0: //Req 03 sl@0: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4017 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test sl@0: It is reasonably common to mix Latin, Tamil as well as other script in texts. This must include the numerals. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: testText[4] = 0x0036;//Latin 06 sl@0: testText[5] = 0x0BEC;//Tamil 06 sl@0: sl@0: param.iPosInText = 4 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 5 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x8000077A); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 8); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 5 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 6 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000c20); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 16); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: /*Req 04 1.3.4, 1.3.20 sl@0: 1.3.4 1. Tamil is a semi-syllabic script and in Tamil text rendering the basic unit for handling text must be the orthographic syllable. sl@0: 2. Therefore, a text-rendering engine should first identify a syllable and then analyze the syllable. Based on the analysis, text-rendering engine should then be able to select and/or shape the glyphs required for rendering the syllable and to perform contextual positioning of glyphs inside a syllable. sl@0: 3. After a syllable has been formed it must be considered an indivisible and invariable unit. sl@0: 4. The shape of a syllable is not affected by surrounding syllables. sl@0: 1.3.20 Syllable is the smallest unbreakable component in Tamil*/ sl@0: sl@0: /*Req 07 1.3.5 sl@0: sl@0: 1.3.5 1. In Tamil, when ligatures are used there is a possibility that the shaping of the previous consonant will depend on the next consonant the user enters sl@0: 2. In Tamil, there is a possibility that even though the characters are entered one by one the position of the matras change depending on the consonant and the type of the matra sl@0: sl@0: Req 08 1.3.19 sl@0: sl@0: 1.3.19 In Tamil white space is used as a word boundary. Line breaking should be based on word boundaries sl@0: sl@0: sl@0: Req 09 1.2.4 sl@0: sl@0: 1.2.4 For compatibility with legacy encodings, split matra and vowel representations must be recognized as identical to the single code representations (preferred) sl@0: */ sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4018")); sl@0: //Req 10 1.3.6 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4018 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test the requirement. sl@0: Tamil character shaping MUST be based on combining character sequences. All shaping processes (splitting, reordering, glyph selection) MUST occur in the context of combining character sequence. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: testText[6] = 0x0BAA; // Pa sl@0: testText[7] = 0x0BCD; //Virama sl@0: testText[8] = 0x0B95; //Ka sl@0: testText[9] = 0x0BCD; //Virama sl@0: testText[10] = 0x0B9F; //Tta sl@0: testText[11] = 0x0BC7; //-e sl@0: sl@0: testText[12] = 0x0BAA;//Pa sl@0: testText[13] = 0x0BCD;//Virama sl@0: testText[14] = 0x0B95;//Ka sl@0: testText[15] = 0x0BCC;//AU sl@0: sl@0: testText[16] = 0x0B95; //Ka sl@0: testText[17] = 0x0BCD; //Virama sl@0: testText[18] = 0x0BB7; //Ssa sl@0: testText[19] = 0x0BCB; //OO sl@0: sl@0: param.iPosInText = 6 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 12 sl@0: && param.iOutputGlyphs == 4 sl@0: && param.iOutput[0].iCode == 0x80000c3a sl@0: && param.iOutput[1].iCode == 0x80000c30 sl@0: && param.iOutput[2].iCode == 0x80000c13 sl@0: && param.iOutput[3].iCode == 0x80000bfb); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 51); sl@0: #endif sl@0: sl@0: INFO_PRINTF7(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[3].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[3].iCode); sl@0: sl@0: param.iPosInText = 12 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 16 sl@0: && param.iOutputGlyphs ==4 sl@0: && param.iOutput[0].iCode == 0x80000c3a sl@0: && param.iOutput[1].iCode == 0x80000c12 sl@0: && param.iOutput[2].iCode == 0x80000bf6 sl@0: && param.iOutput[3].iCode == 0x80000c19); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 56); sl@0: #endif sl@0: sl@0: INFO_PRINTF7(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[3].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[3].iCode); sl@0: sl@0: param.iPosInText = 16 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 20 sl@0: && param.iOutputGlyphs == 3 sl@0: && param.iOutput[0].iCode == 0x80000c13 sl@0: && param.iOutput[1].iCode == 0x80000c2f sl@0: && param.iOutput[2].iCode == 0x80000c0d); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 54); sl@0: #endif sl@0: sl@0: INFO_PRINTF7(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[2].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[2].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4019")); sl@0: //Req 11 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4019 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test the requirement sl@0: Matras /-e/, /-ee/ and /-ai/ are reordered with the consonant they follow in memory order. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: sl@0: testText[20] = 0x0B95; //Ka sl@0: testText[21] = 0x0BC7; //-e sl@0: sl@0: param.iPosInText = 20 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 22 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000c13 sl@0: && param.iOutput[1].iCode == 0x80000bf6 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 26); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4020")); sl@0: //Req 12 1.3.5.2 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4020 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test the requirment sl@0: Matras /-o/, /-oo/ and /-au/ are split into two halves that enclose the consonant they follow in memory order. sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: sl@0: testText[22] = 0x0B95; //Ka sl@0: testText[23] = 0x0BCA; //O sl@0: sl@0: sl@0: param.iPosInText = 22 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 24 sl@0: && param.iOutputGlyphs == 3 sl@0: && param.iOutput[0].iCode == 0x80000c12 sl@0: && param.iOutput[1].iCode == 0x80000bf6 sl@0: && param.iOutput[2].iCode == 0x80000c0d); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 37); sl@0: #endif sl@0: sl@0: INFO_PRINTF7(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x iOutput[2].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode, param.iOutput[2].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4021")); sl@0: //Req 13 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4021 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test the requirment. sl@0: Tamil Modifier "Ayatham" MUST be treated as an independent character sl@0: @SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: sl@0: testText[24] = 0x0B95; //Ka sl@0: testText[25] = 0x0B83; //Aythem sl@0: testText[26] = 0x0B85; //A sl@0: sl@0: param.iPosInText = 24; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 25 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000bf6); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4022")); sl@0: //Req 14 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4022 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test the requirement. sl@0: Rendering Engine MUST be capable of handling TAMIL ANUSVARA sl@0: It has been suggested that this character be deprecated in Unicode sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: sl@0: testText[27] = 0x0B95; //Ka sl@0: testText[28] = 0x0B82; //Anusvara sl@0: testText[29] = 0x0B95; //Ka sl@0: sl@0: param.iPosInText = 27; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 29 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000bf6 sl@0: && param.iOutput[1].iCode == 0x80000be8); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 19); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: param.iPosInText = 29; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 30 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000bf6 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4023")); sl@0: //Req 15 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4023 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test the requirment sl@0: Tamil consonant /ra/ changes its shape, when a virama is applied to it. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: sl@0: testText[30] = 0x0BB0; //Ra sl@0: testText[31] = 0x0BCD; //Virama sl@0: testText[32] = 0x8205; //ZWJ sl@0: sl@0: sl@0: param.iPosInText = 30; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 32 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000c03 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 10); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4024")); sl@0: //Req 16 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4024 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test sl@0: Matra /-aa/ is combined to consonants in regular fashion. No extra shaping is required. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: sl@0: testText[33] = 0x0B95; //Ka sl@0: testText[34] = 0x0B82; //Anusvara sl@0: sl@0: param.iPosInText = 33 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 35 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000bf6 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 19); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4025")); sl@0: //Req 17 1.3.11 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4025 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test sl@0: Matras /-i/ and /-ii/ MUST form a ligature with consonant /tta/. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: sl@0: testText[35] = 0x0B9F; //Tta sl@0: testText[36] = 0x0BBF; //I sl@0: sl@0: testText[37] = 0x0B9F; //Tta sl@0: testText[38] = 0x0BC0; //Ii sl@0: sl@0: param.iPosInText = 35 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 37 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000c51); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 15); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: param.iPosInText = 37 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 39 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000c52); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4026")); sl@0: //Req 18 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4026 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test sl@0: Consonant /ra/ takes an alternate shape when combined with matras /-i/ and /-ii/. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: testText[39] = 0x0BB0; //Ra sl@0: testText[40] = 0x0BBF; //I sl@0: sl@0: testText[41] = 0x0BB0; //Ra sl@0: testText[42] = 0x0BC0; //Ii sl@0: sl@0: param.iPosInText = 39 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 41 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000c0d sl@0: && param.iOutput[1].iCode == 0x80000c0e ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 41 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 43 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000c0d sl@0: && param.iOutput[1].iCode == 0x80000c0f); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4027")); sl@0: //Req 19 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4027 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test the requirement sl@0: Matras /-i/ and /-ii/ take an alternate form when applied to consonants /nga/, /pa/, /ya/ and /va/. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: testText[43] = 0x0B99; //Nga sl@0: testText[44] = 0x0BBF; //I sl@0: sl@0: testText[45] = 0x0B99; //Nga sl@0: testText[46] = 0x0BC0; //Ii sl@0: sl@0: param.iPosInText = 43 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 45 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000bf7 sl@0: && param.iOutput[1].iCode == 0x80000c0e ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 19); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: param.iPosInText = 45 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 47 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000c4a ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 17); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4028")); sl@0: sl@0: //Req 20 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4028 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test the requirement. sl@0: Matras /-u/ and /-uu/ join in ligature form with all other consonants than /ha/, /ja/, /sa/, /ssa/ and /k.ssa/. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: testText[47] = 0x0B9C; //Ja sl@0: testText[48] = 0x0BC1; //U sl@0: sl@0: testText[49] = 0x0B9C; //Ja sl@0: testText[50] = 0x0BC2; //Uu sl@0: sl@0: param.iPosInText = 47 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 49 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000bf9 sl@0: && param.iOutput[1].iCode == 0x80000c10); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 26); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: sl@0: param.iPosInText = 49; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 51 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000bf9 sl@0: && param.iOutput[1].iCode == 0x80000c11 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 29); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4029")); sl@0: //Req 21 1.3.15 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4029 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test the requirement. sl@0: Matra /-ai/ is combined to consonants in regular fashion. No extra shaping is required. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: testText[51] = 0x0B95; //Ka sl@0: testText[52] = 0x0BC8; //Ai sl@0: sl@0: param.iPosInText = 51; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 53 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000c14 sl@0: && param.iOutput[1].iCode == 0x80000bf6); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 31); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4030")); sl@0: //Req 22 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4030 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test the requirement sl@0: Consonant cluster MUST always form conjunct consonant /k.ssa/, which behaves as if it were a proper consonant of its own sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: testText[53] = 0x0B95; //Ka sl@0: testText[54] = 0x0BCD; //Virama sl@0: testText[55] = 0x0BB7; //Ssa sl@0: sl@0: param.iPosInText = 53; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 56 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000c2f ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 31); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4031")); sl@0: //Req 23 1.3.17 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4031 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test sl@0: Character sequence MUST be rendered as a ligature form /s.rii/. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: testText[56] = 0x0BB8; //Sa sl@0: testText[57] = 0x0BCD; //Virama sl@0: testText[58] = 0x0BB0; //Ra sl@0: testText[59] = 0x0BC0; //Matra I sl@0: sl@0: param.iPosInText = 56; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 60 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000c79 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 27); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4032")); sl@0: //Req 24 1.3.18 sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4032 sl@0: @SYMTestCaseDesc Automated GDI testing for Tamil sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Tamil glyph clusters to test sl@0: Vertical position of the glyphs for combining characters virama, matras /-i/ and /-ii/ must be determined separately in relation to the relevant base glyph sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8742:Tamil Text Rendering sl@0: */ sl@0: testText[60] = 0x0B95; //Ka sl@0: testText[62] = 0x0BCD; //Virama sl@0: testText[63] = 0x8205; //ZWJ sl@0: sl@0: param.iPosInText = 60; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 61 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000bf6 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: } sl@0: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-3479 sl@0: @SYMTestCaseDesc Automated GDI testing for correct localised punctuation after indic characters sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Indic strings with western punctuation sl@0: @SYMTestExpectedResults The expected punctuation glyphs for the implied locale should be returned sl@0: @SYMDEF DEF106651 sl@0: */ sl@0: void CTGlyphSelection::TestGlyphs(CFont* aFont, CFont::TPositionParam& aParam, sl@0: const TPtrC16& aText, const TPtrC16& aExpectedGlyphs) sl@0: { sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-3479")); sl@0: TUint16* glyphs = CONST_CAST(TUint16*,aExpectedGlyphs.Ptr()); sl@0: const TInt mask = 0x80000000-1; sl@0: TBool r; sl@0: RShapeInfo shapeInfo; sl@0: aParam.iText.Set(aText); sl@0: aParam.iPosInText = aParam.iPen.iX = aParam.iPen.iY = 0; sl@0: while(aParam.iPosInText < aParam.iText.Length()) sl@0: { sl@0: r = aFont->GetCharacterPosition2(aParam,shapeInfo); sl@0: //INFO_PRINTF3(_L("Glyph %d Icode 0x%x"),*glyphs,aParam.iOutput[0].iCode); sl@0: TEST(r && ((aParam.iOutput[0].iCode & mask) == *glyphs++)); sl@0: } sl@0: shapeInfo.Close(); sl@0: TRAPD(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: } sl@0: void CTGlyphSelection::TestTeluguChars(CFbsFont* aFont) sl@0: { sl@0: INFO_PRINTF1(_L("Test Telugu Glyphs")); sl@0: sl@0: TBool r; sl@0: TBuf<162> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: testText.SetLength(162); sl@0: // Make sure there is no garbage values in the memory we are using. sl@0: for (TInt i = 0; i < testText.Length(); i++) sl@0: testText[i]=0xFFFF; sl@0: sl@0: param.iText.Set(testText); sl@0: RShapeInfo shapeInfo; sl@0: sl@0: //Testdata for Telugu Langauage sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4033")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4033 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: These consonants contain a small tick mark (crest) at the top of the glyph. This graphical detail can be considered to be a vocalic stem that indirectly indicates the inherent vowel /-a/. VIRAMA replaces the vocalic stem. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: // Req 4.1 sl@0: sl@0: testText[0] = 0x0C15; sl@0: testText[1] = 0x0C4D; sl@0: param.iPosInText = 0 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 2 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f49 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 9); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAPD(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4034")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4034 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?VIRAMA attaches the upward stroke at the right of the glyph. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[2] = 0x0C16; sl@0: testText[3] = 0x0C4D; sl@0: sl@0: param.iPosInText = 2 ; sl@0: sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: sl@0: TEST(r && param.iPosInText == 4 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f4a); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4035")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4035 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?VIRAMA is attached to a stroke at the upper right corner. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: sl@0: testText[4] = 0x0C23; sl@0: testText[5] = 0x0C4D; sl@0: sl@0: param.iPosInText = 4 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 6 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f57 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4036")); sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4036 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: Matras MATRA VOCALIC R and MATRA VOCALIC RR never attach the consonant glyph causing shape changes, but they are always placed at the right of the consonant glyph. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: //Req 4.2 sl@0: testText[6] = 0x0C2E; sl@0: testText[7] = 0x0C43; sl@0: sl@0: param.iPosInText = 6 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 8 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000f21 sl@0: && param.iOutput[1].iCode == 0x80000f31 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 24); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4037")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4037 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: Matras MATRA VOCALIC R and MATRA VOCALIC RR never attach the consonant glyph causing shape changes, but they are always placed at the right of the consonant glyph. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[8] = 0x0C32; sl@0: sl@0: testText[9] = 0x0C44; sl@0: sl@0: param.iPosInText = 8 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 10 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000f25 sl@0: && param.iOutput[1].iCode == 0x80000f32); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 22); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4038")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4038 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Matras MATRA VOCALIC R and MATRA VOCALIC RR never attach the consonant glyph causing shape changes, but they are always placed at the right of the consonant glyph. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: //Req 4.2.1 sl@0: testText[10] = 0x0C15; sl@0: testText[11] = 0x0C3E; sl@0: sl@0: param.iPosInText = 10 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 12 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f6d ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4039")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4039 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?MATRA AA attaches to the upwards left curving stroke sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[12] = 0x0C1F; sl@0: testText[13] = 0x0C3E; sl@0: param.iPosInText = 12 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 14 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f77 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 16); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4040")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4040 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?MATRA AA attaches the upwards (left curving) stroke at the top of the glyph sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[14] = 0x0C1C; sl@0: testText[15] = 0x0C3E; sl@0: sl@0: param.iPosInText = 14 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 16 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f74 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 15); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4041")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4041 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?MATRA AA is drawn on top of the glyph sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[16] = 0x0C23; sl@0: testText[17] = 0x0C3E; sl@0: sl@0: param.iPosInText = 16 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 18 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f7b ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 16); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4042")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4042 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?MATRA AA attaches to the upwards left curving stroke, the vowel stem remains intact sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[18] = 0x0C2B; sl@0: testText[19] = 0x0C3E; sl@0: sl@0: param.iPosInText = 18 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 20 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f82 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 16); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4043")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4043 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?MATRA AA replaces the vowel stem, the upwards left curving stroke is extended sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[20] = 0x0C2A; sl@0: testText[21] = 0x0C3E; sl@0: sl@0: param.iPosInText = 20 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 22 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f81); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 16); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4044")); sl@0: //Req 4.2.2 sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4044 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign replaces the vowel stem sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[22] = 0x0C26; sl@0: testText[23] = 0x0C3F; sl@0: sl@0: param.iPosInText = 22 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 24 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000fa2 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 11); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4045")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4045 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?The upwards left curving stroke extends, vowel sign attaches to the extended stroke sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[24] = 0x0C16; sl@0: testText[25] = 0x0C3F; sl@0: sl@0: param.iPosInText = 24 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 26 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f92); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4046")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4046 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign attaches the upward stroke at the top of the glyph sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[26] = 0x0C1C; sl@0: testText[27] = 0x0C3F; sl@0: sl@0: param.iPosInText = 26 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 28 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f98 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4047")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4047 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign attaches the upward stroke at the top of the glyph sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[28] = 0x0C1E; sl@0: testText[29] = 0x0C40; sl@0: sl@0: param.iPosInText = 28 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 30 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000fbe ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 14); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4048")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4048 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign attaches to the right upper corner of the glyph sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[30] = 0x0C1F; sl@0: testText[31] = 0x0C3F; sl@0: sl@0: param.iPosInText = 30; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 32 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f9b ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4049")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4049 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign takes a loop form that replaces the vowel stem sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[32] = 0x0C1D; sl@0: testText[33] = 0x0C3F; sl@0: sl@0: param.iPosInText = 32 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 34 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f99 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 19); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4050")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4050 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?The upwards left curving stroke extends, vowel sign replaces the vowel stem at the tip of the extended stroke sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[34] = 0x0C1B; sl@0: testText[35] = 0x0C3F; sl@0: sl@0: param.iPosInText =34 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 36 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f97 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4051")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4051 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign replaces the upwards curving stroke at the top of the glyph sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[36] = 0x0C1C; sl@0: testText[37] = 0x0C3F; sl@0: sl@0: param.iPosInText = 36 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 38 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000f98 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4052")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4052 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel stem is removed. sl@0: ?Vowel stem is removed and MATRA II takes a form that looks like MATRA AA sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[38] = 0x0C2F; sl@0: testText[39] = 0x0C3F; sl@0: sl@0: param.iPosInText = 38 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 40 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000faa ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 19); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4053")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4053 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign attaches to the right of the consonant glyph, vowel stem remains intact sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[40] = 0x0C15; sl@0: testText[41] = 0x0C41; sl@0: sl@0: param.iPosInText = 40 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText ==42 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000fd9 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 14); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4054")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4054 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign takes a miniature form which attaches to the stroke at the top of the consonant glyph sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[42] = 0x0C19; sl@0: testText[43] = 0x0C41; sl@0: sl@0: param.iPosInText = 42 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 44 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80000fda ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 15); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4055")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4055 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign attaches the consonant sign from below. Vowel stem remains intact. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[44] = 0x0C2E; sl@0: testText[45] = 0x0C41; sl@0: sl@0: param.iPosInText = 44 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 46 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000f21 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 21); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: sl@0: testText[46] = 0x0C36; sl@0: testText[47] = 0x0C41; sl@0: sl@0: param.iPosInText = 46 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 48 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000f28 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 14); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4056")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4056 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign replaces the vowel stem sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: // Req 4.2.4 sl@0: testText[48] = 0x0C28; sl@0: testText[49] = 0x0C46; sl@0: sl@0: param.iPosInText = 48 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 50 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80001000 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 11); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4057")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4057 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign replaces the vowel stem sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[50] = 0x0C1B; sl@0: testText[51] = 0x0C47; sl@0: sl@0: param.iPosInText = 50 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 52 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80001017 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 12); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4058")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4058 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign replaces the vowel stem sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[52] = 0x0C1D; sl@0: testText[53] = 0x0C48; sl@0: sl@0: param.iPosInText = 52 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 54 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x80000ff5 sl@0: && param.iOutput[1].iCode == 0x80000f3b ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 19); sl@0: #endif sl@0: sl@0: INFO_PRINTF6(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x iOutput[1].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode, param.iOutput[1].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4059")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4059 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign replaces the vowel stem. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: // Req 4.2.5 sl@0: testText[54] = 0x0C15; sl@0: testText[55] = 0x0C4A; sl@0: sl@0: param.iPosInText = 54 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 56 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80001059 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 13); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4060")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4060 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign replaces the vowel stem. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: sl@0: testText[56] = 0x0C21; sl@0: testText[57] = 0x0C4B; sl@0: sl@0: param.iPosInText = 56 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 58 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x80001089 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 14); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-4061")); sl@0: /* sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-4061 sl@0: @SYMTestCaseDesc Automated GDI testing for Telugu sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid Telugu glyph clusters to test sl@0: ?Vowel sign replaces the vowel stem. sl@0: @@SYMTestExpectedResults The expected glyph clusters for given Unicode characters must be returned sl@0: @SYMPREQ 1766: Tamil for Sphinx sl@0: @SYMREQ 8743:Tamil Text Rendering sl@0: */ sl@0: testText[58] = 0x0C26; sl@0: testText[59] = 0x0C4C; sl@0: sl@0: param.iPosInText = 58 ; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont->GetCharacterPosition2(param,shapeInfo); sl@0: sl@0: TEST(r && param.iPosInText == 60 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x800010b2 ); sl@0: sl@0: #if defined __WINS__ || defined __WINSCW__ sl@0: TEST(r && param.iPen.iX == 14); sl@0: #endif sl@0: sl@0: INFO_PRINTF5(_L("The values are iPosInText=%d iPen.iX=%d iOutputGlyphs=%d iOutput[0].iCode=0x%x"), param.iPosInText, param.iPen.iX, param.iOutputGlyphs, param.iOutput[0].iCode); sl@0: } sl@0: sl@0: void CTGlyphSelection::TestIndicPunctuation(CFbsFont* aFont) sl@0: { sl@0: INFO_PRINTF1(_L("Test Indic Punctuation")); sl@0: sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: //INFO_PRINTF1(_L("// punctuation string after Kannada text")); sl@0: TestGlyphs(aFont,param,_L("\xC95!?#@"),_L("\x7A8\x920\x93C\x922\x23")); sl@0: //INFO_PRINTF1(_L("// punctuation string before Kannada text")); sl@0: TestGlyphs(aFont,param,_L("!?#@\xC95"),_L("\x21\x3F\x23\x40\x7A8")); sl@0: //INFO_PRINTF1(_L("// punctuation string before and after Kannada text")); sl@0: TestGlyphs(aFont,param,_L(" \"\xC95\" "),_L("\x20\x20\x22\x7A8\x22\x20\x20")); sl@0: //INFO_PRINTF1(_L("// punctuation before and after latin text followed by punctuation before and after kannada text")); sl@0: TestGlyphs(aFont,param,_L("\x201c\x041\x201D (\xc95)"),_L("\x201c\x41\x201d\x20\x28\x7a8\x29")); sl@0: //INFO_PRINTF1(_L("// mixed kannada/ latin with punctuation surrounded by whitespace inbetween")); sl@0: TestGlyphs(aFont,param,_L("\xc95 , \x041"),_L("\x7a8\x20\x929\x20\x41")); sl@0: //INFO_PRINTF1(_L("// mixed kannada/ latin with punctuation surrounded by whitespace inbetween (reversed)")); sl@0: TestGlyphs(aFont,param,_L("\x041 , \xc95"),_L("\x41\x20\x2C\x20\x7a8")); sl@0: //INFO_PRINTF1(_L("// mixed kannada/ latin with punctuation next to latin")); sl@0: TestGlyphs(aFont,param,_L("\x041, \xc95"),_L("\x41\x2C\x20\x7a8")); sl@0: //INFO_PRINTF1(_L("// mixed kannada/ latin with punctuation next to kannada")); sl@0: TestGlyphs(aFont,param,_L("\x041 ,\xc95"),_L("\x41\x20\x2C\x7a8")); sl@0: //INFO_PRINTF1(_L("// mixed kannada/ latin with punctuation next to latin and seperating tab")); sl@0: TestGlyphs(aFont,param,_L("\x041,\t\xc95"),_L("\x41\x2C\x9\x7a8")); sl@0: //INFO_PRINTF1(_L("// mixed kannada/ latin with punctuation next to kannada and seperating tab")); sl@0: TestGlyphs(aFont,param,_L("\x041\t,\xc95"),_L("\x41\x9\x2C\x7a8")); sl@0: //INFO_PRINTF1(_L("// devanagari digits with colons")); sl@0: TestGlyphs(aFont,param,_L("\x966\x03a\x967\x03a\x968\x03a\x969\x03a\x96a\x03a\x96b\x03a\x96c\x03a\x96d\x03a\x96e\x03a\x96f\x03a"), sl@0: _L("\x582\x77e\x583\x77e\x584\x77e\x585\x77e\x586\x77e\x587\x77e\x588\x77e\x589\x77e\x58a\x77e\x58b\x77e")); sl@0: //INFO_PRINTF1(_L("// string of only punctuation")); sl@0: TestGlyphs(aFont,param,_L("\x002D\x002D\x002D\x002D\x002D\x002D"),_L("\x002D\x002D\x002D\x002D\x002D\x002D")); sl@0: //INFO_PRINTF1(_L("// one Kannada character followed my multiple punctuation and non-punctuaion")); sl@0: TestGlyphs(aFont,param,_L("\x0C95!\x0022\x00A3$%^&*()-={}[]:@~;'#<>?,./"), sl@0: _L("\x07A8\x0920\x0022\x00A3\x0024\x0923\x005E\x0009\x0927\x0028\x0029\x092A\x003D\x007B\x007D\x005B\x005D\x0937\x0023\x007E\x0938\x0027\x0922\x003C\x003E\x093C\x0929\x092B\x092C")); sl@0: } sl@0: sl@0: sl@0: sl@0: void CTGlyphSelection::TestIndicCharsL() sl@0: { sl@0: // create a font store for testing sl@0: CFontStore* fontStore = CFontStore::NewL(&User::Heap()); sl@0: sl@0: //load all ecom implemented rasterizer dlls. installs the rasterizer. sl@0: LoadOpenFontLibraries(fontStore); sl@0: // test font preparation sl@0: fontStore->iKPixelWidthInTwips = 11860; //This value is default sl@0: sl@0: //add any required font files sl@0: TUid err = fontStore->AddFileL(KTestHindiFontFile); sl@0: sl@0: TFontSpec testHindiFontSpec(KTestHindiFontFaceName,200); sl@0: sl@0: TUid err1 = fontStore->AddFileL(KTestIndicFontFile); sl@0: sl@0: TFontSpec testIndicFontSpec(KTestIndicFontFaceName,200); sl@0: sl@0: CFbsBitmap* bmp = new(ELeave) CFbsBitmap; sl@0: sl@0: TInt ret = bmp->Create(TSize(100,100),EGray2); sl@0: if (ret == KErrNotSupported) sl@0: return; sl@0: else sl@0: User::LeaveIfError(ret); sl@0: sl@0: CFbsBitmapDevice* device = NULL; sl@0: TRAPD(err2,device = CFbsBitmapDevice::NewL(bmp)); sl@0: TEST(err2 == KErrNone); sl@0: sl@0: CFbsBitGc* gc = NULL; sl@0: User::LeaveIfError(device->CreateContext(gc)); sl@0: // Font file Creation sl@0: CFbsFont* hindiFont = NULL; sl@0: User::LeaveIfError(device->GetNearestFontToDesignHeightInTwips(hindiFont,testHindiFontSpec)); sl@0: gc->UseFont(hindiFont); sl@0: CleanupStack::PushL(hindiFont); sl@0: sl@0: //Testcode for Hindi language sl@0: ((CTGlyphSelectionStep*)iStep)->RecordTestResultL(); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-1580")); sl@0: TestHindiChars(hindiFont); sl@0: ((CTGlyphSelectionStep*)iStep)->RecordTestResultL(); sl@0: sl@0: CleanupStack::Pop(hindiFont); sl@0: sl@0: // Font file Creation sl@0: CFbsFont* indicFont = NULL; sl@0: User::LeaveIfError(device->GetNearestFontToDesignHeightInTwips(indicFont,testIndicFontSpec)); sl@0: gc->UseFont(indicFont); sl@0: CleanupStack::PushL(indicFont); sl@0: sl@0: //Testcode for Kannada, Marathi,Gujarati,Bengali language sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-3381")); sl@0: TestKannadaChars(indicFont); sl@0: ((CTGlyphSelectionStep*)iStep)->RecordTestResultL(); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-3360")); sl@0: TestMarathiChars(indicFont); sl@0: ((CTGlyphSelectionStep*)iStep)->RecordTestResultL(); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-3417")); sl@0: TestGujaratiChars(indicFont); sl@0: TestBengaliChars(indicFont); sl@0: TestTamilChars(indicFont); sl@0: TestTeluguChars(indicFont); sl@0: TestIndicPunctuation(indicFont); sl@0: CleanupStack::Pop(indicFont); sl@0: sl@0: //Cleaning the memory sl@0: delete bmp; sl@0: delete device; sl@0: delete gc; sl@0: fontStore->RemoveFile(err); sl@0: fontStore->RemoveFile(err1); sl@0: delete fontStore; sl@0: REComSession::FinalClose(); sl@0: } sl@0: sl@0: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CT-0221 sl@0: @SYMTestCaseDesc Test support for Vietnamese characters. sl@0: @SYMTestPriority High sl@0: @SYMTestActions Attempt to compose various valid and invalid Vietnamese glyph clusters. sl@0: @SYMTestExpectedResults The test must not fail. sl@0: @SYMPREQ 402: GDI for Bravo. sl@0: */ sl@0: void CTGlyphSelection::TestVietnameseChars() sl@0: { sl@0: /** sl@0: This method is a test case to test GetCharacterPosition() correctly sl@0: processes Vietnamese characters. sl@0: */ sl@0: TBool r; sl@0: TBuf<41> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: testText.SetLength(41); sl@0: sl@0: testText[0] = 0x0055; // capital U sl@0: testText[1] = 0x031B; // combining horn - expect 0x01AF (succeed) sl@0: sl@0: testText[2] = 0x0055; // capital U sl@0: testText[3] = 0x0027; // apostrophe - expect 0x0055 (fail) sl@0: sl@0: testText[4] = 0x0055; // capital U sl@0: testText[5] = 0x02B9; // modifier prime - expect 0x0055 (fail) sl@0: sl@0: testText[6] = 0x0055; // capital U sl@0: testText[7] = 0x02BC; // modifier apostrophe - expect 0x0055 (fail) sl@0: sl@0: testText[8] = 0x0055; // capital U sl@0: testText[9] = 0x0315; // combining comma above right - expect 0x0055, 0x0315 (fail) sl@0: sl@0: testText[10] = 0x0055; // capital U sl@0: testText[11] = 0x2019; // right single quote mark - expect 0x0055 (fail) sl@0: sl@0: testText[12] = 0x01AF; // capital U with horn sl@0: testText[13] = 0x0020; // space - expect 0x01AF (succeed) sl@0: sl@0: testText[14] = 0x0045; // capital E sl@0: testText[15] = 0x031B; // combining horn - expect 0x0045, 0x031B (fail) sl@0: sl@0: testText[16] = 0x0041; // capital A sl@0: testText[17] = 0x0306; // combining breve sl@0: testText[18] = 0x0301; // combining acute - expect 0x1EAE (succeed) sl@0: sl@0: testText[19] = 0x0102; // capital A with breve sl@0: testText[20] = 0x0301; // combining acute - expect 0x1EAE (succeed) sl@0: sl@0: testText[21] = 0x0041; // capital A sl@0: testText[22] = 0x0301; // combining acute sl@0: testText[23] = 0x0306; // combining breve - expect 0x0041, 0x0301, 0x0306 (fail) sl@0: sl@0: testText[24] = 0x0041; // capital A sl@0: testText[25] = 0x0323; // combining dot below sl@0: testText[26] = 0x0306; // combining breve - expect 0x1EB6 (succeed) sl@0: sl@0: testText[27] = 0x1EA0; // capital A with dot below sl@0: testText[28] = 0x0306; // combining breve - expect 0x1EB6 (succeed) sl@0: sl@0: testText[29] = 0x0102; // capital A with breve sl@0: testText[30] = 0x0323; // combining dot below - expect 0x0102, 0x0323 (fail) sl@0: sl@0: testText[31] = 0x0045; // capital A sl@0: testText[32] = 0x0302; // combining circumflex sl@0: testText[33] = 0x0301; // combining acute - expect 0x1EBE (succeed) sl@0: sl@0: testText[34] = 0x00CA; // capital A with circumflex sl@0: testText[35] = 0x0301; // combining acute - expect 0x1EBE (succeed) sl@0: sl@0: testText[36] = 0x004F; // capital O sl@0: testText[37] = 0x031B; // combining horn sl@0: testText[38] = 0x0309; // combining hook above - expect 0x1EDE (succeed) sl@0: sl@0: testText[39] = 0x01A0; // capital O with horn sl@0: testText[40] = 0x0309; // combining hook above - expect 0x1EDE (succeed) sl@0: sl@0: param.iText.Set(testText); sl@0: sl@0: // 1: Capital U with combining horn sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 2 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x01AF); sl@0: sl@0: // 2: Capital U with apostrophe sl@0: param.iPosInText = 2; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 3 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x0055); sl@0: sl@0: // 3: Capital U with modifier prime sl@0: param.iPosInText = 4; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 5 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x0055); sl@0: sl@0: // 4: Capital U with modifier apostrophe sl@0: param.iPosInText = 6; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 7 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x0055); sl@0: sl@0: // 5: Capital U with combining comma above right sl@0: param.iPosInText = 8; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 10 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x0055 sl@0: && param.iOutput[1].iCode == 0x0315); sl@0: sl@0: // 6: Capital U with right single quote sl@0: param.iPosInText = 10; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 11 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x0055); sl@0: sl@0: // 7: Capital U with horn plus space sl@0: param.iPosInText = 12; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 13 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x01AF); sl@0: sl@0: // 8: Capital E with combining horn sl@0: param.iPosInText = 14; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 16 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x0045 sl@0: && param.iOutput[1].iCode == 0x031B); sl@0: sl@0: // 9: Capital A with combining breve with combining acute sl@0: param.iPosInText = 16; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 19 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x1EAE); sl@0: sl@0: // 10: Capital A with breve with combining acute sl@0: param.iPosInText = 19; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 21 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x1EAE); sl@0: sl@0: // 11: Capital A with combining acute with combining breve sl@0: param.iPosInText = 21; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 24 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 3 sl@0: && param.iOutput[0].iCode == 0x0041 sl@0: && param.iOutput[1].iCode == 0x0301 sl@0: && param.iOutput[2].iCode == 0x0306); sl@0: sl@0: // 12: Capital A with combining dot below with combining breve sl@0: param.iPosInText = 24; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 27 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x1EB6); sl@0: sl@0: // 13: Capital A with dot below with combining breve sl@0: param.iPosInText = 27; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 29 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x1EB6); sl@0: sl@0: // 14: Capital A with breve with combining dot below sl@0: param.iPosInText = 29; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 31 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 2 sl@0: && param.iOutput[0].iCode == 0x0102 sl@0: && param.iOutput[1].iCode == 0x0323); sl@0: sl@0: // 15: Capital A with combining circumflex with combining acute sl@0: param.iPosInText = 31; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 34 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x1EBE); sl@0: sl@0: // 16: Capital A with circumflex with combining acute sl@0: param.iPosInText = 34; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 36 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x1EBE); sl@0: sl@0: // 17: Capital O with combining horn with combing hook above sl@0: param.iPosInText = 36; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 39 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x1EDE); sl@0: sl@0: // 18: Capital O with horn with combing hook above sl@0: param.iPosInText = 39; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 41 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 0x1EDE); sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestNonBmpCharsL() sl@0: { sl@0: // create a font store for testing sl@0: CFontStore* fontStore = CFontStore::NewL(&User::Heap()); sl@0: sl@0: //load all ecom implemented rasterizer dlls. installs the rasterizer. sl@0: LoadOpenFontLibraries(fontStore); sl@0: // test font preparation sl@0: fontStore->iKPixelWidthInTwips = 11860; //This value is default sl@0: sl@0: //add any required font files sl@0: TUid err = fontStore->AddFileL(KTestGB18030FontFile); sl@0: sl@0: TFontSpec testGB18030FontSpec(KTestGB18030FontFaceName,200); sl@0: sl@0: CFbsBitmap* bmp = new(ELeave) CFbsBitmap; sl@0: sl@0: TInt ret = bmp->Create(TSize(100,100),EGray2); sl@0: if (ret == KErrNotSupported) sl@0: return; sl@0: else sl@0: User::LeaveIfError(ret); sl@0: sl@0: CFbsBitmapDevice* device = NULL; sl@0: TRAPD(err2,device = CFbsBitmapDevice::NewL(bmp)); sl@0: TEST(err2 == KErrNone); sl@0: sl@0: CFbsBitGc* gc = NULL; sl@0: User::LeaveIfError(device->CreateContext(gc)); sl@0: // Font file Creation sl@0: CFbsFont* gb18030Font = NULL; sl@0: User::LeaveIfError(device->GetNearestFontToDesignHeightInTwips(gb18030Font,testGB18030FontSpec)); sl@0: gc->UseFont(gb18030Font); sl@0: CleanupStack::PushL(gb18030Font); sl@0: sl@0: //Testcode for GB18030 sl@0: ((CTGlyphSelectionStep*)iStep)->RecordTestResultL(); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("TI18N-GDI-CIT-4077")); sl@0: TestNonBmpCharsInGB18030(gb18030Font); sl@0: ((CTGlyphSelectionStep*)iStep)->RecordTestResultL(); sl@0: sl@0: CleanupStack::Pop(gb18030Font); sl@0: sl@0: //Cleaning the memory sl@0: delete bmp; sl@0: delete device; sl@0: delete gc; sl@0: fontStore->RemoveFile(err); sl@0: delete fontStore; sl@0: REComSession::FinalClose(); sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestTextDirection() sl@0: /** sl@0: This method is a test case to test GetCharacterPosition() correctly sl@0: produces glyph bounding boxes and utilizes various pen offsets in sl@0: a horizontal and vertical context. sl@0: */ sl@0: { sl@0: TBool r; sl@0: TBuf<20> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: testText.SetLength(5); sl@0: testText[0] = 'a'; sl@0: testText[1] = 'B'; sl@0: testText[2] = 'c'; sl@0: testText[3] = ' '; sl@0: testText[4] = '1'; sl@0: param.iText.Set(testText); sl@0: sl@0: // 1: Test horizontal text pen advancement & bounds sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 1 sl@0: && param.iPen == TPoint(10,0) sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 'a' sl@0: && param.iOutput[0].iBounds.iTl == TPoint(0,-10) sl@0: && param.iOutput[0].iBounds.iBr == TPoint(10,2)); sl@0: // add check for bounds sl@0: sl@0: // 2: Test horizontal text pen advancement with +ve pen offset sl@0: param.iPosInText = 4; sl@0: param.iPen.iX = 20; sl@0: param.iPen.iY = 12; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 5 sl@0: && param.iPen == TPoint(30,12) sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == '1' sl@0: && param.iOutput[0].iBounds.iTl == TPoint(20,2) sl@0: && param.iOutput[0].iBounds.iBr == TPoint(30,14)); sl@0: sl@0: // 3: Test horizontal text pen advancement with -ve pen offset sl@0: param.iPosInText = 4; sl@0: param.iPen.iX = -10; sl@0: param.iPen.iY = -24; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 5 sl@0: && param.iPen == TPoint(0,-24) sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == '1' sl@0: && param.iOutput[0].iBounds.iTl == TPoint(-10,-34) sl@0: && param.iOutput[0].iBounds.iBr == TPoint(0,-22)); sl@0: sl@0: // 4: Test vertical text pen advancement & bounds sl@0: param.iDirection = CFont::EVertical; sl@0: param.iPosInText = 1; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 2 sl@0: && param.iPen == TPoint(0,12) sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == 'B' sl@0: && param.iOutput[0].iBounds.iTl == TPoint(0,0) sl@0: && param.iOutput[0].iBounds.iBr == TPoint(10,12)); sl@0: sl@0: // 5: Test vertical text pen advancement with +ve pen offset sl@0: param.iPosInText = 4; sl@0: param.iPen.iX = 20; sl@0: param.iPen.iY = 12; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 5 sl@0: && param.iPen == TPoint(20,24) sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == '1' sl@0: && param.iOutput[0].iBounds.iTl == TPoint(20,12) sl@0: && param.iOutput[0].iBounds.iBr == TPoint(30,24)); sl@0: sl@0: // 6: Test vertical text pen advancement with -ve pen offset sl@0: param.iPosInText = 4; sl@0: param.iPen.iX = -10; sl@0: param.iPen.iY = -24; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r && param.iPosInText == 5 sl@0: && param.iPen == TPoint(-10,-12) sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == '1' sl@0: && param.iOutput[0].iBounds.iTl == TPoint(-10,-24) sl@0: && param.iOutput[0].iBounds.iBr == TPoint(0,-12)); sl@0: } sl@0: sl@0: void CTGlyphSelection::TestAllUnicodeChars() sl@0: /** sl@0: This method is a test case to test GetCharacterPosition() correctly sl@0: processes all the characters in the Unicode code space 0x0000 to sl@0: 0xffff. sl@0: */ sl@0: { sl@0: TBool r; sl@0: TBuf<8> testText(0); sl@0: CFont::TPositionParam param; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: TInt errors = 0; sl@0: testText.SetLength(1); sl@0: for (TUint i = 0xd802; i <= 0xffff; i++) sl@0: { sl@0: testText[0] = (TText16) i; sl@0: if (i==0x1b) continue; // Skip as CTestFont designed to fail here r==0. sl@0: param.iText.Set(testText); sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: if (!r || param.iPosInText != 1) sl@0: { sl@0: errors++; sl@0: //RDebug::Print(_L("%04x(%d,%d,%d), "), i, r, param.iPosInText, param.iOutputGlyphs ); sl@0: //if (errors%8 == 0) sl@0: // RDebug::Print(_L("\n")); sl@0: } sl@0: } sl@0: sl@0: TEST (errors == 0); sl@0: } sl@0: sl@0: /** Tests that ligatures (presently just Lam-Alef in Arabic) work correctly sl@0: when diacritics are required on one, both or neither character comprising the sl@0: ligature. */ sl@0: void CTGlyphSelection::TestLigaturesWithDiacritics() sl@0: { sl@0: // independent letters sl@0: const TText KAlef = 0x627; sl@0: const TText KLam = 0x644; sl@0: const TText KBeh = 0x628; sl@0: // dependent marks sl@0: const TText KFatha = 0x64E; sl@0: const TText KDamma = 0x64F; sl@0: // ligature forms sl@0: const TText KLamAlefIsolated = 0xFEFB; sl@0: const TText KLamAlefFinal = 0xFEFC; sl@0: sl@0: struct TTestCase sl@0: { sl@0: // Logical order input. sl@0: TText iInputL[8]; sl@0: // Visual order input, should be equivalent to iInputL. sl@0: TText iInputV[8]; sl@0: // Which cluster to test sl@0: TInt iClusterUnderTestStartL; sl@0: TInt iClusterUnderTestStartV; sl@0: // Expected glyphs to appear (in any order, but...) sl@0: TInt iGlyphs[8]; sl@0: // ...number of glyphs from the start of iGlyphs that sl@0: // are in order of their expected x-coordinates (of their sl@0: // centres) sl@0: TInt iGlyphsInOrder; sl@0: }; sl@0: const TTestCase KTestCases[] = sl@0: { sl@0: {{KLam, KAlef, 0}, {KAlef, KLam, 0}, sl@0: 0, 0, {KLamAlefIsolated, 0}, 1}, sl@0: {{KBeh, KLam, KAlef, KBeh, 0}, {KBeh, KAlef, KLam, KBeh, 0}, sl@0: 1, 1, {KLamAlefFinal, 0}, 1}, sl@0: {{KLam, KFatha, KAlef, 0}, {KAlef, KLam, KFatha, 0}, sl@0: 0, 0, {KLamAlefIsolated, KFatha, 0}, 1}, sl@0: {{KBeh, KLam, KFatha, KAlef, KBeh, 0}, {KBeh, KAlef, KLam, KFatha, KBeh, 0}, sl@0: 1, 1, {KLamAlefFinal, KFatha, 0}, 1}, sl@0: {{KLam, KAlef, KDamma, 0}, {KAlef, KDamma, KLam, 0}, sl@0: 0, 0, {KLamAlefIsolated, KDamma, 0}, 1}, sl@0: {{KBeh, KLam, KAlef, KDamma, KBeh, 0}, {KBeh, KAlef, KDamma, KLam, KBeh, 0}, sl@0: 1, 1, {KLamAlefFinal, KDamma, 0}, 1}, sl@0: {{KLam, KFatha, KAlef, KDamma, 0}, {KAlef, KDamma, KLam, KFatha, 0}, sl@0: 0, 0, {KDamma, KFatha, KLamAlefIsolated, 0}, 2}, sl@0: {{KBeh, KLam, KFatha, KAlef, KDamma, KBeh, 0}, sl@0: {KBeh, KAlef, KDamma, KLam, KFatha, KBeh, 0}, sl@0: 1, 1, {KDamma, KFatha, KLamAlefFinal, 0}, 2}, sl@0: }; sl@0: TBuf<8> input; sl@0: CFont::TPositionParam param; sl@0: for (TInt testCase = 0; sl@0: testCase != sizeof(KTestCases)/sizeof(KTestCases[0]); sl@0: ++testCase) sl@0: { sl@0: const TTestCase& t = KTestCases[testCase]; sl@0: for (TInt logical = 0; logical != 2; ++logical) sl@0: { sl@0: const TText* in = logical? sl@0: t.iInputL : t.iInputV; sl@0: input.Zero(); sl@0: while (*in) sl@0: input.Append(*in++); sl@0: param.iText.Set(input); sl@0: param.iPosInText = logical? sl@0: t.iClusterUnderTestStartL : t.iClusterUnderTestStartV; sl@0: param.iFlags = static_cast(logical? sl@0: CFont::TPositionParam::EFLogicalOrder : 0); sl@0: param.iPen.SetXY(0, 0); sl@0: TBool r = iTestFont->GetCharacterPosition(param); sl@0: TEST(r); sl@0: TInt currentX = KMinTInt; sl@0: TInt expectedGlyphNo = 0; sl@0: while (t.iGlyphs[expectedGlyphNo] != 0) sl@0: { sl@0: // FInd the expected glyph in the output. sl@0: TInt outputGlyph = 0; sl@0: while (outputGlyph != param.iOutputGlyphs sl@0: && static_cast(param.iOutput[outputGlyph].iCode) sl@0: != t.iGlyphs[expectedGlyphNo]) sl@0: { sl@0: ++outputGlyph; sl@0: } sl@0: TEST(outputGlyph < param.iOutputGlyphs); sl@0: TInt x = param.iOutput[outputGlyph].iBounds.Center().iX; sl@0: TEST(t.iGlyphsInOrder <= expectedGlyphNo sl@0: || currentX < x); sl@0: currentX = x; sl@0: ++expectedGlyphNo; sl@0: } sl@0: TEST(expectedGlyphNo == param.iOutputGlyphs); sl@0: } sl@0: } sl@0: } sl@0: sl@0: #if defined(__GCC32__) sl@0: typedef wchar_t __TText; sl@0: #elif defined(__VC32__) sl@0: typedef TUint16 __TText; sl@0: #elif defined(__CW32__) sl@0: typedef TUint16 __TText; sl@0: #elif !defined(__TText_defined) sl@0: #error no typedef for __TText sl@0: #endif sl@0: const __TText* KLatinNoSideBearings = L"ABCDE"; sl@0: const __TText* KLatinLeftSideBearing = L"WABCD"; sl@0: const __TText* KLatinRightSideBearing = L"ABCDW"; sl@0: const __TText* KLatinBothSideBearings = L"WABCW"; sl@0: const __TText* KArabicAlefWaw = L"\x627\x648"; sl@0: const __TText* KArabicWawAlef = L"\x648\x627"; sl@0: const __TText* KGb18030NoSideBearings = L"\xD840\xDC00xyz\xD87E\xDE1D"; sl@0: const __TText* KGb18030LeftSideBearings = L"W\xD840\xDC00xy\xD87E\xDE1D"; sl@0: const __TText* KGb18030RightSideBearings = L"\xD840\xDC00xy\xD87E\xDE1DW"; sl@0: const __TText* KGb18030BothSideBearings = L"W\xD840\xDC00x\xD87E\xDE1DW"; sl@0: struct TMeasureTextTest sl@0: { sl@0: const __TText* iText; sl@0: TInt iExpectedAdvanceLogical; sl@0: TInt iExpectedAdvanceL2R; sl@0: TInt iExpectedBoundsL2RLeft; sl@0: TInt iExpectedBoundsL2RRight; sl@0: TInt iExpectedBoundsL2RTop; sl@0: TInt iExpectedBoundsL2RBottom; sl@0: TInt iExpectedAdvanceR2L; sl@0: TInt iExpectedBoundsR2LLeft; sl@0: TInt iExpectedBoundsR2LRight; sl@0: TInt iExpectedBoundsR2LTop; sl@0: TInt iExpectedBoundsR2LBottom; sl@0: }; sl@0: const TMeasureTextTest KMeasureTextResults[] = sl@0: { sl@0: {KLatinNoSideBearings, 50, 50, 0, 50, -10, 2, 50, 0, 50, -10, 2}, sl@0: {KLatinLeftSideBearing, 50, 50, -1, 50, -10, 2, 50, 0, 51, -10, 2}, sl@0: {KLatinRightSideBearing, 50, 50, 0, 51, -10, 2, 50, -1, 50, -10, 2}, sl@0: {KLatinBothSideBearings, 50, 50, -1, 51, -10, 2, 50, -1, 51, -10, 2}, sl@0: {KArabicAlefWaw, 20, 20, 0, 20, -10, 2, 20, -5, 20, -10, 2}, sl@0: {KArabicWawAlef, 20, 20, -5, 20, -10, 2, 20, 0, 20, -10, 2}, sl@0: // ones containing surrogate pairs sl@0: {KGb18030NoSideBearings, 50, 50, 0, 50, -10, 2, 50, 0, 50, -10, 2}, sl@0: {KGb18030LeftSideBearings, 50, 50, -1, 50, -10, 2, 50, 0, 51, -10, 2}, sl@0: {KGb18030RightSideBearings, 50, 50, 0, 51, -10, 2, 50, -1, 50, -10, 2}, sl@0: {KGb18030BothSideBearings, 50, 50, -1, 51, -10, 2, 50, -1, 51, -10, 2}, sl@0: }; sl@0: /** Tests CFont::MeasureText */ sl@0: void CTGlyphSelection::TestMeasureText() sl@0: { sl@0: CFont::TMeasureTextInput input; sl@0: CFont::TMeasureTextOutput output; sl@0: TInt advance; sl@0: for (TInt i = 0; sl@0: i != sizeof(KMeasureTextResults)/sizeof(KMeasureTextResults[0]); ++i) sl@0: { sl@0: TPtrC text(reinterpret_cast( sl@0: KMeasureTextResults[i].iText)); sl@0: advance = iTestFont->MeasureText(text, &input, &output); sl@0: TEST(advance == KMeasureTextResults[i].iExpectedAdvanceLogical); sl@0: input.iFlags = CFont::TMeasureTextInput::EFVisualOrder; sl@0: advance = iTestFont->MeasureText(text, &input, &output); sl@0: TEST(advance == KMeasureTextResults[i].iExpectedAdvanceL2R); sl@0: TEST(output.iBounds.iTl.iX == KMeasureTextResults[i].iExpectedBoundsL2RLeft); sl@0: TEST(output.iBounds.iBr.iX == KMeasureTextResults[i].iExpectedBoundsL2RRight); sl@0: TEST(output.iBounds.iTl.iY == KMeasureTextResults[i].iExpectedBoundsL2RTop); sl@0: TEST(output.iBounds.iBr.iY == KMeasureTextResults[i].iExpectedBoundsL2RBottom); sl@0: input.iFlags = CFont::TMeasureTextInput::EFVisualOrderRightToLeft; sl@0: advance = iTestFont->MeasureText(text, &input, &output); sl@0: TEST(advance == KMeasureTextResults[i].iExpectedAdvanceR2L); sl@0: TEST(output.iBounds.iTl.iX == KMeasureTextResults[i].iExpectedBoundsR2LLeft); sl@0: TEST(output.iBounds.iBr.iX == KMeasureTextResults[i].iExpectedBoundsR2LRight); sl@0: TEST(output.iBounds.iTl.iY == KMeasureTextResults[i].iExpectedBoundsR2LTop); sl@0: TEST(output.iBounds.iBr.iY == KMeasureTextResults[i].iExpectedBoundsR2LBottom); sl@0: } sl@0: sl@0: INFO_PRINTF1(_L("Test fix for INC086257 - EFIncludePenPositionInBoundsCheck")); sl@0: // left-to-right w/o flag and bounds set to just fit string disregarding sidebearings sl@0: input.iFlags = 0; sl@0: input.iMaxBounds = 50; sl@0: iTestFont->MeasureText(_L("XXXXX"), &input, &output); sl@0: TEST(output.iChars == 5); sl@0: // set flag, string should no longer fit (break happens) sl@0: input.iFlags = CFont::TMeasureTextInput::EFIncludePenPositionInBoundsCheck; sl@0: iTestFont->MeasureText(_L("XXXXX"), &input, &output); sl@0: TEST(output.iChars == 4); sl@0: // right-to-left w/o flag and bounds set to just fit string disregarding sidebearings sl@0: input.iFlags = CFont::TMeasureTextInput::EFVisualOrderRightToLeft; sl@0: iTestFont->MeasureText(_L("\x5EA\x5EA\x5EA\x5EA\x5EA"), &input, &output); sl@0: TEST(output.iChars == 5); sl@0: // set flag, string should no longer fit (break happens) sl@0: input.iFlags |= CFont::TMeasureTextInput::EFIncludePenPositionInBoundsCheck; sl@0: iTestFont->MeasureText(_L("\x5EA\x5EA\x5EA\x5EA\x5EA"), &input, &output); sl@0: TEST(output.iChars == 4); sl@0: // top-to-bottom w/o flag and bounds set to just fit string disregarding endbearings sl@0: input.iFlags = 0; sl@0: input.iMaxBounds = 60; sl@0: input.iDirection = CFont::EVertical; sl@0: iTestFont->MeasureText(_L("\x304B\x304B\x304B\x304B\x304B"), &input, &output); sl@0: TEST(output.iChars == 5); sl@0: // set flag, string should no longer fit (break happens) sl@0: input.iFlags = CFont::TMeasureTextInput::EFIncludePenPositionInBoundsCheck; sl@0: iTestFont->MeasureText(_L("\x304B\x304B\x304B\x304B\x304B"), &input, &output); sl@0: TEST(output.iChars == 4); sl@0: } sl@0: sl@0: void CTGlyphSelection::RunTestCaseL(TInt aCurTestCase) sl@0: /** sl@0: This method will execute each test case method in the class sl@0: logging its progress as it does so. sl@0: */ sl@0: { sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(KUnknownSYMTestCaseIDName); sl@0: switch(aCurTestCase) sl@0: { sl@0: case 1: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0200 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0200")); sl@0: INFO_PRINTF1(_L("Test API Boundaries")); sl@0: TestApiBoundaries(); sl@0: break; sl@0: case 2: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0201 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0201")); sl@0: INFO_PRINTF1(_L("Test CTRL Chars")); sl@0: TestCtrlCharsIgnored(); sl@0: break; sl@0: case 3: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0202 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0202")); sl@0: INFO_PRINTF1(_L("Test Latin Chars")); sl@0: TestLatinChars(); sl@0: break; sl@0: case 4: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0203 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0203")); sl@0: INFO_PRINTF1(_L("Test Soft Hypen Char")); sl@0: TestSoftHyphen(); sl@0: break; sl@0: case 5: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0204 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0204")); sl@0: INFO_PRINTF1(_L("Test Surrogate Pairs")); sl@0: TestSurrogates(); sl@0: INFO_PRINTF1(_L("Test Supplementary Chars")); sl@0: TestNonBmpCharsL(); sl@0: break; sl@0: case 6: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0205 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0205")); sl@0: INFO_PRINTF1(_L("Test Combining Latin Chars")); sl@0: TestCombiningLatinChars(); sl@0: break; sl@0: case 7: sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0221")); sl@0: INFO_PRINTF1(_L("Test Vietnamese Chars")); sl@0: TestVietnameseChars(); sl@0: break; sl@0: case 8: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0206 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0206")); sl@0: INFO_PRINTF1(_L("Test Vertical/Horizontal Text Bounds")); sl@0: TestTextDirection(); sl@0: break; sl@0: case 9: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0207 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0207")); sl@0: INFO_PRINTF1(_L("Test All Unicode Characters")); sl@0: TestAllUnicodeChars(); sl@0: break; sl@0: case 10: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0208 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0208")); sl@0: INFO_PRINTF1(_L("Test Ligatures with Diacritics")); sl@0: TestLigaturesWithDiacritics(); sl@0: break; sl@0: case 11: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0209 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0209")); sl@0: INFO_PRINTF1(_L("Test CFont::MeasureText()")); sl@0: TestMeasureText(); sl@0: break; sl@0: case 12: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0210 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0210")); sl@0: INFO_PRINTF1(_L("Test Indic Glyphs")); sl@0: TestIndicCharsL(); sl@0: break; sl@0: case 13: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0211 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0211")); sl@0: INFO_PRINTF1(_L("Test Thai Rendering")); sl@0: ExecuteThaiTests(); sl@0: break; sl@0: case 14: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0212 sl@0: */ sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0212")); sl@0: INFO_PRINTF1(_L("Test isolated Combining Latin Chars")); sl@0: TestIsolatedCombiningLatinChars(); sl@0: break; sl@0: case 15: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0213 sl@0: */ sl@0: INFO_PRINTF1(_L("Test Indic Gurmukhi and Malayalam Chars")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0213")); sl@0: ExecuteIndicGurmukhiMalayalamTests(); sl@0: break; sl@0: case 16: sl@0: /** sl@0: @SYMTestCaseID GRAPHICS-SYSLIB-GDI-CIT-0214 sl@0: */ sl@0: INFO_PRINTF1(_L("Test Rendering Context")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-SYSLIB-GDI-CIT-0214")); sl@0: TestContextInShapeInfo(); sl@0: break; sl@0: case 17: sl@0: TestComplete(); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(KNotATestSYMTestCaseIDName); sl@0: ((CTGlyphSelectionStep*)iStep)->CloseTMSGraphicsStep(); sl@0: break; sl@0: } sl@0: ((CTGlyphSelectionStep*)iStep)->RecordTestResultL(); sl@0: } sl@0: sl@0: void CTGlyphSelection::TestPerformance() sl@0: /** sl@0: This method tests the performance of the API under test sl@0: by executing a 10000 cycles of each test case. sl@0: **/ sl@0: { sl@0: TStopWatch profile; sl@0: INFO_PRINTF1(_L("Test Performance...")); sl@0: sl@0: profile.Start(); sl@0: for (TInt i = 0; i < 10000; i++) sl@0: { sl@0: TestCtrlCharsIgnored(); sl@0: TestLatinChars(); sl@0: TestSoftHyphen(); sl@0: TestSurrogates(); sl@0: TestCombiningLatinChars(); sl@0: TestTextDirection(); sl@0: sl@0: } sl@0: TUint numMilliSecs = profile.Stop(); sl@0: sl@0: INFO_PRINTF3(_L("Performance test end %d.%d s\n"),numMilliSecs/1000,numMilliSecs%1000); sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestThai_SimpleChars() sl@0: /** sl@0: This routine tests individual Thai base characters pumping them sl@0: through the CFont::GetCharacterPosition() API. sl@0: */ sl@0: { sl@0: TBool r; sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: TBuf<5> testText(0); sl@0: testText.SetLength(1); sl@0: param.iText.Set(testText); sl@0: sl@0: for (TUint i=0; Thai_SimpleChars[i] != 0xFFFF; i++) sl@0: { sl@0: testText[0] = Thai_SimpleChars[i]; sl@0: param.iPosInText = 0; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: sl@0: TEST(r && param.iPosInText == 1 sl@0: && param.iPen.iX == 10 sl@0: && param.iOutputGlyphs == 1 sl@0: && param.iOutput[0].iCode == Thai_SimpleChars[i]); sl@0: } sl@0: } sl@0: sl@0: sl@0: void CTGlyphSelection::TestThai_ValidGlyphClusters() sl@0: /** sl@0: This routine tests combining sequences of Thai base & mark sl@0: characters pumping them through the CFont::GetCharacterPosition() API. sl@0: The sequences mainly test the correct formation of Thay Glyph clusters sl@0: and the PUA substutions that take place. sl@0: */ sl@0: { sl@0: TInt failures=0; sl@0: TBool r; sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: sl@0: for (TUint i=0; Thai_ValidGlyphClusters[i].iTextLen != -1; i++) sl@0: { sl@0: TBuf<8> testText(Thai_ValidGlyphClusters[i].iText); sl@0: param.iText.Set(testText); sl@0: param.iPosInText = Thai_ValidGlyphClusters[i].iPosInText; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: sl@0: if (r && param.iPosInText == Thai_ValidGlyphClusters[i].oPosInText sl@0: && param.iOutputGlyphs == Thai_ValidGlyphClusters[i].oOutputLen) sl@0: { sl@0: for (TInt j=0; j testText(Thai_GlyphClusterBoundaries[i].iText); sl@0: param.iText.Set(testText); sl@0: sl@0: for (TUint k=0; k<2; k++) sl@0: { sl@0: if (Thai_GlyphClusterBoundaries[i].oOut[k].iPosInText == -1) sl@0: continue; sl@0: sl@0: param.iPosInText = Thai_GlyphClusterBoundaries[i].oOut[k].iPosInText; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = iTestFont->GetCharacterPosition(param); sl@0: sl@0: if (r && param.iPosInText == Thai_GlyphClusterBoundaries[i].oOut[k].oPosInText sl@0: && param.iOutputGlyphs == Thai_GlyphClusterBoundaries[i].oOut[k].oOutputLen) sl@0: { sl@0: for (TInt j=0; j"),_L("\xE04\xE33:\?>")); sl@0: } sl@0: sl@0: /** sl@0: This fuction tests Indic Gurmukhi and Malayalam support sl@0: */ sl@0: void CTGlyphSelection::ExecuteIndicGurmukhiMalayalamTests() sl@0: { sl@0: // create a font store for testing sl@0: CFontStore* fontStore = CFontStore::NewL(&User::Heap()); sl@0: sl@0: //load all ecom implemented rasterizer dlls. installs the rasterizer. sl@0: LoadOpenFontLibraries(fontStore); sl@0: // test font preparation sl@0: fontStore->iKPixelWidthInTwips = 11860; //This value is default sl@0: sl@0: //add any required font files sl@0: TUid err1 = fontStore->AddFileL(KTestIndicFontFile); sl@0: sl@0: TFontSpec testIndicFontSpec(KTestIndicFontFaceName,200); sl@0: sl@0: CFbsBitmap* bmp = new(ELeave) CFbsBitmap; sl@0: sl@0: TInt ret = bmp->Create(TSize(100,100),EGray2); sl@0: if (ret == KErrNotSupported) sl@0: return; sl@0: else sl@0: User::LeaveIfError(ret); sl@0: sl@0: CFbsBitmapDevice* device = NULL; sl@0: TRAPD(err2,device = CFbsBitmapDevice::NewL(bmp)); sl@0: TEST(err2 == KErrNone); sl@0: sl@0: CFbsBitGc* gc = NULL; sl@0: User::LeaveIfError(device->CreateContext(gc)); sl@0: sl@0: // Font file Creation sl@0: CFbsFont* indicFont = NULL; sl@0: User::LeaveIfError(device->GetNearestFontToDesignHeightInTwips(indicFont,testIndicFontSpec)); sl@0: gc->UseFont(indicFont); sl@0: CleanupStack::PushL(indicFont); sl@0: sl@0: //Testcode for Kannada, Marathi,Gujarati,Bengali language sl@0: // Test Indic Gurmukhi digit. sl@0: TInt err; sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: INFO_PRINTF1(_L("Test Indic Gurmukhi digits")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-TI18N-GDI-CIT-4063")); sl@0: TestGurmukhiDigit( *indicFont ); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: INFO_PRINTF1(_L("Test Indic Gurmukhi and Latin")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-TI18N-GDI-CIT-4064")); sl@0: TestGurmukhiAndLatin( *indicFont ); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: INFO_PRINTF1(_L("Test Indic DEF102858 on Gurmukhi")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-TI18N-GDI-CIT-4065")); sl@0: TestGurmukhiModifierAfterConsonantViramaZWJ( *indicFont ); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: INFO_PRINTF1(_L("Test Indic Gurmukhi consonant leading")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-TI18N-GDI-CIT-4066")); sl@0: TestGurmukhiWithConsonantInitial( *indicFont ); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: INFO_PRINTF1(_L("Test Indic Gurmukhi vowel leading")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-TI18N-GDI-CIT-4068")); sl@0: TestGurmukhiWithVowelInitial( *indicFont ); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: INFO_PRINTF1(_L("Test Indic Malayalam digits")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-TI18N-GDI-CIT-4067")); sl@0: TestMalayalamDigit( *indicFont ); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: INFO_PRINTF1(_L("Test Indic Malayalam and Latin")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-TI18N-GDI-CIT-4069")); sl@0: TestMalayalamAndLatin( *indicFont ); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: INFO_PRINTF1(_L("Test Indic DEF102858 on Malayalam")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-TI18N-GDI-CIT-4070")); sl@0: TestMalayalamModifierAfterConsonantViramaZWJ( *indicFont ); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: INFO_PRINTF1(_L("Test Indic Malayalam consonant leading")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-TI18N-GDI-CIT-4071")); sl@0: TestMalayalamWithConsonantInitial( *indicFont ); sl@0: TRAP(err,((CTGlyphSelectionStep*)iStep)->RecordTestResultL()); sl@0: if (err!=KErrNone) sl@0: INFO_PRINTF1(_L("Failed to record test result")); sl@0: INFO_PRINTF1(_L("Test Indic Malayalam vowel leading")); sl@0: ((CTGlyphSelectionStep*)iStep)->SetTestStepID(_L("GRAPHICS-TI18N-GDI-CIT-4072")); sl@0: TestMalayalamWithVowelInitial( *indicFont ); sl@0: CleanupStack::Pop(indicFont); sl@0: sl@0: //Cleaning the memory sl@0: delete bmp; sl@0: delete device; sl@0: delete gc; sl@0: fontStore->RemoveFile(err1); sl@0: delete fontStore; sl@0: REComSession::FinalClose(); sl@0: } sl@0: /** sl@0: This function tests the Thai Font Rendering feature of the CFont class sl@0: in the GDI.dll and in particular the modifications made to sl@0: CFont::GetCharacterPosition() to support the Unicocde Thai code page. sl@0: First introduced during the Sirocco project (A3.1.1) sl@0: @SYMFssID Graphics/GDI/GDI/1 sl@0: @SYMFssID Graphics/GDI/GDI/2 sl@0: */ sl@0: sl@0: void CTGlyphSelection::ExecuteThaiTests() sl@0: { sl@0: // Test individual Thai digits, letters and sign characters. sl@0: INFO_PRINTF1(_L("Test Thai simple charecters")); sl@0: TestThai_SimpleChars(); sl@0: sl@0: // Test complex Thai char sequences. sl@0: INFO_PRINTF1(_L("Test valid Thai glyph clusters")); sl@0: TestThai_ValidGlyphClusters(); sl@0: sl@0: // Test Thai glyph cluster boundaries. sl@0: INFO_PRINTF1(_L("Test invalid Thai glyph clusters")); sl@0: TestThai_InvalidGlyphClusters(); sl@0: sl@0: // Test Thai SaraAm-punctuation exception. sl@0: INFO_PRINTF1(_L("Test fix for INC118424")); sl@0: TestThai_INC118424(); sl@0: } sl@0: sl@0: sl@0: /* sl@0: * Note: sl@0: * This is just a easy way to help generate the test data info sl@0: * Any new added test data should do manually check firstly to check the correction before using this function sl@0: */ sl@0: // #define GEN_GURMUKHIMALAYALAMTESTDATA sl@0: void CTGlyphSelection::GenerateGurmukhiMalayalamData( const TDesC& filename, const TTestInput_PositionParam6* testArray, const CFbsFont& aFont ) sl@0: { sl@0: RFile file; sl@0: file.Replace( iFs, filename, EFileWrite ); sl@0: sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: RShapeInfo shapeInfo; sl@0: sl@0: if (!testArray) sl@0: { sl@0: return; sl@0: } sl@0: sl@0: for (TUint i = 0; testArray[i].iTextLen != -1; i++) sl@0: { sl@0: TTestInput_PositionParam6 currentArray = testArray[i]; sl@0: TBuf<8> testText(testArray[i].iText); sl@0: param.iText.Set(testText); sl@0: sl@0: TBuf8<256> datatext; sl@0: datatext.SetLength(0); sl@0: //{ 1, {0x0a66}, { {0, 1, 1, {0x12fe} }, {-1, 1, 1, {0} } } }, sl@0: datatext.Format(_L8("{ %d, {"), testArray[i].iTextLen); // 1, sl@0: sl@0: for (TUint i = 0; i tmp; sl@0: tmp.Format(_L8("0x%x, "), currentArray.iText[i]); // {0x0a66}, sl@0: datatext.Append(tmp); sl@0: } sl@0: datatext = datatext.Left(datatext.Length()-2); sl@0: datatext.Append(_L8("}, { ")); sl@0: sl@0: if (shapeInfo.IsOpen()) sl@0: shapeInfo.Close(); sl@0: sl@0: for (TUint k = 0; k < 6; k++) sl@0: { sl@0: param.iPosInText = k; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: TBool ret = aFont.GetCharacterPosition2(param, shapeInfo); sl@0: if (0 == param.iOutputGlyphs) sl@0: continue; sl@0: sl@0: TBuf8<16> tmp; sl@0: tmp.Format(_L8("{%d, %d, %d, {"), k, param.iPosInText, param.iOutputGlyphs); sl@0: datatext.Append(tmp); sl@0: sl@0: for (TInt j = 0; j < param.iOutputGlyphs; j++) sl@0: { sl@0: TText16 aCode = param.iOutput[j].iCode; sl@0: TBuf8<128> tmp; sl@0: tmp.Format(_L8("0x%x, "), aCode); sl@0: datatext.Append(tmp); sl@0: } //end for sl@0: datatext = datatext.Left(datatext.Length()-2); sl@0: datatext.Append(_L8("}}, ")); sl@0: } //end for sl@0: datatext.Append(_L8(" {-1, 1, 1, {0}} } }, \n")); sl@0: sl@0: file.Write(datatext); sl@0: } //end for sl@0: sl@0: file.Close(); sl@0: return; sl@0: } sl@0: sl@0: void CTGlyphSelection::DoEachGurmukhiMalayalamCase( const TTestInput_PositionParam6* testArray, const CFbsFont& aFont ) sl@0: { sl@0: TInt failures=0; sl@0: TBool r; sl@0: CFont::TPositionParam param; sl@0: param.iDirection = CFont::EHorizontal; sl@0: param.iFlags = CFont::TPositionParam::EFLogicalOrder; sl@0: RShapeInfo shapeInfo; sl@0: sl@0: if ( !testArray ) sl@0: { sl@0: return; sl@0: } sl@0: sl@0: for (TUint i=0; testArray[i].iTextLen != -1; i++) sl@0: { sl@0: TBuf<8> testText(testArray[i].iText); sl@0: param.iText.Set(testText); sl@0: if(shapeInfo.IsOpen()) sl@0: shapeInfo.Close(); sl@0: sl@0: for (TUint k=0; k<6; k++) sl@0: { sl@0: // If it's end of sequence sl@0: if ( testArray[i].oOut[k].iPosInText == -1) sl@0: break; sl@0: sl@0: param.iPosInText = testArray[i].oOut[k].iPosInText; sl@0: param.iPen.iX = param.iPen.iY = 0; sl@0: sl@0: r = aFont.GetCharacterPosition2(param, shapeInfo); sl@0: sl@0: if (r && param.iPosInText == testArray[i].oOut[k].oPosInText sl@0: && param.iOutputGlyphs == testArray[i].oOut[k].oOutputLen) sl@0: { sl@0: for (TInt j=0; j