Как динамически создавать Template для кнопки в WPF?
Path path = new();
path.Data = Geometry.Parse("M0,0 L8,8 M8,0 L0,8");
path.StrokeThickness = 3;
ControlTemplate controlTemplate = new() { Template = /*template*/ };
Button button = new() { Template = controlTemplate };
как мне создать Template на основе path (что вписать вместо /*template*/)?