13

Linux窗口管理器下的截图

 3 years ago
source link: https://jiajunhuang.com/articles/2020_07_25-linux_screenshot.md.html
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.

Linux窗口管理器下的截图

Linux使用窗口管理器时,也想做到截图然后保存到剪贴板,之后就可以到处贴比如贴到虚拟机里的Windows,不过如果直接使用截图 工具的话,是没有办法保存到剪贴板的,不过使用xclip可以做到。我使用的是XMonad,加这么一行:

((mod4Mask, xK_a), spawn "sleep 0.2; scrot -s -e 'xclip -selection clipboard -t \"image/png\" < $f && rm $f'")

这样就可以使用 Win + a 快捷键来进行截图了,注意前面的 sleep 0.2,如果没有这一行,scrot也没有办法成功调用。

这个办法同样也适用于其它窗口管理器,例如i3, openbox, awesome等。


微信公众号
关注公众号,获得及时更新

工作一年的总结

Python 的继承

MongoDB 的一些坑

Python的yield关键字有什么作用?

借助coroutine用同步的语法写异步

Python3函数参数中的星号

使用Git Hooks

Token Bucket 算法

nginx配置笔记

阅读Flask源码

尤克里里

学习使用Bootstrap4的栅格系统

利用Github的WebHook完成自动部署

使用Tornado和rst来写博客

Haskell do notation




About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK