You might take a look at so called "Selector types" (<a href="http://qt.nokia.com/doc/4.3/stylesheet-syntax.html#selector-types">http://qt.nokia.com/doc/4.3/stylesheet-syntax.html#selector-types</a>). Given a QDialog and its children (e.g. QPushButtons), this can prevent this cascading behaviour of styles, although I've never had any problems with that without using this way of "selecting" matching objects..<div>
<br></div><div>Can you show a small piece of code (small stylesheet and the way you apply it) please?</div><div><br><div class="gmail_quote">On Tue, Mar 9, 2010 at 9:05 PM, Jebagnana Das <span dir="ltr"><<a href="mailto:jebagnanadas@gmail.com">jebagnanadas@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;"><p>Hello all,</p>
<p>If i apply a property to a parent widget it is automatically applied
for child widgets too.. Is there any way of preventing this?? <br></p><p>For
example if i set background color as white in a dialog then any button,combo
boxes and scroll bars(within the dialog) looks white and it lacks it's native look(have to
say it's unpleasant to the eyes(esp. in unix) & ugly).. Is there any way that i can apply the
stylesheets only to a parent widget not to it's children? can i exclude specifically some child widgets from not inheriting parent SS properties??<br></p>
<br>_______________________________________________<br>
PyQt mailing list <a href="mailto:PyQt@riverbankcomputing.com">PyQt@riverbankcomputing.com</a><br>
<a href="http://www.riverbankcomputing.com/mailman/listinfo/pyqt" target="_blank">http://www.riverbankcomputing.com/mailman/listinfo/pyqt</a><br></blockquote></div><br><br clear="all"><br>-- <br>Nick Gaens<br>
</div>