how to print extended ascii code

William Anthony weiliangCDT at gmail.com
Sun Sep 14 20:16:05 PDT 2008


> On 2008 Sep 12, at 23:13, William Anthony wrote:
> >> William Anthony wrote:
> >>> My Java application currently running on windows, and there are
> >>> some printout form that use extended ascii code (128-255), eg: box
> >>> characters.
> >>> When I tested them with cups, it show scrambled characters.
> >>> Is there any workaround? Thanks.
> >>
> >> Those aren't "extended ASCII" (there is no such thing), those are one
> >> of the old IBM code pages, and we do not provide support for them.
> >
> > OK, I understand it's the "old" thing that cups won't support. So,
> > is there the "new" thing cups supported that I can use to implement
> > box characters? Thanks.
>
> CUPS uses UTF-8 Unicode.
>
> It seems to me that with a backend like tea4cups you could wire recode
> into the output filters to convert whatever codepage is being used
> into UTF-8.
>
> --
> brandon s. allbery [solaris,freebsd,perl,pugs,haskell] allbery at kf8nh.com
> system administrator [openafs,heimdal,too many hats] allbery at ece.cmu.edu
> electrical and computer engineering, carnegie mellon university    KF8NH
>
>
I'm quite new to code page thing, after I read somewhere at
http://en.wikipedia.org/wiki/Code_page
http://en.wikipedia.org/wiki/Unicode
http://en.wikipedia.org/wiki/Box_drawing_characters

I tried to replace my box character to unicode, eg:
decimal 201 to \u2554
decimal 218 to \u250c, etc

The result is, no scrambled data anymore, but it shows '?' character. Maybe my printer (LX-300+ II, LQ 2180) don't support unicode, I'm not sure.




More information about the cups mailing list