The Text Objects: 5.5 Using VisText: Key Functions

Up: GEOS SDK TechDocs | Up | Prev: 5.4 Text Filters | Next: 5.6 Setting Text Confines
VisTextKeyFunction, MSG_VIS_TEXT_DO_KEY_FUNCTION

The VisText object is able to recognize certain generic functions that operate on text. Most of these functions are initiated through a key sequence entered by the user, but you can mimic such a key sequence by sending the text object MSG_VIS_TEXT_DO_KEY_FUNCTION, passing it a VisTextKeyFunction .

The following VisTextKeyFunction values are recognized by the text object:

VTKF_FORWARD_LINE
VTKF_BACKWARD_LINE
VTKF_SELECT_ADJUST_FORWARD_LINE
VTKF_SELECT_ADJUST_BACKWARD_LINE
VTKF_FORWARD_CHAR
VTKF_BACKWARD_CHAR
VTKF_FORWARD_WORD
VTKF_BACKWARD_WORD
VTKF_FORWARD_PARAGRAPH
VTKF_BACKWARD_PARAGRAPH
VTKF_START_OF_LINE
VTKF_END_OF_LINE
VTKF_START_OF_TEXT
VTKF_END_OF_TEXT
VTKF_SELECT_WORD
VTKF_SELECT_LINE
VTKF_SELECT_PARAGRAPH
VTKF_SELECT_OBJECT
VTKF_SELECT_ADJUST_FORWARD_CHAR
VTKF_SELECT_ADJUST_BACKWARD_CHAR
VTKF_SELECT_ADJUST_FORWARD_WORD
VTKF_SELECT_ADJUST_BACKWARD_WORD
VTKF_SELECT_ADJUST_FORWARD_PARAGRAPH
VTKF_SELECT_ADJUST_BACKWARD_PARAGRAPH
VTKF_SELECT_ADJUST_TO_START
VTKF_SELECT_ADJUST_TO_END
VTKF_SELECT_ADJUST_START_OF_LINE
VTKF_SELECT_ADJUST_END_OF_LINE
VTKF_DELETE_BACKWARD_CHAR
VTKF_DELETE_BACKWARD_WORD
VTKF_DELETE_BACKWARD_LINE
VTKF_DELETE_BACKWARD_PARAGRAPH
VTKF_DELETE_TO_START
VTKF_DELETE_CHAR
VTKF_DELETE_WORD
VTKF_DELETE_LINE
VTKF_DELETE_PARAGRAPH
VTKF_DELETE_TO_END
VTKF_DELETE_EVERYTHING
VTKF_DESELECT
VTKF_TOGGLE_OVERSTRIKE_MODE
VTKF_TOGGLE_SMART_QUOTES

MSG_VIS_TEXT_DO_KEY_FUNCTION

void	MSG_VIS_TEXT_DO_KEY_FUNCTION
        VisTextKeyFunction			func,
        word			data);

This message allows the text object to mimic certain text operations that normally are the result of user keystrokes.

Note: the VisTextKeyFunction types VTKF_SELECT_LINE, VTKF_SELECT_PARAGRAPH, and VTKF_SELECT_OBJECT will be supported in an upcoming release.

Source: Unrestricted.

Destination: Any text object

Parameters: func VisTextKeyFunction to perform.

data
Data for that key function (if needed).

Interception: Generally not intercepted.


Up: GEOS SDK TechDocs | Up | Prev: 5.4 Text Filters | Next: 5.6 Setting Text Confines