Xpra: Ticket #1572: Will html5 client be able to list client's local printers in browser and print on it !!!!

Will html5 client be able to list client's local printers in browser and print on it !!!! As of xpra desktop client using launcher(windows/ubuntu) does i.e(it shows & prints on local client printers)

Xpra server running on lubuntu 16.04 :  dpkg -l  | grep xpra
ii  xpra  2.1-20170402r15494-1 i386  tool to detach/reattach running X programs

Xpra windows client running on windows 7(32bit) : xpra version 2.0.2

Xpra ubuntu client running on ubuntu 14.04 :

dpkg -l | grep xpra
ii  xpra  1.0.5-r15455-1	i386 	tool to detach/reattach running X programs

Mon, 10 Jul 2017 12:45:50 GMT - Antoine Martin: status, description changed; resolution set

No. Browsers do not allow Javascript code to query the hardware.

(just to clarify: printing from the HTML5 client should already work, and the print dialog should allow you to choose the printer - but this all happens within the brower's UI, client side)

This could be done using a browser extension (ie: activex, flash, native chrome extension, etc) Then we would also need more code to skip the print dialog and go straight to the printer selected.

Mon, 10 Jul 2017 13:02:14 GMT - Rahul Dange:

Thanks for quick reply.

I got your point but are there any pointers / examples for developing native chrome extension !

Mon, 10 Jul 2017 13:15:58 GMT - Antoine Martin:

See #1573.

Mon, 10 Jul 2017 13:18:53 GMT - Rahul Dange:

Thanks Antoine.

Will look into it.

Thu, 13 Jul 2017 10:24:57 GMT - Rahul Dange:

Hi Antione,

Just being curious,

How xpra handles client side printing !!!

For e.g when i connect to xpra server from windows xpra launcher(desktop client) , server shows windows client's local printer in its printer dialog box list and also prints it to clients selected printer correctly, all this done without having python 2.7 installed on that windows machine...

Also in server i saw all windows client printer listed in cups(i.e by command lpstat -v ) and after session disconnect clients printer are gone..

this is just awesome. How it is done !!!

websockify ??? how xpra identify printers and creates printer queue for that session !!

Thu, 13 Jul 2017 10:33:52 GMT - Antoine Martin:

See this printing wiki edit.

The actual code can be found here: browser/xpra/trunk/src/xpra/platform (just look for all the "printing" files there and in each platform specific subfolder)

Sat, 23 Jan 2021 05:28:03 GMT - migration script:

this ticket has been moved to: https://github.com/Xpra-org/xpra/issues/1572