mirror of
https://github.com/nicbarker/clay.git
synced 2025-04-07 23:08:03 +00:00
[Core] Fix inverted condition for setting booleanWarnings.maxTextMeasureCacheExceeded (#275)
Some checks failed
CMake on multiple platforms / build (Release, cl, cl, windows-latest) (push) Has been cancelled
CMake on multiple platforms / build (Release, clang, clang++, ubuntu-latest) (push) Has been cancelled
CMake on multiple platforms / build (Release, gcc, g++, ubuntu-latest) (push) Has been cancelled
Some checks failed
CMake on multiple platforms / build (Release, cl, cl, windows-latest) (push) Has been cancelled
CMake on multiple platforms / build (Release, clang, clang++, ubuntu-latest) (push) Has been cancelled
CMake on multiple platforms / build (Release, gcc, g++, ubuntu-latest) (push) Has been cancelled
This commit is contained in:
parent
5afdf3f8c9
commit
766325c395
2
clay.h
2
clay.h
@ -1443,7 +1443,7 @@ Clay__MeasureTextCacheItem *Clay__MeasureTextCached(Clay_String *text, Clay_Text
|
||||
measured = Clay__MeasureTextCacheItemArray_Get(&context->measureTextHashMapInternal, newItemIndex);
|
||||
} else {
|
||||
if (context->measureTextHashMapInternal.length == context->measureTextHashMapInternal.capacity - 1) {
|
||||
if (context->booleanWarnings.maxTextMeasureCacheExceeded) {
|
||||
if (!context->booleanWarnings.maxTextMeasureCacheExceeded) {
|
||||
context->errorHandler.errorHandlerFunction(CLAY__INIT(Clay_ErrorData) {
|
||||
.errorType = CLAY_ERROR_TYPE_ELEMENTS_CAPACITY_EXCEEDED,
|
||||
.errorText = CLAY_STRING("Clay ran out of capacity while attempting to measure text elements. Try using Clay_SetMaxElementCount() with a higher value."),
|
||||
|
Loading…
Reference in New Issue
Block a user