sources/interface.cpp

changeset 49
9e0f26f020e1
parent 48
02009f1ec2b7
child 50
874bbfa55da8
equal deleted inserted replaced
48:02009f1ec2b7 49:9e0f26f020e1
483 int end = min<int> (displayString.length(), start + displayLength); 483 int end = min<int> (displayString.length(), start + displayLength);
484 assert (g_cursor >= start and g_cursor <= end); 484 assert (g_cursor >= start and g_cursor <= end);
485 485
486 // Render the input string 486 // Render the input string
487 mvhline (LINES - 2, 0, ' ', COLS); 487 mvhline (LINES - 2, 0, ' ', COLS);
488 mvprintw (y, prompt.length() + 1, "%s", displayString.chars()); 488 mvprintw (y, prompt.length() + 1, "%s", displayString.mid (start, end).chars());
489 489
490 // Render the prompt 490 // Render the prompt
491 attron (promptColor); 491 attron (promptColor);
492 mvprintw (y, 0, "%s", prompt.chars()); 492 mvprintw (y, 0, "%s", prompt.chars());
493 attroff (promptColor); 493 attroff (promptColor);

mercurial