awful: move taglist label in label.all
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
112f0863dc
commit
4e081e7c2a
|
@ -84,7 +84,7 @@ mytaglist:mouse_add(mouse({}, 3, function (object, tag) tag.selected = not tag.s
|
||||||
mytaglist:mouse_add(mouse({ modkey }, 3, function (object, tag) awful.client.toggletag(tag) end))
|
mytaglist:mouse_add(mouse({ modkey }, 3, function (object, tag) awful.client.toggletag(tag) end))
|
||||||
mytaglist:mouse_add(mouse({ }, 4, awful.tag.viewnext))
|
mytaglist:mouse_add(mouse({ }, 4, awful.tag.viewnext))
|
||||||
mytaglist:mouse_add(mouse({ }, 5, awful.tag.viewprev))
|
mytaglist:mouse_add(mouse({ }, 5, awful.tag.viewprev))
|
||||||
function mytaglist.label(t) return awful.widget.taglist.label(t, bg_focus, fg_focus) end
|
function mytaglist.label(t) return awful.widget.taglist.label.all(t, bg_focus, fg_focus) end
|
||||||
|
|
||||||
-- Create a tasklist widget
|
-- Create a tasklist widget
|
||||||
mytasklist = widget({ type = "tasklist", name = "mytasklist" })
|
mytasklist = widget({ type = "tasklist", name = "mytasklist" })
|
||||||
|
|
|
@ -45,6 +45,7 @@ P.client = {}
|
||||||
P.tag = {}
|
P.tag = {}
|
||||||
P.widget = {}
|
P.widget = {}
|
||||||
P.widget.taglist = {}
|
P.widget.taglist = {}
|
||||||
|
P.widget.taglist.label = {}
|
||||||
P.widget.tasklist = {}
|
P.widget.tasklist = {}
|
||||||
P.widget.tasklist.label = {}
|
P.widget.tasklist.label = {}
|
||||||
|
|
||||||
|
@ -758,14 +759,14 @@ function P.unescape(text)
|
||||||
return text
|
return text
|
||||||
end
|
end
|
||||||
|
|
||||||
--- Return labels for a taglist widget.
|
--- Return labels for a taglist widget with all tag from screen.
|
||||||
-- It returns the tag name and set a special
|
-- It returns the tag name and set a special
|
||||||
-- foreground and background color for selected tags.
|
-- foreground and background color for selected tags.
|
||||||
-- @param t The tag.
|
-- @param t The tag.
|
||||||
-- @param bg_focus The background color for selected tag.
|
-- @param bg_focus The background color for selected tag.
|
||||||
-- @param fg_focus The foreground color for selected tag.
|
-- @param fg_focus The foreground color for selected tag.
|
||||||
-- @return A string to print.
|
-- @return A string to print.
|
||||||
function P.widget.taglist.label(t, bg_focus, fg_focus)
|
function P.widget.taglist.label.all(t, bg_focus, fg_focus)
|
||||||
local text = ""
|
local text = ""
|
||||||
if t.selected then
|
if t.selected then
|
||||||
text = "<bg color='"..bg_focus.."'/> <span color='"..fg_focus.."'>"..t.name.."</span> "
|
text = "<bg color='"..bg_focus.."'/> <span color='"..fg_focus.."'>"..t.name.."</span> "
|
||||||
|
|
Loading…
Reference in New Issue