Files
Better-Seewo/Better-EN5/Services/Conversion/DocumentModel.cs

57 lines
1.5 KiB
C#
Raw Normal View History

using System.Collections.Generic;
namespace BetterEN5.Services.Conversion;
public class DocumentModel
{
public string Title { get; set; } = "";
public string Author { get; set; } = "";
public long SlideWidth { get; set; } = 12192000;
public long SlideHeight { get; set; } = 6858000;
public List<SlideModel> Slides { get; set; } = new();
}
public class SlideModel
{
public string Name { get; set; } = "";
public long Width { get; set; }
public long Height { get; set; }
public List<ElementModel> Elements { get; set; } = new();
}
public abstract class ElementModel
{
}
public class TextElement : ElementModel
{
public string Text { get; set; } = "";
public long X { get; set; }
public long Y { get; set; }
public long Width { get; set; }
public long Height { get; set; }
public string FontName { get; set; } = "微软雅黑";
public double FontSize { get; set; } = 18;
public string FontColor { get; set; } = "#FF000000";
public bool IsBold { get; set; }
}
public class ImageElement : ElementModel
{
public byte[]? Data { get; set; }
public string ContentType { get; set; } = "image/png";
public string FileName { get; set; } = "";
public long X { get; set; }
public long Y { get; set; }
public long Width { get; set; }
public long Height { get; set; }
}
public class ShapeElement : ElementModel
{
public long X { get; set; }
public long Y { get; set; }
public long Width { get; set; }
public long Height { get; set; }
}