awesomewm/modules/screenshot/init.lua

46 lines
701 B
Lua
Raw Normal View History

2022-07-16 17:41:00 -07:00
local script = conf_dir .. "modules/screenshot/screenshot.fish"
script = script .. " "
2022-08-01 15:00:16 -07:00
local function screenshot_action(mode)
awful.spawn(script .. mode, false)
2022-07-16 17:41:00 -07:00
end
return {
keybinds = gears.table.join(
awful.key( {}, "Print",
function ()
2022-08-01 15:00:16 -07:00
screenshot_action("normal")
2022-07-16 17:41:00 -07:00
end,
{
description = "Take a screenshot",
2022-08-01 15:00:16 -07:00
group = "Screenshot"
}
),
awful.key( {"Control"}, "Print",
function ()
screenshot_action("ocr")
end,
{
description = "OCR Capture",
group = "Screenshot"
}
),
awful.key( {"Shift"}, "Print",
function ()
screenshot_action("pin")
end,
{
description = "Pin a screenshot",
group = "Screenshot"
2022-07-16 17:41:00 -07:00
}
)
)
}