Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

window.print() does not work #56

Open
niloy opened this Issue · 60 comments
@niloy

Tested on Ubuntu 12.04
nw version: 0.2.5

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

@zcbenz

Confirmed, currently we don't have support for printing, it could be implemented in future.

@riggerthegeek

+1 for window.print() support.

I've forked this project to see if I can add it - can I have some clue as to where I might need to look to add window.print()?

@rogerwang
Owner

@riggerthegeek , you can find how it was implemented in the 'browser' component of Chromium and port it to Content Shell

@rogerwang
Owner

please refer to this commit in upstream for reference: https://src.chromium.org/viewvc/chrome?view=rev&revision=140725

@riggerthegeek

Thanks Roger.

@zcbenz zcbenz was assigned
@rogerwang rogerwang was assigned
@rogerwang
Owner

@riggerthegeek is there any progress on your side? or we'll start working on this feature.

@riggerthegeek

@rogerwang I had a look at it, but bravely moved onto something else

@TamerZorba

printing is the most requested important feature we hope you add as soon as possible

@prophet

Agreed - very important!

@cmpscabral

@rogerwang any progress on this issue? is there something I can help with?

@rogerwang
Owner

it's working in progress.

The work include moving bunch of code from chrome/browser/printing & chrome/browser/ui/webui/print_preview to the content shell. The hard thing is to cut the dependencies on profile and others of the browser component. So it may not to be done in this release.

@cmpscabral

@rogerwang thanks for the update :)

@cmpscabral

@rogerwang Hi Roger, any news on this issue? Thanks!

@rogerwang
Owner

I'm still moving the print view support from browser to content shell, which need some effort. The print backend support would be simpler.

I'll put the code WIP into a branch so the progress would be more visible. thanks

@cmpscabral

thanks for the update :)

@rogerwang
Owner

Due to the demand on this feature, we'd like to put it as the top 1 in TODO list for major features. And in our release plan soon to be announced, it will be in our next major release (0.5.0), which is scheduled in late March.

@riggerthegeek

Great news

@cmpscabral

great news :)

@zycbob

looking forward to this feature, thanks!

@ntankovic

One more team looking forward to this! Great project, thanks!

@Denouncer

Also looking forward to this feature - a must!

Will the printing functionality support the "--kiosk-printing" parameter, similar to the current kiosk mode for silent printing?

@zaceno

For my current project I will soon have to chose wether to implement the reporting feature with a pdf-generation library, or rely on the printing in node-webkit. Obviously I would prefer the latter. So I'm very interested in hearing how this feature is coming along. (seeing that the issue is "due" in just a day now). PS: Great work so far on this project -- you are doing a great service to many a developer.

@rogerwang
Owner
@zaceno

Thanks for the update, Roger. I understand these things take time and will be patiently awaiting 0.5.0. I can live without the preview for now, but it will be very good to have as well, when it comes.

@Xanor

@rogerwang when is the expected release date for 0.5.0?

@rogerwang
Owner

FYI. Print support (window.print) is released in 0.5.0 RC: https://groups.google.com/d/msg/node-webkit/QactmnGNN3Q/prWFJ2znIEIJ

Print preview support will be added before 0.5.2

@cmpscabral

Hi Roger, great news, can't wait to try it out!

@monolighter

It's nice to see window.print(), but how it printed ?
By screenshot of current frame ?
node: "0.8.17"
node-webkit: "0.5.0-rc"
Hope print will have landscape option and margin props ;)

@zaceno

Just realized I never came back here to say a big thank you to @rogerwang for getting printing support in. So far it's working out great. Huge props!

@riggerthegeek

Seconded

@jonathandelgado

Big +1 From me. Glad to see this is being worked on.

@bear888 bear888 referenced this issue
Closed

Print Preview #1139

@pushpak

+1 for @Denouncer 's request

--kiosk-printing parameter would be a great.

Currently i tried adding this parameter to the args like "chromium-args" : "--kiosk-printing", but it didnt work.

@DanielVF

Should this issue be closed?

@jonathandelgado

@DanielVF No, it hasn't been implemented; note the TBD milestone.

@DanielVF

@jonathandelgado Gotcha. I had thought from the announcement that it was released.

@Mithgol

That announcement says that window.print() works but print previews do not.

It's just that — no one bothered to create yet another issue for the print preview feature, and the lack of previews is what is holding this issue currently.

@jonathandelgado

In addition, there was talk about implementing a silent print API, not sure if that is still in the works.

@theHazzard

is there any progress with the print preview feature?

@bradbamford

+1 for silent print

@Nithanaroy

+1 for Silent Printing...
Any place where I can try to read and implement from, may be from chromium code?

@chriddyp

Would print preview allow for programmatic "save page as pdf"? that's something I would love for my app right now

@inluxc

+1

@derekgeneric

+1 silent printing / kiosk printing

@0000marcell

is someone working in print preview ?

@theHazzard

+1 for print preview

@Rameshv

+1 for print preview

@navinkrishnan

Any progress on print preview ?

@tomorrownull

+1 for Silent Printing.

@bmatusiak-irf

+1 for Silent Printing.

@TuanAnh207

+n for print preview !!!!!!

@JaredCubilla

+1 for Print Preview

@inluxc

I have the last version and can not print in windows with mozilla pdfjs. But it works in mac and linux. Pdfjs is in a iframe.

@mahavirjain

Any update regarding Print Preview Feature.?

@majodev

+1

@aramirez92

+1 for silent printing

@hvva

NW 0.12.0 - window.print() stopped working. 0.11.6 was working fine.

@baconface

I am 1+ for silent printing.

However. I might add printing and even silent printing can be done in NW.js using node. Possible methods:

  • Use a printing NPM
  • Execute a batch or shell script by calling it with node.js/io.js
  • Send one with node.js/io.js via the IPP / network printer
@simoami

+1 for silent printing!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.