Line data Source code
1 : #include "textwidget.hpp" 2 : 3 : namespace qtreports 4 : { 5 : namespace detail 6 : { 7 : 8 185 : TextWidget::TextWidget() {} 9 : 10 185 : TextWidget::~TextWidget() {} 11 : 12 2177 : void TextWidget::setText( const QString & text ) 13 : { 14 2177 : m_text = text; 15 2177 : } 16 : 17 2454 : const QString TextWidget::getText() const 18 : { 19 2454 : return m_text.isEmpty() ? m_originalText : m_text; 20 : } 21 : 22 185 : void TextWidget::setOriginalText( const QString & text ) 23 : { 24 185 : m_originalText = text; 25 185 : } 26 : 27 697 : const QString TextWidget::getOriginalText() const 28 : { 29 697 : return m_originalText; 30 : } 31 : 32 : } 33 : }