From eb7ae0fb20d7a4dba4f1f9253f807abdd29bd6cd Mon Sep 17 00:00:00 2001 From: Zsolt Udvari Date: Mon, 26 Oct 2009 10:58:39 +0100 Subject: [PATCH] awful.tag: allow table as layout argument (FS#670) Signed-off-by: Julien Danjou --- lib/awful/tag.lua.in | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/awful/tag.lua.in b/lib/awful/tag.lua.in index d3544cf1..bb8e72a0 100644 --- a/lib/awful/tag.lua.in +++ b/lib/awful/tag.lua.in @@ -33,7 +33,7 @@ history.limit = 20 --- Create a set of tags and attach it to a screen. -- @param names The tag name, in a table -- @param screen The tag screen, or 1 if not set. --- @param layout The layout to set for this tags by default. +-- @param layout The layout or layout table to set for this tags by default. -- @return A table with all created tags. function new(names, screen, layout) local screen = screen or 1 @@ -45,7 +45,7 @@ function new(names, screen, layout) if id == 1 then tags[#tags].selected = true end - setproperty(tags[#tags], "layout", layout) + setproperty(tags[#tags], "layout", layout[#tags] or layout[1] or layout) end return tags end