Re: Qt Style Sheet Vs Code
Quote:
Originally Posted by
Ashutosh2k1
I want to do same effect as the style sheet do, through the code can it be possible? .
Yes. The stylesheets make use of a special Qt Style (cpp code), so you can check out how it is done.
Quote:
I explain the problem .Suppose for QPush Button there are different states (pseudo) like Hover checked etc .In the Qt Style sheet we can set the state and suppose change the background color . I want to do the same functionality through code Can it be possible
Yes.
Re: Qt Style Sheet Vs Code
Thanks
Can u Tell me where i will get the code
Re: Qt Style Sheet Vs Code
Re: Qt Style Sheet Vs Code
For changing background and other things through code, have a look at QPalette, and QWidget::setPalette