[sane-devel] button query
m. allan noah
kitno455 at gmail.com
Thu Nov 18 12:23:56 UTC 2010
Initial implementation of buttons relied on 'magic' names. Later, this
was changed to use the 'cap' on the option. Look for options with
SANE_CAP_SOFT_DETECT and SANE_CAP_HARD_SELECT
TYPE_BUTTON is really only used to indicate a boolean software option
that won't 'stick'.
On Thu, Nov 18, 2010 at 6:00 AM, Florian Lohoff <f at zz.de> wrote:
> i once wrote a little C app to poll my document scanner (Fujitu fi4120C)
> for the buttons on the front (Function digit, "scan" and "send to").
> I now tried to recompile it against libsane 1.0.21-5 (from 1.0.19-23)
> and now my tool fails.
> After a bit debugging the buttons i found that from the results of
> sane_get_option_descriptor the buttons got renamed
> from e.g. "button-scan" to "scan" and the like.
> So i thought - well - lets see if there is an identifier and found
> that there is "type" in the SANE_Option_Descriptor which in case
> of the scan button is "bool" although there is a TYPE_BUTTON which
> i thought would be a better fit.
> Although it is unclear how i could find the "function" button which itself is
> not queriable but only the digit one can toggle through.
> Its a button but also an integer.
> Hints? Bug? Feature? Incomplete transition in the backend?
> How am i supposed to automatically find the buttons?
> Florian Lohoff f at zz.de
> Professionell gesehen bin ich zu haben ....
> -----BEGIN PGP SIGNATURE-----
> Version: GnuPG v1.4.9 (GNU/Linux)
> -----END PGP SIGNATURE-----
> sane-devel mailing list: sane-devel at lists.alioth.debian.org
> Unsubscribe: Send mail with subject "unsubscribe your_password"
> to sane-devel-request at lists.alioth.debian.org
"The truth is an offense, but not a sin"
More information about the sane-devel