[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    KDE/kdepim/kleopatra/utils
From:       Frank Osterfeld <frank.osterfeld () kdemail ! net>
Date:       2008-04-18 12:30:06
Message-ID: 1208521806.542642.30821.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 798489 by osterfeld:

escape arguments for tooltips twice. For whatever reason this is needed to display \
E-Mail addresses like "<foo@bar.com>" correctly (otherwise interpreted as tag). \
Actually escaping once should be enough. Qt bug?

 M  +3 -1      formatting.cpp  


--- trunk/KDE/kdepim/kleopatra/utils/formatting.cpp #798488:798489
@@ -133,7 +133,9 @@
 	return i18n( "<tr><th>%1:</th><td>%2</td></tr>", field, arg );
     }
     QString format_row( const QString & field, const QString & arg ) {
-	return i18n( "<tr><th>%1:</th><td>%2</td></tr>", field, Qt::escape( arg ) );
+    // ### strings like <foo@bar.com> are only not interpreted as HTML tag if \
escaped twice +    // happened Qt 4.3.3 and Qt 4.4rc1. Change back to one escape() \
call if you see entities like &lt; in tooltips +        return i18n( \
"<tr><th>%1:</th><td>%2</td></tr>", field, Qt::escape( Qt::escape( arg ) ) );  }
     QString format_row( const QString & field, const char * arg ) {
 	return format_row( field, QString::fromUtf8( arg ) );


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic