diff options
author | Jacques Lucke <mail@jlucke.com> | 2019-03-07 14:01:32 +0300 |
---|---|---|
committer | Jacques Lucke <mail@jlucke.com> | 2019-03-07 14:02:27 +0300 |
commit | d617466d87863d75a83dd01e68da7228907f4656 (patch) | |
tree | 969ce7ef4618ad0c2ba0cc109ed9c1384d51b745 /source/blender/blenlib/BLI_string.h | |
parent | e25cdac24bc48cbb0f05f42b52e42adaaae63499 (diff) |
Refactor building the draw string for floats and ints
Differential Revision: https://developer.blender.org/D4466
Diffstat (limited to 'source/blender/blenlib/BLI_string.h')
-rw-r--r-- | source/blender/blenlib/BLI_string.h | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/source/blender/blenlib/BLI_string.h b/source/blender/blenlib/BLI_string.h index 91eefc0f5b1..831626b164b 100644 --- a/source/blender/blenlib/BLI_string.h +++ b/source/blender/blenlib/BLI_string.h @@ -111,6 +111,10 @@ int BLI_string_find_split_words( BLI_snprintf(dst, ARRAY_SIZE(dst), format, __VA_ARGS__) #define SNPRINTF_RLEN(dst, format, ...) \ BLI_snprintf_rlen(dst, ARRAY_SIZE(dst), format, __VA_ARGS__) +#define STR_CONCAT(dst, len, suffix) \ + len += BLI_strncpy_rlen(dst + len, suffix, ARRAY_SIZE(dst) - len) +#define STR_CONCATF(dst, len, format, ...) \ + len += BLI_snprintf_rlen(dst + len, ARRAY_SIZE(dst) - len, format, __VA_ARGS__) /** \} */ #ifdef __cplusplus |