Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

discovers GUI elements

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 discogui
Octocat-spinner-32 docs
Octocat-spinner-32 tests
Octocat-spinner-32 .gitignore
Octocat-spinner-32 LICENSE.txt
Octocat-spinner-32 MANIFEST.in
Octocat-spinner-32 README.rst
Octocat-spinner-32 TODO
Octocat-spinner-32 pavement.py
Octocat-spinner-32 requirements.txt
Octocat-spinner-32 setup.py
Octocat-spinner-32 tox.ini
README.rst

discogui discovers GUI elements

Links:
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
  • slow
Known problems:
  • Python 3 is not supported
Possible applications:
  • GUI unit-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

  • install Xvfb and Xephyr

  • install Xlib

  • install scrot

  • install PIL

  • install xdotool

  • install pip

  • install latest PyMouse and the program:

    # as root
    pip install https://github.com/pepijndevos/PyMouse/zipball/master
    pip install discogui
    

Ubuntu

sudo apt-get install python-pip
sudo apt-get install xvfb
sudo apt-get install xserver-xephyr
sudo apt-get install python-xlib
sudo apt-get install scrot
sudo apt-get install python-imaging
sudo apt-get install xdotool

# PyPI version of PyMouse is too old, this is the latest
sudo pip install https://github.com/pepijndevos/PyMouse/zipball/master

sudo pip install discogui

Uninstall

# as root
pip uninstall discogui
Something went wrong with that request. Please try again.