• Home
  • History
  • Annotate
Name Date Size #Lines LOC

..03-May-2022-

build-aux/H23-Dec-2021-452421

data/H03-May-2022-1,7781,712

help/H23-Dec-2021-27,89423,813

po/H23-Dec-2021-84,21768,073

src/H03-May-2022-11,1089,938

subprojects/H23-Dec-2021-54

COPYINGH A D23-Dec-202134.3 KiB675553

NEWSH A D23-Dec-202128.3 KiB1,011671

README.mdH A D23-Dec-20214.9 KiB13399

meson.buildH A D23-Dec-20212 KiB6960

simple-scan.doapH A D23-Dec-20211.3 KiB3330

README.md

1[![Build Status](https://gitlab.gnome.org/GNOME/simple-scan/badges/master/build.svg)](https://gitlab.gnome.org/GNOME/simple-scan/pipelines)
2[![License](https://img.shields.io/badge/License-GPL%20v3-blue.svg)](https://gitlab.gnome.org/GNOME/simple-scan/blob/master/COPYING)
3
4# Introduction
5
6*Document Scanner* is a document scanning application for [GNOME](https://www.gnome.org/)
7It allows you to capture images using [image scanners](https://en.wikipedia.org/wiki/Image_scanner)
8(e.g. flatbed scanners) that have suitable [SANE drivers](http://sane-project.org/) installed.
9
10# Building the flatpak with GNOME Builder
11
12It is recommended to use the development flatpak for developing this application.
13That way you won't have to download all dependencies yourself and it'll be consistent between all distros.
14
151. Download [GNOME Builder](https://flathub.org/apps/details/org.gnome.Builder)
162. Click the `Clone Repository` button in Builder and use https://gitlab.gnome.org/GNOME/simple-scan.git as the URL.
173. Click the Run button in the headerbar
18
19Note that this flatpak requires access to all devices (--device=all), and so isn't made for general use.
20For this reason and until a more suitable solution is found to interact with a host `saned`, please don't
21try to publish it on Flathub.
22
23# Building manually from source
24
25Install the dependencies
26
27For Ubuntu/Debian:
28```
29$ sudo apt install -y meson valac gcc gettext itstool libfribidi-dev libgirepository1.0-dev libgtk-3-dev libgusb-dev libcolord-dev libpackagekit-glib2-dev libwebp-dev libsane-dev git ca-certificates
30
31```
32
33For Fedora:
34```
35$ sudo dnf install -y meson vala gettext itstool fribidi-devel gtk3-devel gobject-introspection-devel libgusb-devel colord-devel PackageKit-glib-devel libwebp-devel sane-backends-devel git
36```
37
38For Arch Linux:
39```
40sudo pacman -S meson vala gettext itstool fribidi gtk3 gobject-introspection libgusb colord libwebp sane git
41
42```
43
44Get the source:
45```
46$ git clone https://gitlab.gnome.org/GNOME/simple-scan.git
47$ cd simple-scan
48```
49
50Build and run:
51```
52$ meson --prefix $PWD/_install _build
53$ ninja -C _build all install
54$ XDG_DATA_DIRS=_install/share:$XDG_DATA_DIRS ./_install/bin/simple-scan
55```
56
57If libhandy is used as a subproject (i.e. system libhandy not found or
58too old), then make sure to use the resulting .so file as well when
59running, e.g. by using the `LD_LIBRARY_PATH` variable:
60```
61$ LD_LIBRARY_PATH=_install/lib/x86_64-linux-gnu XDG_DATA_DIRS=_install/share:$XDG_DATA_DIRS ./_install/bin/simple-scan
62```
63
64# Debugging
65
66There is a `--debug` command line switch to enable more verbose logging:
67```
68$ simple-scan --debug
69```
70
71Log messages can also be found in the `$HOME/.cache/simple-scan` folder.
72
73If you don't have a scanner ready, you can use a virtual `test` scanner:
74```
75$ simple-scan --debug test
76```
77
78This app works by using the [SANE API](http://sane-project.org/html/) to
79capture images. It chooses the settings it thinks are appropriate for what you
80are trying to do. Drivers have many options and are of differing quality - it
81is useful to work out if any issues are caused by the app or the drivers. To
82confirm it is a driver issue you can use the graphical tool (XSane) or the
83command line
84[scanimage](http://www.sane-project.org/man/scanimage.1.html) provided
85by the SANE project - these allow to to easily see and control all the
86settings your driver provides.
87
88If XSane is also not working, then the issue could be caused by wrongly
89loaded backend. To enable debug traces on Sane, set `SANE_DEBUG_DLL`
90environment variable:
91
92```
93$ export SANE_DEBUG_DLL=255
94```
95
96When set, SANE backends will show informational messages while
97*Document Scanner* is running
98
99Example:
100
101With HP MFP 135a scanner, there is missing `libusb-0.1.so.4`
102shared library, during loading `smfp` prioprietary backend:
103
104```
105[dll] sane_get_devices
106[dll] load: searching backend `smfp' in `/usr/lib/x86_64-linux-gnu/sane:/usr/lib/sane'
107[dll] load: trying to load `/usr/lib/x86_64-linux-gnu/sane/libsane-smfp.so.1'
108[dll] load: couldn't open `/usr/lib/x86_64-linux-gnu/sane/libsane-smfp.so.1' (No such file or directory)
109[dll] load: trying to load `/usr/lib/sane/libsane-smfp.so.1'
110[dll] load: dlopen()ing `/usr/lib/sane/libsane-smfp.so.1'
111[dll] load: dlopen() failed (libusb-0.1.so.4: No such file or directory)
112```
113
114# Contributing
115
116To contribute code create merge requests on
117[gitlab.gnome.org](https://gitlab.gnome.org/GNOME/simple-scan). If you
118find issues please [report them](https://gitlab.gnome.org/GNOME/simple-scan/issues).
119
120## Translation
121
122A lot of information about translation process can be found at
123[GNOME TranslationProject](https://wiki.gnome.org/TranslationProject/).
124The translation files for *Document Scanner* User Interface and User Guide,
125are available [here](https://l10n.gnome.org/module/simple-scan/).
126
127To be able to run Document Scanner in selected language, the `LANGUAGE` could be used.
128For example to run Document Scanner in Polish language:
129
130```
131$ LANGUAGE=pl XDG_DATA_DIRS=_install/share:$XDG_DATA_DIRS ./_install/bin/simple-scan
132```
133