Skip to content

Commit 2046ebe

Browse files
committed
Add SDL_tolower and SDL_toupper to SDL_stdinc
1 parent b54c5c7 commit 2046ebe

File tree

1 file changed

+40
-0
lines changed

1 file changed

+40
-0
lines changed

units/SDL_stdinc.inc

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -957,6 +957,46 @@ function SDL_isprint(x: cint): cint; cdecl;
957957
function SDL_isgraph(x: cint): cint; cdecl;
958958
external SDL_LibName {$IFDEF DELPHI} {$IFDEF MACOS} name '_SDL_isgraph' {$ENDIF} {$ENDIF};
959959

960+
(* -- Character manipulation functions -- *)
961+
962+
{*
963+
* Convert low-ASCII English letters to uppercase.
964+
*
965+
* **WARNING**: Regardless of system locale, this will only convert ASCII
966+
* values 'a' through 'z' to uppercase.
967+
*
968+
* This function returns the uppercase equivalent of `x`. If a character
969+
* cannot be converted, or is already uppercase, this function returns `x`.
970+
*
971+
* \param x character value to check.
972+
* \returns capitalized version of x, or x if no conversion available.
973+
*
974+
* \threadsafety It is safe to call this function from any thread.
975+
*
976+
* \since This function is available since SDL 3.2.0.
977+
*}
978+
function SDL_toupper(x: cint): cint; cdecl;
979+
external SDL_LibName {$IFDEF DELPHI} {$IFDEF MACOS} name '_SDL_toupper' {$ENDIF} {$ENDIF};
980+
981+
{*
982+
* Convert low-ASCII English letters to lowercase.
983+
*
984+
* **WARNING**: Regardless of system locale, this will only convert ASCII
985+
* values 'A' through 'Z' to lowercase.
986+
*
987+
* This function returns the lowercase equivalent of `x`. If a character
988+
* cannot be converted, or is already lowercase, this function returns `x`.
989+
*
990+
* \param x character value to check.
991+
* \returns lowercase version of x, or x if no conversion available.
992+
*
993+
* \threadsafety It is safe to call this function from any thread.
994+
*
995+
* \since This function is available since SDL 3.2.0.
996+
*}
997+
function SDL_tolower(x: cint): cint; cdecl;
998+
external SDL_LibName {$IFDEF DELPHI} {$IFDEF MACOS} name '_SDL_tolower' {$ENDIF} {$ENDIF};
999+
9601000
(* -- Floating-point arithmetic functions -- *)
9611001

9621002
{*

0 commit comments

Comments
 (0)