Lines Matching defs:option
19 * License, or (at your option) any later version.
711 * @param opt - string that keeps the option name to check src for
715 * @return The function returns SANE_TRUE if the option has been found,
724 /* skip the option string */
725 name = (const char*)&src[strlen("option")];
727 /* get the name of the option */
735 DBG( _DBG_SANE_INIT, "Decoding option >%s<\n", opt );
739 /* assign the default value for this option... */
757 /* assign the default value for this option... */
781 * @param src - string that keeps the option name to check src for
964 if( 0 == strncmp(str, "option", 6)) {
1190 SANE_Status sane_control_option( SANE_Handle handle, SANE_Int option,
1206 if((option < 0) || (option >= NUM_OPTIONS))
1215 switch (option) {
1224 *(SANE_Word *)value = s->val[option].w;
1230 (s->val[option].w << SANE_FIXED_SCALE_SHIFT);
1237 s->opt[option].constraint.string_list[s->val[option].w]);
1246 memcpy( value, s->val[option].wa, s->opt[option].size );
1255 status = sanei_constrain_value( s->opt + option, value, info );
1260 if( SANE_CONSTRAINT_STRING_LIST == s->opt[option].constraint_type ) {
1262 optval = search_string_list( s->opt[option].constraint.string_list,
1268 switch (option) {
1285 s->val[option].w = (SANE_Word)best;
1303 s->val[option].w = *(SANE_Word *)value;
1309 s->val[option].w = *(SANE_Word *)value;
1325 if( SANE_TRUE == s->val[option].w ) {
1351 s->val[option].w =
1388 s->val[option].w = optval - s->opt[option].constraint.string_list;
1392 s->val[option].w = optval - s->opt[option].constraint.string_list;
1397 if( s->val[option].w == 0 ) {
1415 if( s->val[option].w == 1 ) {
1447 memcpy( s->val[option].wa, value, s->opt[option].size );
1465 /** according to the option number, return a pointer to a descriptor
1468 sane_get_option_descriptor( SANE_Handle handle, SANE_Int option )
1472 if((option < 0) || (option >= NUM_OPTIONS))
1475 return &(s->opt[option]);