On 4/2/07, Jan Willem Stumpel <[EMAIL PROTECTED]> wrote:
Jeff Zhang wrote: > If you just want to convert txt into ps then pdf, u2ps from > gnome-u2ps will produce better pdf quality with correct embeded > font. I am sorry, I do not agree. Compared to paps, u2ps is a very poor program indeed. - u2ps, unasked, adds a frame around the text and a header. I want a text printer just to print the text that I feed it. With paps, adding headers etc. is just an option. - The margins are wrong (u2ps apparently assumes that I print using US letter paper, which I don't). The man page offers no option to cure this. - u2ps does not seem to use fontconfig (with its automatic font selection fallback). It is basically a "one font" program. If, using u2ps mytest.txt, I try to print a page containing many different languages, box characters, etc., the results are horribly wrong. By default, Chinese, Korean, Japanese, Arabic, Greek, Hebrew, Russian, and all the languages of India are printed only as empty rectangles. - If I specify the option --gpfamily=Freemono, box characters, Greek, and Russian are printed OK; Hebrew is printed, but wrongly; and other scripts not at all (rectangles). - If I specify the option --gpfamily=Code2000, all languages are printed, but not in monospace (you lose the "text printing" feeling; you lose printing boxes made out of utf-8 "box characters"). Also, the right-to-left languages (Hebrew and Arabic) are printed the wrong way round, and the "complex text layout" (Indic) languages are printed wrongly. - u2ps recognizes tabs, but it does not recognize form feeds (which you would want a text printer, a drop-in replacement of an ASCII print system, to do). - u2ps constantly produces weird warnings like ** (gnome-u2ps:7247): WARNING **: IPP request failed with status 1280 ** (gnome-u2ps:7247): WARNING **: IPP request failed with status 1280 (gnome-u2ps:7247): GnomePrint-WARNING **: Problem while creating filter from 'frgba': filter 'frgba' is unknown Maybe this would cure itself if I installed full GNOME, but I don't want to do that. - I have some minor quibbles too, for instance that u2ps by default outputs directly to the print queue, instead of to stdout, as a proper print filter should do. OK, you can *convert* it to a filter by means of -o /dev/stdout. paps has none of these disadvantages. I have not found *one* aspect in which u2ps is better than paps. Also as to print quality (for the characters that *do* get printed) I think u2ps is in no way superior to paps. The paps output can easily be pdf'd by means of ps2pdf. Sorry to be so harsh, but I think I gave arguments. Yes, paps is better than u2ps in function(sure, a2ps will be the best if
not for unicode), however, the pdf produced after ps2pdf is not the case in my own experience. As u2ps can produce TrueType fonts embeded pdf file while paps not. with simple unicode encoding file(test.txt), like: chinese 中文 then produce with: u2ps -X utf8 --gpfamily="Sans 12" test.txt -o u2ps.ps paps --font "Sans 12" <test.txt >paps.ps ps2pdf u2ps.ps ps2pdf paps.ps then run: % pdffonts u2ps.pdf name type emb sub uni object ID ------------------------------------ ------------ --- --- --- --------- GHTXAC+GnomeUni-MicrosoftYaHei_005 TrueType yes yes no 14 0 MGWIUQ+GnomeUni-MicrosoftYaHei_007 TrueType yes yes no 12 0 SPULKW+GnomeUni-MicrosoftYaHei_004 TrueType yes yes no 10 0 EEOVEQ+GnomeUni-MicrosoftYaHei TrueType yes yes no 8 0 % pdffonts paps.pdf name type emb sub uni object ID ------------------------------------ ------------ --- --- --- --------- Helvetica Type 1 no no no 8 0