]> git.vomp.tv Git - vompclient.git/commitdiff
Bug fix, but was caught by other code. More efficient now.
authorChris Tallon <chris@vomp.tv>
Mon, 15 Aug 2022 13:40:43 +0000 (13:40 +0000)
committerChris Tallon <chris@vomp.tv>
Mon, 15 Aug 2022 13:40:43 +0000 (13:40 +0000)
src/boxx.cc
src/surfacevector.cc

index 956830213868531843b6b316b225615b3e9f938f..cc568669934c3daf68ad659768fc0ae5b1e2ca76 100644 (file)
@@ -338,7 +338,7 @@ int Boxx::drawPara(const char* text, int x, int y, const DrawStyle& colour, unsi
       if (charwidtharray)
       {
         thisCharWidth = charwidtharray[cur_char & 0xFF];
-        if (cur_char && 0xFFFFFF00) thisCharWidth = osdv->getCharWidth(cur_char);
+        if (cur_char & 0xFFFFFF00) thisCharWidth = osdv->getCharWidth(cur_char);
       }
       else
       {
index a02dd18d220697550a3af0815cb2eb15129c7711..aec6b93aed61ad22d1521ba4e38900bbe82d8495 100644 (file)
@@ -108,7 +108,7 @@ int SurfaceVector::drawText(const char* text, int x, int y, int width, const Dra
 
     float cur_shift = charwidtharray[tempo & 0xFF];
 
-    if (tempo && 0xFFFFFF00) cur_shift = osd->getCharWidth(tempo);
+    if (tempo & 0xFFFFFF00) cur_shift = osd->getCharWidth(tempo);
 
     shift += cur_shift;
     length -= num_bytes;