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

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

Closed
totaam opened this issue Jul 10, 2017 · 9 comments

Comments

@totaam
Copy link
Collaborator

totaam commented Jul 10, 2017

Issue migrated from trac ticket # 1572

component: html5 | priority: major | resolution: invalid | keywords: html5 printing

2017-07-10 13:35:30: radzz created the issue


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-15455-1	i386 	tool to detach/reattach running X programs
@totaam
Copy link
Collaborator Author

totaam commented Jul 10, 2017

2017-07-10 13:45:51: antoine changed status from new to closed

@totaam
Copy link
Collaborator Author

totaam commented Jul 10, 2017

2017-07-10 13:45:51: antoine set resolution to invalid

@totaam
Copy link
Collaborator Author

totaam commented Jul 10, 2017

2017-07-10 13:45:51: antoine edited the issue description

@totaam
Copy link
Collaborator Author

totaam commented Jul 10, 2017

2017-07-10 13:45:51: antoine commented


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.

@totaam totaam closed this as completed Jul 10, 2017
@totaam
Copy link
Collaborator Author

totaam commented Jul 10, 2017

2017-07-10 14:02:15: radzz commented


Thanks for quick reply.

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

@totaam
Copy link
Collaborator Author

totaam commented Jul 10, 2017

2017-07-10 14:15:59: antoine commented


See #1573.

@totaam
Copy link
Collaborator Author

totaam commented Jul 10, 2017

2017-07-10 14:18:53: radzz commented


Thanks Antoine.

Will look into it.

@totaam
Copy link
Collaborator Author

totaam commented Jul 13, 2017

2017-07-13 11:24:58: radzz commented


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 !!

@totaam
Copy link
Collaborator Author

totaam commented Jul 13, 2017

2017-07-13 11:33:52: antoine commented


See [/wiki/Printing?action=diff&version=24 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)

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

1 participant