When I print using PDF or HTML using the corresponding DocFlavor, how come it is printed as garbage or plain text?
First, do not assume that any of the defined DocFlavors are supported. Use the PrintService’s isDocFlavorSupported to find out which flavors are supported. If you find out that it is not supported but know that your printer can handle this then you may go ahead and print it using the DocFlavor.xxx.AUTOSENSE. This is equivalent to printing a raw data. If on the other hand your printer does not support it you need to write your own PrintService which handles the conversion from PDF/HTML to the printer language e.g. PostScript.
Related Questions
- When print the PDF from Acrobat Reader, the rotated text watermark with opacity cannot be printed correctly on some types of printers. Why?
- When I print using PDF or HTML using the corresponding DocFlavor, how come it is printed as garbage or plain text?
- Whats the difference between the HTML Editor and the Plain Text Editor?