Table of Contents

Interface IAvaloniaUi

Namespace
VpnHood.AppUi.Hosting.Avalonia
Assembly
VpnHood.AppUi.Hosting.Avalonia.dll

Defines a UI a head can run: the head names it as a type argument.

public interface IAvaloniaUi

Remarks

The members are static, as a head needs both answers before the UI's first view, with no instance of it.

Properties

AvailableCultures

Gets the languages this UI has words for, which the app is told as it is configured, so its language list and its choice of culture come from the words that exist.

public static abstract IReadOnlyList<string> AvailableCultures { get; }

Property Value

IReadOnlyList<string>

Methods

PrepareContentAsync(IAssetProvider, CancellationToken)

Puts in place what the UI needs before its first view, its words and the fonts its styles name, from the content store the head hands in.

public static abstract Task PrepareContentAsync(IAssetProvider assets, CancellationToken cancellationToken)

Parameters

assets IAssetProvider

The UI's content store: a folder in process, or the app's web host from a browser page.

cancellationToken CancellationToken

The token to monitor for cancellation requests.

Returns

Task

A task that represents the asynchronous operation.