From: Michael Orlitzky Date: Tue, 17 Oct 2023 14:22:35 +0000 (-0400) Subject: src/svgtiny_strings.h: intern a "userdata" key string X-Git-Url: https://gitweb.michael.orlitzky.com/?a=commitdiff_plain;h=464180cc828f82561012de3610743dc13c7bba54;p=libsvgtiny.git src/svgtiny_strings.h: intern a "userdata" key string To implement libcss's select handler API, we need to implement two functions that get/set "userdata" on a node. The corresponding libdom API allows you to set arbitrary data in the form of key->value pairs; so to identify THIS particular data, we need to use the same string each time. For that reason we intern "_libcss_user_data" and call it the "userdata_key". --- diff --git a/src/svgtiny_strings.h b/src/svgtiny_strings.h index 1dc3bca..c77dc59 100644 --- a/src/svgtiny_strings.h +++ b/src/svgtiny_strings.h @@ -57,5 +57,6 @@ SVGTINY_STRING_ACTION2(stop_color,stop-color) SVGTINY_STRING_ACTION2(zero_percent,0%) SVGTINY_STRING_ACTION2(hundred_percent,100%) SVGTINY_STRING_ACTION2(universal,*) +SVGTINY_STRING_ACTION2(userdata_key,_libcss_user_data) #undef SVGTINY_STRING_ACTION