GUI discovery
Project description
discogui discovers GUI elements
- Links:
documentation: http://discogui.readthedocs.org
- Features:
python module
works on Linux
does not depend on Accessibility technologies
toolkit independent
only basic tests on very simple GUI
GUI should be displayed on Xvfb or Xephyr
- Known problems:
Python 3 is not supported
slow
- Possible applications:
automatic GUI testing
automatic GUI control
Basic usage
from discogui.buttons import discover_buttons
from easyprocess import EasyProcess
from pyvirtualdisplay import Display
with Display():
with EasyProcess('zenity --question') as p:
p.sleep(1)
buttons = discover_buttons()
print buttons
Installation
General
Ubuntu 14.04
sudo apt-get install python-pip xvfb python-xlib scrot python-pil xdotool sudo pip install https://github.com/pepijndevos/PyMouse/zipball/master sudo pip install discogui
Uninstall
# as root pip uninstall discogui
Usage
basic
Code:
#-- include('examples/basic.py')--#
'''
1. start zenity Yes/No dialog on Xvfb
2. discover buttons using :mod:`discogui.buttons` module
3. print rectangles
'''
from discogui.buttons import discover_buttons
from easyprocess import EasyProcess
from pyvirtualdisplay import Display
def main():
with Display(visible=0):
with EasyProcess('zenity --question') as p:
p.sleep(5)
buttons = discover_buttons()
print( buttons )
if __name__ == '__main__':
main()
#-#
Output:
#-- sh('python -m discogui.examples.basic 2>/dev/null')--#
[ScreenRect((582,407,667,442)), ScreenRect((491,407,576,442))]
#-#
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
discogui-0.1.tar.gz
(47.6 kB
view details)
File details
Details for the file discogui-0.1.tar.gz.
File metadata
- Download URL: discogui-0.1.tar.gz
- Upload date:
- Size: 47.6 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: Python-urllib/2.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
0831a624ccd276e83b21fd5af076026b37edc3c739bdecb04d8252f81d3f3463
|
|
| MD5 |
a9bc6c9f7ff85b242b16a752e25de8f1
|
|
| BLAKE2b-256 |
53c74c74232f34c900c658a6e487f5210124001009790925584f33ad49f6e865
|