Export (0) Print
Expand All
6 out of 15 rated this helpful - Rate this topic

Cursors

A cursor is a small picture whose location on the screen is controlled by a pointing device, such as a mouse, pen, or trackball. In the remainder of this overview, the term mouse refers to any pointing device.

When the user moves the mouse, the system moves the cursor accordingly. The cursor functions enable applications to create, load, display, animate, move, confine, and destroy cursors.

In This Section

NameDescription
About Cursors

Discusses the standard cursors.

Using Cursors

Discusses how to perform tasks related to cursors.

Cursor Reference

Contains the API reference.

 

Cursor Functions

NameDescription
ClipCursor

Confines the cursor to a rectangular area on the screen. If a subsequent cursor position (set by the SetCursorPos function or the mouse) lies outside the rectangle, the system automatically adjusts the position to keep the cursor inside the rectangular area.

CopyCursor

Copies the specified cursor.

CreateCursor

Creates a cursor having the specified size, bit patterns, and hot spot.

DestroyCursor

Destroys a cursor and frees any memory the cursor occupied. Do not use this function to destroy a shared cursor.

GetClipCursor

Retrieves the screen coordinates of the rectangular area to which the cursor is confined.

GetCursor

Retrieves a handle to the current cursor.

GetCursorInfo

Retrieves information about the global cursor.

GetCursorPos

Retrieves the cursor's position, in screen coordinates.

GetPhysicalCursorPos

Retrieves the position of the cursor in physical coordinates.

LoadCursor

Loads the specified cursor resource from the executable (.EXE) file associated with an application instance.

LoadCursorFromFile

Creates a cursor based on data contained in a file.

SetCursor

Sets the cursor shape.

SetCursorPos

Moves the cursor to the specified screen coordinates. If the new coordinates are not within the screen rectangle set by the most recent ClipCursor function call, the system automatically adjusts the coordinates so that the cursor stays within the rectangle.

SetPhysicalCursorPos

Sets the position of the cursor in physical coordinates.

SetSystemCursor

Enables an application to customize the system cursors. It replaces the contents of the system cursor specified by the id parameter with the contents of the cursor specified by the hcur parameter and then destroys hcur.

ShowCursor

Displays or hides the cursor.

 

Cursor Notifications

NameDescription
WM_SETCURSOR

Sent to a window if the mouse causes the cursor to move within a window and mouse input is not captured.

 

Cursor Structures

NameDescription
CURSORINFO

Contains global cursor information.

 

 

 

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.