diff --git a/tests/examples/awful/mouse/coords.lua b/tests/examples/awful/mouse/coords.lua index 7b2ed7074..7f68e4222 100644 --- a/tests/examples/awful/mouse/coords.lua +++ b/tests/examples/awful/mouse/coords.lua @@ -1,4 +1,5 @@ --DOC_GEN_OUTPUT --DOC_GEN_IMAGE --DOC_HIDE +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {x = 175, width = 128, height = 96} --DOC_HIDE mouse.coords {x=175+60,y=60} --DOC_HIDE diff --git a/tests/examples/awful/placement/aero_snap.lua b/tests/examples/awful/placement/aero_snap.lua index 6ab50a1a0..ec191f3ae 100644 --- a/tests/examples/awful/placement/aero_snap.lua +++ b/tests/examples/awful/placement/aero_snap.lua @@ -5,6 +5,10 @@ screen[1]._resize {width = 180, height = 120} --DOC_HIDE screen._add_screen {x = 190, y = 0, width = 180, height = 120} --DOC_HIDE screen._add_screen {x = 380, y = 0, width = 180, height = 120} --DOC_HIDE +for s in screen do + require("awful.tag").add("1", {screen=s, selected=true}) --DOC_HIDE +end + for _, pos in ipairs{"left", "right"} do local c1 = client.gen_fake {x = 80, y = 55, width=78, height=50} placement.align(client.focus, {position = pos, honor_workarea=true}) diff --git a/tests/examples/awful/placement/align.lua b/tests/examples/awful/placement/align.lua index 69e6b9cd6..ea0c3fda5 100644 --- a/tests/examples/awful/placement/align.lua +++ b/tests/examples/awful/placement/align.lua @@ -1,6 +1,7 @@ --DOC_HIDE_ALL --DOC_GEN_IMAGE local placement = require("awful.placement") +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {x= 50} for _, pos in ipairs{ "top_left", "top_right", "bottom_left", "bottom_right", @@ -14,6 +15,8 @@ end screen._add_screen {x = 70, y = 260 , width = 128, height = 96} screen._add_screen {x = 210, y = 260 , width = 128, height = 96} +require("awful.tag").add("1", {screen=screen[2], selected=true}) --DOC_HIDE +require("awful.tag").add("1", {screen=screen[3], selected=true}) --DOC_HIDE local c diff --git a/tests/examples/awful/placement/bottom.lua b/tests/examples/awful/placement/bottom.lua index c70ee710e..da7715da5 100644 --- a/tests/examples/awful/placement/bottom.lua +++ b/tests/examples/awful/placement/bottom.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.bottom --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE local c = client.gen_fake {x = 45, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/bottom_left.lua b/tests/examples/awful/placement/bottom_left.lua index 125a0e648..a5afb9dab 100644 --- a/tests/examples/awful/placement/bottom_left.lua +++ b/tests/examples/awful/placement/bottom_left.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.bottom_left --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE local c = client.gen_fake {x = 45, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/bottom_right.lua b/tests/examples/awful/placement/bottom_right.lua index b0d450821..5b95f2cef 100644 --- a/tests/examples/awful/placement/bottom_right.lua +++ b/tests/examples/awful/placement/bottom_right.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.bottom_right --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE local c = client.gen_fake {x = 45, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/center_horizontal.lua b/tests/examples/awful/placement/center_horizontal.lua index 1ab1eee22..c77f7f009 100644 --- a/tests/examples/awful/placement/center_horizontal.lua +++ b/tests/examples/awful/placement/center_horizontal.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.center_horizontal --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE local c = client.gen_fake {x = 45, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/center_vertical.lua b/tests/examples/awful/placement/center_vertical.lua index a867eab20..0817921df 100644 --- a/tests/examples/awful/placement/center_vertical.lua +++ b/tests/examples/awful/placement/center_vertical.lua @@ -4,6 +4,7 @@ -- @tparam[opt={}] table args Other arguments") --DOC_HEADER -- @staticfct awful.placement.center_vertical --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE --[[local c = ]]client.gen_fake {x = 45, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/centered.lua b/tests/examples/awful/placement/centered.lua index c7af1052d..08523a424 100644 --- a/tests/examples/awful/placement/centered.lua +++ b/tests/examples/awful/placement/centered.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.centered --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE local c = client.gen_fake {x = 45, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/closest_mouse.lua b/tests/examples/awful/placement/closest_mouse.lua index 815b0568f..b0cd346a7 100644 --- a/tests/examples/awful/placement/closest_mouse.lua +++ b/tests/examples/awful/placement/closest_mouse.lua @@ -1,6 +1,7 @@ --DOC_GEN_OUTPUT --DOC_GEN_IMAGE --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE local c = client.gen_fake {x = 20, y = 20, width= 280, height=200, screen =screen[1]} --DOC_HIDE local bw = c.border_width --DOC_HIDE diff --git a/tests/examples/awful/placement/compose.lua b/tests/examples/awful/placement/compose.lua index 750afb29d..83b4cce01 100644 --- a/tests/examples/awful/placement/compose.lua +++ b/tests/examples/awful/placement/compose.lua @@ -1,4 +1,5 @@ --DOC_GEN_IMAGE --DOC_HIDE +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {x = 175, width = 128, height = 96} --DOC_NO_USAGE --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE local c = client.gen_fake {x = 220, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/compose2.lua b/tests/examples/awful/placement/compose2.lua index b0112684d..820bfafb4 100644 --- a/tests/examples/awful/placement/compose2.lua +++ b/tests/examples/awful/placement/compose2.lua @@ -1,4 +1,5 @@ --DOC_GEN_IMAGE --DOC_HIDE +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {x = 175, width = 128, height = 96} --DOC_NO_USAGE --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE local c = client.gen_fake {x = 220, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/left.lua b/tests/examples/awful/placement/left.lua index 3621383d7..6c9e29dfb 100644 --- a/tests/examples/awful/placement/left.lua +++ b/tests/examples/awful/placement/left.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.left --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE local c = client.gen_fake {x = 45, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/maximize.lua b/tests/examples/awful/placement/maximize.lua index aa40c2bf9..8466b0acd 100644 --- a/tests/examples/awful/placement/maximize.lua +++ b/tests/examples/awful/placement/maximize.lua @@ -2,6 +2,11 @@ screen[1]._resize {width = 128, height = 96} --DOC_HIDE screen._add_screen {x = 140, y = 0, width = 128, height = 96} --DOC_HIDE screen._add_screen {x = 280, y = 0, width = 128, height = 96} --DOC_HIDE + +for s in screen do --DOC_HIDE + require("awful.tag").add("1", {screen=s, selected=true}) --DOC_HIDE +end --DOC_HIDE + local placement = require("awful.placement") --DOC_HIDE for k, pos in ipairs{ --DOC_HIDE diff --git a/tests/examples/awful/placement/maximize_horizontally.lua b/tests/examples/awful/placement/maximize_horizontally.lua index de0f85b2a..7fad3db57 100644 --- a/tests/examples/awful/placement/maximize_horizontally.lua +++ b/tests/examples/awful/placement/maximize_horizontally.lua @@ -4,6 +4,7 @@ -- @tparam[opt={}] table args Other arguments") --DOC_HEADER -- @staticfct awful.placement.maximize_horizontally --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local placement = require("awful.placement") --DOC_HIDE diff --git a/tests/examples/awful/placement/maximize_vertically.lua b/tests/examples/awful/placement/maximize_vertically.lua index d3ef034bd..e5011b56a 100644 --- a/tests/examples/awful/placement/maximize_vertically.lua +++ b/tests/examples/awful/placement/maximize_vertically.lua @@ -4,6 +4,7 @@ -- @tparam[opt={}] table args Other arguments") --DOC_HEADER -- @staticfct awful.placement.maximize_vertically --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local placement = require("awful.placement") --DOC_HIDE diff --git a/tests/examples/awful/placement/next_to.lua b/tests/examples/awful/placement/next_to.lua index ccaa893e1..833fccecb 100644 --- a/tests/examples/awful/placement/next_to.lua +++ b/tests/examples/awful/placement/next_to.lua @@ -1,5 +1,7 @@ --DOC_GEN_IMAGE --DOC_HIDE local awful = { placement = require("awful.placement") }--DOC_HIDE + +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {x= 0, width = 640, height=200} --DOC_HIDE local parent_client = client.gen_fake {x = 0, y = 0, width=350, height=70} --DOC_HIDE diff --git a/tests/examples/awful/placement/next_to_mouse.lua b/tests/examples/awful/placement/next_to_mouse.lua index 2e34e0ade..c7328f302 100644 --- a/tests/examples/awful/placement/next_to_mouse.lua +++ b/tests/examples/awful/placement/next_to_mouse.lua @@ -1,4 +1,5 @@ --DOC_GEN_IMAGE --DOC_HIDE +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE client.gen_fake {x = 10, y = 10, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/no_offscreen.lua b/tests/examples/awful/placement/no_offscreen.lua index 4b4054ef0..95246b3d6 100644 --- a/tests/examples/awful/placement/no_offscreen.lua +++ b/tests/examples/awful/placement/no_offscreen.lua @@ -1,6 +1,8 @@ --DOC_GEN_OUTPUT --DOC_GEN_IMAGE --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE + --DOC_HIDE no_offscreen is auto-called when startup is true, avoid this. awesome.startup = false -- luacheck: globals awesome.startup --DOC_HIDE diff --git a/tests/examples/awful/placement/no_overlap.lua b/tests/examples/awful/placement/no_overlap.lua index d0fe9b1f2..f295202f7 100644 --- a/tests/examples/awful/placement/no_overlap.lua +++ b/tests/examples/awful/placement/no_overlap.lua @@ -1,4 +1,5 @@ --DOC_GEN_IMAGE --DOC_HIDE +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE screen._add_screen {x = 140, y = 0 , width = 128, height = 96} --DOC_HIDE screen._add_screen {x = 0 , y = 110, width = 128, height = 96} --DOC_HIDE diff --git a/tests/examples/awful/placement/resize_to_mouse.lua b/tests/examples/awful/placement/resize_to_mouse.lua index 01cf64166..fb13b06aa 100644 --- a/tests/examples/awful/placement/resize_to_mouse.lua +++ b/tests/examples/awful/placement/resize_to_mouse.lua @@ -2,9 +2,12 @@ --DOC_GEN_IMAGE local awful = {placement = require("awful.placement")} local unpack = unpack or table.unpack -- luacheck: globals unpack (compatibility with Lua 5.1) - screen._setup_grid(64, 48, {4, 4, 4, 4}, {workarea_sides=0}) +for s in screen do + require("awful.tag").add("1", {screen=s, selected=true}) --DOC_HIDE +end + local function test_touch_mouse(c) local coords = mouse.coords() diff --git a/tests/examples/awful/placement/right.lua b/tests/examples/awful/placement/right.lua index b1f63b66a..c6227532c 100644 --- a/tests/examples/awful/placement/right.lua +++ b/tests/examples/awful/placement/right.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.right --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE local c = client.gen_fake {x = 45, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/skip_fullscreen-no_fullscreen.lua b/tests/examples/awful/placement/skip_fullscreen-no_fullscreen.lua index 7207f4600..060cbcf12 100644 --- a/tests/examples/awful/placement/skip_fullscreen-no_fullscreen.lua +++ b/tests/examples/awful/placement/skip_fullscreen-no_fullscreen.lua @@ -1,6 +1,8 @@ --DOC_GEN_OUTPUT --DOC_GEN_IMAGE --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE + --DOC_HIDE no_offscreen is auto-called when startup is true, avoid this. awesome.startup = false -- luacheck: globals awesome.startup --DOC_HIDE diff --git a/tests/examples/awful/placement/skip_fullscreen.lua b/tests/examples/awful/placement/skip_fullscreen.lua index 2e1e749e8..b3d5ee532 100644 --- a/tests/examples/awful/placement/skip_fullscreen.lua +++ b/tests/examples/awful/placement/skip_fullscreen.lua @@ -1,5 +1,6 @@ --DOC_GEN_OUTPUT --DOC_GEN_IMAGE --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE --DOC_HIDE no_offscreen is auto-called when startup is true, avoid this. awesome.startup = false -- luacheck: globals awesome.startup --DOC_HIDE diff --git a/tests/examples/awful/placement/stretch.lua b/tests/examples/awful/placement/stretch.lua index 696981140..cd1024852 100644 --- a/tests/examples/awful/placement/stretch.lua +++ b/tests/examples/awful/placement/stretch.lua @@ -4,6 +4,9 @@ screen[1]._resize {width = 128, height = 96} screen._add_screen {x = 140, y = 0 , width = 128, height = 96} screen._add_screen {x = 0 , y = 110, width = 128, height = 96} screen._add_screen {x = 140, y = 110, width = 128, height = 96} +for s in screen do + require("awful.tag").add("1", {screen=s, selected=true}) +end local placement = require("awful.placement") for k, pos in ipairs{ diff --git a/tests/examples/awful/placement/stretch_down.lua b/tests/examples/awful/placement/stretch_down.lua index e22caf5d8..2c39c7dbd 100644 --- a/tests/examples/awful/placement/stretch_down.lua +++ b/tests/examples/awful/placement/stretch_down.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.stretch_down --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local placement = require("awful.placement") --DOC_HIDE diff --git a/tests/examples/awful/placement/stretch_left.lua b/tests/examples/awful/placement/stretch_left.lua index db81f765d..e043abe6d 100644 --- a/tests/examples/awful/placement/stretch_left.lua +++ b/tests/examples/awful/placement/stretch_left.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.stretch_left --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local placement = require("awful.placement") --DOC_HIDE diff --git a/tests/examples/awful/placement/stretch_right.lua b/tests/examples/awful/placement/stretch_right.lua index d217a781d..9fe5ac579 100644 --- a/tests/examples/awful/placement/stretch_right.lua +++ b/tests/examples/awful/placement/stretch_right.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.stretch_right --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local placement = require("awful.placement") --DOC_HIDE diff --git a/tests/examples/awful/placement/stretch_up.lua b/tests/examples/awful/placement/stretch_up.lua index 67a2bea75..d569f6ed7 100644 --- a/tests/examples/awful/placement/stretch_up.lua +++ b/tests/examples/awful/placement/stretch_up.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.stretch_up --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local placement = require("awful.placement") --DOC_HIDE diff --git a/tests/examples/awful/placement/top.lua b/tests/examples/awful/placement/top.lua index 60fc17006..756c26162 100644 --- a/tests/examples/awful/placement/top.lua +++ b/tests/examples/awful/placement/top.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.top --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE local c = client.gen_fake {x = 45, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/top_left.lua b/tests/examples/awful/placement/top_left.lua index 339bd9e10..fda50a9dd 100644 --- a/tests/examples/awful/placement/top_left.lua +++ b/tests/examples/awful/placement/top_left.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.top_left --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE local c = client.gen_fake {x = 45, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/top_right.lua b/tests/examples/awful/placement/top_right.lua index 2df7c70a2..7d5b25296 100644 --- a/tests/examples/awful/placement/top_right.lua +++ b/tests/examples/awful/placement/top_right.lua @@ -5,6 +5,7 @@ -- @treturn table The new geometry --DOC_HEADER -- @staticfct awful.placement.top_right --DOC_HEADER +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE local c = client.gen_fake {x = 45, y = 35, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/placement/under_mouse.lua b/tests/examples/awful/placement/under_mouse.lua index 13c034047..53efa7cae 100644 --- a/tests/examples/awful/placement/under_mouse.lua +++ b/tests/examples/awful/placement/under_mouse.lua @@ -1,4 +1,5 @@ --DOC_GEN_IMAGE --DOC_HIDE +require("awful.tag").add("1", {screen=screen[1], selected=true}) --DOC_HIDE screen[1]._resize {width = 128, height = 96} --DOC_HIDE local awful = {placement = require("awful.placement")} --DOC_HIDE client.gen_fake {x = 10, y = 10, width=40, height=30} --DOC_HIDE diff --git a/tests/examples/awful/titlebar/constructor.lua b/tests/examples/awful/titlebar/constructor.lua index a35f0adbd..687bf97c2 100644 --- a/tests/examples/awful/titlebar/constructor.lua +++ b/tests/examples/awful/titlebar/constructor.lua @@ -5,6 +5,8 @@ local awful = { titlebar = require("awful.titlebar"), local beautiful = require("beautiful") local wibox = require("wibox") +require("awful.tag").add("1", {screen=screen[1], selected = true}) + screen[1]._resize { width = 646, height = 182 } local c @@ -38,27 +40,31 @@ c = clients[1] setup( --DOC_HIDE_END - -- Create default titlebar + -- Create default titlebar. awful.titlebar(c) +--DOC_NEWLINE --DOC_HIDE_START ) + c = clients[2] setup( --DOC_HIDE_END - -- Create titlebar on the client's bottom edge + -- Create titlebar on the client's bottom edge. awful.titlebar(c, { position = "bottom" }) --DOC_HIDE_START ) + c = clients[3] setup( --DOC_HIDE_END +--DOC_NEWLINE - -- Create titlebar with inverted colors + -- Create titlebar with inverted colors. awful.titlebar(c, { bg_normal = beautiful.fg_normal, fg_normal = beautiful.bg_normal }) --DOC_HIDE_START diff --git a/tests/examples/awful/titlebar/default.lua b/tests/examples/awful/titlebar/default.lua index 853d04ae5..1ca78a857 100644 --- a/tests/examples/awful/titlebar/default.lua +++ b/tests/examples/awful/titlebar/default.lua @@ -1,14 +1,19 @@ ---DOC_GEN_IMAGE --DOC_HIDE +--DOC_GEN_IMAGE --DOC_NO_USAGE -local place = require("awful.placement") --DOC_HIDE -local awful = { titlebar = require("awful.titlebar"), --DOC_HIDE - button = require("awful.button"), --DOC_HIDE - } --DOC_HIDE -local wibox = require("wibox") --DOC_HIDE -local gears = {table = require("gears.table")} --DOC_HIDE +--DOC_HIDE_START +local place = require("awful.placement") +local awful = { titlebar = require("awful.titlebar"), + button = require("awful.button"), + tag = require("awful.tag"), + } +local wibox = require("wibox") +local gears = {table = require("gears.table")} -local c = client.gen_fake {hide_first=true} --DOC_HIDE -place.maximize(c, {honor_padding=true, honor_workarea=true}) --DOC_HIDE +awful.tag.add("1", {screen=screen[1], selected = true}) + +local c = client.gen_fake {hide_first=true} +place.maximize(c, {honor_padding=true, honor_workarea=true}) +--DOC_HIDE_END -- Create a titlebar for the client. -- By default, `ruled.client` will create one, but all it does is to call this @@ -19,6 +24,8 @@ place.maximize(c, {honor_padding=true, honor_workarea=true}) --DOC_HIDE bg_normal = "#ff0000", }) + --DOC_NEWLINE + -- buttons for the titlebar local buttons = gears.table.join( awful.button({ }, 1, function() @@ -33,7 +40,9 @@ place.maximize(c, {honor_padding=true, honor_workarea=true}) --DOC_HIDE end) ) - top_titlebar : setup { + --DOC_NEWLINE + + top_titlebar.widget = { { -- Left awful.titlebar.widget.iconwidget(c), buttons = buttons, @@ -59,3 +68,4 @@ place.maximize(c, {honor_padding=true, honor_workarea=true}) --DOC_HIDE } --DOC_HIDE vim: filetype=lua:expandtab:shiftwidth=4:tabstop=8:softtabstop=4:textwidth=80 +