Results 1 to 2 of 2

Thread: Style Sheet Question

  1. #1
    Join Date
    Dec 2008
    Location
    Istanbul, TURKEY
    Posts
    537
    Qt products
    Qt4
    Platforms
    Windows Android
    Thanks
    14
    Thanked 13 Times in 13 Posts

    Default Style Sheet Question

    Hi,

    As far as I know a widget does not inherit it's parent style sheets as the documentation says as well;

    When using Qt Style Sheets, a widget does not automatically inherit its font and color setting from its parent widget.
    But in the "Cascading" part of the document it says;

    An arbitrary widget's effective style sheet is obtained by merging the style sheets set on the widget's ancestors (parent, grandparent, etc.), as well as any style sheet set on the QApplication.
    Here it says a widget can inherit the style sheet. So what's the deal here?

    Thanks from advance..

  2. #2
    Join Date
    Jan 2012
    Location
    Dortmund, Germany
    Posts
    159
    Qt products
    Qt4
    Platforms
    Windows Android
    Thanks
    69
    Thanked 10 Times in 8 Posts

    Default Re: Style Sheet Question

    It depends on the selector type you are using when setting the style sheet. Read here:
    StyleSheet Syntax

Similar Threads

  1. Style sheet related question
    By chandan in forum Newbie
    Replies: 1
    Last Post: 7th May 2010, 16:51
  2. Problems with Gradient style used through Style sheet on ARM platform
    By puneet.narsapur in forum Qt for Embedded and Mobile
    Replies: 0
    Last Post: 25th January 2010, 13:48
  3. qt 4 color palette / style sheet question
    By killerwookie99 in forum Qt Programming
    Replies: 1
    Last Post: 7th November 2008, 00:05
  4. style sheet issue.
    By kaushal_gaurav in forum Qt Programming
    Replies: 2
    Last Post: 7th August 2008, 08:18
  5. How to use style sheet
    By safknw in forum Qt Programming
    Replies: 1
    Last Post: 20th November 2006, 14:05

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Qt is a trademark of The Qt Company.