Skip to content

Instantly share code, notes, and snippets.

@blueyed
Created February 19, 2015 14:14
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save blueyed/366754effedfe6e68d05 to your computer and use it in GitHub Desktop.
Save blueyed/366754effedfe6e68d05 to your computer and use it in GitHub Desktop.
-- Add tooltip to tasklist {{{
-- Ref: https://awesome.naquadah.org/bugs/index.php?do=details&task_id=1250
-- NOTE: interferes/prevents sloppy focus when coming through the tooltip.
local my_tasklist_update = function(w, buttons, label, data, objects)
awful.widget.common.list_update(w, buttons, label, data, objects)
for _,o in ipairs(objects) do
if not data[o].tooltip then
data[o].tooltip = awful.tooltip({
objects = { data[o].tb },
delay_show = 1,
})
-- Change textbox (once).
data[o].tb:set_ellipsize("middle")
end
data[o].tooltip:set_text(data[o].tb._layout.text)
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment