优化排列顺序
This commit is contained in:
@@ -39,7 +39,7 @@ namespace SpineViewer.Dialogs
|
|||||||
PropertyInfo? labelProp = category.GetType().GetProperty("Label", BindingFlags.Instance | BindingFlags.Public);
|
PropertyInfo? labelProp = category.GetType().GetProperty("Label", BindingFlags.Instance | BindingFlags.Public);
|
||||||
if (labelProp == null) continue;
|
if (labelProp == null) continue;
|
||||||
string? label = labelProp.GetValue(category) as string;
|
string? label = labelProp.GetValue(category) as string;
|
||||||
if (label != "导出") continue;
|
if (label != "[1] 导出") continue;
|
||||||
|
|
||||||
// 获取该分组下的所有属性项
|
// 获取该分组下的所有属性项
|
||||||
PropertyInfo? gridItemsProp = category.GetType().GetProperty("GridItems", BindingFlags.Instance | BindingFlags.Public);
|
PropertyInfo? gridItemsProp = category.GetType().GetProperty("GridItems", BindingFlags.Instance | BindingFlags.Public);
|
||||||
|
|||||||
@@ -60,32 +60,32 @@ namespace SpineViewer.Exporter
|
|||||||
/// 输出文件夹
|
/// 输出文件夹
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Editor(typeof(FolderNameEditor), typeof(UITypeEditor))]
|
[Editor(typeof(FolderNameEditor), typeof(UITypeEditor))]
|
||||||
[Category("导出"), DisplayName("输出文件夹"), Description("逐个导出时可以留空,将逐个导出到模型自身所在目录")]
|
[Category("[1] 导出"), DisplayName("输出文件夹"), Description("逐个导出时可以留空,将逐个导出到模型自身所在目录")]
|
||||||
public string? OutputDir { get; set; } = null;
|
public string? OutputDir { get; set; } = null;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 导出单个
|
/// 导出单个
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Category("导出"), DisplayName("导出单个"), Description("是否将模型在同一个画面上导出单个文件,否则逐个导出模型")]
|
[Category("[1] 导出"), DisplayName("导出单个"), Description("是否将模型在同一个画面上导出单个文件,否则逐个导出模型")]
|
||||||
public bool ExportSingle { get; set; } = false;
|
public bool ExportSingle { get; set; } = false;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 画面分辨率
|
/// 画面分辨率
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[TypeConverter(typeof(SizeConverter))]
|
[TypeConverter(typeof(SizeConverter))]
|
||||||
[Category("导出"), DisplayName("分辨率"), Description("画面的宽高像素大小,请在预览画面参数面板进行调整")]
|
[Category("[1] 导出"), DisplayName("分辨率"), Description("画面的宽高像素大小,请在预览画面参数面板进行调整")]
|
||||||
public Size Resolution { get; }
|
public Size Resolution { get; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 渲染视窗
|
/// 渲染视窗
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Category("导出"), DisplayName("视图"), Description("画面的视图参数,请在预览画面参数面板进行调整")]
|
[Category("[1] 导出"), DisplayName("视图"), Description("画面的视图参数,请在预览画面参数面板进行调整")]
|
||||||
public SFML.Graphics.View View { get; }
|
public SFML.Graphics.View View { get; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 是否仅渲染选中
|
/// 是否仅渲染选中
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Category("导出"), DisplayName("仅渲染选中"), Description("是否仅导出选中的模型,请在预览画面参数面板进行调整")]
|
[Category("[1] 导出"), DisplayName("仅渲染选中"), Description("是否仅导出选中的模型,请在预览画面参数面板进行调整")]
|
||||||
public bool RenderSelectedOnly { get; }
|
public bool RenderSelectedOnly { get; }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ namespace SpineViewer.Exporter.Implementations.ExportArgs
|
|||||||
/// 单帧画面格式
|
/// 单帧画面格式
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[TypeConverter(typeof(ImageFormatConverter))]
|
[TypeConverter(typeof(ImageFormatConverter))]
|
||||||
[Category("单帧画面"), DisplayName("图像格式")]
|
[Category("[2] 单帧画面"), DisplayName("图像格式")]
|
||||||
public ImageFormat ImageFormat
|
public ImageFormat ImageFormat
|
||||||
{
|
{
|
||||||
get => imageFormat;
|
get => imageFormat;
|
||||||
@@ -35,14 +35,14 @@ namespace SpineViewer.Exporter.Implementations.ExportArgs
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 文件名后缀
|
/// 文件名后缀
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Category("单帧画面"), DisplayName("文件名后缀"), Description("与图像格式匹配的文件名后缀")]
|
[Category("[2] 单帧画面"), DisplayName("文件名后缀"), Description("与图像格式匹配的文件名后缀")]
|
||||||
public string FileSuffix { get => imageFormat.GetSuffix(); }
|
public string FileSuffix { get => imageFormat.GetSuffix(); }
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// DPI
|
/// DPI
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[TypeConverter(typeof(SizeFConverter))]
|
[TypeConverter(typeof(SizeFConverter))]
|
||||||
[Category("单帧画面"), DisplayName("DPI"), Description("导出图像的每英寸像素数,用于调整图像的物理尺寸")]
|
[Category("[2] 单帧画面"), DisplayName("DPI"), Description("导出图像的每英寸像素数,用于调整图像的物理尺寸")]
|
||||||
public SizeF DPI
|
public SizeF DPI
|
||||||
{
|
{
|
||||||
get => dpi;
|
get => dpi;
|
||||||
|
|||||||
@@ -20,7 +20,7 @@ namespace SpineViewer.Exporter.Implementations.ExportArgs
|
|||||||
/// 文件名后缀
|
/// 文件名后缀
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[TypeConverter(typeof(SFMLImageFileSuffixConverter))]
|
[TypeConverter(typeof(SFMLImageFileSuffixConverter))]
|
||||||
[Category("帧序列参数"), DisplayName("文件名后缀"), Description("帧文件的后缀,同时决定帧图像格式")]
|
[Category("[3] 帧序列参数"), DisplayName("文件名后缀"), Description("帧文件的后缀,同时决定帧图像格式")]
|
||||||
public string FileSuffix { get; set; } = ".png";
|
public string FileSuffix { get; set; } = ".png";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -22,14 +22,14 @@ namespace SpineViewer.Exporter.Implementations.ExportArgs
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 调色板最大颜色数量
|
/// 调色板最大颜色数量
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Category("GIF 参数"), DisplayName("调色板最大颜色数量"), Description("设置调色板使用的最大颜色数量, 越多则色彩保留程度越高")]
|
[Category("[3] GIF 参数"), DisplayName("调色板最大颜色数量"), Description("设置调色板使用的最大颜色数量, 越多则色彩保留程度越高")]
|
||||||
public uint MaxColors { get => maxColors; set => maxColors = Math.Clamp(value, 2, 256); }
|
public uint MaxColors { get => maxColors; set => maxColors = Math.Clamp(value, 2, 256); }
|
||||||
private uint maxColors = 256;
|
private uint maxColors = 256;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// 透明度阈值
|
/// 透明度阈值
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Category("GIF 参数"), DisplayName("透明度阈值"), Description("小于该值的像素点会被认为是透明像素")]
|
[Category("[3] GIF 参数"), DisplayName("透明度阈值"), Description("小于该值的像素点会被认为是透明像素")]
|
||||||
public byte AlphaThreshold { get => alphaThreshold; set => alphaThreshold = value; }
|
public byte AlphaThreshold { get => alphaThreshold; set => alphaThreshold = value; }
|
||||||
private byte alphaThreshold = 128;
|
private byte alphaThreshold = 128;
|
||||||
|
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ namespace SpineViewer.Exporter.Implementations.ExportArgs
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 导出时长
|
/// 导出时长
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Category("视频参数"), DisplayName("时长"), Description("可以从模型列表查看动画时长, 如果小于 0, 则在逐个导出时每个模型使用各自的当前动画时长")]
|
[Category("[2] 视频参数"), DisplayName("时长"), Description("可以从模型列表查看动画时长, 如果小于 0, 则在逐个导出时每个模型使用各自的当前动画时长")]
|
||||||
public float Duration
|
public float Duration
|
||||||
{
|
{
|
||||||
get => duration;
|
get => duration;
|
||||||
@@ -28,7 +28,7 @@ namespace SpineViewer.Exporter.Implementations.ExportArgs
|
|||||||
/// <summary>
|
/// <summary>
|
||||||
/// 帧率
|
/// 帧率
|
||||||
/// </summary>
|
/// </summary>
|
||||||
[Category("视频参数"), DisplayName("帧率"), Description("每秒画面数")]
|
[Category("[2] 视频参数"), DisplayName("帧率"), Description("每秒画面数")]
|
||||||
public float FPS { get; set; } = 60;
|
public float FPS { get; set; } = 60;
|
||||||
|
|
||||||
public override string? Validate()
|
public override string? Validate()
|
||||||
|
|||||||
Reference in New Issue
Block a user