ResourceInclude Class
Definition
Loads a resource dictionary from a specified URL.
public class ResourceInclude
Remarks
If used from the XAML code, it is replaced with direct resource dictionary reference. When used in runtime, this type might be unsafe with trimming and AOT.
Constructors
| Name | Description |
|---|---|
| ResourceInclude (2 overloads) | Initializes a new instance of the Avalonia.Markup.Xaml.Styling.ResourceInclude class. |
ResourceInclude overloads
ResourceInclude Constructor
Initializes a new instance of the Avalonia.Markup.Xaml.Styling.ResourceInclude class.
public ResourceInclude(IServiceProvider serviceProvider)
Parameters
serviceProvider IServiceProvider
The XAML service provider.
ResourceInclude Constructor
Initializes a new instance of the Avalonia.Markup.Xaml.Styling.ResourceInclude class.
public ResourceInclude(Uri baseUri)
Parameters
baseUri Uri
The base URL for the XAML context.
Methods
| Name | Description |
|---|---|
| TryGetResource | No summary available. |
TryGetResource Method
public bool TryGetResource(object key, Avalonia.Styling.ThemeVariant theme, object& value)
Parameters
key object
theme Avalonia.Styling.ThemeVariant
value object&
Returns
bool
Properties
| Name | Description |
|---|---|
| Loaded | Gets the loaded resource dictionary. |
| Owner | No summary available. |
| Source | Gets or sets the source URL. |
Loaded Property
Gets the loaded resource dictionary.
public Avalonia.Controls.IResourceDictionary Loaded { get; set; }
Owner Property
public Avalonia.Controls.IResourceHost Owner { get; set; }
Source Property
Gets or sets the source URL.
public Uri Source { get; set; }
Events
| Name | Description |
|---|---|
| OwnerChanged | No summary available. |
OwnerChanged Event
public event EventHandler OwnerChanged