[Qt-interest] Elided rich text

KC Jones kc at asperasoft.com
Fri Feb 12 00:39:22 CET 2010


Anyone know any tricks that enable the use of QFontMetrics::elidedText()
with strings that contain HTML-like formatting tags?

In my testing is appears that elidedText() treats the string as a plain text
string (not sure about Unicode content) and any formatting tags, such as
"<span style='background-color:#8a8;padding:2px;'>blah blah blah</span>" are
treated as displayable text, yielding useless results.

Is this just a bug?  Seems like one to me,

This would not be an issue for me if QLabel would start supporting eliding
directly.  Hint, hint...
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.qt-project.org/pipermail/qt-interest-old/attachments/20100211/8ae6d251/attachment.html 


More information about the Qt-interest-old mailing list