This site has been retired. For up to date information, see handbook.gnome.org or gitlab.gnome.org.


[Home] [TitleIndex] [WordIndex

{i} This document state about GnomeScan 0.6 redesign

1. Introduction

1.1. Scanning in Gnome

Currently, Gnome desktop provide nothing about scan. Distro has to include third party software (often xsane) which do not fit Gnome HIG and does not integrate well in Gnome desktop (xsane is just a Gtk+ app including a Gimp plugin).

1.2. GnomeScan Lames As For 0.4

GnomeScan has been fastly design in order to provide a proof of concept implementation during the Google Summer of code 2006. Gnome Scan design now shows his lame.

As GnomeScan is moving to full Gnome infrastructure, i (ÉtienneBersac) take that opportunity to fix GnomeScan design. This time, i really want to design Gnome Scan in a way consistent with GtkPrint.

1.3. What Exists

1.4. GnomeScan Goals

2. Job

While printing let app do their one pre processing before sending job to printer, scanning imply a lot of post processing. The overall process (called job) is divided in three parts for each page : acquiring, processing, outputing. Acquiring is done through scanner, files, etc.. Processing si done through Gegl. Outputing is done by app. Gnome Scan will provide common output plugin like images, basic PDF and OCR.

2.1. Configuring

A job contains all the objects selected to acquire, process and output the data. It also contains all the settings for the objects.

2.2. Acquiring

We'll have to implement different backend for scanner. file and sane backends will be implemented, each using a shared object.

2.2.1. Scanner Parameters

An issue with scanner is the huge variety of scanner. SANE solve it partially by using an undefined set of options. The same way, we must implement such option handling in gnome-scan. While GObject properties are fixed in class definition, scanner "params" are not. Also, GObject param specs does not fit scanners needs. We will define our own set of GParamSpecs. All of scanner GParamSpecs will include the following extra properties :

Following the list of GSParamSpecs :

GParamFlags are also restrictive for scanner. Here is GSParamFlags values :

2.2.2. Scanner Signals

When gnome-scan is running, it own scanner so we must implement our own event monitoring system. A list of signals will be declared. All signals have a signal spec, having the following properties :

The scanner object will emit an "event" signal with the SignalSpec and a GValue containing event specific data (e.g. a gboolean for paper-in signal; an error enum value, etc.).

2.3. Processing

Gegl is a rocking base for processing. It already includes tons of operation and is easy to integrate in Gnome Scan thanks to GLib type system. GeglProcessor allow to monitor progress. However, GeglOperation are not really UI friendly. We should provide some tiny wrappers around one or more GeglOperation and expose some options to the UI.

2.4. Outputing

Outputing means writing to file, importing in app, etc. The output of the process pipeline is a GdkPixbuf. It's then up to the output backend to do whatever he wants. Output must be configurable. However, Output parameters use the same param specs than input, in order to build an efficien user interface.

3. User Interface

3.1. Dialog

The main widget is the GnomeScanDialog with the following spec

3.2. Option widget

A widget handling all options types.

3.3. Progress Dialog

This widget is an internal widget which handle the acquisition process and show post processing progress. It allow user to cancel a running task, and trigger acquisition of next frame.

3.4. Preview Area

A good idea is to provide a GnomeScanPreviewArea widget whith the following specs :

4. Implementation

diagramme.png

This diagram does not contains all class. I added GnomeScanModule and GnomeScanModuleManager for handling plugin loading. Also, the diagram does not documents signals.

5. App/Plugins

5.1. Standalone Scanning App

5.2. Gimp Plugin

5.3. F-Spot Plugin

5.4. Abiword Plugin

5.5. Evolution Plugin

6. Open questions

7. Links

8. Comments


2024-10-23 11:28