diff --git a/lib/layoutpreviewimage.php b/lib/layoutpreviewimage.php index 360af76..393eb3a 100644 --- a/lib/layoutpreviewimage.php +++ b/lib/layoutpreviewimage.php @@ -25,6 +25,7 @@ class LayoutPreviewImage { private static $one_row_height = 65; private static $two_row_height = 31; private static $three_row_height = 20; + private static $six_row_height = 8; private static $spacer = 3; /* Constructor. @@ -93,6 +94,9 @@ class LayoutPreviewImage { if ($this->rows == 1) { return self::$one_row_height; } + if ($this->rows > 5) { + return $this->rows * self::$six_row_height + ($this->rows - 1) * self::$spacer; + } if ($this->rows > 2) { return $this->rows * self::$three_row_height + ($this->rows - 1) * self::$spacer; } @@ -103,6 +107,9 @@ class LayoutPreviewImage { if ($this->rows == 1) { return self::$one_row_height; } + if ($this->rows > 5) { + return self::$six_row_height; + } if ($this->rows > 2) { return self::$three_row_height; } diff --git a/lib/view.php b/lib/view.php index 4b4dc79..611d97a 100644 --- a/lib/view.php +++ b/lib/view.php @@ -224,7 +224,7 @@ class View { ), ); - public static $maxlayoutrows = 6; // see number of colours avail in layoutpreview.php + public static $maxlayoutrows = 20; /** * For retrieving and checking numbers of columnns in any given row