TKeyboard VCL Component
======================

Version: 1.10


DESCRIPTION

TKeyboard displays an alphanumeric or numeric keyboard on the screen. TKeyboard is derived from TPanel. 

Shift and Caps lock: The behavior of the shift key is slightly different than on
real keyboards. Pressing shift once puts TKeyboard in shift mode and TKeyboard
displays the second function of the keys. After pressing one key TKeyboard falls
back in normal mode. Caps lock works just as it does in a real keyboard.

The CharCase property controls the case of the returned characters. On ecUpper
all characters are converted to uppercase, on ecLower all characters are
converted to lowercase, on ecNormal characters are in lowercase when not in shift
or caps mode. If in shift or caps mode all characters are in uppercase.

Through the LinkedControl property TKeyboard can be linked to any descendant of
TWinControl. By linking a control to TKeyboard, keys pressed on TKeyboard are
passed to the linked control. This is especially usefull for TEdit, TMemo, TRichtText and TComboBox (and the corresponding ...DB.. controls). TWinControl is used as LinkedControl class because its the first common anchestor for all the controls above.

The keyboard layout of TKeyboard reflects a standard US keyboard. The layout can
be changed by changing the ANLRow constants below.

When a normal key is pressed a OnKey event is generated. For special keys (Tab, Shift, Caps,
Enter, Space, Backspace, Escape and F1-F12) an OnSpecialKey event is generated. The 
type used to pass the special key is TSpecialKey declared as:

TSpecialKey = (skTab, skCaps, skLeftShift, skRightShift, skEnter, skBackspace, skEscape,
		skF1, skF2, skF3, skF4, skF5, skF6, skF7, skF8, skF9, skF10, skF11, skF12);


All the other properties and events I added should be self explaining.



PORTABILITY

TKeyboard has been written and tested with Delphi 4 Client/Server. But I see no reason it
shouldn't work with Delphi2 and 3 or CBuilder.



KNOWN PROBLEMS:

-When changing BevelInner, BevelOuter, BevelWidth or BorderWidth the control 
 does not automatically resize. This is because I couldn't figure out how
 to trigger the resize since I cannot override the property set methods
 of TCustomPanel where those properties are defined. Workaround is calling
 Resize after changing one of the above at runtime or manually resize the component
 at design time.

-When the linked control is deleted from the form an access violation appears in the
 property editor. Workaround is clearing the LinkedControl property or linking to another
 control.



HISTORY:

Version 1.10: 
- Removed default value for HighlightColor, now the highlighting works correctly.
- Adjusted Space key width to be exactly centered.
- Changed kbmNumeric mode to kbmCalculator mode and introduced new Numeric mode kbmNumeric.
- Introduced IFDEF's for different Delphi versions. No FlatKeys property in Delphi 2.0
- New property 'Options' to disable or hide special keys.
- Added BoldShiftIndicator to Options property. If true Shift and Caps key are in bold font   style when active



CONTACT

For suggestions, bug reports and to get the newest versions write to:

	Martin Geier
	geier@iname.com




Have fun with it...

	Martin


Copyright: Martin Geier, 1999

