Windows 3.1 Device Drivers (ddag31qh.hlp) (Table of Contents; Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
KeySelection
                                                     Up Next Previous
────────────────────────────────────────────────────────────────────────────
 
POINT KeySelection(lpPntStruc, StartType, Mfunc)
LPEXTPAINTSTRUC lpPntStruc;
WORD StartType;
WORD Mfunc;
 
The KeySelection function moves the start or end point of the selection
rectangle and returns that point's new location.
 
Parameter   Description
────────────────────────────────────────────────────────────────────────────
 
 
lpPntStruc  Points to an EXTPAINTSTRUC structure.
 
StartType   Specifies whether the SHIFT key is up or down. The StartType
            parameter is zero if the key is up, and nonzero if the key
            down.
 
Mfunc       Specifies the direction to move the selection point. This
            parameter can be one of the following values.
 
            Value  Meaning
            ────────────────────────────────────────────────────────────────
            0      Move right.
 
            1      Move left.
 
            2      Move down.
 
            3      Move up.
 
Return Value
 
The return value is a POINT structure containing the x- and y-coordinates of
the new selection start or end point.
 
Comments
 
The export ordinal for this function is 4.
 
WINOLDAP calls the KeySelection function whenever the user presses an arrow
key or a SHIFT+arrow key combination. If an arrow key is pressed, the
function moves the current start point left, right, up, or down as specified
by the Mfunc parameter. If a SHIFT+arrow key combination is pressed, the
function moves the current end point in the specified direction.
 
The amount the function moves the point depends on the display mode. In text
mode, the function moves by the width and height of the current font. In
graphics mode, the function moves by a width and height that is reasonable
for the given display.
 
KeySelection does not update the EXTPAINTSTRUC structure. Instead, WINOLDAP
calls either the BeginSelection or MakeSelctRect function and passes it the
new point.
 
See Also
 
BeginSelection, MakeSelctRect, EXTPAINTSTRUC, POINT