GnomeScanner

GnomeScanner — Acquisition plugin

Synopsis




typedef             GnomeScanEvent;
                    GnomeScanner;
const gchar*        gnome_scanner_get_icon_name         (GnomeScanner *scanner);

Object Hierarchy


  GObject
   +----GnomeScanPlugin
         +----GnomeScanner

Properties


  "icon-name"                gchararray            : Read / Write / Construct Only
  "sensors"                  gpointer              : Read
  "status"                   GnomeScannerStatus    : Read

Signals


  "event"                                          : Run Last
  "settings-changed"                               : Run Last
  "status-changed"                                 : Run Last

Description

GnomeScanner is the base class for backend specific scanner (like e.g SANE). Following SANE design, Gnome Scan scanner has an undefined set of option. But unlike SANE, the scanner itself handle acquisition.

Each GnomeScanner should monitor its sensor (e.g. paper-in) and trigger an event on sensor state changes.

Details

GnomeScanEvent

typedef gpointer GnomeScanEvent;


GnomeScanner

typedef struct {
  GnomeScannerStatus status;
} GnomeScanner;

A GnomeScanner publish all instance specific plugins parameters and handle the real acquisition work (e.g. throug SANE, TWAIN, etc.)


gnome_scanner_get_icon_name ()

const gchar*        gnome_scanner_get_icon_name         (GnomeScanner *scanner);

Return the icon-name representing the type of the device.

scanner : a GnomeScanner
Returns : a icon-name string

Property Details

The "icon-name" property

  "icon-name"                gchararray            : Read / Write / Construct Only

The icon name representing the device.

Default value: NULL


The "sensors" property

  "sensors"                  gpointer              : Read

A list of sensor specification.


The "status" property

  "status"                   GnomeScannerStatus    : Read

Device status

Default value: GNOME_SCANNER_UNKNOWN

Signal Details

The "event" signal

void                user_function                      (GnomeScanner *scanner,
                                                        gpointer      event,
                                                        gpointer      user_data)      : Run Last

Emitted when an hardware event is triggered. (button, wheel, paper-in, etc.)

scanner : the emitting GnomeScanner
event : the emitted even.
user_data : user data set when the signal handler was connected.

The "settings-changed" signal

void                user_function                      (GnomeScanner *scanner,
                                                        gpointer      user_data)      : Run Last

Emitted when the scanner has settings are hard setted.

scanner : the emitting GnomeScanner
user_data : user data set when the signal handler was connected.

The "status-changed" signal

void                user_function                      (GnomeScanner *scanner,
                                                        gpointer      user_data)      : Run Last

Emitted when the scanner status as changed.

scanner : the emitting GnomeScanner
user_data : user data set when the signal handler was connected.