ControlSetMarginsPreset Method |
Sets the margins to a preset from ControlLayoutPreset enum. This is code equivalent of using the Layout menu in 2D editor.
Use parameter resize_mode with constants from ControlLayoutPresetMode to better determine the resulting size of the Control. Constant size will be ignored if used with presets that change size, e.g. PRESET_LEFT_WIDE.
Use parameter margin to determine the gap between the Control and the edges.
Namespace: Godot
public void SetMarginsPreset( ControlLayoutPreset preset, ControlLayoutPresetMode resizeMode = ControlLayoutPresetMode.Minsize, int margin = 0 )
[Missing <param name="preset"/> documentation for "M:Godot.Control.SetMarginsPreset(Godot.Control.LayoutPreset,Godot.Control.LayoutPresetMode,System.Int32)"]
[Missing <param name="resizeMode"/> documentation for "M:Godot.Control.SetMarginsPreset(Godot.Control.LayoutPreset,Godot.Control.LayoutPresetMode,System.Int32)"]
[Missing <param name="margin"/> documentation for "M:Godot.Control.SetMarginsPreset(Godot.Control.LayoutPreset,Godot.Control.LayoutPresetMode,System.Int32)"]