How to save dialog position in preferences and open dialog in specific x+y position?

hi, i’m running around with a bunch of dialogs and would love to be able to, upon close dialog, somehow retain their positioning, and then make sure that the dialog opens in that position when reopened. is this possible, or does every lua dialog always start solidly in the center of everything?