Giter Club home page Giter Club logo

foomatic-db-engine's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

foomatic-db-engine's Issues

foomatic-ppdfile does not use manufacturer and model for 1284DeviceID

Windows 10 and 11 require 1284DeviceID to contain MFG and MDL elements, otherwise the shared printer would silently fail upon adding (or install endlessly, without any error).

foomatic-ppdfile, from which foo2zjs generates .ppd files, doesn't seem to use general <manufacturer> and <model> XML elements for 1284DeviceID generation, requiring them to be in <autodetect> section, at least supplied as <generic> autodetect method.

In case of missing <autodetect> section, general <manufacturer> and <model> should be used for 1284DeviceID generation.

Setting pdftops-renderer?

I'm having issues with the default PDF to PS renderer pdftops in ptouch-driver. As explained in the cups-filters README, the pdftops-renderer print option can be set either per job with lpr -o pdftops-renderer=gs or per queue with lpadmin -o pdftops-renderer-default=gs, which makes those issues go away.

The following posting suggests that there's a way to set pdftops-renderer from PPD files as well. However, the following PPD code has no effect:

*OpenUI *pdftops-renderer: PickOne
*Defaultpdftops-renderer: gs
*pdftops-renderer gs/GhostScript: ""
*CloseUI: *pdftops-renderer

Is there a way to define pdftops-renderer or pdftops-renderer-default in a Foomatic xml file? Note that the print option doesn't add any Foomatic command-line arguments like <arg_substitution> or PostScript code like <arg_postscript>. I couldn't figure out a way to pass printer options from the CUPS PPD Extensions specfication, either. Thanks for any help!

Missing *DefaultResolution

When a printer has a Resolution option, foomatic will usually generate code for a user interface element in the PPD file, including a *DefaultResolution statement. When there is only a single choice for the Resolution, something like this will end up in the PPD file instead, however:

*FoomaticRIPOption Resolution: enum CmdLine A 100
*FoomaticRIPOptionSetting Resolution=300dpi: " -r300"

In this case, the *DefaultResolution statement is missing entirely. The problem with that is that the *DefaultResolution statement is meaningful even when there is no choice of resolutions. Without it, users of the PPD file will have no idea what the resolution of the printer should be.

A workaround for this is to add a <ppdentry> to the printer definition, but since foomatic does know the resolution, it should really be smart enough to add the *DefaultResolution entry automatically.

Allow printers to hard-wire values of options

I'm looking for a reasonable way to hard-wire the value of an option for a specific printer. For example, with the following shortened definition, I can define the default value of the option:

<option type="enum" id="opt/Resolution">
  <arg_longname><en>Resolution</en></arg_longname>
  <arg_shortname><en>Resolution</en></arg_shortname>
  <arg_execution> ... </arg_execution>
  <constraints>
    <constraint sense="true">
      <driver>driver</driver>
      <printer>printer</printer>
      <arg_defval>ev/300dpi</arg_defval>
    </constraint>
  </constraints>
  <enum_vals>
    <enum_val id="ev/300dpi">
      <ev_driverval>300</ev_driverval>
      ...
    </enum_val>
    <enum_val id="ev/600dpi">
      <ev_driverval>600</ev_driverval>
      ...
    </enum_val>
  </enum_vals>
</option>

If I add constraints on the enum_vals so that only a single option remains available for a printer, the option will disappear fro user interfaces and it will effectively be hard-wired.

However, for options that always have exactly one value for each supported printers, this still requires adding an enum for each possible choice, and some boilerplate code. It obviously doesn't work at all for options that have free values.

What I'd ideally like to do is to directly define the driverval, so something like <arg_val>300</arg_val> instead of <arg_defval>ev/300dpi</arg_defval>. Is there a way to do that already?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.