[Interest] [Qt-interest] How to stop changed font propagation to children
Tony Rietwyk
tony at rightsoft.com.au
Fri Nov 4 00:12:05 CET 2011
> Sent: Friday, 4 November 2011 4:22 AM
>
> > Hi,
> >
> > eg. QGroupBox, or QMainWindow ... when I change font size I don't want
> > to propagate such changes to children ... any way to do so ?
>
> hm...seem that if child widget font is not default one then parent doesn't
do
> that, but otherwise it changes child's font .... and no way to stop it.
> QEvent::FontChange doesn't trigger in order parent,children but
> children,parent and there's no way to get out why FontChange comes
> (because it's changed for widget itself or parent does that change).
> Anyone have idea how to fix this problem ?
>
> zeljko
Hi,
If you change the font via style sheet, then you can restrict it to
QGroupBox or QMainWindow only, or even by objectName.
Hope that helps,
Tony
More information about the Interest
mailing list