Первый крутой круг

This commit is contained in:
2026-03-03 19:07:53 +03:00
parent b1177265ea
commit 4bf92356af
5 changed files with 75 additions and 47 deletions

View File

@@ -532,6 +532,13 @@ fn drawPropertyEditor(canvas: *Canvas, obj: *Document.Object, prop: *const Prope
canvas.requestRedraw();
}
},
.arc_percent => |pct| {
var next = pct;
if (dvui.sliderEntry(@src(), "{d:0.0}%", .{ .value = &next, .min = 0.0, .max = 100.0, .interval = 1.0 }, .{ .expand = .horizontal })) {
obj.setProperty(canvas.allocator, .{ .data = .{ .arc_percent = next } }) catch {};
canvas.requestRedraw();
}
},
.end_point => |pt| {
var next = pt;
var changed = false;
@@ -745,6 +752,7 @@ fn propertyLabel(tag: std.meta.Tag(PropertyData)) []const u8 {
.locked => "Locked",
.size => "Size",
.radii => "Radii",
.arc_percent => "Arc %",
.end_point => "End point",
.points => "Points",
.fill_rgba => "Fill color",