增加工作区背景图片参数

This commit is contained in:
ww-rm
2025-09-22 23:30:02 +08:00
parent 93b70509ec
commit dbc15952cc
2 changed files with 6 additions and 4 deletions

View File

@@ -43,10 +43,9 @@ namespace SpineViewer.Models
public Color BackgroundColor { get; set; }
// TODO: 背景图片
//public string? BackgroundImagePath { get; set; }
public string BackgroundImagePath { get; set; }
//public ? BackgroundImageDisplayMode { get; set; }
public Stretch BackgroundImageMode { get; set; } = Stretch.Uniform;
}
public class SpineObjectWorkspaceConfigModel

View File

@@ -551,7 +551,6 @@ namespace SpineViewer.ViewModels.MainWindow
public RendererWorkspaceConfigModel WorkspaceConfig
{
// TODO: 背景图片
get
{
return new()
@@ -568,6 +567,8 @@ namespace SpineViewer.ViewModels.MainWindow
Speed = Speed,
ShowAxis = ShowAxis,
BackgroundColor = BackgroundColor,
BackgroundImagePath = BackgroundImagePath,
BackgroundImageMode = BackgroundImageMode,
};
}
set
@@ -583,6 +584,8 @@ namespace SpineViewer.ViewModels.MainWindow
Speed = value.Speed;
ShowAxis = value.ShowAxis;
BackgroundColor = value.BackgroundColor;
BackgroundImagePath = value.BackgroundImagePath;
BackgroundImageMode = value.BackgroundImageMode;
}
}
}