Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Paste from outside VNC does not work #3

Open
greenrd opened this issue Jan 25, 2016 · 5 comments
Open

Paste from outside VNC does not work #3

greenrd opened this issue Jan 25, 2016 · 5 comments

Comments

@greenrd
Copy link
Contributor

greenrd commented Jan 25, 2016

Here on Fedora, TigerVNC is being picked up and used - not sure if that's relevant.

@feklee
Copy link
Owner

feklee commented Jan 25, 2016

Just contacted the current maintainer of GTK VNC, the VNC library that vncdesk relies on. In the options I couldn't find anything concerning copy and paste, and with the included example viewer gvncviewer it doesn't work.

BTW, I just pushed a new version, with updated version numbers for GTK (needs 3) and GTK VNC:

gi.require_version('Gtk', '3.0')
gi.require_version('GtkVnc', '2.0')

@dmoebius
Copy link

There are two errors. First, configure_xvnc() in vnc_server.py has an error: the check for "vncconfig -list" is missing the "-display" parameter, leading always to the message "vncconfig not available". I changed the following lines:

    system("vncconfig -list >/dev/null 2>&1" +
           " && (vncconfig -nowin -display=:" + str(_number) + " &)" +
           " || echo 'vncconfig not available'")

to:

    system("vncconfig -display=:" + str(_number) + " -list >/dev/null 2>&1" +
           " && (vncconfig -nowin -display=:" + str(_number) + " &)" +
           " || echo 'vncconfig not available'")

This is at least a step in the right direction. I can now connect to Xvnc using:

$ vncdesk 1 &
$ vncviewer -PasswordFile  ~/.vncdesk/1/.passwd -Shared :1

and clipboard works in the vncviewer. But it doesn't work in the GtkVnk widget created by vncdesk. Seems there's a bug with this widget. I searched Gnome's bugzilla, but didn't find anything.

A wild guess: could it be that the vncdesk client must implement/react on the signal "vnc_server_cut_text" in main.py ?!? See https://lazka.github.io/pgi-docs/GtkVnc-2.0/classes/Display.html for API docs.

@dmoebius
Copy link

It really seems that vncdesk must implement cut/copy/paste in both directions, using signal "vnc_server_cut_text" and method "vnc_client_cut_text". Vinagre does the same, see methods vnc_server_cut_text_cb and vinagre_vnc_tab_paste_text in https://github.com/GNOME/vinagre/blob/master/plugins/vnc/vinagre-vnc-tab.c

@feklee
Copy link
Owner

feklee commented Aug 16, 2016

configure_xvnc() in vnc_server.py has an error: the check for "vncconfig -list" is missing the "-display" parameter, leading always to the message "vncconfig not available".

Not necessary over here, on an Arch system. Anyhow, I added the display parameter. AFAICT it doesn’t hurt. New release is 1.4.1. Thanks for the report!

Thanks also for the link to the vinaigre code. Perhaps it allows me to figure out how to implement copy & paste. Patches are always welcome. ;)

@feklee
Copy link
Owner

feklee commented Aug 24, 2016

@dmoebius Just tried Vinagre 3.20.2, but copy and paste doesn’t work. Does it for you?

With TightVNC it does work when connecting to the exact same VNC server. vncclient -nowin is running on that server.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants