awful.widget: use margin instead of spaces
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
842886b7d0
commit
683b1a9572
|
@ -142,10 +142,10 @@ local function widget_tasklist_label_common(c, args)
|
||||||
local bg_focus = args.bg_focus or theme.tasklist_bg_focus or theme.bg_focus
|
local bg_focus = args.bg_focus or theme.tasklist_bg_focus or theme.bg_focus
|
||||||
local fg_urgent = args.fg_urgent or theme.tasklist_fg_urgent or theme.fg_urgent
|
local fg_urgent = args.fg_urgent or theme.tasklist_fg_urgent or theme.fg_urgent
|
||||||
local bg_urgent = args.bg_urgent or theme.tasklist_bg_urgent or theme.bg_urgent
|
local bg_urgent = args.bg_urgent or theme.tasklist_bg_urgent or theme.bg_urgent
|
||||||
local text = ""
|
local text = "<margin left=\"2\" right=\"2\"/>"
|
||||||
local name
|
local name
|
||||||
if c.floating then
|
if c.floating then
|
||||||
text = "<bg image=\"@AWESOME_ICON_PATH@/tasklist/floatingw.png\" align=\"right\"/>"
|
text = text.."<bg image=\"@AWESOME_ICON_PATH@/tasklist/floatingw.png\" align=\"right\"/>"
|
||||||
end
|
end
|
||||||
if c.minimized then
|
if c.minimized then
|
||||||
name = util.escape(c.icon_name) or ""
|
name = util.escape(c.icon_name) or ""
|
||||||
|
@ -156,12 +156,12 @@ local function widget_tasklist_label_common(c, args)
|
||||||
if bg_focus and fg_focus then
|
if bg_focus and fg_focus then
|
||||||
text = text .. "<bg color='"..bg_focus.."'/><span color='"..util.color_strip_alpha(fg_focus).."'>"..name.."</span>"
|
text = text .. "<bg color='"..bg_focus.."'/><span color='"..util.color_strip_alpha(fg_focus).."'>"..name.."</span>"
|
||||||
else
|
else
|
||||||
text = text .. " "..name.." "
|
text = text .. name
|
||||||
end
|
end
|
||||||
elseif c.urgent and bg_urgent and fg_urgent then
|
elseif c.urgent and bg_urgent and fg_urgent then
|
||||||
text = text .. "<bg color='"..bg_urgent.."'/><span color='"..util.color_strip_alpha(fg_urgent).."'>"..name.."</span>"
|
text = text .. "<bg color='"..bg_urgent.."'/><span color='"..util.color_strip_alpha(fg_urgent).."'>"..name.."</span>"
|
||||||
else
|
else
|
||||||
text = text .. " "..name.." "
|
text = text .. name
|
||||||
end
|
end
|
||||||
return text
|
return text
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in New Issue