mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 06:07:34 +00:00
Terminal+LibVT: Add "clear including history" action (Ctrl+Shift+K) :^)
Sometimes you just want to get rid of all your scrollback history in the terminal, and now there's a way to do that.
This commit is contained in:
parent
e8a59ef842
commit
0c4b0c0312
5 changed files with 27 additions and 0 deletions
|
@ -49,6 +49,14 @@ void Terminal::clear()
|
|||
set_cursor(0, 0);
|
||||
}
|
||||
|
||||
void Terminal::clear_including_history()
|
||||
{
|
||||
m_history.clear();
|
||||
clear();
|
||||
|
||||
m_client.terminal_history_changed();
|
||||
}
|
||||
|
||||
inline bool is_valid_parameter_character(u8 ch)
|
||||
{
|
||||
return ch >= 0x30 && ch <= 0x3f;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue