Add a text in scratch buffer to make it explicit it wont be saved

Fixes #2759
This commit is contained in:
Maxime Coste 2019-03-17 10:41:11 +11:00
parent da687f8b7d
commit f87e844244

View File

@ -82,7 +82,9 @@ Buffer& BufferManager::get_buffer(StringView name)
Buffer& BufferManager::get_first_buffer()
{
if (all_of(m_buffers, [](auto& b) { return (b->flags() & Buffer::Flags::Debug); }))
create_buffer("*scratch*", Buffer::Flags::None);
create_buffer("*scratch*", Buffer::Flags::None,
"*** this is a *scratch* buffer which wont be automatically saved ***\n"
"*** use it for notes or open a file buffer with the edit command ***\n");
return *m_buffers.back();
}