Dialog
classin packageklyn.gui.windows
public class Dialog extends MainWindow:
└ Window
└ Dialog

Base class for standalone dialog windows.

A dialog owns the same themed content surface as a MainWindow, but is intended for short modal interactions. Specialized dialogs can compose their controls through centralWidget and run a nested event loop with run().

dialog = Dialog("Confirmation")
dialog.centralWidget.add(Label("Continue?"))
dialog.run()
Properties
Modifier and Type Member Description
public property modal
modal as Boolean = false
Whether this dialog is intended to block interaction with its owner while it is displayed.
Inherited Properties
propertyInherited Properties from MainWindow: centralWidget, menuBar
propertyInherited Properties from Window: appearanceMode, frame, title
propertyInherited Properties from Widget: accentColor, backgroundColor, borderColor, bottom, canFocus, cornerRadius, cursor, font, foregroundColor, hasFocus, height, isEnabled, isHovered, isManaged, isPressed, isTabStop, isVisible, layoutParams, margin, maxHeight, maxWidth, minHeight, minWidth, parent, preferredHeight, preferredWidth, resolvedStyleCache, resolvedStyleCacheAppearanceMode, resolvedStyleCacheFont, resolvedStyleCacheRevision, resolvedStyleCacheStateKey, resolvedStyleCacheStyleClass, resolvedStyleCacheZoomRevision, right, size, sizePolicy, styleClass, toolTip, width, window, x, y
Inherited Events
eventInherited Events from Window: closed
eventInherited Events from Widget: focusGained, focusLost, keyPressed, keyReleased, mouseMoved, mousePressed, mouseReleased, mouseWheel, paintRequested, resized
Constructors
Modifier and Type Member Description
public Dialog
Dialog(title as String = ""):
Creates an empty dialog window.
Inherited Methods
methodInherited Methods from MainWindow: applyLayout, applyTheme, paint, relayout, render, setBounds
methodInherited Methods from Window: adjustContentZoom, adjustFontZoom, applyContentZoom, applyLayout, applyNativeFrame, applyTheme, capture, capture, centerIn, close, copyToClipboard, emitClosed, readFromClipboard, relayout, render, repaint, repaintWidget, resetContentZoom, resetFontZoom, run, show, simulateMouseClick, simulateMousePressed, simulateMouseReleased, syncContentZoomSize, theme
methodInherited Methods from Widget: applyThemeMetrics, blur, containsPoint, emitFocusGained, emitFocusLost, emitKeyPressed, emitKeyReleased, emitMouseMoved, emitMousePressed, emitMouseReleased, emitMouseWheel, handleTabKey, notifyPaintRequested, paint, paintClipped, paintOverlay, preferredSizeIncludesContentZoom, repaint, requestFocus, resolvePreferredHeight, resolvePreferredWidth, resolvedFont, setBounds