arch截屏工具--shutter(图形化) / scort(命

作者: Gaarahan | 来源:发表于2018-09-01 22:30 被阅读8次

    在初步配置完自己的arch+i3-gaps之后,当然需要一个截屏工具来分享,最开始选择的是scrot,用了一段时间后,发现scrot有很多不便的地方,必须命令行使用,无法复制到剪贴板,换了shutter,又见到了网上有改造scort的方法,因此都纪录了下来


    0. 桌面截屏镇楼

    1. scrot

    • 最开始选择的是scrot,网上一搜就有推荐的,就顺手装了一个,使用也比较简单,简单罗列几个常用的
      scrot [option] [file] -----基本格式 scrot 参数 文件名
    • 参数
      -d NUM -------延迟NUM秒后截屏

      -c -----搭配-d,显示延时的倒计时

      -s -------手动框选截图(没法截图,自己体验)
      scrot -s xxx.png

    搭配xclip截图并粘贴到剪贴板(手动划重点)

    • 安装xclip
      yaourt -S xclip
    • 配置快捷键操作
      注意: 个人自制操作,较为麻烦,但使用上完美还原我在Ubuntu时的截屏操作
    • 首先将如下代码写入i3配置文件
    # cut all the screen 
    bindsym  --release Print exec "sh ~/.config/i3/screencut/cut_all.sh"
    # cut current window
    bindsym --release $mod+Print exec "sh ~/.config/i3/screencut/cut_cur.sh"
    # cut selection 
    bindsym --release $mod+Shift+Print exec "sh ~/.config/i3/screencut/cut_sel.sh"
    
    • 分别建立上面代码中的多个shell文件,内容如下:

    ~/.config/i3/screencut/cut_all.sh

    scrot -e 'xclip -selection clipoard -t "image/png" $f && mv $f ~/Picture/ScreenShortcut/%Y-%m-%d_%H:%m_desktop.png'
    

    ~/.config/i3/screencut/cut_cur.sh

    scrot -u -b -m -e 'xclip -selection clipoard -t "image/png" $f && mv $f ~/Picture/ScreenShortcut/%Y-%m-%d_%H:%m_current.png'
    

    ~/.config/i3/screencut/cut_sel.sh

    scrot -s -b -m -e 'xclip -selection clipoard -t "image/png" $f && mv $f ~/Picture/ScreenShortcut/%Y-%m-%d_%H:%m_select.png'
    
    • mod+shift+r刷新一下桌面,就可以用了
      PrtSc ---直接截取全屏并复制到剪贴板
      mod + PrtSc ---截取当前活动窗口并复制到剪贴板
      mod + shift + PrtSc ---框选截屏并复制到剪贴板
    • 注意 : 上面的文件路径以及文件名都是个人自定义,可选择自己喜欢的路径及文件名
    • 个人配置, 如果你有更好的建议,欢迎帮我做出改进_

    2. shutter

    安装

    yaourt -S shutter
    按照指引安装软件及依赖即可

    • 图形化的软件,界面设计也很简洁,就不多做介绍

    绑定到快捷键

    将软件的启动绑定到快捷键,方便使用

    bindsym $mod+Print exec shutter


    这样就可以使用键盘上的PrtSc键来快速启动shutter了,但是实际上个人感觉不如上面的配置好用

    相关文章

      网友评论

        本文标题:arch截屏工具--shutter(图形化) / scort(命

        本文链接:https://www.haomeiwen.com/subject/nfkuwftx.html