• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-R7000-V1.0.7.12_1.2.5/src/router/busybox-1.x/libbb/

Lines Matching defs:cursor

72 static unsigned cursor;
88 /* Put 'command_ps[cursor]', cursor++.
89 * Advance cursor on screen. If we reached right margin, scroll text up
93 int c = (unsigned char)command_ps[cursor];
123 // Huh? What if command_ps[cursor] == '\0' (we are at the end already?)
124 cursor++;
130 while (cursor < command_len)
160 if (num > cursor)
161 num = cursor;
164 cursor -= num;
189 cursor = 0;
202 printf("\033[J"); /* erase after cursor */
213 /* Delete the char in front of the cursor, optionally saving it
217 int j = cursor;
240 input_backward(cursor - j); /* back to old pos cursor */
251 ocursor = cursor;
253 memmove(command_ps + cursor + j, command_ps + cursor, command_len - cursor + 1);
254 strncpy(command_ps + cursor, delbuf, j);
257 input_backward(cursor - ocursor - j + 1); /* at end of new text */
261 /* Delete the char in back of the cursor */
264 if (cursor > 0) {
273 if (cursor < command_len)
274 cmdedit_set_out_char(command_ps[cursor + 1]);
741 * to the position of the cursor */
742 tmp = strncpy(matchBuf, command_ps, cursor);
743 tmp[cursor] = '\0';
813 command_ps[cursor - recalc_pos] = 0;
815 strcpy(matchBuf, command_ps + cursor);
823 recalc_pos = cursor + len_found;
835 int sav_cursor = cursor; /* change goto_new_line() */
985 while (cursor < command_len && !isspace(command[cursor]))
987 if (eat) while (cursor < command_len && isspace(command[cursor]))
994 if (isalnum(command[cursor]) || command[cursor] == '_') {
995 while (cursor < command_len
996 && (isalnum(command[cursor+1]) || command[cursor+1] == '_'))
998 } else if (ispunct(command[cursor])) {
999 while (cursor < command_len && ispunct(command[cursor+1]))
1003 if (cursor < command_len)
1006 if (eat && cursor < command_len && isspace(command[cursor]))
1007 while (cursor < command_len && isspace(command[cursor]))
1015 while (cursor < command_len && isspace(command[cursor]))
1017 while (cursor < command_len-1 && !isspace(command[cursor+1]))
1024 if (cursor >= command_len-1)
1027 while (cursor < command_len-1 && isspace(command[cursor]))
1029 if (cursor >= command_len-1)
1031 if (isalnum(command[cursor]) || command[cursor] == '_') {
1032 while (cursor < command_len-1
1033 && (isalnum(command[cursor+1]) || command[cursor+1] == '_')
1037 } else if (ispunct(command[cursor])) {
1038 while (cursor < command_len-1 && ispunct(command[cursor+1]))
1046 while (cursor > 0 && isspace(command[cursor-1]))
1048 while (cursor > 0 && !isspace(command[cursor-1]))
1055 if (cursor <= 0)
1058 while (cursor > 0 && isspace(command[cursor]))
1060 if (cursor <= 0)
1062 if (isalnum(command[cursor]) || command[cursor] == '_') {
1063 while (cursor > 0
1064 && (isalnum(command[cursor-1]) || command[cursor-1] == '_')
1068 } else if (ispunct(command[cursor])) {
1069 while (cursor > 0 && ispunct(command[cursor-1]))
1221 /* new y for current cursor */
1222 int new_y = (cursor + cmdedit_prmt_len) / w;
1224 redraw((new_y >= cmdedit_y ? new_y : cmdedit_y), command_len - cursor);
1354 input_backward(cursor);
1411 command[cursor] = 0;
1412 command_len = cursor;
1419 redraw(0, command_len - cursor);
1446 /* Control-U -- Clear line before cursor */
1447 if (cursor) {
1448 strcpy(command, command + cursor);
1449 command_len -= cursor;
1457 while (cursor > 0 && isspace(command[cursor-1]))
1459 while (cursor > 0 && !isspace(command[cursor-1]))
1468 input_backward(cursor);
1483 if (cursor > 0) {
1517 sc = cursor;
1523 input_backward(cursor);
1548 nc = cursor;
1549 input_backward(cursor - sc);
1550 while (nc-- > cursor)
1559 while (sc-- > cursor)
1567 while (cursor < command_len)
1585 *(command + cursor) = c;
1663 input_backward(cursor);
1700 if (cursor == (command_len - 1)) { /* Append if at the end of the line */
1701 command[cursor] = c;
1702 command[cursor+1] = '\0';
1705 int sc = cursor;
1710 /* rewrite from cursor */
1713 input_backward(cursor - sc);