cursor()

Environment

Description

Sets the cursor to a predefined shape or restores the default cursor.

Syntax

void cursor() void cursor(int type)

Parameters

NameTypeDescription
typeintARROW, CROSS, HAND, MOVE, TEXT_CURSOR, WAIT (optional)

Returns

void

Related

Under the Hood

From Processing.h:

void cursor(); void cursor(int type);

Under the Hood

From Processing.cpp:

void PApplet::cursor() {if(gWindow)glfwSetInputMode(gWindow,GLFW_CURSOR,GLFW_CURSOR_NORMAL);} void PApplet::cursor(int type){if(!gWindow)return;GLFWcursor* c=glfwCreateStandardCursor(type);if(c)glfwSetCursor(gWindow,c);}