You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit b35ec2a
Browse filesBrowse the repository at this point in the historyBrowse files
virtualvoidGLPrintText(constchar* s, float x, float y, float* color, float scale, uint32_t nCharacters) = 0;// nCharacters > 0: at most that many characters, otherwise until the terminating 0
if (maxChars <= 0 || line.size() <= (size_t)maxChars) {
38
+
print(line.c_str(), 0, 0);
39
+
continue;
40
+
}
41
+
constsize_t textStart = line.find(": ");
42
+
constsize_t indent = textStart != std::string::npos && textStart + 2 < (size_t)maxChars / 2 ? textStart + 2 : 0; // Continuation lines aligned with the text after the keys, if that leaves enough space
43
+
size_t pos = 0; // Start of the part not yet printed
44
+
for (bool first = true;; first = false) { // Wrap at the last space that fits, or hard if there is none (also if it is only in the keys)
45
+
constsize_t lineIndent = first ? 0 : indent, available = maxChars - lineIndent;
0 commit comments