Lines Matching defs:option

11    License, or (at your option) any later version.
52 . . - sane_get_option_descriptor() : get option information
53 . . - sane_control_option() : change option values
990 /* sanei_scsi_open takes an option bufsize argument */
1412 /* set option defaults */
1497 else if ((t = strstr (s, "option")) != NULL)
1732 sane_get_option_descriptor (SANE_Handle handle, SANE_Int option)
1735 DBG (DBG_proc, ">> sane_get_option_descriptor: %d name=%s\n", option,
1736 s->opt[option].name);
1738 if ((unsigned) option >= NUM_OPTIONS)
1742 s->opt[option].name);
1743 return (s->opt + option);
2042 sane_control_option (SANE_Handle handle, SANE_Int option,
2053 name = s->opt[option].name ? s->opt[option].name : "(nil)";
2056 DBG (DBG_proc, ">> sane_control_option: %s option=%d name=%s\n",
2057 action == SANE_ACTION_GET_VALUE ? "SET" : "GET", option, name);
2061 if (option >= NUM_OPTIONS)
2064 cap = s->opt[option].cap;
2070 DBG (DBG_proc, "sane_control_option get_value option=%d\n", option);
2071 switch (option)
2085 *(SANE_Word *) val = s->val[option].w;
2101 *(SANE_Bool *) val = s->val[option].w;
2124 DBG (DBG_proc, "STRING=%s\n", s->val[option].s);
2125 strcpy (val, s->val[option].s);
2128 (u_long) sizeof (val), (u_long) sizeof (s->val[option].s));
2133 memcpy (val, s->val[option].wa, s->opt[option].size);
2240 DBG (DBG_proc, "sane_control_option:invalid option number %d\n",
2241 option);
2248 switch (s->opt[option].type)
2253 name, option, *(SANE_Word *) val);
2257 name, option, SANE_UNFIX (*(SANE_Word *) val));
2261 name, option, (char *) val);
2265 name, option);
2270 option);
2276 sanei_constrain_value (s->opt + option, val,
2280 switch (option)
2289 if (info && s->val[option].w != *(SANE_Word *) val)
2291 s->val[option].w = *(SANE_Word *) val;
2304 if (info && s->val[option].w != *(SANE_Word *) val)
2313 s->val[option].w = *(SANE_Word *) val;
2326 if (s->val[option].s)
2327 free (s->val[option].s);
2328 s->val[option].s = strdup (val);
2341 s->val[option].w = *(SANE_Word *) val;
2345 memcpy (s->val[option].wa, val, s->opt[option].size);
2350 if (strcmp (s->val[option].s, (SANE_String) val))
2370 if (s->val[option].s)
2371 free (s->val[option].s);
2372 s->val[option].s = strdup (val);
2390 if (info && s->val[option].w != *(SANE_Word *) val)
2392 s->val[option].w = *(SANE_Word *) val;
2397 /* a string option */
2403 if (info && strcmp ((char *) s->val[option].s, (char *) val))
2405 if (s->val[option].s)
2406 free (s->val[option].s);
2407 s->val[option].s = strdup (val);
2426 /* a string option */
2428 if (strcmp (s->val[option].s, (SANE_String) val))
2475 free (s->val[option].s);
2476 s->val[option].s = strdup (val);
2481 if (strcmp (s->val[option].s, (SANE_String) val))
2483 free (s->val[option].s);
2484 s->val[option].s = strdup (val);
2492 /* a string option */
2495 if (strcmp (s->val[option].s, (SANE_String) val))
2535 free (s->val[option].s);
2536 s->val[option].s = strdup (val);
2859 /* Bytes 45, 365 Binary Filtering for lineart and halftone can be set when option IPU is installed */