Re: Too many options for xscanimage

Chris Pinkham (cpinkham@billing.infi.net)
Mon, 23 Nov 1998 18:04:00 -0500 (EST)

> Yes, there already is the "advanced" option concept. If you mark an
> option as advanced, graphical interfaces such as xscanimage will

I don't know if it is relevant to the backend that started this discussion,
but one thing I did recently with the Artec backend was make sure that only
relevant options are displayed. I think I got the idea from either the
Microtek or Umax backend.

For example, if on the Artec backend, the 'Negative' option is only valid
when in non-color mode, that option will only display when the 'Mode'
option is set to something non-color. This causes the xscanimage to redraw
itself when I change modes, but it can have a few advantages....

1) helps keep the window small if not all options are relevant.
2) possibly eliminate bug reports about "option ABC doesn't work when
I'm in mode XYZ."
3) helps me remember which options are associated with each other. :-)

For those who might not have done this, it's accomplished by toggling
SANE_CAP_INACTIVE for a particular option and then setting the
SANE_INFO_RELOAD_OPTIONS flag. Usually this would be done inside
sane_control_option() in the SANE_ACTION_SET_VALUE part of the if statement.

Chris

*****************************************************************************
** Chris Pinkham Linux v2.0.35, Sane v0.74, Gimp v1.0 **
** cpinkham@sh001.infi.net http://www4.infi.net/~cpinkham/ **
*****************************************************************************

--
Source code, list archive, and docs: http://www.mostang.com/sane/
To unsubscribe: echo unsubscribe sane-devel | mail majordomo@mostang.com