Class SkinButton
- Namespace
- VisioForge.Core.UI.WPF.Skins
- Assembly
- VisioForge.Core.dll
A customizable button control that integrates with the VisioForge skinning system. This button can display both SVG and PNG images with automatic state management for hover, pressed, and disabled states. It uses SkiaSharp for high-performance rendering and supports dynamic skin switching.
public class SkinButton : SKElement, IAnimatable, ISupportInitialize, IFrameworkInputElement, IInputElement, IQueryAmbientInheritance
Implements
Inherited Members
Remarks
The SkinButton automatically handles visual states by:
- Loading appropriate graphics from the skin system
- Applying hover effects with color overlays
- Showing pressed states with shadow effects
- Rendering disabled states with transparency overlays
- Scaling graphics to fit the button dimensions
The button integrates with the SkinManager to load graphics and styling information from skin definition files.
Constructors
SkinButton()
Initializes a new instance of the VisioForge.Core.UI.WPF.Skins.SkinButton class.
public SkinButton()Fields
ElementStateProperty
The element state property.
public static readonly DependencyProperty ElementStatePropertyField Value
ElementTypeProperty
Dependency property for the ElementType property. Determines what type of skin element this button represents.
public static readonly DependencyProperty ElementTypePropertyField Value
SkinNameProperty
The skin name property.
public static readonly DependencyProperty SkinNamePropertyField Value
Properties
ElementState
Gets or sets the state of the element.
public SkinElementState ElementState { get; set; }Property Value
ElementType
Gets or sets the type of skin element this button represents.
public SkinElementType ElementType { get; set; }Property Value
Remarks
Changing this property will trigger a reload of the appropriate graphics from the current skin and update the button's visual appearance.
SkinName
Gets or sets the name of the skin.
public string SkinName { get; set; }