title | author | description | keywords |
---|---|---|---|
ImageEx |
nmetulev |
The ImageEx Control and downloads images asynchronously, while showing a loading indicator. |
windows 10, uwp, windows community toolkit, uwp community toolkit, uwp toolkit, ImageEx, xaml control, xaml |
The ImageEx control downloads images asynchronously, while showing a loading indicator. Source images are then stored in the application's local cache to preserve resources and load time. ImageEx also extends the default Image and ImageBrush Platform controls respectively to improve performance through caching. You can also use a placeholder image that will be displayed while loading the main image.
[!div class="nextstepaction"] Try it in the sample app
<controls:ImageEx Name="ImageExControl" IsCacheEnabled="True"
PlaceholderSource="/assets/thumbnails/thumbnails.png"
Source="/assets/bigPicture.png" CornerRadius="20"/>
Property | Type | Description |
---|---|---|
NineGrid | Thickness | Gets or sets the nine-grid used by the image |
IsCacheEnabled | bool | Gets or sets a value indicating whether gets or sets cache state |
ImageExCachingStrategy | enum | Gets or sets a value indicating how the Image will be cached |
CornerRadius | double | Get or set the radius of image corner |
EnableLazyLoading | bool | Gets or sets a value indicating is lazy loading enabled. |
LazyLoadingThreshold | double | Gets or sets a value indicating the threshold for triggering lazy loading. Default value is 300 px. |
ImageExControl Sample Page Source. You can see this in action in the Windows Community Toolkit Sample App.
- ImageEx Control XAML File is the XAML template used in the toolkit for the default styling.
Device family | Universal, 10.0.16299.0 or higher |
---|---|
Namespace | Microsoft.Toolkit.Uwp.UI.Controls |
NuGet package | Microsoft.Toolkit.Uwp.UI.Controls |