Add custom control
using MyApp.MyControls; Window "MyApp.MainWindow" { MyCustomControl { } } or Window "MyApp.MainWindow" { MyApp.MyControls.MyCustomControl { } } |
Fade In element on Loaded event
![]() |
TextBlock { "Hello, World!" Style: Style { TargetType: TextBlock #FadeIn_OnEvent("Loaded") } } |
Visibility binded to CheckBox.IsChecked property
![]() |
TextBlock { "Hello, World!" Style: Style { TargetType: TextBlock #Visibility_OnBinding(bind IsChecked from "VisibilityCheckbox", false, "Hidden") } } CheckBox "VisibilityCheckbox" { "Is visible" } |
Fade In and Out binded to CheckBox.IsChecked property
![]() |
TextBlock { "Hello, World!" Style: Style { TargetType: TextBlock #Fade_OnBinding(bind IsChecked from "VisibilityCheckbox", true) } } CheckBox "VisibilityCheckbox" { "Is visible" } |
Fade on ViewModel property
TextBlock { "Hello, World!" Style: Style { TargetType: TextBlock #Fade_OnBinding(bind ShouldBeVisible, true) } } |
Animate on Mouse hover
![]() |
Border "ParentBorder" { Height: 30, Width: 30, Background: LightBlue Style: Style { TargetType: Border #DoubleAnimation_PropertyTrigger_Toggle("IsMouseOver", true, "Width", 30, 100, "0:0:0.1") } TextBlock { "Hello, World!" Margin: 7 Style: Style { TargetType: TextBlock #Visibility_OnBinding(bind Width from "ParentBorder", 100) } } } |