add(layout/Marging): relative margins for Elements
Some checks failed
Zig Project Action / Lint, Spell-check and test zig project (push) Failing after 32s

This commit is contained in:
2024-11-13 18:08:58 +01:00
parent 61f6c72bf8
commit bc1bc757d4
8 changed files with 293 additions and 77 deletions

View File

@@ -88,13 +88,15 @@ pub fn Layout(comptime Event: type, comptime Renderer: type) type {
pub const HStack = @import("layout/HStack.zig").Layout(Event, Element, Renderer);
pub const VStack = @import("layout/VStack.zig").Layout(Event, Element, Renderer);
pub const Padding = @import("layout/Padding.zig").Layout(Event, Element, Renderer);
pub const Marging = @import("layout/Marging.zig").Layout(Event, Element, Renderer);
pub const Framing = @import("layout/Framing.zig").Layout(Event, Element, Renderer);
};
// test widget implementation satisfies the interface
// test layout implementation satisfies the interface
comptime Type.Interface.satisfiedBy(Type);
comptime Type.Interface.satisfiedBy(Type.HStack);
comptime Type.Interface.satisfiedBy(Type.VStack);
comptime Type.Interface.satisfiedBy(Type.Padding);
comptime Type.Interface.satisfiedBy(Type.Marging);
comptime Type.Interface.satisfiedBy(Type.Framing);
return Type;
}