Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions graf3d/gl/src/TGLFontManager.cxx
Original file line number Diff line number Diff line change
Expand Up @@ -188,6 +188,15 @@ void TGLFont::RenderHelper(const Char *txt, Double_t x, Double_t y, Double_t ang
glPushMatrix();
//glLoadIdentity();

#ifndef BUILTIN_FTGL
// https://github.com/root-project/root/issues/22076#issuecomment-4342764706
char* vtxt = (char*)txt; // cast away const
const auto len = strlen(vtxt);
for(auto i = 0UL; i < len; ++i)
if (static_cast<unsigned char>(vtxt[i]) > static_cast<unsigned char>('\277'))
vtxt[i] = '\277';
#endif

// FTGL is not const correct.
Float_t llx = 0.f, lly = 0.f, llz = 0.f, urx = 0.f, ury = 0.f, urz = 0.f;
BBox(txt, llx, lly, llz, urx, ury, urz);
Expand Down
Loading