cups printing UTF-8 text/plain document empty on opensuse 11.4

This is just to understand how things work or not work!

My printers are a Samsung laser and an Epson Dot-matrix. I am writing an Indian language document using kwrite. I can print alright from kwrite. Also, the same document I can compose on Libreoffice and print perfect. No issue there.

I tried printing kwrite file (*.txt) dircet from ‘lp’. Now, the Indian language characters in the document are left blank. But the English language characters print. To understand what is happening, I read up a bit on cups and looked up the spool control file. When printing from kwrite , the spool control file sees the mime as application/pdf. See below.

cat c00033
Gattributes-charsetutf-8Httributes-natural-languageen-inE
printer-uri’ipp://localhost:631/prinprinttest.txtIdocument-formatapplication/pdfDmediaLetter!
job-priority2job-uuid-urn:uuid:6ee6edc9-a427-3bb3-6752-401957080557Bjob-originating-host-name localhost!time-at-creationN]��time-at-processing!time-at-completedN]��!job-id!# job-state!▒job-media-sheets-completedEjob-printer-uri)ipp://linux-pbod.site/printers/epsonlx300!
job-k-octetsDjob-hold-untilno-holdB
job-sheetsnoneBnone

If I direct print the same document using ‘lp’ command, the mime is seen as text/plain.

linux-pbod:/var/spool/cups # cat c00035
Gattributes-charsetutf-8Httributes-natural-languageen-inE
printer-uri’ipp://localhost:631/printers/epsonlx300Bjob-originating-user-namepbhatjob-name printtestIdocument-format
text/plain!copies#
finishingsBjob-hold-untilno-hold!
job-priority2B
job-sheetsnoneBnone! number-upjob-uuid-urn:uuid:90085c8c-66d8-393a-4d07-c4fe107a8911Bjob-originating-host-name localhost!time-at-creationN]��time-at-processing!time-at-completedN]�!job-id## job-state!▒job-media-sheets-completedEjob-printer-uri)ipp://linux-pbod.site/printers/epsonlx300!
job-k-octets

I understand that. kwrite is converting to pdf before sending to print-spooler. For ‘lp’ , the document remains a plain/text document.

But what I do fail to understand is, the text/plain document should have been processed by spooler(cups) filter texttops and then printer filter foomatic-rip. If such processing had taken place, the print output should have been equal to what kwrite produces. I suspect cups is sending it raw to the printer and as printer does not understand the UTF-8 encoded characters, not have the font, is not able to print. Now, my questions are,

  1. Isn’t cups ( here, ‘lp’) supposed to process text/plain before sending to printer,?

  2. OR is it that cups is missing something like the font information while processing and hence is not able to process the Indian language characters, encoded in UTF-8.

How to find out?

Thanks.

Some more inputs.

My system language is set to en_IN.UTF-8(RC_LANG=en_IN.UTF-8) and all other parameters are not set in /etc/sysconfig/language.

Cups is obviously seeing the encoding correct. I also understand cups supports only UTF-8 now. So, why it is printing only ASCII chararcters and not non-ASCII utf-8 characters?