Popup

Base container control for popups and dialogs.

Popup is a base Control used to show dialogs and popups. It's a subwindow and modal by default (see Control) and has helpers for custom popup behavior. All popup methods ensure correct placement within the viewport.

Members

Aliases

BaseClasses
alias BaseClasses = AliasSeq!(typeof(_GODOT_base), typeof(_GODOT_base).BaseClasses)
Undocumented in source.

Enums

Constants
enum Constants

Functions

isExclusive
bool isExclusive()
opAssign
typeof(null) opAssign(typeof(null) n)
opEquals
bool opEquals(Popup other)
opEquals
bool opEquals(typeof(null) n)
popup
void popup(Rect2 bounds)

Popup (show the control in modal form).

popupCentered
void popupCentered(Vector2 size)

Popup (show the control in modal form) in the center of the screen relative to its current canvas transform, at the current size, or at a size determined by size.

popupCenteredClamped
void popupCenteredClamped(Vector2 size, double fallback_ratio)

Popup (show the control in modal form) in the center of the screen relative to the current canvas transform, clamping the size to size, then ensuring the popup is no larger than the viewport size multiplied by fallback_ratio.

popupCenteredMinsize
void popupCenteredMinsize(Vector2 minsize)

Popup (show the control in modal form) in the center of the screen relative to the current canvas transform, ensuring the size is never smaller than minsize.

popupCenteredRatio
void popupCenteredRatio(double ratio)

Popup (show the control in modal form) in the center of the screen relative to the current canvas transform, scaled at a ratio of size of the screen.

setAsMinsize
void setAsMinsize()

Shrink popup to keep to the minimum size of content.

setExclusive
void setExclusive(bool enable)
toHash
size_t toHash()

Mixins

__anonymous
mixin baseCasts
Undocumented in source.

Properties

popupExclusive
bool popupExclusive [@property getter]
bool popupExclusive [@property setter]

If true, the popup will not be hidden when a click event occurs outside of it, or when it receives the ui_cancel action event. Note: Enabling this property doesn't affect the Close or Cancel buttons' behavior in dialogs that inherit from this class. As a workaround, you can use WindowDialog.getCloseButton or ConfirmationDialog.getCancel and hide the buttons in question by setting their CanvasItem.visible property to false.

Static functions

_new
Popup _new()

Construct a new instance of Popup. Note: use memnew!Popup instead.

Static variables

_classBindingInitialized
bool _classBindingInitialized;
Undocumented in source.

Structs

GDNativeClassBinding
struct GDNativeClassBinding
Undocumented in source.

Unions

__anonymous
union __anonymous
Undocumented in source.

Variables

_GODOT_internal_name
enum string _GODOT_internal_name;
Undocumented in source.

Mixed In Members

From mixin baseCasts

as
inout(To) as()
Undocumented in source. Be warned that the author may not have intended to support it.
as
inout(To) as()
Undocumented in source. Be warned that the author may not have intended to support it.
as
inout(ToRef) as()
Undocumented in source. Be warned that the author may not have intended to support it.
opCast
template opCast(To)
Undocumented in source.
opCast
template opCast(To)
Undocumented in source.
opCast
template opCast(ToRef)
Undocumented in source.
opCast
void* opCast()
Undocumented in source. Be warned that the author may not have intended to support it.
opCast
godot_object opCast()
Undocumented in source. Be warned that the author may not have intended to support it.
opCast
bool opCast()
Undocumented in source. Be warned that the author may not have intended to support it.

Meta