center gywindow correctly when width or height are specified