Added print screenshot command
parent
5dca4a76b4
commit
e8312903db
|
@ -52,5 +52,17 @@ return {
|
|||
group = "Screenshot"
|
||||
}
|
||||
)
|
||||
),
|
||||
|
||||
awful.key( {"Shift", "Control", "Mod1"}, "Print",
|
||||
function ()
|
||||
-- Make sure your default printer is set in CUPS!
|
||||
screenshot_action("lpr")
|
||||
end,
|
||||
|
||||
{
|
||||
description = "Print a screenshot",
|
||||
group = "Screenshot"
|
||||
}
|
||||
)
|
||||
}
|
||||
|
|
|
@ -43,6 +43,14 @@ function capture
|
|||
echo $ocr | sed -e "s/^[ \t]*//" | xclip -i -rmlastnl -selection clipboard
|
||||
rm $tmp_file
|
||||
|
||||
case lpr
|
||||
# Default printer must be set for the lpr command to work.
|
||||
|
||||
# TODO: don't lpr if screenshot is cancelled.
|
||||
flameshot gui --accept-on-select --path $tmp_file
|
||||
convert $tmp_file $tmp_file.pdf
|
||||
lpr -T "Autoprint Screenshot" $tmp_file.pdf
|
||||
rm $tmp_file
|
||||
|
||||
case "*"
|
||||
echo "Unknown action \"$argv[1]\""
|
||||
|
|
Loading…
Reference in New Issue