Attention: Here be dragons

This is the latest (unstable) version of this documentation, which may document features not available in or compatible with released stable versions of Godot.

ConfirmationDialog

Inherits: AcceptDialog < Window < Viewport < Node < Object

Inherited By: EditorCommandPalette, EditorFileDialog, FileDialog, ScriptCreateDialog

Dialog for confirmation of actions.

Description

Dialog for confirmation of actions. This dialog inherits from AcceptDialog, but has by default an OK and Cancel button (in host OS order).

To get cancel action, you can use:

get_cancel_button().pressed.connect(self.canceled)

Properties

String

cancel_button_text

"Cancel"

Vector2i

min_size

Vector2i(200, 70) (overrides Window)

Vector2i

size

Vector2i(200, 100) (overrides Window)

String

title

"Please Confirm..." (overrides Window)

Methods

Button

get_cancel_button ( )


Property Descriptions

String cancel_button_text = "Cancel"

  • void set_cancel_button_text ( String value )

  • String get_cancel_button_text ( )

The text displayed by the cancel button (see get_cancel_button).


Method Descriptions

Button get_cancel_button ( )

Returns the cancel button.

Warning: This is a required internal node, removing and freeing it may cause a crash. If you wish to hide it or any of its children, use their CanvasItem.visible property.