dialog autosizing + centering including margin specification