Hello,
How to make a QString text underlined?
for example:
you@gmail.com --> you@gmail.com
Thank you!
-B
Hello,
How to make a QString text underlined?
for example:
you@gmail.com --> you@gmail.com
Thank you!
-B
QString is a string... just a type. Where do you want to underlyne it? where do you want to show the text? (QLabel, QGraphicsTextItem...)
in QLineEdit
In that case I'd say one possible solution is styleSheet property.
try this:
QString underline("<u>abc</u>");
I think you have to use QWidget::setStyle or QWidget::styleSheet
Example: change the backgroundcolor in a QLabel.
Qt Code:
mylabel->setStyleSheet(strStyle);To copy to clipboard, switch view to plain text mode
maratk1n (24th November 2017)
Bookmarks