refactor: Drop tokenized labels

Handle placeholder tokens inside each label
instead of cloning into a new instance each time
This commit is contained in:
Michael Carlberg 2016-10-19 01:26:17 +02:00
parent 37e367eb79
commit 68f72d69cc
19 changed files with 185 additions and 209 deletions
include/components

View file

@ -154,7 +154,7 @@ class builder {
if (!label || !*label)
return;
auto text = label->m_text;
auto text = label->get();
if (label->m_maxlen > 0 && text.length() > label->m_maxlen) {
text = text.substr(0, label->m_maxlen) + "...";