phpprintipp
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Phpprintipp] Media attributes


From: Thomas Harding
Subject: Re: [Phpprintipp] Media attributes
Date: Sat, 23 Aug 2008 20:17:14 +0200
User-agent: Mutt/1.5.13 (2006-08-11)

On Fri, Aug 22, 2008 at 06:50:39PM +0200, Psou wrote:
> Anyway, there are still two issues that I can't solve while using 
> PrintIPP::getPrinterAttributes() :
> 1 - All kind of attributes which concern media (type, format and source) are 
> mixed in the same attribute : "media_supported". As I want to build a print 
> dialog box, I need to separate these three groups of attributes. I'm quite 
> sure that there is a way to do so, since when I use CUPS http interface, I 
> get three distinct lists of values to set up separately the type (Preprinted, 
> Transparency, Labels...), the format (Letter, A4, ...)  and the source (Auto, 
> Tray1, Tray2,...) of paper.

Well: Maybe CUPS http interface uses "CUPS-Get-Printer" operation, with
'all' for requested-attributes. CUPS-Get-Printer is not yet supported
by php::print::ipp (I think it didn't exists as I wrote CUPS front-end).

What you describe ("mixed response") is "media-supported" attribute 
response to Get-Printer-Attributes operation, which is the standard
IPP response.

Howether, you can try this to collect a complete (but standard) response:
//$requested_attributes = array('job-sheets-supported','media-supported');
$requested_attributes = array('all');
$ipp->setAttribute('requested-attributes',$requested_attributes);
$ipp->getPrinterAttributes();
var_dump($ipp->printer_attributes);

I think it is not in my documentation :(

Currently, there is a lot CUPS specific operations not handled by CUPS
php::print::ipp frontend, and I have no time to implement them, at least
before october.

I will thanks anyone who will take a look to
http://www.cups.org/documentation.php/spec-ipp.html
then implement missings in php::print::ipp (and there is not only CUPS
specific stuff!). There are also some operations already coded but
nether tested because CUPS was not ready...

I recall the cvs:
cvs -z3 -d:pserver:address@hidden:/sources/phpprintipp co phpprintipp

Patches could be sent in this ML.

> 2 - Some attributes, which are only available with one specific 
> printer/driver, are not  returned in the list of attributes 
> (watermark-text-supported or watermark-font-supported on a HP LaserJet, ...). 
> How can I get all the attributes available with one printer ?

Try the piece of code I wrote above, but there is no warranty...

Again, it depends on CUPS's response to standard IPP's Get-Printer-Attributes
query. 

-- 
=== The BOFH Excuse Server ===
Your excuse is: Vendor no longer supports the product




reply via email to

[Prev in Thread] Current Thread [Next in Thread]