Design Scanner Gnome Scan Infrastructure


You may know that i'm currenlty working on a librarized xsane
replacement. Obviously, the project is dual headed : in one hand a
scanner API and in the other hand an UI API. I build a review of current
scan UI at in order to
point out wrong and good ideas. If you can put those ideas in the wiki , that would be helpful. As this is
my first project any help in library design are very very welcome.

Here are some thoughts about Gnome Scanning :

     1. Scanner have multiple use - The first 4 are to be implemented in
        my Google SoC project - :
              * Simple case :	I want to have a picture of a business
                card. No matter of color, transformation, resolution, i
                just want it as i saw it in real world (e.g. blank
                cropped, 1:1 scale, etc.)
              * Advanced case : i want to scan a picture as material for
                graphism or similar. I want to choose resolution,
                colorspace etc.
              * Album case :	I have ton of old photos i want to numerize
                and burn to CD. I have an ADF and i want to put all
                those photo, select format of photo and launch mass
                acquisition into that album.
              * Document case :	I have a 10 page printed document i want
                to import. I select "New document from scanner". I have
                flatbed. I then put the first page, acquisition begin,
                for each page acquired, programm ask me to put the next
                page or stop. When all acquisition is done, the OCR tool
                is launch and i get a new document containing the text
              * Fax case :	I want to fax a page with my flatbed scanner
                and my modem. I don't want to bother colorspace nor
                resolution. Just select scanner if needed, contact phone
                in addressbook and scan each page i want to send.
     2. According to Review of Dialog, use all-in-one interface for all
        of these use drove to far too complex UI that rebut most users
        (see xsane/quiteinsane).
     3. Gimp plugin is useful. Integration in application is a must
        feature we have to ship. Standalone scan app (e.g. scan+save to
        file) is useful only for basic use. In other cases, Application
        itself use scan feature like print feature : menu entry+dialog.
        That make scan feature easier to access.
     4. Scanner options are of two kind : persistent options and
        acquisition option. We must have two tools for each kind of
        options. A capplet configure persistent options. Applications
        configure acquisition options. UI expose some options the
        application wants the user to modify for his convenience.
     5. UI should be modular. Applications are able to decide which
        options does not worth to let user changing it (e.g. colorspace
        for fax is allways B&W ; resolution for basic scanning is always
        screen resolution, mostly 96dpi), and which options worth to be
        set internally or just using gconf (not exposed via UI).
     6. Each UI must allow choose of device if multiple.
     7. According to Wizard are used by standalone all-in-one scan tool.
        Wizard used are long (e.g. VueScan). We must not use wizard.
        KISS. Scan UI must be a Acquisition Settings Dialog. Like print
        dialog. (did you ever see a wizard for printing ?)

In a more technical point of view, here is a braindump of app workflow
to show how they might use the library. I consider using two library
libgnomescan an libgnomescanui (remember the dual-headed library above).

     1. App initialise Scan Context.
     2. App configure hidden settings (such as mono/multi scan,
        colorspace, etc.).
     3. App build UI using libgnomescanui widgets (devices selector,
        preview widget, etc.) connecting widgets with Context.
     4. App trigger launch of Dialog.
     5. Widgets set Context Acquisition options.
     6. Widget launchs acquisition.
     7. Library show Acquisition dialog showing progress. Dialog ask for
        next page in flatbed step by step multi scan.
     8. For each picture acquired, app receive a gdkpixbuf using signal.
     9. Once acquisition is done, quit UI
    10. App free all stuffs.

This is just my current view of the workflow. I'll be very happy to have
a review by you !

I also wonder how we can learn lesson from libgnomeprint{ui,} and
gtkprint work.


Verso l'Alto !

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]