Weird stylesheet behavior for ui form designer

  • Hello everyone,
    while I was trying to edit a QLabel, i really don't know why it happened so but everything (qlabels, qpushbuttons, qspinbox and even my custom qpushbuttons) had the same style sheet. I know that while setting stylesheet programmatically, using QLabel {} etc. affects stylesheets target, but this is in form designer. Stylesheet of all of the affected elements have their stylesheet field empty. I deleted the tested label but nothing changed. Beside, I tried to search about the issue over the internet but keywords are so generic, i couldn't reach any information that is useful. Any help will be appreciated.

    Even setting these ui elements' stylesheet smtg. else programmatically does not fix this.

    Thanks in advance,


  • How about the styleSheet of "VideoMonitoringForm"?
    The styleSheet you set on a widget will also apply to all his children.

  • @Bonnie Wouv that's it! You ve got the point. It seems that i clicked over an empty field next to my qlabel (which corresponds the form) and then set its stylesheet but i didn't notice that it is not my qlabel.

    With your correct answer, my question now seems to be a very foolish one :) but thanks a lot, you saved my day

Log in to reply