矩形屏幕区域的几何图形
python-xrectsel的Python项目详细描述
python x矩形选择
矩形屏幕区域的几何结构
这个项目的想法基于xrectsel
https://github.com/lolilolicon/xrectsel。
安装:
pip3 install python-xrectsel --user
用法:
Usage: xrectsel [OPTIONS] Options: -f, --format TEXT Format string... %x - start x-coordinate %y - start y-coordinate %X - start %Y - end %w - width %h - height --help Show this message and exit.
- 默认格式是
%wx%h+%x+%y
$ xrectsel $ # select rectangle on sreen 901x634+44+7 #(x-coordinate, y-coordinate, width, height)
- 格式化字符串
$ xrectsel -f "--x=%x --y=%y --width=%w --height=%h" --x=264 --y=387 --width=1204 --height=519