[Printing-architecture] Get all the job attributes

Michael Sweet msweet at apple.com
Mon Apr 15 16:25:08 UTC 2019


> On Apr 5, 2019, at 4:31 AM, Deepak Patankar <patankardeepak04 at gmail.com> wrote:
> ...
> 1. The media-col attribute is not returned in the request. How I can change the request to get media-col ?

It will only be returned if it was sent in the original print request.  Currently we do not synthesize IPP attributes when the Job is created, just when it gets sent to an IPP printer.

If you'd like us to do so, please file a bug at:

    https://github.com/apple/cups/issues <https://github.com/apple/cups/issues>


> 2. The paper type is given as "MediaType Envelope", How I can get the media-type from the response ? I tried: 
>            if ((attr = ippFindAttribute(response, "MediaType", 
>         IPP_TAG_KEYWORD)) != NULL && ippGetCount(attr)>0){

MediaType (like all PPD options sent as attributes) will have the IPP_TAG_NAME syntax.

>              if ((attr = ippFindAttribute(response, "media-type", 
>         IPP_TAG_KEYWORD)) != NULL && ippGetCount(attr)>0){

while "media-type" (the IPP attribute) can be IPP_TAG_NAME or IPP_TAG_KEYWORD, so here I'd usually look for IPP_TAG_ZERO and check for a NULL string value (which would indicate something that is not a name or keyword).

Michael Sweet, Senior Printing System Engineer

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.linuxfoundation.org/pipermail/printing-architecture/attachments/20190415/b038232d/attachment.html>

More information about the Printing-architecture mailing list