Initial dialog position

An x::w::create_dialog_args or a x::w::standard_dialog_args object specifies a new dialog's settings. toolboxlayoutmanager.C uses a screen_position() method to explicitly specify where the new dialog opens:

args.restore(x::w::dialog_position::on_the_left);

A x::w::dialog_position places the new dialog next to one of the main window's borders. It's possible to place only one dialog on each border, intelligently.

Note

Showing a dialog together with its main window requires using the on_stabilized() callback, for reliable dialog positioning.

toolbox_dialog->set_dialog_position(x::w::dialog_position::on_the_left);

Calling an existing x::w::dialog's set_dialog_position() with an x::w::dialog_position resets the dialog's default position. This is effective only when the dialog is not shown, and has no effect for visible dialogs.