KSaneCore
interface.cpp
124 qCDebug(KSANECORE_LOG) << "sane_open(\"" << deviceName << "\", &handle) failed! status = " << sane_strstatus(status);
132Interface::OpenStatus Interface::openRestrictedDevice(const QString &deviceName, const QString &userName, const QString &password)
159 qCDebug(KSANECORE_LOG) << "sane_open(\"" << deviceName << "\", &handle) failed! status = " << sane_strstatus(status);
static void authorization(SANE_String_Const resource, SANE_Char *username, SANE_Char *password)
static function called by sane_open to get authorization from user
Definition authentication.cpp:94
This class provides the core interface for accessing the scan controls and options.
Definition interface.h:33
QList< Option * > getOptionsList()
This function returns all available options when a device is opened.
Definition interface.cpp:247
int setOptionsMap(const QMap< QString, QString > &options)
This method can be used to write many parameter values at once.
Definition interface.cpp:285
void stopScan()
This method is used to cancel a scan or prevent an automatic new scan.
Definition interface.cpp:208
OptionName
This enumeration is used to obtain a specific option with getOption(KSaneOptionName).
Definition interface.h:62
OpenStatus openRestrictedDevice(const QString &deviceName, const QString &userName, const QString &password)
This method opens the specified scanner device with a specified username and password.
Definition interface.cpp:132
bool reloadDevicesList(DeviceType type=AllDevices)
Get the list of available scanning devices.
Definition interface.cpp:87
QString deviceModel() const
This method returns the model of the currently opened scanner.
Definition interface.cpp:82
Option * getOption(OptionName optionEnum)
This function returns a specific option.
Definition interface.cpp:252
QString deviceVendor() const
This method returns the vendor name of the currently opened scanner.
Definition interface.cpp:77
OpenStatus openDevice(const QString &deviceName)
This method opens the specified scanner device and adds the scan options to the options list.
Definition interface.cpp:100
void lockScanImage()
Locks the mutex protecting the QImage pointer of scanImage() from concurrent access during scanning.
Definition interface.cpp:233
void unlockScanImage()
Unlocks the mutex protecting the QImage pointer of scanImage() from concurrent access during scanning...
Definition interface.cpp:240
QMap< QString, QString > getOptionsMap()
This method reads the available parameters and their values and returns them in a QMap (Name,...
Definition interface.cpp:271
void scanFinished(KSaneCore::Interface::ScanStatus status, const QString &strStatus)
This signal is emitted when the scanning has ended.
void batchModeCountDown(int remainingSeconds)
This signal is emitted for the count down when in batch mode.
QImage * scanImage() const
Gives direct access to the QImage that is used to store the image data retrieved from the scanner.
Definition interface.cpp:225
QString deviceName() const
This method returns the internal device name of the currently opened scanner.
Definition interface.cpp:72
void scanProgress(int percent)
This signal is emitted for progress information during a scan.
A wrapper class providing access to the internal KSaneBaseOption to access all options provided by KS...
Definition option.h:29
bool setValue(const QVariant &value)
This slot allows to change the current value of the option.
Definition option.cpp:141
Q_SCRIPTABLE CaptureState status()
QString i18n(const char *text, const TYPE &arg...)
const char * constData() const const
bool contains(const Key &key) const const
iterator end()
iterator find(const Key &key)
size_type remove(const Key &key)
Q_EMITQ_EMIT
QMetaObject::Connection connect(const QObject *sender, PointerToMemberFunction signal, Functor functor)
void deleteLater()
bool disconnect(const QMetaObject::Connection &connection)
bool isEmpty() const const
QByteArray toLatin1() const const
void finished()
void timeout()
This file is part of the KDE documentation.
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:19:34 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2024 The KDE developers.
Generated on Tue Mar 26 2024 11:19:34 by doxygen 1.10.0 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.