Добавьте файлы проекта.

This commit is contained in:
2026-01-07 21:28:32 +03:00
parent 02603e60ad
commit fc994edf71
15 changed files with 531 additions and 0 deletions

View File

@@ -0,0 +1,35 @@
using Lattice.Core.Abstractions;
namespace Lattice.Core.Models;
/// <summary>
/// Абстрактный базовый класс для всех узлов дерева компоновки.
/// </summary>
public abstract class LayoutNode : ILayoutElement
{
/// <inheritdoc/>
public Guid Id { get; } = Guid.NewGuid();
/// <inheritdoc/>
public string Name { get; set; } = string.Empty;
/// <inheritdoc/>
public double WidthValue { get; set; } = 1.0;
/// <inheritdoc/>
public bool IsWidthStar { get; set; } = true;
/// <inheritdoc/>
public double HeightValue { get; set; } = 1.0;
/// <inheritdoc/>
public bool IsHeightStar { get; set; } = true;
/// <inheritdoc/>
public ILayoutElement? Parent { get; set; }
/// <summary>
/// Возвращает строковое представление узла для отладки.
/// </summary>
public override string ToString() => $"{GetType().Name} [{Name}] ({Id.ToString()[..4]})";
}