Call HP Print Service plugin from application?

With Samsung devices, I see that the HP print plug-in is installed, and several applications, such as Gallery, can use it. In any case, the application can call and transmit print data?

+4
source share
1 answer

Android PrintHelper Support Library provides an easy way to print images.

private void doPhotoPrint() {
    PrintHelper photoPrinter = new PrintHelper(getActivity());
    photoPrinter.setScaleMode(PrintHelper.SCALE_MODE_FIT);
    Bitmap bitmap = BitmapFactory.decodeResource(getResources(),
            R.drawable.droids);
    photoPrinter.printBitmap("droids.jpg - test print", bitmap);
}
0
source

Source: https://habr.com/ru/post/1538846/


All Articles