Open Source Android Apps for Developers: Android-vnc-viewer (VNC viewer client for Android platform)

Cute Android: Open Source Android Apps for Developers: Android-vnc-viewer (VNC viewer client for Android platform)

Android-vnc-viewer is an open source Android app which is a VNC viewer for Android platform. Android-vnc-viewer is forked from tightVNC viewer. This project is still under development. android-vnc-viewer lets you use your Android mobile device as a client for a VNC server. It is a work in progress and still has a number of limitations. Android-vnc-viewer is now available on Android Market. The latest development builds will still be available here.

Project Home

Project owners
herbage, ipauldev, James.Moger, googlec…, koansin.tan

Latest Version (Build 182 – 20100819)
* Support for UltraVNC windows authentication
* Meta-characters for Hangul input


QR code

Source Code
# Non-members may check out a read-only working copy anonymously over HTTP.
svn checkout android-vnc-viewer-read-only

Using android-vnc-viewer

android-vnc-viewer lets you use your Android mobile device as a client for a VNC server. It is a work in progress and still has a number of limitations.
Connection Configuration

When you first open android-vnc-viewer, you will see a connection configuration page. Here you can set up a connection with a VNC server, or choose an already configured connection.

The page is divided into two sections. The top section contains a drop-down list of the connection configurations you’ve created. The first time you run android-vnc-viewer, this list will have only one entry: New. Select New when you want to create a new configuration.

Next to the list is a Connect button. The Connect button will start the VNC client with the currently selected configuration.

The bottom section of the page is where you enter your connection configurations. There are more options than will fit on the page, so this section scrolls.

Nickname Each configuration you create can have a nickname which will make it easy to find in the list. Enter that name here.

Password If your VNC server is configured to require a password, enter that password here. Most configuration settings are stored in a simple database on your device. The password will only be stored if you check Keep; otherwise, you will have to re-enter it when you recall a configuration. Even if the password is not stored in the database, it will remain available on the page for as long as android-vnc-viewer runs on your device.

Address This is where you enter the DNS name or IP address of the computer running the VNC server to which you want to connect.

Port Here you should enter the port number of the VNC server. This field will default to the first VNC port number, 5900.

Color Format The client supports a number of color formats, which are specified by number of colors/number of bits per pixel. Formats with more bits per pixel provide greater fidelity to high color depth displays, but use more bandwidth (sometimes dramatically more because they don’t compress as well) and more CPU on your Android device. Not all VNC servers support all color depths; OS/X Remote Desktop for example requires 24-bit color. If you are having trouble connecting, try another color depth.

Use local mouse pointer Some VNC servers (notably OS/X desktop sharing) will not draw the mouse pointer on the client; it’s hard to use them without knowing where the mouse is. Checking this option will cause android-vnc-viewer to draw a small square cursor at the mouse position (it’s not the actual mouse cursor, but it’s better than nothing).

Force full-screen bitmap The VNC client requires a bitmap for it’s representation of the display. For a VNC server serving a large display, this bitmap might require more memory than Android allows in an application. To work with these large displays, android-vnc-client breaks large display into smaller tiles and works with only one tile at a time. Unfortunately, this will sometimes create some visual artifacts. In particular, when a large display is in Fit to Screen mode only a portion of it will be visible, and in 1:1 mode as you pan over a large display you might see different parts of the display flicker in. android-vnc-client will only use tiling if it thinks the display is too large to fit in memory, but you can override this decision and always turn off tiling by checking Force full-screen bitmap. This might cause the application to crash on connection.

Repeater Press this button if you are using an UltraVNC repeater to connect to your VNC server. In this case, you should have entered the address and the port of the repeater in those fields; in the repeater dialog you should enter the VNC server address from the repeater and the screen id or port number, separated by colons.

The menu on this page allows you to Delete unneeded connection configurations; to Save as Copy an existing connection to base a different configuration from it; or to open this Manual/Wiki.

VNC Client

After you press the connect button, android-vnc-viewer will try to connect to the specified VNC server. If it is able to handshake, authenticate and download the first frame, you will be able to see and control the served display.

In general, VNC servers expect clients with a full keyboard, a mouse and a generously-sized screen. Because the Android device lacks these, android-vnc-client has some special adaptations to make it usable.


The served display can be shown on the Android device in three modes. You can switch between the modes with the Scaling (Menu-Z) menu item.

Zoomable is the default mode with the latest version of android-vnc-viewer. It allows you to select one of a number of zoom levels on the fly, so you can see more of your screen or zoom in for more accurate touch control. To some extent it supercedes the other modes, but it will use slightly more battery power.

1:1 mode shows the display with pixels mapped one-to-one. Typically, only a portion of the served display will show on the Android device; you can pan around the display with the device controls.

Fit to Screen mode scales the full display so it will fit on the device screen. This doesn’t work properly with large displays, since the phone can’t fit them all into its memory.

Input Modes

There are several modes for adapting the input controls of the Android device to the VNC display, to enable a style of interaction most convenient for the applications you are using. You can switch between these modes with the Input Mode (Menu-P) menu item.

Touch Mouse Pan and Zoom This is the default input mode and is designed to work like the Android browser. You can both pan the display and control the mouse using the touchscreen and gestures. You pan by dragging or flicking on the touchscreen; you click the mouse by tapping on it. You right-click by double-tapping (or by holding down the camera button while tapping). You drag the mouse by doing a long press on the display, and then dragging. In this mode the trackball or DPad (if your phone has one) can also be used to control the mouse; this may give you finer control. You can zoom the screen size with the +/- buttons, or, if your device supports multi-touch and has Android 2.0+, you can pinch to zoom out and spread to zoom in.

Touchpad Mode This is the alternate gesture-based interface. In this mode, touching the screen moves the mouse cursor like a mouse touchpad. The screen will pan to follow the mouse (unless you turn it off). Tapping the screen clicks the mouse, where it is rather than where you tap. For multi-touch capable devices, drag two fingers to pan the screen independent of the mouse position. Otherwise, it works like Touch Mouse Pan and Zoom.

No Pan; Trackball Mouse This mode is only available in Fit to Screen scaling and is the only input mode available then. In this mode the touchscreen is not used. Keyboard events are sent to the server and the trackball (if your device, like the G1, has a trackball) controls the VNC mouse.

Desktop Panning Mode In this mode, both the touchscreen and the trackball are used to pan the device display over the larger VNC display. Keyboard events are sent to the server. Pressing the trackball toggles between Desktop Panning and Mouse Pointer Control modes.

Mouse Control Mode In this mode, use the touchscreen to control the mouse. Touching the screen generates a mouse click at that point; dragging on the screen creates a mouse drag. Keyboard events are sent as normal. The trackball is used to send arrow-key events to the VNC server. Pressing the trackball toggles between Mouse Pointer Control and Desktop Panning modes.

Touch Pan; Trackball Mouse In this mode, drag on the touchscreen to pan the device display over the VNC display. Keyboard events are sent to the server. The trackball controls the VNC mouse. Pressing the trackball sends a mouse click; holding the ball down while rolling accomplishes a click and drag. This is the default input mode when scaling is set to One-to-One.

DPad Pan; Touch Mouse In this mode, use the directional pad (available on some devices) to pan the display over the VNC display. Touch the screen to send a mouse click; touch and slide to send a mouse drag. Use the camera button while touching the screen to simulate a right-button click or drag.

Special Controls

Some special controls try to make up for missing features of an Android device (i.e., a G1) as a VNC controller.

* To use the right mouse button, hold down the Camera button while clicking as appropriate for the selected input mode (touching the screen or clicking the trackball). If your phone has no dedicated camera button, you can send a right click by double-tapping or with the _Send Keys_ menu item.

* To send the Esc key, press the Back button on the device.

* To send the arrow keys, roll the trackball in Mouse Pointer Control Mode or use Menu-H,J,K,L for Left, Down, Up, Right

* The Alt button generally is used to send the special symbols that aren’t otherwise available on the keyboard, rather than sending the Alt meta-key over the VNC connection.

* The volume control buttons simulate turning the mouse scroll wheel up or down. (Holding them down doesn’t work, to scroll further click repeatedly).

* To send control keys, function keys and other special keys and combinations see Special Keys.

* To send (or resend) a whole block of text, use the Send Text menu option.

Other Menu Items

Send Keys (Menu-S) This opens the Special Keys dialog to let you configure and send special keys and combinations.

Mouse @ (Menu-M) Warps the VNC mouse to the center of the portion of the display shown on your device.

Send Text (Menu-E) Opens a dialog that lets you enter a block of text that can then be sent to the server. Useful for phones without a physical keyboard.

Color Mode (Menu-C) Allows you to switch the Color Mode of your connection.

Pan Follows Mouse (Menu-F) The display will automatically pan to follow the mouse around the screen

Mouse follow pan If you pan the display so the mouse moves off the visible portion of the screen, the mouse will be warped to the middle of the screen. You can use both follow modes together.

Disconnect (Menu-D) Closes the current VNC connection, returning you to the configuration page.

Ctrl-Alt-Del (Menu-A) Sends Ctrl-Alt-Del over the VNC connection.

Info (Menu-I) Gives information about current configuration

Send Key Again (Menu-G) Send the last sent special key again

Special Key

The Send Keys (Menu-S) button opens the Send Special Keys dialog. This allows you to access all the keys on a full-sized keyboard, or to send keys or any mouse button with any combination of the modifiers Shift, Alt and Ctrl. (You might even use it as a touch-screen keyboard, but you would have to be incredibly patient.)

The dialog has checkboxes to select Shift, Alt and Ctrl, and a list of keys to select from. When you have the desired key combination, press the Send button and it will be sent to the VNC server.

Every time you send a special key in this way it is saved to a list. As a shortcut you can select from that list instead of selecting from the list of all the keys.

Actually, multiple lists of special keys are supported. You can use the buttons at the bottom of the scrolling section of the dialog to create a New list or to Copy your list to a new name. This way you can have compact, application specific lists, if you want, for quick access to the keys you need.

An entry on the VNC Client menu lets you re-send the last special key you sent with the shortcut Menu-G.

You can operate this dialog from the keyboard as well as using the touch controls. Press Alt and Shift to toggle those modifiers. Press the Search button to toggle the Ctrl modifier. When you type a regular key on the keyboard, that key plus the selected modifiers will be sent immediately to the server.
Devices without Keyboards¶

android-vnc-viewer can work effectively on devices without physical keyboards. Use the Send Keys menu option to send keystrokes that are commands in themselves (i.e. Alt-Tab). When you need to enter a block of text, use the Enter Text command, type the text with the Android keyboard, and press send. You can edit the text before it is sent to make sure it is correct, and the Enter Text command will remember the texts you’ve sent in that session, so you can send them again quickly (convenient for passwords you have to enter many times).

android-vnc-viewer lets you create home screen shortcuts for quick access to your favorite connections. Long click on the home screen, select Shortcuts in the menu, then scroll down to VNC Connection. You’ll get a page that lists your configured connections. Select one and it will be added to the home screen as a short cut. Selecting a short cut starts that connection immediately.


Posted by Cute Android

Related Android Apps:

  1. Open Source Android Apps for Developers: Graphicpages (A comic viewer for the Android platform)
  2. Open Source Android Apps for Developers: Mustard (StatusNet client for android platform)
  3. Open Source Android Apps for Developers: g2android (A Gallery2 client for the Android platform)
  4. Open Source Android Apps for Developers: Funambol (SyncML client for the Google Android mobile platform)
  5. Open Source Android Apps for Developers: Androidchat (Open source IRC client for the Android platform)
  6. Open Source Android Apps for Developers: Android-vnc (Framebuffer VNC server specifically for the emerging Android platform)
  7. Open Source Android Apps for Developers: Android-vnc-server (Android VNC Server)
  8. Open Source Android Apps for Developers: APDFViewer (A PDF file viewer for Android platform)
  9. Open Source Android Apps for Developers: Twitli (Open Source Twitter client for Android)
  10. Open Source Android Apps for Developers: Daap-client (DAAP Client for Android OS)