using Qrakhen.TilingFrames.Models; using System.Windows; using System.Windows.Controls; namespace Qrakhen.TilingFrames.Controls; public class PanelControl : Control { static PanelControl() { DefaultStyleKeyProperty.OverrideMetadata( typeof(PanelControl), new FrameworkPropertyMetadata(typeof(PanelControl))); } public PanelControl() { } #region DependencyProperties public Orientation SplitOrientation => Panel.SplitOrientation; public TilingNode Alpha => Panel.Alpha; public TilingNode? Beta => Panel.Beta; public Models.TilingPanel Panel { get => (Models.TilingPanel)GetValue(PanelProperty); set => SetValue(PanelProperty, value); } public static DependencyProperty PanelProperty = DependencyProperty .Register(nameof(Panel), typeof(Models.TilingPanel), typeof(PanelControl), new PropertyMetadata(null)); public double SplitterWidth { get => (double)GetValue(SplitterWidthProperty); set => SetValue(SplitterWidthProperty, value); } public static DependencyProperty SplitterWidthProperty = DependencyProperty .Register( nameof(SplitterWidth), typeof(double), typeof(PanelControl), new PropertyMetadata(8.0)); #endregion }