DesktopWindowCapabilities enum

Namespace Runic.Desktop in Runic.Desktop 0.23.0

public enum DesktopWindowCapabilities

Identifies a platform-window operation reported by a presentation.

Remarks

Open: a later minor release can add operations, so test for the flags you use.

Values

None

None = 0

No platform-window operation is available.

NativeHandle

NativeHandle = 1

The presentation exposes its native top-level window handle.

Focus

Focus = 2

The window can be activated and focused.

Minimize

Minimize = 4

The window can be minimized.

Maximize

Maximize = 8

The window can be maximized and restored.

Resize

Resize = 16

The window can be resized.

Move

Move = 32

The window can be moved to a screen position.

CloseConfirmation

CloseConfirmation = 64

User close requests can be confirmed by DesktopWindowOptions.ConfirmCloseAsync.

Announcements

Announcements = 128

The window can ask the screen reader to announce a message (DesktopWindow.AnnounceAsync).

State

State = 256

The window reports its bounds, maximized and full-screen state (DesktopWindow.State and DesktopWindow.StateChanged), and applies DesktopWindowOptions.Placement.

FileDrop

FileDrop = 512

The window reports files the user drops onto it, with their native paths (DesktopWindow.FilesDropped).

Visibility

Visibility = 1024

The window can be hidden and shown again without closing it (DesktopWindow.SetVisibleAsync, DesktopWindow.HideAsync and DesktopWindow.ShowAsync). Every embedded window reports it.

MenuBar = 2048

The window can show DesktopHostOptions.MenuBar natively, in the window or in a global menu bar (DesktopWindow.MenuBarPlacement). A window host factory that reports it in IDesktopWindowHostFactory.Capabilities keeps DesktopHost.Validate from reporting menu-bar-unsupported.

ContextMenu

ContextMenu = 4096

The window can show native context menus (DesktopWindow.ShowContextMenuAsync).

FullScreen

FullScreen = 8192

The window can enter and leave full screen (DesktopWindow.SetFullScreenAsync), and opens full-screen from a DesktopWindowPlacement.FullScreen placement.

MonitorPlacement

MonitorPlacement = 16384

The window can be placed on a chosen monitor: DesktopWindow.MoveToMonitorAsync and DesktopWindowOptions.MonitorId. Wayland lets no application position its windows, so GTK windows there do not report it.

FileDrag

FileDrag = 32768

The window can start native drags of files, text and URIs out of it (DesktopWindow.StartDragAsync).

Activity

Activity = 65536

The window reports whether it is active, minimized and visible (DesktopWindow.Activity and DesktopWindow.ActivityChanged).

ColorScheme

ColorScheme = 131072

The window changes its light or dark appearance while it is open (DesktopWindow.SetColorSchemeAsync).

PerWindowColorScheme

PerWindowColorScheme = 262144

DesktopWindow.SetColorSchemeAsync changes this window only. Without it, but with DesktopWindowCapabilities.ColorScheme, the scheme is shared: on Linux by every GTK window of the process, on Windows by the windows that share a WebView2 profile (DesktopWindowOptions.ProfilePath), and a call changes all of them.

Ownership

Ownership = 524288

The window can be opened owned by another window and window-modal to it (DesktopWindowOptions.Owner and DesktopWindowOptions.Modality), and can own windows itself.

LayoutDirection

LayoutDirection = 1048576

The window changes the direction of its native parts while it is open (DesktopWindow.SetLayoutDirectionAsync): on Windows its frame, caption buttons, system menu and menu bar, on Linux the GTK window and Runic's widgets in it.

Bounds

Bounds = 2097152

The window reports its frame in exact native units and the frame the user sees (DesktopWindowState.Bounds and DesktopWindowState.VisibleBounds), and moves and resizes in one native operation (DesktopWindow.SetBoundsAsync). On Wayland, which lets no application position its windows, GTK windows report it for the size alone.

MinimumSize

MinimumSize = 4194304

The window's minimum size can change while it is open (DesktopWindow.SetMinimumSizeAsync).

Placement

Placement = 8388608

The open window maximizes and restores on request, idempotently (DesktopWindow.MaximizeAsync and DesktopWindow.RestoreAsync), and takes a saved placement (DesktopWindow.SetPlacementAsync), which DesktopWindowState.Placement then reports back. On Wayland, which lets no application position its windows, GTK windows report it for a placement without a position.