QScriptValue PHILabelItem::html( const QScriptValue &t ) { if ( !t.isValid() ) return realText(); setHtmlText( true ); setText( t.toString() ); return self(); }
QScriptValue PHILabelItem::text( const QScriptValue &t ) { if ( !t.isValid() ) { QString s=realText(); return s.replace( QRegExp( L1( "<[^>]*>" ) ), QString() ); } setText( t.toString() ); setHtmlText( false ); return self(); }
void TextField::setHtmlText(const std::wstring& str) { setHtmlText(ws2utf8(str.c_str())); }