UI: tweak drawing of header status text for transparent headers.
This commit is contained in:
@@ -778,6 +778,21 @@ void BLI_str_toupper_ascii(char *str, const size_t len)
|
||||
str[i] -= 'a' - 'A';
|
||||
}
|
||||
|
||||
/**
|
||||
* Strip whitespace from end of the string.
|
||||
*/
|
||||
void BLI_str_rstrip(char *str)
|
||||
{
|
||||
for (int i = strlen(str) - 1; i > 0; i--) {
|
||||
if (isspace(str[i])) {
|
||||
str[i] = '\0';
|
||||
}
|
||||
else {
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Strip trailing zeros from a float, eg:
|
||||
* 0.0000 -> 0.0
|
||||
|
||||
Reference in New Issue
Block a user