Skip to main content

X11PlatformOptions Class

Definition

Namespace:Avalonia
Assembly:Avalonia.X11
Package:Avalonia.X11

Platform-specific options which apply to Linux.

public class X11PlatformOptions

Inheritance: object -> X11PlatformOptions

Constructors

NameDescription
X11PlatformOptionsNo summary available.

X11PlatformOptions Constructor

public X11PlatformOptions()

Properties

NameDescription
EnableDrawnDecorationsEnables client-side drawn window decorations on X11. When true and ExtendClientAreaToDecorationsHint is set on a window, Avalonia will draw its own decorations (titlebar, borders, resize grips) instead of using the X11 window manager decorations.
EnableImeDetermines whether to use IME. IME would be enabled by default if the current user input language is one of the following: Mandarin, Japanese, Vietnamese or Korean.
EnableInputFocusProxyDetermines whether to use Input Focus Proxy. The default value is false.
EnableMultiTouchEnables multitouch support. The default value is true.
EnableSessionManagementDetermines whether to enable support for the X Session Management Protocol.
ExternalGLibMainLoopExceptionLoggerIf Avalonia is in control of a run loop, we propagate exceptions by stopping the run loop frame and rethrowing an exception. However, if there is no Avalonia-controlled run loop frame, there is no way to report such exceptions, since allowing those to escape native->managed call boundary will likely brick GLib machinery since it's not aware of managed Exceptions This property allows to inspect such exceptions before they will be ignored
GlProfilesNo summary available.
GlxRendererBlacklistNo summary available.
OverlayPopupsEmbeds popups to the window when set to true. The default value is false.
RenderingModeGets or sets Avalonia rendering modes with fallbacks. The first element in the array has the highest priority. The default value is: Avalonia.X11RenderingMode.Glx, Avalonia.X11RenderingMode.Software.
ShouldRenderOnUIThreadRender directly on the UI thread instead of using a dedicated render thread. This can be usable if your device don't have multiple cores to begin with. This setting is false by default.
UseDBusFilePickerEnables DBus file picker instead of GTK. The default value is true.
UseDBusMenuEnables global menu support on Linux desktop environments where it's supported (e. g. XFCE and MATE with plugin, KDE, etc). The default value is true.
UseGLibMainLoopIf this option is set to true, GMainLoop and GSource based dispatcher implementation will be used instead of epoll-based one. Use this if you need to use GLib-based libraries on the main thread
UseRetainedFramebufferRetain window framebuffer contents if using CPU rendering mode. This will keep an offscreen bitmap for each window with contents of the previous frame While improving performance by saving a blit, it will increase memory consumption if you have many windows
WmClassNo summary available.

EnableDrawnDecorations Property

Enables client-side drawn window decorations on X11. When true and ExtendClientAreaToDecorationsHint is set on a window, Avalonia will draw its own decorations (titlebar, borders, resize grips) instead of using the X11 window manager decorations.

public Nullable<bool> EnableDrawnDecorations { get; set; }

EnableIme Property

Determines whether to use IME. IME would be enabled by default if the current user input language is one of the following: Mandarin, Japanese, Vietnamese or Korean.

public Nullable<bool> EnableIme { get; set; }

Remarks

Input method editor is a component that enables users to generate characters not natively available on their input devices by using sequences of characters or mouse operations that are natively available on their input devices.

EnableInputFocusProxy Property

Determines whether to use Input Focus Proxy. The default value is false.

public bool EnableInputFocusProxy { get; set; }

EnableMultiTouch Property

Enables multitouch support. The default value is true.

public Nullable<bool> EnableMultiTouch { get; set; }

Remarks

Multitouch allows a surface (a touchpad or touchscreen) to recognize the presence of more than one point of contact with the surface at the same time.

EnableSessionManagement Property

Determines whether to enable support for the X Session Management Protocol.

public bool EnableSessionManagement { get; set; }

Remarks

X Session Management Protocol is a standard implemented on most Linux systems that uses Xorg. This enables apps to control how they can control and/or cancel the pending shutdown requested by the user.

ExternalGLibMainLoopExceptionLogger Property

If Avalonia is in control of a run loop, we propagate exceptions by stopping the run loop frame and rethrowing an exception. However, if there is no Avalonia-controlled run loop frame, there is no way to report such exceptions, since allowing those to escape native->managed call boundary will likely brick GLib machinery since it's not aware of managed Exceptions This property allows to inspect such exceptions before they will be ignored

public Action<Exception> ExternalGLibMainLoopExceptionLogger { get; set; }

GlProfiles Property

public System.Collections.Generic.IList<Avalonia.OpenGL.GlVersion> GlProfiles { get; set; }

GlxRendererBlacklist Property

public System.Collections.Generic.IList<string> GlxRendererBlacklist { get; set; }

OverlayPopups Property

Embeds popups to the window when set to true. The default value is false.

public bool OverlayPopups { get; set; }

RenderingMode Property

Gets or sets Avalonia rendering modes with fallbacks. The first element in the array has the highest priority. The default value is: Avalonia.X11RenderingMode.Glx, Avalonia.X11RenderingMode.Software.

public System.Collections.Generic.IReadOnlyList<Avalonia.X11RenderingMode> RenderingMode { get; set; }

Remarks

If application should work on as wide range of devices as possible, at least add Avalonia.X11RenderingMode.Software as a fallback value.

Exceptions

ShouldRenderOnUIThread Property

Render directly on the UI thread instead of using a dedicated render thread. This can be usable if your device don't have multiple cores to begin with. This setting is false by default.

public bool ShouldRenderOnUIThread { get; set; }

UseDBusFilePicker Property

Enables DBus file picker instead of GTK. The default value is true.

public bool UseDBusFilePicker { get; set; }

UseDBusMenu Property

Enables global menu support on Linux desktop environments where it's supported (e. g. XFCE and MATE with plugin, KDE, etc). The default value is true.

public bool UseDBusMenu { get; set; }

UseGLibMainLoop Property

If this option is set to true, GMainLoop and GSource based dispatcher implementation will be used instead of epoll-based one. Use this if you need to use GLib-based libraries on the main thread

public bool UseGLibMainLoop { get; set; }

UseRetainedFramebuffer Property

Retain window framebuffer contents if using CPU rendering mode. This will keep an offscreen bitmap for each window with contents of the previous frame While improving performance by saving a blit, it will increase memory consumption if you have many windows

public Nullable<bool> UseRetainedFramebuffer { get; set; }

WmClass Property

public string WmClass { get; set; }