Продолжение рефакторинга (вынесение WPF в отдельный проект)
This commit is contained in:
@@ -0,0 +1,102 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Windows;
|
||||
using System.Windows.Controls;
|
||||
using System.Windows.Data;
|
||||
using System.Windows.Documents;
|
||||
using System.Windows.Input;
|
||||
using System.Windows.Media;
|
||||
using System.Windows.Media.Imaging;
|
||||
using System.Windows.Navigation;
|
||||
using System.Windows.Shapes;
|
||||
using Pf2e.Scrapper.Helpers;
|
||||
|
||||
namespace Pf2e.WPF.EntityViewer.Component;
|
||||
|
||||
internal partial class ViewControl : UserControl
|
||||
{
|
||||
#region "Поля элемента управления"
|
||||
|
||||
/// <summary>
|
||||
/// Высота строки поля структуры.
|
||||
/// </summary>
|
||||
[DesignerSerializationVisibility(DesignerSerializationVisibility.Visible)]
|
||||
[Category("Entity Render")]
|
||||
[Description("The height of each item in the tree view.")]
|
||||
public double ItemHeight
|
||||
{
|
||||
get { return (double)GetValue(ItemHeightProperty); }
|
||||
set { SetValue(ItemHeightProperty, value); }
|
||||
}
|
||||
public static readonly DependencyProperty ItemHeightProperty = DependencyProperty.Register(
|
||||
"ItemHeight",
|
||||
typeof(double),
|
||||
typeof(ViewControl),
|
||||
new PropertyMetadata(20.0)
|
||||
);
|
||||
|
||||
/// <summary>
|
||||
/// Ширина отступа глубины.
|
||||
/// </summary>
|
||||
[DesignerSerializationVisibility(DesignerSerializationVisibility.Visible)]
|
||||
[Category("Entity Render")]
|
||||
[Description("The size of tab.")]
|
||||
public double DepthSize
|
||||
{
|
||||
get { return (double)GetValue(DepthSizeProperty); }
|
||||
set { SetValue(DepthSizeProperty, value); }
|
||||
}
|
||||
public static readonly DependencyProperty DepthSizeProperty = DependencyProperty.Register(
|
||||
"DepthSize",
|
||||
typeof(double),
|
||||
typeof(ViewControl),
|
||||
new PropertyMetadata(20.0)
|
||||
);
|
||||
|
||||
/// <summary>
|
||||
/// Размер шрифта типа поля сущности.
|
||||
/// </summary>
|
||||
[DesignerSerializationVisibility(DesignerSerializationVisibility.Visible)]
|
||||
[Category("Entity Render")]
|
||||
[Description("The size of tab.")]
|
||||
public double TypeFontSize
|
||||
{
|
||||
get { return (double)GetValue(TypeFontSizeProperty); }
|
||||
set { SetValue(TypeFontSizeProperty, value); }
|
||||
}
|
||||
public static readonly DependencyProperty TypeFontSizeProperty = DependencyProperty.Register(
|
||||
"TypeFontSize",
|
||||
typeof(double),
|
||||
typeof(ViewControl),
|
||||
new PropertyMetadata(9.5)
|
||||
);
|
||||
|
||||
/// <summary>
|
||||
/// Размер кнопки плюс/минус.
|
||||
/// </summary>
|
||||
[DesignerSerializationVisibility(DesignerSerializationVisibility.Visible)]
|
||||
[Category("Entity Render")]
|
||||
[Description("The size of plus/minus button.")]
|
||||
public double ButtonSize
|
||||
{
|
||||
get { return (double)GetValue(ButtonSizeProperty); }
|
||||
set { SetValue(ButtonSizeProperty, value); }
|
||||
}
|
||||
public static readonly DependencyProperty ButtonSizeProperty = DependencyProperty.Register(
|
||||
"ButtonSize",
|
||||
typeof(double),
|
||||
typeof(ViewControl),
|
||||
new PropertyMetadata(12.0)
|
||||
);
|
||||
|
||||
#endregion
|
||||
|
||||
public ViewControl()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user