graphicsdeviceinterface/gdi/inc/BidiVisual.h
changeset 183 6a1564a2f3e6
parent 168 2bd88482bfe5
child 194 18f84489a694
equal deleted inserted replaced
168:2bd88482bfe5 183:6a1564a2f3e6
     1 // Copyright (c) 2002-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 
       
    16 #ifndef BIDIVISUAL_H_
       
    17 #define BIDIVISUAL_H_
       
    18 
       
    19 #include <bidi.h>
       
    20 
       
    21 class TBidiLogicalToVisual
       
    22 /** 
       
    23 This class is a low-level class for bi-directionally reordering text. It 
       
    24 allows the re-ordering of text using no leaving functions at all, and provides 
       
    25 a finer degree of control than TBidiText. However, it should not be used 
       
    26 without understanding the basics of the Unicode Bi-directional Reordering 
       
    27 Algorithm. 
       
    28 @publishedAll
       
    29 @released
       
    30 */
       
    31 	{
       
    32 public:
       
    33 	enum {KMinCharAvailable = 4};
       
    34 
       
    35 	IMPORT_C TBidiLogicalToVisual(const TDesC& aText, TBool aRightToLeft,
       
    36 		TBidirectionalState::TRunInfo* aRunInfoArray, TInt aRunInfoLength);
       
    37 	IMPORT_C TBidiLogicalToVisual(const TDesC& aText,
       
    38 		TBidirectionalState::TRunInfo* aRunInfoArray, TInt aRunInfoLength);
       
    39 	IMPORT_C TInt Reorder();
       
    40 	IMPORT_C void GetVisualLine(TDes& aLine, TInt aStart, TInt aEnd,
       
    41 		TChar aTruncationChar);
       
    42 private:
       
    43 	const TDesC& iText;
       
    44 	TBool iRightToLeft;
       
    45 	TBidirectionalState::TRunInfo* iRunInfoArray;
       
    46 	TInt iRunInfoArrayLength;
       
    47 	TInt iRuns;
       
    48 	TUint32 iSpare2;
       
    49 	};
       
    50 
       
    51 #endif