From 285cb4810f89bfb742e81c868445c3e7e4262ba8 Mon Sep 17 00:00:00 2001 From: Sasha Koshka Date: Thu, 2 Mar 2023 16:48:37 -0500 Subject: [PATCH] Remove margin from layout interface Layouts will need to store margin and padding values within themseleves. --- layouts/layout.go | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/layouts/layout.go b/layouts/layout.go index 1e44f9b..9921a88 100644 --- a/layouts/layout.go +++ b/layouts/layout.go @@ -18,18 +18,17 @@ type Layout interface { // and changes the position of the entiries in the slice so that they // are properly laid out. The given width and height should not be less // than what is returned by MinimumSize. - Arrange (entries []LayoutEntry, margin int, bounds image.Rectangle) + Arrange (entries []LayoutEntry, bounds image.Rectangle) // MinimumSize returns the minimum width and height that the layout // needs to properly arrange the given slice of layout entries. - MinimumSize (entries []LayoutEntry, margin int) (width, height int) + MinimumSize (entries []LayoutEntry) (width, height int) // FlexibleHeightFor Returns the minimum height the layout needs to lay // out the specified elements at the given width, taking into account // flexible elements. FlexibleHeightFor ( entries []LayoutEntry, - margin int, squeeze int, ) ( height int,