How can you dynamically set the orientation of a widget? I am implementing a QDockWidget with a widget for it's header, and I need to set up the header widget so that when the header orientation is changed in the dock widget, it changes the orientation of it's children (a label and an icon). The text will need to be rendered on it's side( rotated by either 90 or -90 degrees). The Qt doc's aren't very helpful in this regard I'm afraid.

Thanks in advance.