gnu.x11.extension
Class XTest

java.lang.Object
  extended by gnu.x11.extension.Extension
      extended by gnu.x11.extension.XTest

public class XTest
extends Extension

XTEST Extension. The specification can be found here (protocol).


Field Summary
static int BUTTON_PRESS
           
static int BUTTON_RELEASE
           
static int CLIENT_MAJOR_VERSION
           
static int CLIENT_MINOR_VERSION
           
static int KEY_PRESS
           
static int KEY_RELEASE
           
static java.lang.String[] MINOR_OPCODE_STRINGS
           
static int MOTION_NOTIFY
           
 int server_major_version
           
 int server_minor_version
           
 
Fields inherited from class gnu.x11.extension.Extension
display, first_error, first_event, major_opcode, name
 
Constructor Summary
XTest(Display display)
           
 
Method Summary
 boolean compare_cursor(Window window, Cursor cursor)
           
 void fake_button_event(int button, boolean press, int delay)
           
 void fake_input(int type, int detail, int delay, Window root, int x, int y)
           
 void fake_key_event(int keycode, boolean press, int delay)
           
 void fake_motion_event(Window root, int x, int y, boolean relative, int delay)
           
 void grab_control(boolean impervious)
           
 java.lang.String more_string()
          Additional information such as client version and server version to display in toString().
 
Methods inherited from class gnu.x11.extension.Extension
toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

MINOR_OPCODE_STRINGS

public static final java.lang.String[] MINOR_OPCODE_STRINGS

CLIENT_MAJOR_VERSION

public static final int CLIENT_MAJOR_VERSION
See Also:
Constant Field Values

CLIENT_MINOR_VERSION

public static final int CLIENT_MINOR_VERSION
See Also:
Constant Field Values

server_major_version

public int server_major_version

server_minor_version

public int server_minor_version

KEY_PRESS

public static final int KEY_PRESS
See Also:
Constant Field Values

KEY_RELEASE

public static final int KEY_RELEASE
See Also:
Constant Field Values

BUTTON_PRESS

public static final int BUTTON_PRESS
See Also:
Constant Field Values

BUTTON_RELEASE

public static final int BUTTON_RELEASE
See Also:
Constant Field Values

MOTION_NOTIFY

public static final int MOTION_NOTIFY
See Also:
Constant Field Values
Constructor Detail

XTest

public XTest(Display display)
      throws NotFoundException
Throws:
NotFoundException
See Also:
XTestQueryExtension
Method Detail

compare_cursor

public boolean compare_cursor(Window window,
                              Cursor cursor)
Parameters:
cursor - possible: Cursor.NONE, Cursor.CURRENT
See Also:
XTestCompareCursorWithWindow

fake_input

public void fake_input(int type,
                       int detail,
                       int delay,
                       Window root,
                       int x,
                       int y)
Parameters:
type - valid: KEY_PRESS, KEY_RELEASE, BUTTON_PRESS, BUTTON_RELEASE, MOTION_NOTIFY
time - possible: Display.CURRENT_TIME

grab_control

public void grab_control(boolean impervious)
See Also:
XTestGrabControl

fake_button_event

public void fake_button_event(int button,
                              boolean press,
                              int delay)
See Also:
XTestFakeButtonEvent

fake_key_event

public void fake_key_event(int keycode,
                           boolean press,
                           int delay)
See Also:
XTestFakeKeyEvent

fake_motion_event

public void fake_motion_event(Window root,
                              int x,
                              int y,
                              boolean relative,
                              int delay)
See Also:
XTestFakeMotionEvent

more_string

public java.lang.String more_string()
Description copied from class: Extension
Additional information such as client version and server version to display in toString().

Overrides:
more_string in class Extension