ImageButton

Inheritance: Element -> NavigableElement -> VisualElement -> View Xamarin.Forms documentation: ImageButton API / Guide

For details on how the control actually works, please refer to the Xamarin.Forms documentation.

Constructors

Properties

Events

Usages

ImageButton(Aspect.AspectFit, "image-light.png", dark = "image-dark.png")
    .borderColor(light = Color.Red.ToFabColor(), dark = Color.Blue.ToFabColor()) 
    .borderWidth(5.) 
    .isLoading(false) 
    .isOpaque(true) 
    .isPressed(false) 
    .padding(Thickness(5., 10., 5., 10.)) 
    .padding(10.) 
    .padding(5., 10., 5., 10.) 
    .onPressed(PressedMsg) 
    .onReleased(ReleasedMsg)
    
ImageButton(Aspect.AspectFit, FileImageSource(...), dark = StreamImageSource(...))

ImageButton(Aspect.AspectFit, Uri("http://..."), dark = Uri("http://..."))

ImageButton(Aspect.AspectFit, MemoryStream(), dark = FileStream())

Get access to the underlying Xamarin.Forms.ImageButton

let imageButtonRef = ViewRef<ImageButton>()

ImageButton(Aspect.AspectFit, light = "image-light.png", dark = "image-dark.png")
    .reference(imageButtonRef)

Last updated