Skip to content

Commit 88a0d77

Browse files
committed
Add API: ResetPreedit
This is for GLFW3: glfwResetPreeditText
1 parent 5a576c7 commit 88a0d77

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
@@ -1114,6 +1114,7 @@ RLAPI void SetPreeditWindowPosition(int x, int y); // Set a preedit w
11141114
RLAPI void GetPreeditWindowPosition(int *x, int *y); // Get a preedit window postion XY
11151115
RLAPI bool IsImeOn(void); // Check if IME is ON
11161116
RLAPI void SetImeStatus(bool on); // Set IME status
1117+
RLAPI void ResetPreedit(void); // Reset preedit text
11171118

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

src/rcore.c

+6
Original file line numberDiff line numberDiff line change
@@ -3580,6 +3580,12 @@ void SetImeStatus(bool on)
35803580
else glfwSetInputMode(CORE.Window.handle, GLFW_IME, GLFW_FALSE);
35813581
}
35823582

3583+
// Reset preedit text
3584+
void ResetPreedit(void)
3585+
{
3586+
glfwResetPreeditText(CORE.Window.handle);
3587+
}
3588+
35833589
// Set a custom key to exit program
35843590
// NOTE: default exitKey is ESCAPE
35853591
void SetExitKey(int key)

0 commit comments

Comments
 (0)