[PyKDE] QTextBrowser Alignment

Peter Osborne pete at bookware3000.ca
Thu May 9 20:35:00 BST 2002


Hi All,

I'm trying to layout some text in a QTextBrowser and cannot figure out how to 
do it. I'm simply trying to set the alignment to right justify the text.

Just for overkill, I tried this:

self.totalView.setAlignment(Qt.AlignRight)
self.totalView.insert("Total"+chr(9)+"$0.00")
self.totalView.setAlignment(Qt.AlignRight)

Which doesn't work. What I would really like is a way to set a Right Tab at a 
certain point so that all the dollar values will right justify to the right 
edge while the descriptions will stay left justified. Can someone help me 
out?

I looked through the PyQt book but couldn't find anything.

Thanks,
Pete




More information about the PyQt mailing list