mapping a printer model with an Appropriate ppd file
Michael Sweet
mike at easysw.com
Tue Nov 27 09:03:13 PST 2007
svalbard wrote:
> Hi all,
>
> I am currently working on building a GUI to be interfaced with CUPS 1.3.4 package; In my GUI I have a list of printer manufacturers mapped
> With various printer models ; and for a particular printer model selected I needed to know how to map that model with an Appropriate ppd file; as I am using lpadmin command to configure a printer and it has an option of specifying –m model.ppd ;and I needed this mapping of the model with the corresponding ppd file to be used in the lpadmin command ;else it takes it as a raw printer.
>
> How do I handle the mapping?? and how to place this in the lpadmin command.
>
> Any help in this regard will be greatly appreciated.
Best thing to do is use the CUPS APIs directly. The CUPS_GET_DEVICES
operation lists the available devices, ad the CUPS_GET_PPDS operation
can be used to lookup PPDs that match the make, model, and device ID
of an individual device...
Once you find the matching driver, use the CUPS_ADD_MODIFY_PRINTER
operation to add the printer with the device URI and PPD name you
got from the other two requests.
--
______________________________________________________________________
Michael Sweet, Easy Software Products mike at easysw dot com
Internet Printing and Document Software http://www.easysw.com
More information about the cups
mailing list