diff --git a/lib/awful/tag.lua b/lib/awful/tag.lua index 17ee0fb1..11e80fff 100644 --- a/lib/awful/tag.lua +++ b/lib/awful/tag.lua @@ -745,6 +745,10 @@ function tag.object.set_layout(t, layout) return layout end +function tag.object.get_layout(t) + return tag.getproperty(t, "layout") or require("awful.layout.suit.floating") +end + --- Set layout. -- @deprecated awful.tag.setlayout -- @see layout diff --git a/tests/test-awful-tag.lua b/tests/test-awful-tag.lua index 6abf1221..c299862d 100644 --- a/tests/test-awful-tag.lua +++ b/tests/test-awful-tag.lua @@ -69,6 +69,7 @@ local steps = { assert(beautiful.awesome_icon) local t = awful.tag.add("Test", {clients={c}, icon = beautiful.awesome_icon}) + assert(t.layout == awful.layout.suit.floating) check_order()