moved to personal fennel config for awesome and added qutebrowser
This commit is contained in:
parent
403cb92b7d
commit
688748f8a6
502 changed files with 8576 additions and 9597 deletions
56
awes2/widget/xdg-folders/videos.lua
Normal file
56
awes2/widget/xdg-folders/videos.lua
Normal file
|
@ -0,0 +1,56 @@
|
|||
local awful = require('awful')
|
||||
local wibox = require('wibox')
|
||||
local gears = require('gears')
|
||||
|
||||
local clickable_container = require('widget.clickable-container')
|
||||
local dpi = require('beautiful').xresources.apply_dpi
|
||||
|
||||
local config_dir = gears.filesystem.get_configuration_dir()
|
||||
local widget_icon_dir = config_dir .. 'widget/xdg-folders/icons/'
|
||||
|
||||
local vid_widget =
|
||||
wibox.widget {
|
||||
{
|
||||
image = widget_icon_dir .. 'folder-videos' .. '.svg',
|
||||
widget = wibox.widget.imagebox,
|
||||
resize = true
|
||||
},
|
||||
layout = wibox.layout.align.horizontal
|
||||
}
|
||||
|
||||
local videos_button = wibox.widget {
|
||||
{
|
||||
vid_widget,
|
||||
margins = dpi(10),
|
||||
widget = wibox.container.margin
|
||||
},
|
||||
widget = clickable_container
|
||||
}
|
||||
|
||||
videos_button:buttons(
|
||||
gears.table.join(
|
||||
awful.button(
|
||||
{},
|
||||
1,
|
||||
nil,
|
||||
function()
|
||||
awful.spawn.with_shell('xdg-open $(xdg-user-dir VIDEOS)')
|
||||
end
|
||||
)
|
||||
)
|
||||
)
|
||||
|
||||
awful.tooltip
|
||||
{
|
||||
objects = {videos_button},
|
||||
mode = 'outside',
|
||||
align = 'right',
|
||||
margin_leftright = dpi(8),
|
||||
margin_topbottom = dpi(8),
|
||||
timer_function = function()
|
||||
return 'Videos'
|
||||
end,
|
||||
preferred_positions = {'right', 'left', 'top', 'bottom'}
|
||||
}
|
||||
|
||||
return videos_button
|
Loading…
Add table
Add a link
Reference in a new issue