PDA

View Full Version : how to align Qlabel with CHIbutton



kisha18d
25th November 2008, 01:00
hi everyone,im just new using QT and im not really familiar with the codes used. i just want to ask how can i align the label or text inside an image. Im using CHIButton for the image and Qlabel for the text inside. What i want to happen is that the label inside the image should not stepped out of the image.
Thanks in advance :)

spirit
25th November 2008, 07:21
for QLabel look at this description alignment content of QLabel (http://doc.trolltech.com/4.4/qlabel.html#alignment-prop).
I don't know what is CHIButton, but for QPushButton you can use style sheets (http://doc.trolltech.com/4.4/stylesheet.html).


QPushButton {
text-align: left;
}