Lagrange [release]

Text: Clear glyph cache when it fills up

=> 15263b2a311c32e7c7d8efe460a0f86e605928aa

diff --git a/src/ui/text.c b/src/ui/text.c
index ac2766a3..615cb176 100644
--- a/src/ui/text.c
+++ b/src/ui/text.c
@@ -369,7 +369,7 @@ static void initCache_Text_(iText *d) {
     init_Array(&d->cacheRows, sizeof(iCacheRow));
     const int textSize = d->contentFontSize * fontSize_UI;
     iAssert(textSize > 0);
-    const iInt2 cacheDims = init_I2(16, 80);
+    const iInt2 cacheDims = init_I2(16, 40);
     d->cacheSize = mul_I2(cacheDims, init1_I2(iMax(textSize, fontSize_UI)));
     SDL_RendererInfo renderInfo;
     SDL_GetRendererInfo(d->render, &renderInfo);
diff --git a/src/ui/window.c b/src/ui/window.c
index e1bb1c0b..6d358576 100644
--- a/src/ui/window.c
+++ b/src/ui/window.c
@@ -960,7 +960,7 @@ void draw_Window(iWindow *d) {
 #if 0
     /* Text cache debugging. */ {
         SDL_Texture *cache = glyphCache_Text();
-        SDL_Rect rect = { d->root->rect.size.x - 640, 0, 640, 5 * 640 };
+        SDL_Rect rect = { d->root->rect.size.x - 640, 0, 640, 2.5 * 640 };
         SDL_SetRenderDrawColor(d->render, 0, 0, 0, 255);
         SDL_RenderFillRect(d->render, &rect);
         SDL_RenderCopy(d->render, glyphCache_Text(), NULL, &rect);
Proxy Information
Original URL
gemini://git.skyjake.fi/lagrange/release/cdiff/15263b2a311c32e7c7d8efe460a0f86e605928aa
Status Code
Success (20)
Meta
text/gemini; charset=utf-8
Capsule Response Time
27.708006 milliseconds
Gemini-to-HTML Time
0.156833 milliseconds

This content has been proxied by September (ba2dc).