Processing Events with Event Tables

Once the event loop has read an event, it uses event tables to determine what to do next. All processing of user keystrokes and mouse events is done with event tables. Event tables provide a flexible way to translate user input into program actions. An event table consists of a list of event codes; each event code is associated with a C function (an event function) that should be called when this event is processed.

With event tables, you have great flexibility and control of the keyboard and mouse interface of the Vermont Views system. You can modify the event tables used by any processing function, change the key associated with an event function, and write your own event functions.

In addition, you can create event tables for your own uses. You can process keystrokes and mouse actions from the user and translate them into actions using your event table.

Event tables increase the portability of your program because an event code is assigned a function that is always called no matter what operating system you are working under.

For more information about modifying event tables, writing event functions, and creating your own event tables, see Chapter 38, "Writing Event Functions," Chapter 39, "Installing Event Functions and Modifying Event Tables," and Chapter 41, "Processing Events and Keystrokes in Your Code."

More:

What Is an Event Table?

Searching Event Tables


Home Contents Previous Next