MPtiKeyMappings Class Reference

#include <mw/PtiKeyMappings.h>

Link against: PtiEngine.lib

class MPtiKeyMappings

Detailed Description

MPtiKeyMappings

Interface class for PtiEngine keymapping functionality.

Constructor & Destructor Documentation

~MPtiKeyMappings ( )

~MPtiKeyMappings()[inline, virtual]

Member Function Documentation

CurrentKey ( )

TPtiKey CurrentKey()[pure virtual]

Returns PtiEngine key code for last StartMapping() call.

Since
2.6

Returns: PtiEngine key code for last StartMapping() call.

GetAll ( TPtiTextCase )

TPtrC GetAll(TPtiTextCaseaCase)[pure virtual]

Returns all keymapping data for current key, excluding first character (which is expected to be "get all"-control character).

Since
3.0
ParameterDescription
aCaseText case for which data will be returned.

Returns: Constant descriptor pointing to keymap data.

KeyForCharacter ( TUint16 )

TPtiKey KeyForCharacter(TUint16aChar)[pure virtual]

Returns key code for key which produces given unicode character (if found).

Since
2.6
ParameterDescription
aCharA character to be queried.

Returns: Key code for aChar. EPtiKeyNone, if not found.

NextKey ( TPtiKey, TBool &, TPtiTextCase )

TUint16 NextKey(TPtiKeyaKey,
TBool &aAppend,
TPtiTextCaseaCase
)[pure virtual]

Continues keymapping sequence. This method should be called when key event comes in while multitapping timer is active. Takes care of cycling through multitapping candidates associated for given key.

Since
2.6
ParameterDescription
aKeyA key to be mapped.
aAppendRefernce to boolen variable. This will be set to ETrue if current character in editor should be replaced (new multitapping candidate was found) and to EFalse if new character should inserted instead.
aCaseText case for mapping operation.

Returns: Next character assosiated to given key or the first character if aKey was different key than previous key press.

ReplaceKeyMapL ( TPtiKey, TDesC &, TPtiTextCase )

TInt ReplaceKeyMapL(TPtiKeyaKey,
TDesC &aMap,
TPtiTextCaseaCase
)[pure virtual]

Replaces keymapping data for given key and case.

Since
2.6
ParameterDescription
aKeyA key to be replaced.
aMapNew keymapping data for aKey,
aCaseText case for replaced data.

Returns: KErrNone or system wide error code.

StartMapping ( TPtiKey, TPtiTextCase, TPtiEngineInputMode )

TUint16 StartMapping(TPtiKeyaKey,
TPtiTextCaseaCase,
TPtiEngineInputModeaMode = EPtiEngineInputModeNone
)[pure virtual]

Starts mapping new key. Will return first character bound to given key in given text case.

ParameterDescription
aKeyA key to be mapped.
aCaseText case for mapping operation.
aModeInput mode for mapping. This is needed if keymapping data contains characters for several input modes (used mainly with Chinese modes). This value will be matched to possible input mode control characters in keymapping data.

Returns: First character bound to requested key.