|VC++ 6.0 ebook chapter index|
The mouse is a pointing device with one or more buttons. Despite much experimentation with other alternative input devices such as touch screens and light pens, the mouse reigns supreme. Together with variations such as trackballs, which are common on laptop computers, the mouse is the only alternative input device to achieve a massive—virtually universal—penetration in the PC market.
This was not always the case. Indeed, the early developers of Microsoft Windows felt that they shouldn't require users to buy a mouse in order to use the product. So they made the mouse an optional accessory and provided a keyboard interface to all operations in Windows and the "applets" distributed with Windows. (For example, check out the help information for the Windows Calculator to see how each button is obsessively assigned a keyboard equivalent.) Third-party software developers were also encouraged to duplicate mouse functions with a keyboard interface in their applications. The early editions of this book attempted to further disseminate this philosophy.
In theory, Windows now requires a mouse. At least that's what the box says. However, you can unplug your mouse and Windows will boot up fine (aside from a message box informing you that a mouse is not attached). Trying to use Windows without the mouse is akin to playing the piano with your toes (at least initially), but you can definitely do it. For that reason, I still like the idea of providing keyboard equivalents for mouse actions. Touch typists in particular prefer keeping their hands on the keyboard, and I suppose everyone has had the experience of "losing" a mouse on a cluttered desk or having a mouse too clogged up with mouse gunk to work well. The keyboard equivalents usually don't cost much in terms of thought or effort, and they can deliver more functionality to users who prefer them.
Just as the keyboard is usually identified with entering and manipulating text data, the mouse is identified with drawing and manipulating graphical objects. Indeed, most of the sample programs in this chapter draw some graphics, putting to use what we learned in Chapter 5.