| 1143 | } |
| 1144 | |
| 1145 | static char InputWidget_GetLastCol(struct InputWidget* w, int x, int y) { |
| 1146 | cc_string line; char lineBuffer[STRING_SIZE]; |
| 1147 | char col; |
| 1148 | String_InitArray(line, lineBuffer); |
| 1149 | |
| 1150 | for (; y >= 0; y--) { |
| 1151 | line.length = 0; |
| 1152 | InputWidget_FormatLine(w, y, &line); |
| 1153 | |
| 1154 | col = Drawer2D_LastColor(&line, x); |
| 1155 | if (col) return col; |
| 1156 | if (y > 0) { x = w->lines[y - 1].length; } |
| 1157 | } |
| 1158 | return '\0'; |
| 1159 | } |
| 1160 | |
| 1161 | static void InputWidget_UpdateCaret(struct InputWidget* w) { |
| 1162 | static const cc_string caret = String_FromConst("_"); |
no test coverage detected