summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.gitignore2
-rw-r--r--NEWS9
-rw-r--r--README.md2
-rw-r--r--build-aux/snap/snapcraft.yaml15
-rw-r--r--data/org.gnome.SimpleScan.gschema.xml6
-rw-r--r--data/simple-scan.appdata.xml.in10
-rw-r--r--debian/changelog15
-rw-r--r--debian/control2
-rw-r--r--debian/copyright2
-rw-r--r--debian/files1
-rw-r--r--debian/patches/0001-Remove_incorrect_i18n.merge_file_argument.patch30
-rw-r--r--debian/patches/0005-Build_error_with_vala.patch20
-rw-r--r--debian/patches/series2
-rw-r--r--meson.build2
-rw-r--r--src/app-window.vala1
-rw-r--r--src/scanner.vala19
16 files changed, 122 insertions, 16 deletions
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..0ff0ae9
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,2 @@
+.pc
+debian/files
diff --git a/NEWS b/NEWS
index 4589a94..d51b4dc 100644
--- a/NEWS
+++ b/NEWS
@@ -1,3 +1,12 @@
+Overview of changes in simple-scan 40.7
+~~~~~~~~~~~~~~
+Released: 2021-12-23
+
+ * Fix replacing underscore with space in scanner names.
+ * Delete autosave records after creating new document.
+ * Add the device name to the label if there are several identical models.
+ * Fix autosave of Page Side property.
+
Overview of changes in simple-scan 40.6
~~~~~~~~~~~~~~
Released: 2021-10-27
diff --git a/README.md b/README.md
index 0b6751a..75b5b57 100644
--- a/README.md
+++ b/README.md
@@ -26,7 +26,7 @@ Install the dependencies
For Ubuntu/Debian:
```
-$ sudo apt install -y meson valac gcc gettext itstool gobject-introspection libfribidi-dev libgirepository1.0-dev libgtk-3-dev libgusb-dev libcolord-dev libpackagekit-glib2-dev libwebp-dev libsane-dev git ca-certificates
+$ 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
```
diff --git a/build-aux/snap/snapcraft.yaml b/build-aux/snap/snapcraft.yaml
index d9c071b..a20c5b8 100644
--- a/build-aux/snap/snapcraft.yaml
+++ b/build-aux/snap/snapcraft.yaml
@@ -6,7 +6,7 @@ description: |
grade: stable # must be 'stable' to release into candidate/stable channels
confinement: strict
-base: core18
+base: core20
slots:
# for GtkApplication registration
@@ -28,18 +28,20 @@ apps:
- io-ports-control
- raw-usb
command: usr/bin/simple-scan
- extensions: [gnome-3-28]
+ extensions: [ gnome-3-38 ]
desktop: usr/share/applications/simple-scan.desktop
environment:
GSETTINGS_SCHEMA_DIR: $SNAP/share/glib-2.0/schemas
parts:
libsane:
- source: https://salsa.debian.org/debian/sane-backends.git
+ source: https://gitlab.com/sane-project/backends.git
source-type: git
- source-tag: upstream/1.0.27
+ source-tag: release-1.0.33
plugin: autotools
- configflags: [--prefix=/snap/simple-scan/current/usr, --with-api-spec=no]
+ autotools-configure-parameters:
+ - --prefix=/snap/simple-scan/current/usr
+ - --with-api-spec=no
organize:
snap/simple-scan/current/usr: usr
build-packages:
@@ -82,9 +84,10 @@ parts:
- libgtk-3-dev
- libgdk-pixbuf2.0-dev
- libgusb-dev
+ - libgirepository1.0-dev
- libpackagekit-glib2-dev
- libsane-dev
- - python-scour
+ - libwebp-dev
- valac
- zlib1g-dev
libs:
diff --git a/data/org.gnome.SimpleScan.gschema.xml b/data/org.gnome.SimpleScan.gschema.xml
index 35e0f6f..290add1 100644
--- a/data/org.gnome.SimpleScan.gschema.xml
+++ b/data/org.gnome.SimpleScan.gschema.xml
@@ -1,8 +1,8 @@
<schemalist>
<enum id="org.gnome.SimpleScan.PageSide">
- <value value="1" nick="front"/>
- <value value="2" nick="back"/>
- <value value="3" nick="both"/>
+ <value value="0" nick="front"/>
+ <value value="1" nick="back"/>
+ <value value="2" nick="both"/>
</enum>
<schema id="org.gnome.SimpleScan" path="/org/gnome/simple-scan/" gettext-domain="simple-scan">
diff --git a/data/simple-scan.appdata.xml.in b/data/simple-scan.appdata.xml.in
index e3b3b06..f5cec0f 100644
--- a/data/simple-scan.appdata.xml.in
+++ b/data/simple-scan.appdata.xml.in
@@ -25,6 +25,16 @@
<url type="donation">https://www.gnome.org/friends/</url>
<developer_name>The GNOME Project</developer_name>
<releases>
+ <release date="2021-12-27" version="40.7">
+ <description>
+ <ul>
+ <li>Fix replacing underscore with space in scanner names.</li>
+ <li>Delete autosave records after creating new document.</li>
+ <li>Add the device name to the label if there are several identical models.</li>
+ <li>Fix autosave of Page Side property.</li>
+ </ul>
+ </description>
+ </release>
<release date="2021-10-27" version="40.6">
<description>
<ul>
diff --git a/debian/changelog b/debian/changelog
index 73424b6..1f954af 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,18 @@
+simple-scan (40.7-1) unstable; urgency=medium
+
+ * New upstream release.
+ * debian/copyright:
+ - Add year 2022 to myself.
+ * Declare compliance with Debian Policy 4.6.0.1 (No changes needed).
+ * New .gitignore.
+ * New patches:
+ - debian/patches/0001-Remove_incorrect_i18n.merge_file_argument.patch:
+ Fix build error with meson > 0.60.
+ - debian/patches/0005-Build_error_with_vala.patch:
+ Fix accessibility conflict of constant and its value.
+
+ -- Jörg Frings-Fürst <debian@jff.email> Sun, 06 Feb 2022 15:20:34 +0100
+
simple-scan (40.6-1) unstable; urgency=medium
* New upstream release.
diff --git a/debian/control b/debian/control
index 1d1568b..e16cb2c 100644
--- a/debian/control
+++ b/debian/control
@@ -2,7 +2,7 @@ Source: simple-scan
Section: gnome
Priority: optional
Maintainer: Jörg Frings-Fürst <debian@jff.email>
-Standards-Version: 4.6.0.0
+Standards-Version: 4.6.0.1
Rules-Requires-Root: no
Build-Depends:
cmake,
diff --git a/debian/copyright b/debian/copyright
index 90fb797..ca42f98 100644
--- a/debian/copyright
+++ b/debian/copyright
@@ -22,7 +22,7 @@ License: GPL-3+
Files: debian/*
Copyright: 2009-2012 Alessio Treglia <alessio@debian.org>
2009 Robert Ancell <robert.ancell@canonical.com>
- 2014-2021 Jörg Frings-Fürst <debian@jff.email>
+ 2014-2022 Jörg Frings-Fürst <debian@jff.email>
License: GPL-3+
License: GPL-3+
diff --git a/debian/files b/debian/files
deleted file mode 100644
index 091d5c3..0000000
--- a/debian/files
+++ /dev/null
@@ -1 +0,0 @@
-simple-scan_40.6-1_source.buildinfo gnome optional
diff --git a/debian/patches/0001-Remove_incorrect_i18n.merge_file_argument.patch b/debian/patches/0001-Remove_incorrect_i18n.merge_file_argument.patch
new file mode 100644
index 0000000..0fb73d0
--- /dev/null
+++ b/debian/patches/0001-Remove_incorrect_i18n.merge_file_argument.patch
@@ -0,0 +1,30 @@
+Fix accessibility conflict of constant and its value
+Origin: upstream, https://gitlab.gnome.org/GNOME/simple-scan/-/commit/c50802b213c325cfa957d66955f6de96908710d9
+Forwarded: not-needed
+Applied-Upstream: commit: /c50802b213c325cfa957d66955f6de96908710d9
+Last-Update: 2022-02-06
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+Index: trunk/data/meson.build
+===================================================================
+--- trunk.orig/data/meson.build
++++ trunk/data/meson.build
+@@ -8,16 +8,14 @@ install_data ('org.gnome.SimpleScan.gsch
+ install_dir: join_paths (datadir, 'glib-2.0', 'schemas'))
+ meson.add_install_script ('meson_compile_gschema.py')
+
+-i18n.merge_file ('desktop-file',
+- input: 'simple-scan.desktop.in',
++i18n.merge_file (input: 'simple-scan.desktop.in',
+ output: 'simple-scan.desktop',
+ install: true,
+ install_dir: join_paths (datadir, 'applications'),
+ po_dir: '../po',
+ type: 'desktop')
+
+-i18n.merge_file ('appdata-file',
+- input: 'simple-scan.appdata.xml.in',
++i18n.merge_file (input: 'simple-scan.appdata.xml.in',
+ output: 'simple-scan.appdata.xml',
+ install: true,
+ install_dir: join_paths (datadir, 'metainfo'),
diff --git a/debian/patches/0005-Build_error_with_vala.patch b/debian/patches/0005-Build_error_with_vala.patch
new file mode 100644
index 0000000..76387f0
--- /dev/null
+++ b/debian/patches/0005-Build_error_with_vala.patch
@@ -0,0 +1,20 @@
+Remove incorrect i18n.merge_file argument
+Origin: upstream, https://gitlab.gnome.org/GNOME/simple-scan/-/commit/da6626debe00be1a0660f30cf2bf7629186c01d5
+Bug: https://gitlab.gnome.org/GNOME/simple-scan/-/issues/284
+Forwarded: not-needed
+Last-Update: 2022-02-06
+---
+This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
+Index: trunk/src/simple-scan.vala
+===================================================================
+--- trunk.orig/src/simple-scan.vala
++++ trunk/src/simple-scan.vala
+@@ -14,7 +14,7 @@ public class SimpleScan : Gtk.Applicatio
+ static bool show_version;
+ static bool debug_enabled;
+ static string? fix_pdf_filename = null;
+- public const OptionEntry[] options =
++ const OptionEntry[] options =
+ {
+ { "version", 'v', 0, OptionArg.NONE, ref show_version,
+ /* Help string for command line --version flag */
diff --git a/debian/patches/series b/debian/patches/series
index e69de29..e4ed019 100644
--- a/debian/patches/series
+++ b/debian/patches/series
@@ -0,0 +1,2 @@
+0001-Remove_incorrect_i18n.merge_file_argument.patch
+0005-Build_error_with_vala.patch
diff --git a/meson.build b/meson.build
index ed0de6c..50b519a 100644
--- a/meson.build
+++ b/meson.build
@@ -1,5 +1,5 @@
project ('simple-scan', ['vala', 'c'],
- version: '40.6',
+ version: '40.7',
license: 'GPLv3+',
default_options: [
'warning_level=1',
diff --git a/src/app-window.vala b/src/app-window.vala
index c1d4ea3..e163047 100644
--- a/src/app-window.vala
+++ b/src/app-window.vala
@@ -802,6 +802,7 @@ public class AppWindow : Hdy.ApplicationWindow
stop_scan ();
clear_document ();
+ autosave_manager.cleanup ();
});
}
diff --git a/src/scanner.vala b/src/scanner.vala
index d968aec..809ba6c 100644
--- a/src/scanner.vala
+++ b/src/scanner.vala
@@ -354,6 +354,16 @@ public class Scanner : Object
return;
}
+ /* Determine the number of each model to additionally display the name if the model names are the same. */
+ var seen = new HashTable<string, int> (str_hash, str_equal);
+ for (var i = 0; device_list[i] != null; i++)
+ {
+ if (seen.contains(device_list[i].model))
+ seen.set(device_list[i].model, seen.get(device_list[i].model) + 1);
+ else
+ seen.set(device_list[i].model, 1);
+ }
+
var devices = new List<ScanDevice> ();
for (var i = 0; device_list[i] != null; i++)
{
@@ -373,9 +383,14 @@ public class Scanner : Object
scan_device.label = device_list[i].model;
else
scan_device.label = "%s %s".printf (vendor, device_list[i].model);
-
+
/* Replace underscores in name */
- scan_device.label.replace ("_", " ");
+ scan_device.label = scan_device.label.replace ("_", " ");
+
+ /* Additionally add the device name to the label if there are several identical models. */
+ if (seen.get(device_list[i].model) > 1)
+ scan_device.label = "%s on %s".printf (scan_device.label, device_list[i].name);
+
devices.append (scan_device);
}