summaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorRay <[email protected]>2023-04-17 12:18:06 +0200
committerRay <[email protected]>2023-04-17 12:18:06 +0200
commit9d38363e09aa8725415b444cde37a909d4d9d8a0 (patch)
tree317337c087ab5d271dff3edfb57f19680bdc05c9 /src
parente2da32e2daf2cf4de86cc1128a7b3ba66a1bab1c (diff)
downloadraylib-9d38363e09aa8725415b444cde37a909d4d9d8a0.tar.gz
raylib-9d38363e09aa8725415b444cde37a909d4d9d8a0.zip
Remove trailing spaces
Diffstat (limited to 'src')
-rw-r--r--src/rcore.c2
-rw-r--r--src/rtext.c12
2 files changed, 7 insertions, 7 deletions
diff --git a/src/rcore.c b/src/rcore.c
index b1632492..3f2a1df8 100644
--- a/src/rcore.c
+++ b/src/rcore.c
@@ -6949,7 +6949,7 @@ static void LoadAutomationEvents(const char *fileName)
/*
FILE *repFile = fopen(fileName, "rb");
unsigned char fileId[4] = { 0 };
-
+
fread(fileId, 1, 4, repFile);
if ((fileId[0] == 'r') && (fileId[1] == 'E') && (fileId[2] == 'P') && (fileId[1] == ' '))
diff --git a/src/rtext.c b/src/rtext.c
index 1d2b4f35..2df8be8d 100644
--- a/src/rtext.c
+++ b/src/rtext.c
@@ -697,18 +697,18 @@ Image GenImageFontAtlas(const GlyphInfo *chars, Rectangle **charRecs, int glyphC
// Calculate image size based on total glyph width and glyph row count
int totalWidth = 0;
int maxGlyphWidth = 0;
-
+
for (int i = 0; i < glyphCount; i++)
{
if (chars[i].image.width > maxGlyphWidth) maxGlyphWidth = chars[i].image.width;
totalWidth += chars[i].image.width + 2*padding;
}
-
+
int rowCount = 0;
int imageSize = 64; // Define minimum starting value to avoid unnecessary calculation steps for very small images
-
+
// NOTE: maxGlyphWidth is maximum possible space left at the end of row
- while (totalWidth > (imageSize - maxGlyphWidth)*rowCount)
+ while (totalWidth > (imageSize - maxGlyphWidth)*rowCount)
{
imageSize *= 2; // Double the size of image (to keep POT)
rowCount = imageSize/(fontSize + 2*padding); // Calculate new row count for the new image size
@@ -1240,7 +1240,7 @@ Vector2 MeasureTextEx(Font font, const char *text, float fontSize, float spacing
int GetGlyphIndex(Font font, int codepoint)
{
int index = 0;
-
+
#define SUPPORT_UNORDERED_CHARSET
#if defined(SUPPORT_UNORDERED_CHARSET)
int fallbackIndex = 0; // Get index of fallback glyph '?'
@@ -1249,7 +1249,7 @@ int GetGlyphIndex(Font font, int codepoint)
for (int i = 0; i < font.glyphCount; i++)
{
if (font.glyphs[i].value == 63) fallbackIndex = i;
-
+
if (font.glyphs[i].value == codepoint)
{
index = i;