Job title character set?

Michael Sweet mike at easysw.com
Thu May 5 18:35:08 PDT 2005


Ken Herron wrote:
> I have a UTF-16 string which I want to use as the job title when
> calling cupsPrintFile(). The SPM description doesn't mention the
> expected character set for the job title argument, and all the
> examples use simple ASCII.
> 
> I want to make sure the title that I pass is handled properly by
> whatever backend receives the job, e.g. the title displays properly
> in a print-queue list. Can I downconvert to UTF8 and expect that to
> be handled properly? If not, what about downconverting to the
> character set returned by cupsGetLangDefault()? Or is ASCII the only
> character set I can use reliably?

ASCII is the only charset that will work across all protocols; all
IPP implementations must at least support UTF-8, and what we do now
for protocols that don't support UTF-8 is a simple replacement of
each non-ASCII character with a "_" when passing the job.

Currently the web interface purposely doesn't specify the character
set - this is a known bug that will be fixed in CUPS 1.2 which will
only support UTF-8 and US-ASCII over the wire and transcode to/from
the locale charset as needed...

-- 
______________________________________________________________________
Michael Sweet, Easy Software Products           mike at easysw dot com
Internet Printing and Publishing Software        http://www.easysw.com




More information about the cups-devel mailing list