From 5ddf0921d845344713355bfbfbf37e46e0497209 Mon Sep 17 00:00:00 2001 From: Oleksii Bulba Date: Fri, 20 Dec 2024 20:46:51 +0400 Subject: [PATCH] Fix for Cairo renderer --- renderers/cairo/clay_renderer_cairo.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/renderers/cairo/clay_renderer_cairo.c b/renderers/cairo/clay_renderer_cairo.c index 7d4c08d..33a2acd 100644 --- a/renderers/cairo/clay_renderer_cairo.c +++ b/renderers/cairo/clay_renderer_cairo.c @@ -42,16 +42,16 @@ typedef struct caito_t Clay_Renderer_Data; //////////////////////////////// // -// Public API +// Public API (defined in clay_renderer.h) // // Initialize the internal cairo pointer with the user provided instance. // This is REQUIRED before calling Clay_Renderer_Render. -void Clay_Renderer_Initialize(struct Clay_Renderer_Data *cairo); +// void Clay_Renderer_Initialize(struct Clay_Renderer_Data *cairo); // Render the command queue to the `cairo_t*` instance you called // `Clay_Renderer_Initialize` on. -void Clay_Renderer_Render(Clay_RenderCommandArray commands); +// void Clay_Renderer_Render(Clay_RenderCommandArray commands); //////////////////////////////// @@ -84,7 +84,7 @@ static inline char *Clay_Cairo__NullTerminate(Clay_String *str) { } // Measure text using cairo's *toy* text API. -inline Clay_Dimensions Clay_Renderer_MeasureText(Clay_String *str, Clay_TextElementConfig *config) { +Clay_Dimensions Clay_Renderer_MeasureText(Clay_String *str, Clay_TextElementConfig *config) { // Edge case: Clay computes the width of a whitespace character // once. Cairo does not factor in whitespaces when computing text // extents, this edge-case serves as a short-circuit to introduce