Makes /clear behavior configurable.

This commit is contained in:
Spiridonov Alexander
2016-11-07 03:26:15 +03:00
parent 0d6aef68e7
commit fd2346ccb4
3 changed files with 9 additions and 0 deletions

View File

@@ -562,6 +562,11 @@ win_sub_page_up(ProfWin *window)
void
win_clear(ProfWin *window)
{
if (!prefs_get_boolean(PREF_CLEAR_PERSIST_HISTORY)) {
werase(window->layout->win);
return;
}
int y = getcury(window->layout->win);
int *page_start = &(window->layout->y_pos);
*page_start = y;