Page 129 - DCAP408_WEB_PROGRAMMING
P. 129
Unit 7: Character Sets, Fonts and the Keyboard
7.12 Summary Notes
ANSI Character set is defined list of characters identified by the computer hardware and
software.
The three case conversion functions are LOWER, UPPER, and INITCAP and the five
character manipulation functions are CONCAT. SUBSTR, LENGTH, INSTR, and LPAD.
Keystroke messages handle window behavior and character messages verify the text that
is exhibited in a window.
The lParam parameter of a keystroke message includes additional data regarding the
keystroke that produced the message.
WM_CHAR message is posted to the window with the keyboard focus when a
WM_KEYDOWN message is converted by the Translate Message function.
TranslateMessage produces the WM_DEADCHAR message when it processes the
WM_KEYDOWN message from a dead key.
The fg_fontload() function states which stock font fg_print() uses for showing strings.
Windows allows you to create additional fonts relying on the stock fonts, or from character
definitions in an external font file. Such fonts are known as logical fonts, and programs
frequently use logical fonts to offer additional typefaces and dissimilar character sizes.
Text Metric is a font structure contains basic information about a physical font.
The TranslateAccelerator function monitors keyboard input to the message queue,
verifying for key combinations that match an entry in the accelerator table.
7.13 Keywords
ANSI Character Set: ANSI Character set is defined list of characters identified by the computer
hardware and software.
Lparam: The lParam parameter of a keystroke message includes additional data regarding the
keystroke that produced the message.
Text Metric: Text Metric is a font structure contains basic information about a physical font.
TranslateAccelerator: The TranslateAccelerator function monitors keyboard input to the message
queue, verifying for key combinations that match an entry in the accelerator table.
TranslateMessage: TranslateMessage produces the WM_DEADCHAR message when it processes
the WM_KEYDOWN message from a dead key.
WM_CHAR: WM_CHAR message is posted to the window with the keyboard focus when a
WM_KEYDOWN message is converted by the Translate Message function.
7.14 Review Questions
1. What is ANSI Character Set? Also represent the ANSI Character Set table.
2. What are the different types of character functions? Illustrate.
3. Make distinction between CONCAT and INSTR function with example.
4. Explain the concept of processing keyboard messages.
LOVELY PROFESSIONAL UNIVERSITY 123