![]() ![]() This is accomplished by setting the Source property to an animated GIF file: NET MAUI includes support for displaying small, animated GIFs. įor information about displaying font icons by specifying the font icon data in a FontImageSource object, see Display font icons. While the unicode character for the icon is \uf30c, it has to be escaped in XAML and so becomes . In this example, the abbreviated version of the FontImageExtension class name is used to display an XBox icon, from the Ionicons font family, in an Image: The following XAML example shows how to use the FontImage markup extension: Therefore, for XAML markup expressions expressed with curly braces, you can eliminate the Glyph= part of the expression provided that it's the first argument. The Glyph property is the content property of FontImageExtension. The XAML parser allows the FontImageExtension class to be abbreviated as FontImage. Source = ImageSource.FromStream(() => stream) Images can be loaded from streams with the ImageSource.FromStream method: Image image = new Image In this example, the caching period is set to 10 days. The equivalent C# code is: Image image = new Image() To set a specific cache period, set the Source property to an UriImageSource object that sets its CacheValidity property: The default value of this property is true.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |