Skip to content

Commit 17959bf

Browse files
committed
Add API: GetPreeditCursorRectangle
This is for GLFW3: glfwGetPreeditCursorRectangle
1 parent 0eb9f31 commit 17959bf

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

src/raylib.h

+1
Original file line numberDiff line numberDiff line change
@@ -1111,6 +1111,7 @@ RLAPI int GetKeyPressed(void); // Get key pressed
11111111
RLAPI int GetCharPressed(void); // Get char pressed (unicode), call it multiple times for chars queued, returns 0 when the queue is empty
11121112
RLAPI void SetPreeditCallback(PreeditCallback callback); // Set a callback for preedit
11131113
RLAPI void SetPreeditCursorRectangle(int x, int y, int w, int h); // Set the preedit cursor area that is used to decide the position of the candidate window
1114+
RLAPI void GetPreeditCursorRectangle(int *x, int *y, int *w, int *h); // Get the preedit cursor area
11141115

11151116
// Input-related functions: gamepads
11161117
RLAPI bool IsGamepadAvailable(int gamepad); // Check if a gamepad is available

src/rcore.c

+6
Original file line numberDiff line numberDiff line change
@@ -3561,6 +3561,12 @@ void SetPreeditCursorRectangle(int x, int y, int w, int h)
35613561
glfwSetPreeditCursorRectangle(CORE.Window.handle, x, y, w, h);
35623562
}
35633563

3564+
// Get the preedit cursor area
3565+
void GetPreeditCursorRectangle(int *x, int *y, int *w, int *h)
3566+
{
3567+
glfwGetPreeditCursorRectangle(CORE.Window.handle, x, y, w, h);
3568+
}
3569+
35643570
// Set a custom key to exit program
35653571
// NOTE: default exitKey is ESCAPE
35663572
void SetExitKey(int key)

0 commit comments

Comments
 (0)