Taxonomy Categories:
Member Functions:
Interface Category:
API.
Inherits From:
None.
Inherited By:
None.
Purpose:
Provides a handle object through which most clients access virtual keyboards. A single handle can be used to access all available keyboards by changing the current keyboard through the handle.
Instantiation:
Allocate on the heap or the stack.
Deriving Classes:
Not typically derived. It might be required to support different types of TStandardEditableVirtualKeyboard.
Concurrency:
Not multithread safe.
Resource Use:
No special requirements.
- TVirtualKeyboardHandle ()
- TVirtualKeyboardHandle (const TLocalizableName & keyboardName)
- TVirtualKeyboardHandle (const TVirtualKeyboardHandle & copy)
Interface Category:
API.
Purpose:
- Default constructor. Maps using the current system keyboard.
- Creates a handle for a specified keyboard.
- Copy constructor.
Calling Context:
- Called by the stream-in operators and directly.
- Call this function directly.
- Called to copy an object.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual void GetCurrentKeyboard (TLocalizableName & name) const
Interface Category:
API.
Purpose:
Returns the keyboard currently used by this handle.
Calling Context:
Called by clients who want to get the name of the current keyboard.
Parameters:
Return Value:
None. Returns the name in name.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual void SetCurrentKeyboard (const TLocalizableName & name)
Interface Category:
API.
Purpose:
Sets the current keyboard for this handle to that indicated by name. Only works on currently installed keyboards.
Calling Context:
Called by clients to change the keyboard referenced by this handle.
Parameters:
Return Value:
None.
Exceptions:
Throws TVirtualKeyboardException::kSpecifiedKeyboardNotInstalled if the keyboard is not installed.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual TStream & operator <<= (TStream & fromWhere)
Interface Category:
API.
Purpose:
Stream-in operator.
Calling Context:
Called to stream in data.
Parameters:
- TStream & fromWhere -The stream the object is streamed in from.
Return Value:
Returns a reference to the stream the object streams itself in from.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual TStream & operator >>=(TStream & toWhere) const
Interface Category:
API.
Purpose:
Stream-out operator.
Calling Context:
Called to stream out data.
Parameters:
- TStream & toWhere -The stream the object is streamed out to.
Return Value:
Returns a reference to the stream the object streams itself out to.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual ~ TVirtualKeyboardHandle ()
Interface Category:
API.
Purpose:
Destructor.
Calling Context:
Called to destroy an object.
Parameters:
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
TVirtualKeyboard & operator =(const TVirtualKeyboardHandle & from)
Interface Category:
API.
Purpose:
Assignment operator.
Calling Context:
Called when an object is assigned to another compatible object.
Parameters:
Return Value:
A non-const reference to the left-hand side object.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
None.
virtual void CommandText (TVirtualKeyCode :: EVirtualKey key, const TModifierKeys & modifiers, TText & text) const
Interface Category:
API.
Purpose:
Maps from the key and the modifiers to the representative character(s) for the command key using the command keyboard that has been designated for this keyboard. The default calls MapKeyToText.
For example, a virtual keyboard can be set up so that the combination of the key, kVirtualA, with the command and option modifiers set results in a TText that can be displayed in a menu as TUnicode::kCommandKey+TUnicode::kOptionKey+TUnicode::kLatinCapitalLetterA.
Calling Context:
Called by menus and other subsystems that need to display a visual representation for command key equivalents.
Parameters:
- const TModifierKeys & modifiers -The modifiers in effect when the key was typed.
- TText & text -The text equivalent of the key and modifier combination.
Return Value:
None. The text for display is returned in the text parameter.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
Overrides inherited TVirtualKeyboard function.
virtual void MapKeyToText (TVirtualKeyCode :: EVirtualKey key, const TModifierKeys & modifiers, TText & text) const
Interface Category:
API.
Purpose:
Defines the primary mapping functionality of virtual keyboards.
Calling Context:
Called by the typing configuration to produce text from a virtual key and modifier combination.
Parameters:
- TVirtualKeyCode :: EVirtualKey key -The key taken from a key event.
- const TModifierKeys & modifiers -The modifiers in effect when the key was typed.
- TText & text -The text that results from the key and modifier combination.
Return Value:
None.
Exceptions:
Throws no exceptions, passes all exceptions through.
Concurrency:
Not multithread safe.
Other Considerations:
Overrides inherited TVirtualKeyboard function.
Click the icon to mail questions or corrections about this material to Taligent personnel.
Copyright©1995 Taligent,Inc. All rights reserved.