If you use layouts then calling setGeometry is a no-op as the layout will override it.