JavaFX Printing on Android

68 views
Skip to first unread message

Dino Quimson

unread,
Jul 15, 2015, 12:06:32 AM7/15/15
to javafx...@googlegroups.com
I have a Datamax O'Neil printer (portable printer which uses Bluetooth and Wifi technology), One of the requirements of my JavaFX application is to be able to print a receipt. I wonder if this is supported in JavaFX Printing API? Can someone show me how to do it? 

matt....@gmail.com

unread,
Jul 16, 2015, 1:31:57 AM7/16/15
to javafx...@googlegroups.com
Hi Dino,

As far as i'm aware each printer is different and requires drivers added to the phone to print. Applications specific to a user's printer will have file encoding and a set message packet format to send over wifi or bluetooth. These apps also set up a printing service that can run in the background and allow you to print.

This is where to start reading on the subject: https://developer.android.com/reference/android/printservice/package-summary.html

Depending on the development time you have on your project, I would allow the user to export the receipt to the externalStorage/Document (or Downloads) and let the printer app for the user's printer do the printing.

I know, HP, Fuji Zerox and Brother have their own apps that easily print to their branded printers.

riva...@gmail.com

unread,
Aug 5, 2015, 8:46:51 PM8/5/15
to JavaFXAndroid
There is printing support in Android starting with Kitkat (4.4). Most printer brands support it already. It would be nice to have JavaFX printing API supported on top of Android Printing API...
Reply all
Reply to author
Forward
0 new messages