I'd like to save the visibility state of a QDockWidget, when the dialog is closed. Even though, the widget is visible, isVisible will return false. 
What to do?
Using Python (2.7 in my case)
This might be the problem: 
Maybe you call isVisible() from an onClose()-function. Means, your Widget was visible, but is not anymore, when you finally call the isVisible() function
Solution
Call isVisibleTo([ParentWidget]). This will give you the visibility value relative to e.g. your QMainWindow.
Python Qt: Check visibility of widget / isVisible always return false