Code Documentation

client Module

Twisted based VNC client protocol and factory

  1. 2010 Marc Sibson

MIT License

vncdotool.client.ImageFactory()[source]

Wrap importing PIL.Image so vncdotool can be used without PIL being installed. Of course capture and expect won’t work but at least we can still offer key, type, press and move.

class vncdotool.client.VNCDoToolClient[source]

Bases: vncdotool.rfb.RFBClient

bell()[source]
buttons = 0
captureRegion(filename, x, y, w, h)[source]

Save a region of the current display to filename

captureScreen(filename)[source]

Save the current display to filename

cmask = None
commitUpdate(rectangles)[source]
copy_text(text)[source]
cursor = None
deferred = None
drawCursor()[source]
expectRegion(filename, x, y, maxrms=0)[source]

Wait until a portion of the screen matches the target image

The region compared is defined by the box (x, y), (x + image.width, y + image.height)

expectScreen(filename, maxrms=0)[source]

Wait until the display matches a target image

filename: an image file to read and compare against maxrms: the maximum root mean square between histograms of the

screen and target image
keyDown(key)[source]
keyPress(key)[source]

Send a key press to the server

key: string: either [a-z] or a from KEYMAP

keyUp(key)[source]
mouseDown(button)[source]

Send a mouse button down at the last set position

button: int: [1-n]

mouseDrag(x, y, step=1)[source]

Move the mouse point to position (x, y) in increments of step

mouseMove(x, y)[source]

Move the mouse pointer to position (x, y)

mousePress(button)[source]

Send a mouse click at the last set position

button: int: [1-n]

mouseUp(button)[source]

Send mouse button released at the last set position

button: int: [1-n]

paste(message)[source]
pause(duration)[source]
screen = None
updateCursor(x, y, width, height, image, mask)[source]
updateRectangle(x, y, width, height, data)[source]
vncConnectionMade()[source]
vncRequestPassword()[source]
x = 0
y = 0
class vncdotool.client.VNCDoToolFactory[source]

Bases: vncdotool.rfb.RFBFactory

clientConnectionFailed(connector, reason)[source]
clientConnectionMade(protocol)[source]
force_caps = False
nocursor = False
password = None
protocol

alias of VNCDoToolClient

pseudocusor = False
shared = True

Table Of Contents

Previous topic

Release History

This Page