|
|
a6795b9 |
From 134694473ff6a420b4d6845dfa826d76b70da279 Mon Sep 17 00:00:00 2001
|
|
|
09104f0 |
From: =?UTF-8?q?Petr=20P=C3=ADsa=C5=99?= <ppisar@redhat.com>
|
|
|
09104f0 |
Date: Mon, 25 Sep 2017 11:31:22 +0200
|
|
|
09104f0 |
Subject: [PATCH] Use specific font by ImageMagick
|
|
|
09104f0 |
MIME-Version: 1.0
|
|
|
09104f0 |
Content-Type: text/plain; charset=UTF-8
|
|
|
09104f0 |
Content-Transfer-Encoding: 8bit
|
|
|
09104f0 |
|
|
|
09104f0 |
Tests use ImageMagick to draw labels into pictures. This does not work
|
|
|
09104f0 |
with ImageMagick-6.9.9.13-1.fc28.x86_64 and
|
|
|
09104f0 |
rw-base35-fonts-20170801-1.fc28:
|
|
|
09104f0 |
|
|
|
09104f0 |
$ convert label:"The quick brown fox" test.png
|
|
|
09104f0 |
convert: unable to read font `(null)' @ error/annotate.c/RenderFreetype/1362.
|
|
|
09104f0 |
convert: no images defined `test.png' @ error/convert.c/ConvertImageCommand/3258.
|
|
|
09104f0 |
|
|
|
09104f0 |
This patch specifies DejaVu-Sans font explicitly.
|
|
|
09104f0 |
|
|
|
09104f0 |
<https://bugzilla.redhat.com/show_bug.cgi?id=1494563>
|
|
|
09104f0 |
|
|
|
09104f0 |
Signed-off-by: Petr Písař <ppisar@redhat.com>
|
|
|
09104f0 |
---
|
|
|
09104f0 |
t/1122_save_pdf_with_hocr.t | 2 +-
|
|
|
09104f0 |
t/113_save_pdf_with_downsample.t | 2 +-
|
|
|
09104f0 |
t/134_save_tiff_alpha.t | 4 ++--
|
|
|
09104f0 |
t/1621_import_pdf.t | 4 ++--
|
|
|
09104f0 |
t/1625_import_pdf_bw.t | 4 ++--
|
|
|
09104f0 |
t/31_ocropus.t | 6 +++---
|
|
|
09104f0 |
t/32_ocropus_in_thread.t | 2 +-
|
|
|
09104f0 |
t/33_cancel_ocropus.t | 2 +-
|
|
|
09104f0 |
t/351_unpaper.t | 2 +-
|
|
|
09104f0 |
t/352_unpaper.t | 2 +-
|
|
|
09104f0 |
t/353_cancel_unpaper.t | 4 ++--
|
|
|
09104f0 |
t/354_unpaper_with_error.t | 2 +-
|
|
|
09104f0 |
t/355_unpaper2.t | 4 ++--
|
|
|
09104f0 |
t/356_unpaper_corrupt_image.t | 2 +-
|
|
|
09104f0 |
t/357_unpaper_rtl.t | 4 ++--
|
|
|
09104f0 |
t/358_unpaper_with_warning.t | 2 +-
|
|
|
09104f0 |
t/411_tesseract.t | 6 +++---
|
|
|
09104f0 |
t/412_tesseract_in_thread.t | 2 +-
|
|
|
09104f0 |
t/413_cancel_tesseract.t | 2 +-
|
|
|
09104f0 |
t/414_tesseract_with_error.t | 2 +-
|
|
|
09104f0 |
t/421_cuneiform.t | 6 +++---
|
|
|
09104f0 |
t/422_cuneiform_in_thread.t | 2 +-
|
|
|
09104f0 |
t/423_cancel_cuneiform.t | 2 +-
|
|
|
09104f0 |
t/424_cuneiform_with_error.t | 2 +-
|
|
|
09104f0 |
t/431_gocr.t | 2 +-
|
|
|
09104f0 |
t/432_gocr.t | 2 +-
|
|
|
09104f0 |
t/433_cancel_gocr.t | 2 +-
|
|
|
09104f0 |
t/434_gocr_with_error.t | 2 +-
|
|
|
09104f0 |
t/51_process_chain.t | 2 +-
|
|
|
a6795b9 |
t/53_process_chain.t | 2 +-
|
|
|
a6795b9 |
30 files changed, 42 insertions(+), 42 deletions(-)
|
|
|
09104f0 |
|
|
|
09104f0 |
diff --git a/t/1122_save_pdf_with_hocr.t b/t/1122_save_pdf_with_hocr.t
|
|
|
a6795b9 |
index b38bd74..ba9dfc9 100644
|
|
|
09104f0 |
--- a/t/1122_save_pdf_with_hocr.t
|
|
|
09104f0 |
+++ b/t/1122_save_pdf_with_hocr.t
|
|
|
09104f0 |
@@ -18,7 +18,7 @@ Gscan2pdf::Document->setup($logger);
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -colorspace Gray -pointsize 12 -units PixelsPerInch -density 300 label:"The quick brown fox" -border 20x10 test.png'
|
|
|
09104f0 |
+'convert +matte -depth 1 -colorspace Gray -font DejaVu-Sans -pointsize 12 -units PixelsPerInch -density 300 label:"The quick brown fox" -border 20x10 test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
my $info = `identify test.png`;
|
|
|
09104f0 |
my ( $width, $height );
|
|
|
09104f0 |
diff --git a/t/113_save_pdf_with_downsample.t b/t/113_save_pdf_with_downsample.t
|
|
|
a6795b9 |
index 505d691..3a5c80f 100644
|
|
|
09104f0 |
--- a/t/113_save_pdf_with_downsample.t
|
|
|
09104f0 |
+++ b/t/113_save_pdf_with_downsample.t
|
|
|
09104f0 |
@@ -18,7 +18,7 @@ Gscan2pdf::Document->setup($logger);
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -colorspace Gray -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert +matte -depth 1 -colorspace Gray -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/134_save_tiff_alpha.t b/t/134_save_tiff_alpha.t
|
|
|
a6795b9 |
index e913797..c5cde13 100644
|
|
|
09104f0 |
--- a/t/134_save_tiff_alpha.t
|
|
|
09104f0 |
+++ b/t/134_save_tiff_alpha.t
|
|
|
09104f0 |
@@ -17,7 +17,7 @@ Gscan2pdf::Document->setup($logger);
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert -fill lightblue -pointsize 12 -units PixelsPerInch -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert -fill lightblue -font DejaVu-Sans -pointsize 12 -units PixelsPerInch -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
a6795b9 |
@@ -43,7 +43,7 @@ Gtk3->main;
|
|
|
09104f0 |
|
|
|
09104f0 |
like(
|
|
|
09104f0 |
`identify test.tif`,
|
|
|
09104f0 |
- qr/test.tif TIFF 4\d\dx\d\d 4\d\dx\d\d\+0\+0 16-bit sRGB/,
|
|
|
09104f0 |
+ qr/test.tif TIFF \d\d\dx\d\d \d\d\dx\d\d\+0\+0 16-bit sRGB/,
|
|
|
09104f0 |
'valid TIFF created'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
diff --git a/t/1621_import_pdf.t b/t/1621_import_pdf.t
|
|
|
a6795b9 |
index 0138004..e9eb4fe 100644
|
|
|
09104f0 |
--- a/t/1621_import_pdf.t
|
|
|
09104f0 |
+++ b/t/1621_import_pdf.t
|
|
|
09104f0 |
@@ -20,7 +20,7 @@ Gscan2pdf::Document->setup($logger);
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create b&w test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -colorspace Gray -pointsize 12 -units PixelsPerInch -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert +matte -depth 1 -colorspace Gray -font DejaVu-Sans -pointsize 12 -units PixelsPerInch -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
# Add text layer with tesseract
|
|
|
09104f0 |
@@ -29,7 +29,7 @@ if ($tess_installed) {
|
|
|
09104f0 |
}
|
|
|
09104f0 |
else {
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -colorspace Gray -pointsize 12 -density 300 label:"The quick brown fox" test.pdf'
|
|
|
09104f0 |
+'convert +matte -depth 1 -colorspace Gray -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.pdf'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
}
|
|
|
09104f0 |
|
|
|
09104f0 |
diff --git a/t/1625_import_pdf_bw.t b/t/1625_import_pdf_bw.t
|
|
|
a6795b9 |
index 926f5ec..2db6044 100644
|
|
|
09104f0 |
--- a/t/1625_import_pdf_bw.t
|
|
|
09104f0 |
+++ b/t/1625_import_pdf_bw.t
|
|
|
09104f0 |
@@ -18,10 +18,10 @@ Gscan2pdf::Document->setup($logger);
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -colorspace Gray -type Bilevel -pointsize 12 -density 300 label:"The quick brown fox" test.pdf'
|
|
|
09104f0 |
+'convert +matte -depth 1 -colorspace Gray -type Bilevel -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.pdf'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -colorspace Gray -type Bilevel -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert +matte -depth 1 -colorspace Gray -type Bilevel -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
my $old = `identify -format '%m %G %g %z-bit %r' test.png`;
|
|
|
09104f0 |
|
|
|
09104f0 |
diff --git a/t/31_ocropus.t b/t/31_ocropus.t
|
|
|
a6795b9 |
index fad08a8..81a1b6f 100644
|
|
|
09104f0 |
--- a/t/31_ocropus.t
|
|
|
09104f0 |
+++ b/t/31_ocropus.t
|
|
|
09104f0 |
@@ -19,7 +19,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $got = Gscan2pdf::Ocropus->hocr(
|
|
|
09104f0 |
@@ -32,7 +32,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create colour test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert -fill lightblue -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert -fill lightblue -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
$got = Gscan2pdf::Ocropus->hocr(
|
|
|
09104f0 |
@@ -55,7 +55,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-"convert +matte -depth 1 -pointsize 12 -density 300 label:'öÖäÄüÜß' test.png"
|
|
|
09104f0 |
+"convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:'öÖäÄüÜß' test.png"
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
$got = Gscan2pdf::Ocropus->hocr(
|
|
|
09104f0 |
diff --git a/t/32_ocropus_in_thread.t b/t/32_ocropus_in_thread.t
|
|
|
a6795b9 |
index 30406ef..f9fa9fb 100644
|
|
|
09104f0 |
--- a/t/32_ocropus_in_thread.t
|
|
|
09104f0 |
+++ b/t/32_ocropus_in_thread.t
|
|
|
09104f0 |
@@ -23,7 +23,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/33_cancel_ocropus.t b/t/33_cancel_ocropus.t
|
|
|
a6795b9 |
index eb39af1..f1c352d 100644
|
|
|
09104f0 |
--- a/t/33_cancel_ocropus.t
|
|
|
09104f0 |
+++ b/t/33_cancel_ocropus.t
|
|
|
09104f0 |
@@ -20,7 +20,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/351_unpaper.t b/t/351_unpaper.t
|
|
|
a6795b9 |
index 3ac8c3d..0ebc0f8 100644
|
|
|
09104f0 |
--- a/t/351_unpaper.t
|
|
|
09104f0 |
+++ b/t/351_unpaper.t
|
|
|
09104f0 |
@@ -45,7 +45,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert -size 2100x2970 +matte -depth 1 -border 2x2 -bordercolor black -pointsize 12 -density 300 label:"The quick brown fox" test.pnm'
|
|
|
09104f0 |
+'convert -size 2100x2970 +matte -depth 1 -border 2x2 -bordercolor black -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/352_unpaper.t b/t/352_unpaper.t
|
|
|
a6795b9 |
index 83e1e7a..44bb98b 100644
|
|
|
09104f0 |
--- a/t/352_unpaper.t
|
|
|
09104f0 |
+++ b/t/352_unpaper.t
|
|
|
09104f0 |
@@ -45,7 +45,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert -size 2550x3507 +matte -depth 1 -border 2x2 -bordercolor black -pointsize 12 -density 300 label:"The quick brown fox" test.pnm'
|
|
|
09104f0 |
+'convert -size 2550x3507 +matte -depth 1 -border 2x2 -bordercolor black -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/353_cancel_unpaper.t b/t/353_cancel_unpaper.t
|
|
|
a6795b9 |
index 5d1c271..3199a0e 100644
|
|
|
09104f0 |
--- a/t/353_cancel_unpaper.t
|
|
|
09104f0 |
+++ b/t/353_cancel_unpaper.t
|
|
|
09104f0 |
@@ -24,10 +24,10 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -border 2x2 -bordercolor black -pointsize 12 -density 300 label:"The quick brown fox" 1.pnm'
|
|
|
09104f0 |
+'convert +matte -depth 1 -border 2x2 -bordercolor black -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" 1.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -border 2x2 -bordercolor black -pointsize 12 -density 300 label:"The slower lazy dog" 2.pnm'
|
|
|
09104f0 |
+'convert +matte -depth 1 -border 2x2 -bordercolor black -font DejaVu-Sans -pointsize 12 -density 300 label:"The slower lazy dog" 2.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
system('convert -size 100x100 xc:black black.pnm');
|
|
|
09104f0 |
system('convert 1.pnm black.pnm 2.pnm +append test.pnm');
|
|
|
09104f0 |
diff --git a/t/354_unpaper_with_error.t b/t/354_unpaper_with_error.t
|
|
|
a6795b9 |
index 0247b20..f0052a7 100644
|
|
|
09104f0 |
--- a/t/354_unpaper_with_error.t
|
|
|
09104f0 |
+++ b/t/354_unpaper_with_error.t
|
|
|
09104f0 |
@@ -45,7 +45,7 @@ SKIP: {
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
my $filename = 'test.png';
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-"convert -size 2100x2970 +matte -depth 1 -border 2x2 -bordercolor black -pointsize 12 -density 300 label:'The quick brown fox' $filename"
|
|
|
09104f0 |
+"convert -size 2100x2970 +matte -depth 1 -border 2x2 -bordercolor black -font DejaVu-Sans -pointsize 12 -density 300 label:'The quick brown fox' $filename"
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/355_unpaper2.t b/t/355_unpaper2.t
|
|
|
a6795b9 |
index 20ea40a..2af39f9 100644
|
|
|
09104f0 |
--- a/t/355_unpaper2.t
|
|
|
09104f0 |
+++ b/t/355_unpaper2.t
|
|
|
09104f0 |
@@ -22,10 +22,10 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -border 2x2 -bordercolor black -pointsize 12 -density 300 label:"The quick brown fox" 1.pnm'
|
|
|
09104f0 |
+'convert +matte -depth 1 -border 2x2 -bordercolor black -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" 1.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -border 2x2 -bordercolor black -pointsize 12 -density 300 label:"The slower lazy dog" 2.pnm'
|
|
|
09104f0 |
+'convert +matte -depth 1 -border 2x2 -bordercolor black -font DejaVu-Sans -pointsize 12 -density 300 label:"The slower lazy dog" 2.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
system('convert -size 100x100 xc:black black.pnm');
|
|
|
09104f0 |
system('convert 1.pnm black.pnm 2.pnm +append test.pnm');
|
|
|
09104f0 |
diff --git a/t/356_unpaper_corrupt_image.t b/t/356_unpaper_corrupt_image.t
|
|
|
a6795b9 |
index 09257fb..0cb77b7 100644
|
|
|
09104f0 |
--- a/t/356_unpaper_corrupt_image.t
|
|
|
09104f0 |
+++ b/t/356_unpaper_corrupt_image.t
|
|
|
09104f0 |
@@ -51,7 +51,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert -size 2100x2970 +matte -depth 1 -border 2x2 -bordercolor black -pointsize 12 -density 300 label:"The quick brown fox" test.pnm'
|
|
|
09104f0 |
+'convert -size 2100x2970 +matte -depth 1 -border 2x2 -bordercolor black -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
$slist->import_files(
|
|
|
09104f0 |
diff --git a/t/357_unpaper_rtl.t b/t/357_unpaper_rtl.t
|
|
|
a6795b9 |
index 7b05361..b0fb8b8 100644
|
|
|
09104f0 |
--- a/t/357_unpaper_rtl.t
|
|
|
09104f0 |
+++ b/t/357_unpaper_rtl.t
|
|
|
09104f0 |
@@ -23,10 +23,10 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -border 2x2 -bordercolor black -pointsize 12 -density 300 label:"The quick brown fox" 1.pnm'
|
|
|
09104f0 |
+'convert +matte -depth 1 -border 2x2 -bordercolor black -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" 1.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -border 2x2 -bordercolor black -pointsize 12 -density 300 label:"The slower lazy dog" 2.pnm'
|
|
|
09104f0 |
+'convert +matte -depth 1 -border 2x2 -bordercolor black -font DejaVu-Sans -pointsize 12 -density 300 label:"The slower lazy dog" 2.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
system('convert -size 100x100 xc:black black.pnm');
|
|
|
09104f0 |
system('convert 1.pnm black.pnm 2.pnm +append test.pnm');
|
|
|
09104f0 |
diff --git a/t/358_unpaper_with_warning.t b/t/358_unpaper_with_warning.t
|
|
|
a6795b9 |
index d313f28..f28a02f 100644
|
|
|
09104f0 |
--- a/t/358_unpaper_with_warning.t
|
|
|
09104f0 |
+++ b/t/358_unpaper_with_warning.t
|
|
|
09104f0 |
@@ -25,7 +25,7 @@ SKIP: {
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
my $filename = 'test.png';
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -colorspace Gray -pointsize 12 -density 300 label:"The quick brown fox" -rotate 20 '
|
|
|
09104f0 |
+'convert +matte -depth 1 -colorspace Gray -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" -rotate 20 '
|
|
|
09104f0 |
. $filename );
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/411_tesseract.t b/t/411_tesseract.t
|
|
|
a6795b9 |
index f222006..bb91116 100644
|
|
|
09104f0 |
--- a/t/411_tesseract.t
|
|
|
09104f0 |
+++ b/t/411_tesseract.t
|
|
|
09104f0 |
@@ -81,7 +81,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create b&w test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -colorspace Gray -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert +matte -depth 1 -colorspace Gray -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my ( $got, $messages ) = Gscan2pdf::Tesseract->hocr(
|
|
|
09104f0 |
@@ -97,7 +97,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create colour test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert -fill lightblue -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert -fill lightblue -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
( $got, $messages ) = Gscan2pdf::Tesseract->hocr(
|
|
|
09104f0 |
@@ -118,7 +118,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create b&w test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-"convert +matte -depth 1 -colorspace Gray -pointsize 12 -density 300 label:'öÖäÄüÜß' test.png"
|
|
|
09104f0 |
+"convert +matte -depth 1 -colorspace Gray -font DejaVu-Sans -pointsize 12 -density 300 label:'öÖäÄüÜß' test.png"
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
( $got, $messages ) = Gscan2pdf::Tesseract->hocr(
|
|
|
09104f0 |
diff --git a/t/412_tesseract_in_thread.t b/t/412_tesseract_in_thread.t
|
|
|
a6795b9 |
index ba6efe9..db56ac8 100644
|
|
|
09104f0 |
--- a/t/412_tesseract_in_thread.t
|
|
|
09104f0 |
+++ b/t/412_tesseract_in_thread.t
|
|
|
09104f0 |
@@ -23,7 +23,7 @@ SKIP: {
|
|
|
09104f0 |
# Deliberately not setting -units to provoke
|
|
|
09104f0 |
# "Invalid resolution 0 dpi. Using 70 instead." warning from tesseract
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -colorspace Gray -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert +matte -depth 1 -colorspace Gray -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/413_cancel_tesseract.t b/t/413_cancel_tesseract.t
|
|
|
a6795b9 |
index 8bf7c30..0ee53f2 100644
|
|
|
09104f0 |
--- a/t/413_cancel_tesseract.t
|
|
|
09104f0 |
+++ b/t/413_cancel_tesseract.t
|
|
|
09104f0 |
@@ -22,7 +22,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -colorspace Gray -pointsize 12 -density 300 label:"The quick brown fox" test.tif'
|
|
|
09104f0 |
+'convert +matte -depth 1 -colorspace Gray -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.tif'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/414_tesseract_with_error.t b/t/414_tesseract_with_error.t
|
|
|
a6795b9 |
index 788515e..ec488e8 100644
|
|
|
09104f0 |
--- a/t/414_tesseract_with_error.t
|
|
|
09104f0 |
+++ b/t/414_tesseract_with_error.t
|
|
|
09104f0 |
@@ -23,7 +23,7 @@ SKIP: {
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
my $filename = 'test.png';
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-"convert +matte -depth 1 -colorspace Gray -pointsize 12 -density 300 label:'The quick brown fox' $filename"
|
|
|
09104f0 |
+"convert +matte -depth 1 -colorspace Gray -font DejaVu-Sans -pointsize 12 -density 300 label:'The quick brown fox' $filename"
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/421_cuneiform.t b/t/421_cuneiform.t
|
|
|
a6795b9 |
index 51cff00..38ec42a 100644
|
|
|
09104f0 |
--- a/t/421_cuneiform.t
|
|
|
09104f0 |
+++ b/t/421_cuneiform.t
|
|
|
09104f0 |
@@ -19,7 +19,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $got = Gscan2pdf::Cuneiform->hocr(
|
|
|
09104f0 |
@@ -32,7 +32,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create colour test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert -fill lightblue -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert -fill lightblue -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
$got = Gscan2pdf::Cuneiform->hocr(
|
|
|
09104f0 |
@@ -50,7 +50,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-"convert +matte -depth 1 -pointsize 12 -density 300 label:'öÖäÄüÜß' test.png"
|
|
|
09104f0 |
+"convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:'öÖäÄüÜß' test.png"
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
$got = Gscan2pdf::Cuneiform->hocr(
|
|
|
09104f0 |
diff --git a/t/422_cuneiform_in_thread.t b/t/422_cuneiform_in_thread.t
|
|
|
a6795b9 |
index 5f73385..2ff0fd5 100644
|
|
|
09104f0 |
--- a/t/422_cuneiform_in_thread.t
|
|
|
09104f0 |
+++ b/t/422_cuneiform_in_thread.t
|
|
|
09104f0 |
@@ -24,7 +24,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/423_cancel_cuneiform.t b/t/423_cancel_cuneiform.t
|
|
|
a6795b9 |
index 7da3d85..ae8e5c5 100644
|
|
|
09104f0 |
--- a/t/423_cancel_cuneiform.t
|
|
|
09104f0 |
+++ b/t/423_cancel_cuneiform.t
|
|
|
09104f0 |
@@ -23,7 +23,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
+'convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.png'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/424_cuneiform_with_error.t b/t/424_cuneiform_with_error.t
|
|
|
a6795b9 |
index 354be31..62875dd 100644
|
|
|
09104f0 |
--- a/t/424_cuneiform_with_error.t
|
|
|
09104f0 |
+++ b/t/424_cuneiform_with_error.t
|
|
|
09104f0 |
@@ -23,7 +23,7 @@ SKIP: {
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
my $filename = 'test.png';
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-"convert +matte -depth 1 -pointsize 12 -density 300 label:'The quick brown fox' $filename"
|
|
|
09104f0 |
+"convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:'The quick brown fox' $filename"
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/431_gocr.t b/t/431_gocr.t
|
|
|
a6795b9 |
index a4a4603..0ec6b42 100644
|
|
|
09104f0 |
--- a/t/431_gocr.t
|
|
|
09104f0 |
+++ b/t/431_gocr.t
|
|
|
09104f0 |
@@ -21,7 +21,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -pointsize 12 -density 300 label:"The quick brown fox" test.pnm'
|
|
|
09104f0 |
+'convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/432_gocr.t b/t/432_gocr.t
|
|
|
a6795b9 |
index 0ae8cc9..dd577b1 100644
|
|
|
09104f0 |
--- a/t/432_gocr.t
|
|
|
09104f0 |
+++ b/t/432_gocr.t
|
|
|
09104f0 |
@@ -22,7 +22,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -pointsize 12 -density 300 label:"öÖäÄüÜß" test.pnm'
|
|
|
09104f0 |
+'convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:"öÖäÄüÜß" test.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/433_cancel_gocr.t b/t/433_cancel_gocr.t
|
|
|
a6795b9 |
index 3a66fb8..f443463 100644
|
|
|
09104f0 |
--- a/t/433_cancel_gocr.t
|
|
|
09104f0 |
+++ b/t/433_cancel_gocr.t
|
|
|
09104f0 |
@@ -21,7 +21,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -pointsize 12 -density 300 label:"The quick brown fox" test.pnm'
|
|
|
09104f0 |
+'convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" test.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/434_gocr_with_error.t b/t/434_gocr_with_error.t
|
|
|
a6795b9 |
index 7bd8a7d..05e46b6 100644
|
|
|
09104f0 |
--- a/t/434_gocr_with_error.t
|
|
|
09104f0 |
+++ b/t/434_gocr_with_error.t
|
|
|
09104f0 |
@@ -22,7 +22,7 @@ SKIP: {
|
|
|
09104f0 |
# Create test image
|
|
|
09104f0 |
my $filename = 'test.pnm';
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-"convert +matte -depth 1 -pointsize 12 -density 300 label:'The quick brown fox' $filename"
|
|
|
09104f0 |
+"convert +matte -depth 1 -font DejaVu-Sans -pointsize 12 -density 300 label:'The quick brown fox' $filename"
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
my $slist = Gscan2pdf::Document->new;
|
|
|
09104f0 |
diff --git a/t/51_process_chain.t b/t/51_process_chain.t
|
|
|
a6795b9 |
index 067c803..6f97b8a 100644
|
|
|
09104f0 |
--- a/t/51_process_chain.t
|
|
|
09104f0 |
+++ b/t/51_process_chain.t
|
|
|
09104f0 |
@@ -33,7 +33,7 @@ SKIP: {
|
|
|
09104f0 |
|
|
|
09104f0 |
# Create b&w test image
|
|
|
09104f0 |
system(
|
|
|
09104f0 |
-'convert +matte -depth 1 -colorspace Gray -pointsize 12 -density 300 label:"The quick brown fox" -rotate -90 test.pnm'
|
|
|
09104f0 |
+'convert +matte -depth 1 -colorspace Gray -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" -rotate -90 test.pnm'
|
|
|
09104f0 |
);
|
|
|
09104f0 |
|
|
|
09104f0 |
$slist->import_scan(
|
|
|
a6795b9 |
diff --git a/t/53_process_chain.t b/t/53_process_chain.t
|
|
|
a6795b9 |
index 84fc93b..bc09269 100644
|
|
|
a6795b9 |
--- a/t/53_process_chain.t
|
|
|
a6795b9 |
+++ b/t/53_process_chain.t
|
|
|
a6795b9 |
@@ -33,7 +33,7 @@ SKIP: {
|
|
|
a6795b9 |
|
|
|
a6795b9 |
# Create b&w test image
|
|
|
a6795b9 |
system(
|
|
|
a6795b9 |
-'convert +matte -depth 1 -colorspace Gray -pointsize 12 -density 300 label:"The quick brown fox" -rotate -90 test.pnm'
|
|
|
a6795b9 |
+'convert +matte -depth 1 -colorspace Gray -font DejaVu-Sans -pointsize 12 -density 300 label:"The quick brown fox" -rotate -90 test.pnm'
|
|
|
a6795b9 |
);
|
|
|
a6795b9 |
|
|
|
a6795b9 |
$slist->import_scan(
|
|
|
09104f0 |
--
|
|
|
a6795b9 |
2.17.2
|
|
|
09104f0 |
|