|
1 /* |
|
2 * Copyright (c) 2002-2004 Nokia Corporation and/or its subsidiary(-ies). |
|
3 * All rights reserved. |
|
4 * This component and the accompanying materials are made available |
|
5 * under the terms of "Eclipse Public License v1.0"" |
|
6 * which accompanies this distribution, and is available |
|
7 * at the URL "http://www.eclipse.org/legal/epl-v10.html". |
|
8 * |
|
9 * Initial Contributors: |
|
10 * Nokia Corporation - initial contribution. |
|
11 * |
|
12 * Contributors: |
|
13 * |
|
14 * Description: |
|
15 * Provides the CAknFepUICtrlInputPane definition. |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 |
|
21 |
|
22 |
|
23 |
|
24 |
|
25 |
|
26 |
|
27 |
|
28 |
|
29 |
|
30 #ifndef __AKN_FEP_INPUT_PANE_H__ |
|
31 #define __AKN_FEP_INPUT_PANE_H__ |
|
32 |
|
33 #include <e32std.h> |
|
34 |
|
35 /** |
|
36 * pane in which the user's input is shown |
|
37 */ |
|
38 class MAknFepUICtrlInputPane |
|
39 { |
|
40 public: |
|
41 /** |
|
42 * Different layouts, can be used depending on whether used as the input pane, or as |
|
43 * an entry in the popup pinyin window |
|
44 */ |
|
45 enum TInputPaneLayout |
|
46 { |
|
47 ELayoutPhraseInputPane = 3, |
|
48 ELayoutPhrasePinyinPopupPane, |
|
49 ELayoutPhraseMiniQwertyZhuyin |
|
50 }; |
|
51 |
|
52 /** |
|
53 * The number of characters that can be displayed in the input pane. |
|
54 * This does not include the tone mark, which is counted separately. |
|
55 */ |
|
56 enum |
|
57 { |
|
58 EMaxToneMarkLength = 1, |
|
59 EMaxInputCharsInputPaneNotIncludingToneMark = 30, // need 30 in the case of stroke |
|
60 EMaxInputCharsPinyinPopupNotIncludingToneMark = 21, |
|
61 EMaxInputCharsZhuyinPopup = 16, |
|
62 EMaxInputCharsInputPane = EMaxInputCharsInputPaneNotIncludingToneMark + EMaxToneMarkLength, |
|
63 EMaxInputCharsPinyinPopup = EMaxInputCharsPinyinPopupNotIncludingToneMark + EMaxToneMarkLength, |
|
64 EMaxInputChars = EMaxInputCharsInputPane + EMaxInputCharsPinyinPopup // guaranteed big enough for either |
|
65 }; |
|
66 |
|
67 enum |
|
68 { |
|
69 EPhoneticChanged = 0x0001 |
|
70 }; |
|
71 |
|
72 public: |
|
73 virtual void SetText(const TDesC& aDes) = 0; |
|
74 |
|
75 /** |
|
76 * Get the text buffer of the pane |
|
77 * |
|
78 * @output aText the buffer is filled with the contents of the candidate |
|
79 * of the pane, up to the size of the buffer |
|
80 */ |
|
81 virtual void GetText(TDes& aText) const = 0; |
|
82 |
|
83 /** |
|
84 * This function sets the Tone Mark for the Pane. |
|
85 * |
|
86 * @param aToneMark descriptor containing the tone mark character |
|
87 */ |
|
88 virtual void SetToneMark(const TDesC& aToneMark) = 0; |
|
89 |
|
90 /** |
|
91 * This function sets the validity of the tonemark |
|
92 * |
|
93 * @param aValid if ETrue, tonemark will be displayed as valid |
|
94 * if EFalse, tonemark will be displayed as not valid |
|
95 */ |
|
96 virtual void SetToneMarkValidity(TBool aValid) = 0; |
|
97 |
|
98 /** |
|
99 * sets the font to be used, which will override the font from LAF |
|
100 * |
|
101 * @param aFontId the new font id, pass in 0 to use the one from LAF |
|
102 * |
|
103 */ |
|
104 virtual void SetOverrideFontId(TInt aFontId) = 0; |
|
105 virtual void SetFlag(TInt aFlag) = 0; |
|
106 virtual void ClearFlag(TInt aFlag) = 0; |
|
107 virtual TBool IsFlagSet(TInt aFlag) const = 0; |
|
108 }; |
|
109 |
|
110 #endif //__AKN_FEP_INPUT_PANE_H__ |
|
111 |
|
112 // End of file |