script: Support translatable strings for properties
ClutterScript should be able to automatically call gettext() and friends on strings loaded from a UI definition, prior to passing the string to the object it is constructing. The basic implementation is trivial: - set a translation domain on the ClutterScript instance - mark the translatable strings inside the JSON data, like: "property" : { "translatable" : true, "string" : "a translatable string" } The hard part is now getting the tools we use to extract the translatable strings to understand the JSON format we use inside ClutterScript.
This commit is contained in:
@ -130,6 +130,9 @@ gboolean _clutter_script_parse_color (ClutterScript *script,
|
||||
ClutterColor *color);
|
||||
GObject *_clutter_script_parse_alpha (ClutterScript *script,
|
||||
JsonNode *node);
|
||||
gboolean _clutter_script_parse_translatable_string (ClutterScript *script,
|
||||
JsonNode *node,
|
||||
char **str);
|
||||
|
||||
void _clutter_script_construct_object (ClutterScript *script,
|
||||
ObjectInfo *oinfo);
|
||||
|
Reference in New Issue
Block a user