// public static T UseX11<T>(this T builder) where T : AppBuilderBase<T>, new() // { // builder.UseWindowingSubsystem(() => // new AvaloniaX11Platform().Initialize(AvaloniaLocator.Current.GetService<X11PlatformOptions>() ?? // new X11PlatformOptions())); // return builder; // } public static void InitializeX11Platform(X11PlatformOptions options = null) => new AvaloniaX11Platform().Initialize(options ?? new X11PlatformOptions());
public static T UseX11 <T>(this T builder, X11PlatformOptions options = null) where T : AppBuilderBase <T>, new() { builder.UseWindowingSubsystem(() => new AvaloniaX11Platform().Initialize(options ?? new X11PlatformOptions())); return(builder); }