| 144 | } |
| 145 | |
| 146 | void Window_StringView::DrawCmdLines() { |
| 147 | Rect rect = GetItemRect(0); |
| 148 | contents->ClearRect(rect); |
| 149 | |
| 150 | contents->TextDraw(rect.x, rect.y, Font::ColorHeal, "Automatic line break: "); |
| 151 | contents->TextDraw(GetWidth() - 16, rect.y, Font::ColorCritical, auto_linebreak ? "[ON]" : "[OFF]", Text::AlignRight); |
| 152 | |
| 153 | rect = GetItemRect(1); |
| 154 | contents->ClearRect(rect); |
| 155 | |
| 156 | contents->TextDraw(rect.x, rect.y, Font::ColorHeal, "Command evaluation: "); |
| 157 | contents->TextDraw(GetWidth() - 16, rect.y, Font::ColorCritical, cmd_eval ? "[ON]" : "[OFF]", Text::AlignRight); |
| 158 | |
| 159 | #ifdef HAVE_NLOHMANN_JSON |
| 160 | if (this->json_data) { |
| 161 | rect = GetItemRect(2); |
| 162 | contents->ClearRect(rect); |
| 163 | |
| 164 | contents->TextDraw(rect.x, rect.y, Font::ColorHeal, "Pretty Print: "); |
| 165 | contents->TextDraw(GetWidth() - 16, rect.y, Font::ColorCritical, pretty_print ? "[ON]" : "[OFF]", Text::AlignRight); |
| 166 | } |
| 167 | #endif |
| 168 | } |
| 169 | |
| 170 | void Window_StringView::DrawLine(int index) { |
| 171 | Rect rect = GetItemRect(index + GetReservedLineCount()); |