[maemo-developers] Position of the icon in QListWidgetItem
From: Felipe Crochik felipe at crochik.comDate: Tue Oct 19 15:40:31 EEST 2010
- Previous message: Position of the icon in QListWidgetItem
 - Next message: Position of the icon in QListWidgetItem
 - Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
 
I haven't tried with a list item but with buttons you can reposition the
image using just style sheets. Be aware that you (can) have two images: the
background-image and the image. I used the background-image as an extra icon
so I could have an image on the left and one on the right.
Some examples from mycontacts style sheet:
PhoneButton[context="Home"] {
    image:
url(/opt/usr/share/icons/hicolor/48x48/hildon/general_presence_home.png);
    image-position: center right;
}
SMSButton {
    width: 60px;
    max-width: 60px;
    background-image:
url(/opt/usr/share/icons/hicolor/48x48/hildon/general_sms.png);
    background-position: center center;
}
I am sure you found this already but:
http://doc.trolltech.com/4.6/stylesheet-examples.html#customizing-qlistview
Felipe
-----Original Message-----
From: maemo-developers-bounces at maemo.org
[mailto:maemo-developers-bounces at maemo.org] On Behalf Of David Talmage
Sent: Tuesday, October 19, 2010 12:14 AM
To: maemo-developers at maemo.org
Subject: Position of the icon in QListWidgetItem
I need help placing an icon in a QListWidgetItem.  I want the icon to 
appear on the far right instead of the far left.  Can I do this with a 
style sheet?  Do I need to write a delegate instead?
This is for a contact chooser for Qt4.7 that behaves like the 
OssoABookContactChooser.
_______________________________________________
maemo-developers mailing list
maemo-developers at maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers
    - Previous message: Position of the icon in QListWidgetItem
 - Next message: Position of the icon in QListWidgetItem
 - Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
 
