[Core] Add z-index and string base to Render Commands (#227)

This commit is contained in:
Nic Barker 2025-01-26 15:28:35 +13:00 committed by GitHub
parent cb62db77e3
commit 0a703de69a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
14 changed files with 27 additions and 10 deletions

View file

@ -138,7 +138,7 @@ void Clay_Raylib_Render(Clay_RenderCommandArray renderCommands)
{
case CLAY_RENDER_COMMAND_TYPE_TEXT: {
// Raylib uses standard C strings so isn't compatible with cheap slices, we need to clone the string to append null terminator
Clay_String text = renderCommand->text;
Clay_StringSlice text = renderCommand->text;
char *cloned = (char *)malloc(text.length + 1);
memcpy(cloned, text.chars, text.length);
cloned[text.length] = '\0';