google-cloud-print

Print to Google Cloud Print with dynamic URL

廉价感情. 提交于 2019-12-04 19:51:57
I'd like a "print" button on my web-site to print a document with Google Cloud Print, but I want the "url" of the target – a PDF file – to change dynamically, after the button has been clicked (notably, based on what's returned from an AJAX call). The GCP Web Element (GCPWE) seems to have similar functionality, but not quite what I desire. In particular, it seems as though one can only change the "target" (by calling setPrintDocument ) before the button is clicked. Is there a way to specify the URL for GCPWE after the button has been clicked? Here's the example code from the GCPWE site: <div

Any Cloud Print API For ANDROID

江枫思渺然 提交于 2019-12-04 17:55:41
Does anyone know if there is a Cloud print API for Android? .To develop our own Cloud print Apk for Android device. Any tutorial or Sample code for this will be helpful There is an Google Cloud Print API available which I wrote a while back: http://cloudx.fun2code.de/en/api.html JavaDoc and examples are also available. For a more detailed example have a look at the blog entry: http://fun2code-blog.blogspot.de/2011/10/setting-up-cloud-print-printer-using.html Hope that helps... Check this for Google Cloud Print integration with Android. https://developers.google.com/cloud-print/docs/android

How to print a WebView?

橙三吉。 提交于 2019-12-04 14:21:08
My Android app renders a WebView containing a canvas. Cloud Print wants a PDF. How can I generate a PDF with my WebView to send to Cloud Print? Ed Kirk You could first capture the canvas as a png: (taken from stackoverflow answer ) var canvas = document.getElementById("mycanvas"); var img = canvas.toDataURL("image/png"); Then next step get this into a pdf. I haven't seen a javascript based converter, but one could send the png to a custom web service (perhaps running on Google Apps, Amazon AWS or a traditional hosted machine) which simple returns a pdf. ImageMagick could be used here with a

Print Intent for Google Cloud Print App

随声附和 提交于 2019-12-04 13:39:41
As of today, the official Cloud Print documentation from Google still tells you to include the PrintDialogActivity into your app to print documents using Google Cloud Print. However, it's now also possible to print using the official Google Cloud Print app. I couldn't find any documentation for that though. The answer is pretty straightforward, but it still took me a few days to figure it out: Intent printIntent = new Intent(Intent.ACTION_SEND); printIntent.setType("text/html"); printIntent.putExtra(Intent.EXTRA_TITLE, "some cool title for your document"); printIntent.putExtra(Intent.EXTRA

Google cloud print API key

≡放荡痞女 提交于 2019-12-04 10:04:50
问题 I would like to call /search api from javascript client side. To do so, I have read that I need a oauth2 access token. Following the Google guide, I must go to Google cloud Console but there is no Google Cloud Print service to subscribe to. What service should I use to obtain an API key? 回答1: I recently started getting familiarized with both Google Cloud Print and OAuth, so I don't know much. I started in the same way that you seem to be starting. That is, by trying to make a successful

Google cloud print API key

放肆的年华 提交于 2019-12-03 03:56:26
I would like to call /search api from javascript client side. To do so, I have read that I need a oauth2 access token. Following the Google guide, I must go to Google cloud Console but there is no Google Cloud Print service to subscribe to. What service should I use to obtain an API key? I recently started getting familiarized with both Google Cloud Print and OAuth, so I don't know much. I started in the same way that you seem to be starting. That is, by trying to make a successful request to /search . I will describe what worked for me. After creating the project in the Cloud Console, I went

google cloud print from android without dialog

拈花ヽ惹草 提交于 2019-11-30 21:28:46
Can someone tell me if it is possible to silently print using google cloud print from an android device? The goal is that my app grabs a file from a URL or from the SD card and then sends it to a specific printer - all without interaction from anyone looking at the screen or touching anything. It will actually be triggered by a barcode scan on a blue tooth connected device. Thanks César Augusto Muñoz Quintero Well, it is possible but I don't know why there's not too much information about it in the documentation... The tricky part is connecting to the google cloud print API using only the

Printing via Google Cloud Print

梦想的初衷 提交于 2019-11-30 05:37:51
问题 I am trying to print a .txt file that my application saves via FileWriter. The file it saves is /sdcard/StudentLatePass.txt When the print button is clicked, the SD file is saved and then it needs to print. I've been following the google cloud print tutorial. package com.android.upgrayeddapps.latepass; import java.io.File; import java.io.FileOutputStream; import java.io.OutputStreamWriter; import android.app.Activity; import android.app.AlertDialog; import android.content.Context; import

Printer settings with Google Cloud Print

天大地大妈咪最大 提交于 2019-11-30 05:18:20
Anybody that ever wanted to do unattended printing from the browser knows that's not an easy task and on the other hand it is something very useful for any back-office application. Then Google came to save us with GCP. So I got it setup and in a few minutes I had a document printed. But then I wanted to apply some settings to the printer. And this is the moment you realise the documentation is completely lacking on this. It's not even explained how to do something as simple as setting the page to landscape. The documentation only says that you have to send a capabilities parameter in XPS or

Printer settings with Google Cloud Print

狂风中的少年 提交于 2019-11-29 03:01:16
问题 Anybody that ever wanted to do unattended printing from the browser knows that's not an easy task and on the other hand it is something very useful for any back-office application. Then Google came to save us with GCP. So I got it setup and in a few minutes I had a document printed. But then I wanted to apply some settings to the printer. And this is the moment you realise the documentation is completely lacking on this. It's not even explained how to do something as simple as setting the