Lines Matching defs:option
10 License, or (at your option) any later version.
1422 sane_get_option_descriptor (SANE_Handle handle, SANE_Int option)
1426 DBG (DBG_proc, "sane_get_option_descriptor: enter, option %d\n", option);
1428 if ((unsigned) option >= OPT_NUM_OPTIONS)
1435 return dev->opt + option;
1439 sane_control_option (SANE_Handle handle, SANE_Int option,
1447 DBG (DBG_proc, "sane_control_option: enter, option %d, action %d\n",
1448 option, action);
1460 if (option < 0 || option >= OPT_NUM_OPTIONS)
1465 cap = dev->opt[option].cap;
1474 switch (option)
1485 *(SANE_Word *) val = dev->val[option].w;
1491 strcpy (val, dev->val[option].s);
1499 memcpy (val, dev->val[option].wa, dev->opt[option].size);
1511 DBG (DBG_error, "could not set option, not settable\n");
1515 status = sanei_constrain_value (dev->opt + option, val, info);
1518 DBG (DBG_error, "could not set option, invalid value\n");
1522 switch (option)
1535 dev->val[option].w = *(SANE_Word *) val;
1540 dev->val[option].w = *(SANE_Word *) val;
1545 if (strcmp (dev->val[option].s, val) == 0)
1603 free (dev->val[option].s);
1604 dev->val[option].s = (SANE_String) strdup (val);
1622 memcpy (dev->val[option].wa, val, dev->opt[option].size);