Update RingRayLib - raylib.c - Add Function : const char *TextFormat(const char *text)
@@ -4348,6 +4348,20 @@ RING_FUNC(ring_TextCountCodepoints)
RING_API_RETNUMBER(TextCountCodepoints(RING_API_GETSTRING(1)));
}
+
+RING_FUNC(ring_TextFormat)
+{
+ if ( RING_API_PARACOUNT != 1 ) {
+ RING_API_ERROR(RING_API_MISS1PARA);
+ return ;
+ }
+ if ( ! RING_API_ISSTRING(1) ) {
+ RING_API_ERROR(RING_API_BADPARATYPE);
+ return ;
+ }
+ RING_API_RETSTRING(TextFormat(RING_API_GETSTRING(1)));
+}
+
RING_API void ringlib_init(RingState *pRingState)
{
ring_vm_funcregister("initwindow",ring_InitWindow);
@@ -4598,4 +4612,5 @@ RING_API void ringlib_init(RingState *pRingState)
ring_vm_funcregister("textisequal",ring_TextIsEqual);
ring_vm_funcregister("textlength",ring_TextLength);
ring_vm_funcregister("textcountcodepoints",ring_TextCountCodepoints);
+ ring_vm_funcregister("textformat",ring_TextFormat);
}
