Rework TextDrawer interface
This commit is contained in:
@@ -13,7 +13,7 @@ namespace Nz
|
||||
Layout();
|
||||
}
|
||||
|
||||
void RichTextAreaWidget::AppendText(const std::string& text)
|
||||
void RichTextAreaWidget::AppendText(std::string_view text)
|
||||
{
|
||||
//m_text += text;
|
||||
switch (m_echoMode)
|
||||
@@ -132,7 +132,7 @@ namespace Nz
|
||||
UpdateDisplayText();
|
||||
}
|
||||
|
||||
void RichTextAreaWidget::Write(const std::string& text, std::size_t glyphPosition)
|
||||
void RichTextAreaWidget::Write(std::string_view text, std::size_t glyphPosition)
|
||||
{
|
||||
if (m_drawer.HasBlocks())
|
||||
{
|
||||
|
||||
@@ -39,7 +39,7 @@ namespace Nz
|
||||
Layout();
|
||||
}
|
||||
|
||||
void TextAreaWidget::AppendText(const std::string& text)
|
||||
void TextAreaWidget::AppendText(std::string_view text)
|
||||
{
|
||||
m_text += text;
|
||||
|
||||
@@ -113,7 +113,7 @@ namespace Nz
|
||||
SetText(newText);
|
||||
}
|
||||
|
||||
void TextAreaWidget::Write(const std::string& text, std::size_t glyphPosition)
|
||||
void TextAreaWidget::Write(std::string_view text, std::size_t glyphPosition)
|
||||
{
|
||||
if (glyphPosition >= m_drawer.GetGlyphCount())
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user