Search code examples
c++qtrichtextqlabel

Qt QLabel rich text tabulation


I have QLabel with rich text containing HTML anchor tag. I need to make tabulation in this tag's text, i.e. to get my QLabel displaying something like this: "This is"\t"example", where "\t" is tabulation symbol. I've tried to use QString's '\t' control symbol, tried to use RTF's "\tab"-tag, but nothing helps. Qt docs say that there is no tabulation tag in supported HTML subset. It only works if I use "pre" - tag, but it modifies the font of my text, I don't want that.

Is there another way to achieve my goal?

Thanks in advance.


Solution

  • You can use   characters maybe.