diff --git a/src/raygui.h b/src/raygui.h index 8c19cd1..5c0bc60 100644 --- a/src/raygui.h +++ b/src/raygui.h @@ -2991,9 +2991,9 @@ int GuiSliderPro(Rectangle bounds, const char *textLeft, const char *textRight, if (*value > maxValue) *value = maxValue; else if (*value < minValue) *value = minValue; } - + // Control value change check - if(oldValue == *value) result = 0; + if (oldValue == *value) result = 0; else result = 1; // Slider bar limits check @@ -4829,7 +4829,7 @@ static void GuiDrawText(const char *text, Rectangle textBounds, int alignment, C if (guiFont.glyphs[index].advanceX == 0) glyphWidth = ((float)guiFont.recs[index].width*scaleFactor); else glyphWidth = (float)guiFont.glyphs[index].advanceX*scaleFactor; - // Wrap mode text measuring, to validate if + // Wrap mode text measuring, to validate if // it can be drawn or a new line is required if (wrapMode == TEXT_WRAP_CHAR) { @@ -4889,7 +4889,9 @@ static void GuiDrawText(const char *text, Rectangle textBounds, int alignment, C else if (!overflowReached) { overflowReached = true; - for (int j = 0; j < ellipsisWidth; j += ellipsisWidth/3) { + + for (int j = 0; j < ellipsisWidth; j += ellipsisWidth/3) + { DrawTextCodepoint(guiFont, '.', RAYGUI_CLITERAL(Vector2){ textBoundsPosition.x + textOffsetX + j, textBoundsPosition.y + textOffsetY }, (float)GuiGetStyle(DEFAULT, TEXT_SIZE), GuiFade(tint, guiAlpha)); } } @@ -5506,21 +5508,21 @@ static int GetCodepointNext(const char *text, int *codepointSize) if (0xf0 == (0xf8 & ptr[0])) { // 4 byte UTF-8 codepoint - if(((ptr[1] & 0xC0) ^ 0x80) || ((ptr[2] & 0xC0) ^ 0x80) || ((ptr[3] & 0xC0) ^ 0x80)) { return codepoint; } //10xxxxxx checks + if (((ptr[1] & 0xC0) ^ 0x80) || ((ptr[2] & 0xC0) ^ 0x80) || ((ptr[3] & 0xC0) ^ 0x80)) { return codepoint; } //10xxxxxx checks codepoint = ((0x07 & ptr[0]) << 18) | ((0x3f & ptr[1]) << 12) | ((0x3f & ptr[2]) << 6) | (0x3f & ptr[3]); *codepointSize = 4; } else if (0xe0 == (0xf0 & ptr[0])) { // 3 byte UTF-8 codepoint */ - if(((ptr[1] & 0xC0) ^ 0x80) || ((ptr[2] & 0xC0) ^ 0x80)) { return codepoint; } //10xxxxxx checks + if (((ptr[1] & 0xC0) ^ 0x80) || ((ptr[2] & 0xC0) ^ 0x80)) { return codepoint; } //10xxxxxx checks codepoint = ((0x0f & ptr[0]) << 12) | ((0x3f & ptr[1]) << 6) | (0x3f & ptr[2]); *codepointSize = 3; } else if (0xc0 == (0xe0 & ptr[0])) { // 2 byte UTF-8 codepoint - if((ptr[1] & 0xC0) ^ 0x80) { return codepoint; } //10xxxxxx checks + if ((ptr[1] & 0xC0) ^ 0x80) { return codepoint; } //10xxxxxx checks codepoint = ((0x1f & ptr[0]) << 6) | (0x3f & ptr[1]); *codepointSize = 2; }