summaryrefslogtreecommitdiff
path: root/src/book.c
diff options
context:
space:
mode:
authorJörg Frings-Fürst <debian@jff-webhosting.net>2014-07-23 18:18:26 +0200
committerJörg Frings-Fürst <debian@jff-webhosting.net>2014-07-23 18:18:26 +0200
commit44a1fdd0075c7818b65d4191290cdce733687146 (patch)
tree3254cbee0a3ab39757bb7a1972faa884127f33cd /src/book.c
parenta366a6feda133b888da763569953636c90017f57 (diff)
parentcce8437bfbdb21e2b97025de6721c78f6d4654fc (diff)
Merge tag 'upstream/3.13.4.2'
Upstream version 3.13.4.2
Diffstat (limited to 'src/book.c')
-rw-r--r--src/book.c6063
1 files changed, 3224 insertions, 2839 deletions
diff --git a/src/book.c b/src/book.c
index def1bd0..45fd555 100644
--- a/src/book.c
+++ b/src/book.c
@@ -1,4 +1,4 @@
-/* book.c generated by valac 0.22.1, the Vala compiler
+/* book.c generated by valac 0.24.0, the Vala compiler
* generated from book.vala, do not modify */
/*
@@ -177,11 +177,14 @@ void book_clear (Book* self);
void book_set_needs_saving (Book* self, gboolean value);
void book_append_page (Book* self, Page* page);
void book_move_page (Book* self, Page* page, guint location);
+void book_reverse (Book* self);
+void book_combine_sides (Book* self);
+guint book_get_n_pages (Book* self);
+void book_combine_sides_reverse (Book* self);
void book_delete_page (Book* self, Page* page);
Page* book_get_page (Book* self, gint page_number);
guint book_get_page_index (Book* self, Page* page);
static GFile* book_make_indexed_file (Book* self, const gchar* uri, gint i);
-guint book_get_n_pages (Book* self);
static void book_save_multi_file (Book* self, const gchar* type, gint quality, GFile* file, GError** error);
void page_save (Page* self, const gchar* type, gint quality, GFile* file, GError** error);
static void book_save_ps_pdf_surface (Book* self, cairo_surface_t* surface, GdkPixbuf* image, gdouble dpi);
@@ -240,28 +243,28 @@ static void _vala_array_free (gpointer array, gint array_length, GDestroyNotify
static gpointer _page_ref0 (gpointer self) {
#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return self ? page_ref (self) : NULL;
-#line 244 "book.c"
+#line 247 "book.c"
}
static void _book_page_changed_cb_page_pixels_changed (Page* _sender, gpointer self) {
#line 47 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- book_page_changed_cb (self, _sender);
-#line 251 "book.c"
+ book_page_changed_cb ((Book*) self, _sender);
+#line 254 "book.c"
}
static void _book_page_changed_cb_page_crop_changed (Page* _sender, gpointer self) {
#line 48 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- book_page_changed_cb (self, _sender);
-#line 258 "book.c"
+ book_page_changed_cb ((Book*) self, _sender);
+#line 261 "book.c"
}
static void _page_unref0_ (gpointer var) {
#line 14 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
(var == NULL) ? NULL : (var = (page_unref (var), NULL));
-#line 265 "book.c"
+#line 268 "book.c"
}
@@ -270,7 +273,7 @@ static void _g_list_free__page_unref0_ (GList* self) {
g_list_foreach (self, (GFunc) _page_unref0_, NULL);
#line 14 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_list_free (self);
-#line 274 "book.c"
+#line 277 "book.c"
}
@@ -284,14 +287,14 @@ Book* book_construct (GType object_type) {
self->priv->pages = NULL;
#line 38 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return self;
-#line 288 "book.c"
+#line 291 "book.c"
}
Book* book_new (void) {
#line 38 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return book_construct (TYPE_BOOK);
-#line 295 "book.c"
+#line 298 "book.c"
}
@@ -301,7 +304,7 @@ void book_clear (Book* self) {
g_return_if_fail (self != NULL);
#line 54 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = self->priv->pages;
-#line 305 "book.c"
+#line 308 "book.c"
{
GList* page_collection = NULL;
GList* page_it = NULL;
@@ -309,14 +312,14 @@ void book_clear (Book* self) {
page_collection = _tmp0_;
#line 54 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
for (page_it = page_collection; page_it != NULL; page_it = page_it->next) {
-#line 313 "book.c"
+#line 316 "book.c"
Page* _tmp1_ = NULL;
Page* page = NULL;
#line 54 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = _page_ref0 ((Page*) page_it->data);
#line 54 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
page = _tmp1_;
-#line 320 "book.c"
+#line 323 "book.c"
{
Page* _tmp2_ = NULL;
guint _tmp3_ = 0U;
@@ -336,7 +339,7 @@ void book_clear (Book* self) {
g_signal_handlers_disconnect_matched (_tmp4_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp5_, 0, NULL, (GCallback) _book_page_changed_cb_page_crop_changed, self);
#line 54 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_page_unref0 (page);
-#line 340 "book.c"
+#line 343 "book.c"
}
}
}
@@ -346,7 +349,7 @@ void book_clear (Book* self) {
self->priv->pages = NULL;
#line 60 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_signal_emit_by_name (self, "cleared");
-#line 350 "book.c"
+#line 353 "book.c"
}
@@ -357,7 +360,7 @@ static void book_page_changed_cb (Book* self, Page* page) {
g_return_if_fail (page != NULL);
#line 65 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
book_set_needs_saving (self, TRUE);
-#line 361 "book.c"
+#line 364 "book.c"
}
@@ -391,7 +394,7 @@ void book_append_page (Book* self, Page* page) {
g_signal_emit_by_name (self, "page-added", _tmp4_);
#line 75 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
book_set_needs_saving (self, TRUE);
-#line 395 "book.c"
+#line 398 "book.c"
}
@@ -420,7 +423,302 @@ void book_move_page (Book* self, Page* page, guint location) {
g_signal_emit_by_name (self, "reordered");
#line 83 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
book_set_needs_saving (self, TRUE);
-#line 424 "book.c"
+#line 427 "book.c"
+}
+
+
+void book_reverse (Book* self) {
+ GList* new_pages = NULL;
+ GList* _tmp0_ = NULL;
+ GList* _tmp4_ = NULL;
+#line 86 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ g_return_if_fail (self != NULL);
+#line 88 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ new_pages = NULL;
+#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp0_ = self->priv->pages;
+#line 441 "book.c"
+ {
+ GList* page_collection = NULL;
+ GList* page_it = NULL;
+#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ page_collection = _tmp0_;
+#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ for (page_it = page_collection; page_it != NULL; page_it = page_it->next) {
+#line 449 "book.c"
+ Page* _tmp1_ = NULL;
+ Page* page = NULL;
+#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp1_ = _page_ref0 ((Page*) page_it->data);
+#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ page = _tmp1_;
+#line 456 "book.c"
+ {
+ Page* _tmp2_ = NULL;
+ Page* _tmp3_ = NULL;
+#line 90 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp2_ = page;
+#line 90 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp3_ = _page_ref0 (_tmp2_);
+#line 90 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ new_pages = g_list_prepend (new_pages, _tmp3_);
+#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _page_unref0 (page);
+#line 468 "book.c"
+ }
+ }
+ }
+#line 91 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp4_ = new_pages;
+#line 91 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ new_pages = NULL;
+#line 91 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ __g_list_free__page_unref0_0 (self->priv->pages);
+#line 91 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ self->priv->pages = _tmp4_;
+#line 93 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ g_signal_emit_by_name (self, "reordered");
+#line 94 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ book_set_needs_saving (self, TRUE);
+#line 86 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ __g_list_free__page_unref0_0 (new_pages);
+#line 486 "book.c"
+}
+
+
+void book_combine_sides (Book* self) {
+ guint n_front = 0U;
+ guint _tmp0_ = 0U;
+ guint _tmp1_ = 0U;
+ guint _tmp2_ = 0U;
+ guint _tmp3_ = 0U;
+ GList* new_pages = NULL;
+ GList* _tmp19_ = NULL;
+#line 97 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ g_return_if_fail (self != NULL);
+#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp0_ = book_get_n_pages (self);
+#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp1_ = _tmp0_;
+#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp2_ = book_get_n_pages (self);
+#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp3_ = _tmp2_;
+#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ n_front = _tmp1_ - (_tmp3_ / 2);
+#line 100 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ new_pages = NULL;
+#line 512 "book.c"
+ {
+ gint i = 0;
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ i = 0;
+#line 517 "book.c"
+ {
+ gboolean _tmp4_ = FALSE;
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp4_ = TRUE;
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ while (TRUE) {
+#line 524 "book.c"
+ gint _tmp6_ = 0;
+ guint _tmp7_ = 0U;
+ guint _tmp8_ = 0U;
+ gint _tmp9_ = 0;
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp4_) {
+#line 531 "book.c"
+ gint _tmp5_ = 0;
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp5_ = i;
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ i = _tmp5_ + 1;
+#line 537 "book.c"
+ }
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp4_ = FALSE;
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp6_ = i;
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp7_ = book_get_n_pages (self);
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp8_ = _tmp7_;
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(((guint) _tmp6_) < _tmp8_)) {
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ break;
+#line 551 "book.c"
+ }
+#line 103 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp9_ = i;
+#line 103 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if ((_tmp9_ % 2) == 0) {
+#line 557 "book.c"
+ GList* _tmp10_ = NULL;
+ gint _tmp11_ = 0;
+ gconstpointer _tmp12_ = NULL;
+ Page* _tmp13_ = NULL;
+#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp10_ = self->priv->pages;
+#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp11_ = i;
+#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp12_ = g_list_nth_data (_tmp10_, (guint) (_tmp11_ / 2));
+#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp13_ = _page_ref0 ((Page*) _tmp12_);
+#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ new_pages = g_list_append (new_pages, _tmp13_);
+#line 572 "book.c"
+ } else {
+ GList* _tmp14_ = NULL;
+ guint _tmp15_ = 0U;
+ gint _tmp16_ = 0;
+ gconstpointer _tmp17_ = NULL;
+ Page* _tmp18_ = NULL;
+#line 106 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp14_ = self->priv->pages;
+#line 106 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp15_ = n_front;
+#line 106 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp16_ = i;
+#line 106 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp17_ = g_list_nth_data (_tmp14_, _tmp15_ + (_tmp16_ / 2));
+#line 106 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp18_ = _page_ref0 ((Page*) _tmp17_);
+#line 106 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ new_pages = g_list_append (new_pages, _tmp18_);
+#line 591 "book.c"
+ }
+ }
+ }
+ }
+#line 108 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp19_ = new_pages;
+#line 108 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ new_pages = NULL;
+#line 108 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ __g_list_free__page_unref0_0 (self->priv->pages);
+#line 108 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ self->priv->pages = _tmp19_;
+#line 110 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ g_signal_emit_by_name (self, "reordered");
+#line 111 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ book_set_needs_saving (self, TRUE);
+#line 97 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ __g_list_free__page_unref0_0 (new_pages);
+#line 610 "book.c"
+}
+
+
+void book_combine_sides_reverse (Book* self) {
+ GList* new_pages = NULL;
+ GList* _tmp16_ = NULL;
+#line 114 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ g_return_if_fail (self != NULL);
+#line 116 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ new_pages = NULL;
+#line 621 "book.c"
+ {
+ gint i = 0;
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ i = 0;
+#line 626 "book.c"
+ {
+ gboolean _tmp0_ = FALSE;
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp0_ = TRUE;
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ while (TRUE) {
+#line 633 "book.c"
+ gint _tmp2_ = 0;
+ guint _tmp3_ = 0U;
+ guint _tmp4_ = 0U;
+ gint _tmp5_ = 0;
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp0_) {
+#line 640 "book.c"
+ gint _tmp1_ = 0;
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp1_ = i;
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ i = _tmp1_ + 1;
+#line 646 "book.c"
+ }
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp0_ = FALSE;
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp2_ = i;
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp3_ = book_get_n_pages (self);
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp4_ = _tmp3_;
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(((guint) _tmp2_) < _tmp4_)) {
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ break;
+#line 660 "book.c"
+ }
+#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp5_ = i;
+#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if ((_tmp5_ % 2) == 0) {
+#line 666 "book.c"
+ GList* _tmp6_ = NULL;
+ gint _tmp7_ = 0;
+ gconstpointer _tmp8_ = NULL;
+ Page* _tmp9_ = NULL;
+#line 120 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp6_ = self->priv->pages;
+#line 120 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp7_ = i;
+#line 120 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp8_ = g_list_nth_data (_tmp6_, (guint) (_tmp7_ / 2));
+#line 120 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp9_ = _page_ref0 ((Page*) _tmp8_);
+#line 120 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ new_pages = g_list_append (new_pages, _tmp9_);
+#line 681 "book.c"
+ } else {
+ GList* _tmp10_ = NULL;
+ guint _tmp11_ = 0U;
+ guint _tmp12_ = 0U;
+ gint _tmp13_ = 0;
+ gconstpointer _tmp14_ = NULL;
+ Page* _tmp15_ = NULL;
+#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp10_ = self->priv->pages;
+#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp11_ = book_get_n_pages (self);
+#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp12_ = _tmp11_;
+#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp13_ = i;
+#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp14_ = g_list_nth_data (_tmp10_, (_tmp12_ - 1) - (_tmp13_ / 2));
+#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp15_ = _page_ref0 ((Page*) _tmp14_);
+#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ new_pages = g_list_append (new_pages, _tmp15_);
+#line 703 "book.c"
+ }
+ }
+ }
+ }
+#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp16_ = new_pages;
+#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ new_pages = NULL;
+#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ __g_list_free__page_unref0_0 (self->priv->pages);
+#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ self->priv->pages = _tmp16_;
+#line 126 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ g_signal_emit_by_name (self, "reordered");
+#line 127 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ book_set_needs_saving (self, TRUE);
+#line 114 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ __g_list_free__page_unref0_0 (new_pages);
+#line 722 "book.c"
}
@@ -431,33 +729,33 @@ void book_delete_page (Book* self, Page* page) {
guint _tmp3_ = 0U;
Page* _tmp4_ = NULL;
Page* _tmp5_ = NULL;
-#line 86 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 130 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (self != NULL);
-#line 86 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 130 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (page != NULL);
-#line 88 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = page;
-#line 88 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_signal_parse_name ("pixels-changed", TYPE_PAGE, &_tmp1_, NULL, FALSE);
-#line 88 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_signal_handlers_disconnect_matched (_tmp0_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp1_, 0, NULL, (GCallback) _book_page_changed_cb_page_pixels_changed, self);
-#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 133 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = page;
-#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 133 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_signal_parse_name ("crop-changed", TYPE_PAGE, &_tmp3_, NULL, FALSE);
-#line 89 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 133 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_signal_handlers_disconnect_matched (_tmp2_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp3_, 0, NULL, (GCallback) _book_page_changed_cb_page_crop_changed, self);
-#line 90 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 134 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp4_ = page;
-#line 90 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- g_signal_emit_by_name (self, "page-removed", _tmp4_);
-#line 91 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 134 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ self->priv->pages = g_list_remove (self->priv->pages, _tmp4_);
+#line 135 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_ = page;
-#line 91 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- self->priv->pages = g_list_remove (self->priv->pages, _tmp5_);
-#line 92 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 135 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ g_signal_emit_by_name (self, "page-removed", _tmp5_);
+#line 136 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
book_set_needs_saving (self, TRUE);
-#line 461 "book.c"
+#line 759 "book.c"
}
@@ -468,39 +766,39 @@ Page* book_get_page (Book* self, gint page_number) {
gint _tmp5_ = 0;
gconstpointer _tmp6_ = NULL;
Page* _tmp7_ = NULL;
-#line 95 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 139 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (self != NULL, NULL);
-#line 97 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 141 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = page_number;
-#line 97 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 141 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_tmp0_ < 0) {
-#line 478 "book.c"
+#line 776 "book.c"
GList* _tmp1_ = NULL;
guint _tmp2_ = 0U;
gint _tmp3_ = 0;
-#line 98 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 142 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = self->priv->pages;
-#line 98 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 142 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = g_list_length (_tmp1_);
-#line 98 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 142 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3_ = page_number;
-#line 98 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 142 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
page_number = ((gint) _tmp2_) + _tmp3_;
-#line 490 "book.c"
+#line 788 "book.c"
}
-#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp4_ = self->priv->pages;
-#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_ = page_number;
-#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp6_ = g_list_nth_data (_tmp4_, (guint) _tmp5_);
-#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp7_ = _page_ref0 ((Page*) _tmp6_);
-#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
result = _tmp7_;
-#line 99 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 504 "book.c"
+#line 802 "book.c"
}
@@ -509,21 +807,21 @@ guint book_get_page_index (Book* self, Page* page) {
GList* _tmp0_ = NULL;
Page* _tmp1_ = NULL;
gint _tmp2_ = 0;
-#line 102 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 146 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (self != NULL, 0U);
-#line 102 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 146 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (page != NULL, 0U);
-#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = self->priv->pages;
-#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = page;
-#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = g_list_index (_tmp0_, _tmp1_);
-#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
result = (guint) _tmp2_;
-#line 104 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 527 "book.c"
+#line 825 "book.c"
}
@@ -534,35 +832,35 @@ static gint string_last_index_of_char (const gchar* self, gunichar c, gint start
gunichar _tmp1_ = 0U;
gchar* _tmp2_ = NULL;
gchar* _tmp3_ = NULL;
-#line 928 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 930 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
g_return_val_if_fail (self != NULL, 0);
-#line 929 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 931 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp0_ = start_index;
-#line 929 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 931 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp1_ = c;
-#line 929 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 931 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp2_ = g_utf8_strrchr (((gchar*) self) + _tmp0_, (gssize) (-1), _tmp1_);
-#line 929 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 931 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_result_ = _tmp2_;
-#line 931 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 933 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp3_ = _result_;
-#line 931 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 933 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
if (_tmp3_ != NULL) {
-#line 552 "book.c"
+#line 850 "book.c"
gchar* _tmp4_ = NULL;
-#line 932 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 934 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp4_ = _result_;
-#line 932 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 934 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
result = (gint) (_tmp4_ - ((gchar*) self));
-#line 932 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 934 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
return result;
-#line 560 "book.c"
+#line 858 "book.c"
} else {
-#line 934 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 936 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
result = -1;
-#line 934 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 936 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
return result;
-#line 566 "book.c"
+#line 864 "book.c"
}
}
@@ -577,118 +875,112 @@ static gchar* string_slice (const gchar* self, glong start, glong end) {
gboolean _tmp8_ = FALSE;
glong _tmp9_ = 0L;
gboolean _tmp12_ = FALSE;
- gboolean _tmp13_ = FALSE;
- glong _tmp14_ = 0L;
- gboolean _tmp17_ = FALSE;
+ glong _tmp13_ = 0L;
+ glong _tmp16_ = 0L;
+ glong _tmp17_ = 0L;
glong _tmp18_ = 0L;
glong _tmp19_ = 0L;
glong _tmp20_ = 0L;
- glong _tmp21_ = 0L;
- glong _tmp22_ = 0L;
- gchar* _tmp23_ = NULL;
-#line 1189 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+ gchar* _tmp21_ = NULL;
+#line 1226 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
g_return_val_if_fail (self != NULL, NULL);
-#line 1190 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1227 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp0_ = strlen (self);
-#line 1190 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1227 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp1_ = _tmp0_;
-#line 1190 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1227 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
string_length = (glong) _tmp1_;
-#line 1191 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1228 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp2_ = start;
-#line 1191 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1228 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
if (_tmp2_ < ((glong) 0)) {
-#line 602 "book.c"
+#line 898 "book.c"
glong _tmp3_ = 0L;
glong _tmp4_ = 0L;
-#line 1192 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1229 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp3_ = string_length;
-#line 1192 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1229 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp4_ = start;
-#line 1192 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1229 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
start = _tmp3_ + _tmp4_;
-#line 611 "book.c"
+#line 907 "book.c"
}
-#line 1194 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1231 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp5_ = end;
-#line 1194 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1231 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
if (_tmp5_ < ((glong) 0)) {
-#line 617 "book.c"
+#line 913 "book.c"
glong _tmp6_ = 0L;
glong _tmp7_ = 0L;
-#line 1195 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1232 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp6_ = string_length;
-#line 1195 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1232 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp7_ = end;
-#line 1195 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1232 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
end = _tmp6_ + _tmp7_;
-#line 626 "book.c"
+#line 922 "book.c"
}
-#line 1197 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1234 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp9_ = start;
-#line 1197 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1234 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
if (_tmp9_ >= ((glong) 0)) {
-#line 632 "book.c"
+#line 928 "book.c"
glong _tmp10_ = 0L;
glong _tmp11_ = 0L;
-#line 1197 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1234 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp10_ = start;
-#line 1197 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1234 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp11_ = string_length;
-#line 1197 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1234 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp8_ = _tmp10_ <= _tmp11_;
-#line 641 "book.c"
+#line 937 "book.c"
} else {
-#line 1197 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1234 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp8_ = FALSE;
-#line 645 "book.c"
+#line 941 "book.c"
}
-#line 1197 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- _tmp12_ = _tmp8_;
-#line 1197 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- g_return_val_if_fail (_tmp12_, NULL);
-#line 1198 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- _tmp14_ = end;
-#line 1198 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- if (_tmp14_ >= ((glong) 0)) {
-#line 655 "book.c"
+#line 1234 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ g_return_val_if_fail (_tmp8_, NULL);
+#line 1235 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ _tmp13_ = end;
+#line 1235 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ if (_tmp13_ >= ((glong) 0)) {
+#line 949 "book.c"
+ glong _tmp14_ = 0L;
glong _tmp15_ = 0L;
- glong _tmp16_ = 0L;
-#line 1198 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- _tmp15_ = end;
-#line 1198 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- _tmp16_ = string_length;
-#line 1198 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- _tmp13_ = _tmp15_ <= _tmp16_;
-#line 664 "book.c"
+#line 1235 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ _tmp14_ = end;
+#line 1235 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ _tmp15_ = string_length;
+#line 1235 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ _tmp12_ = _tmp14_ <= _tmp15_;
+#line 958 "book.c"
} else {
-#line 1198 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- _tmp13_ = FALSE;
-#line 668 "book.c"
+#line 1235 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ _tmp12_ = FALSE;
+#line 962 "book.c"
}
-#line 1198 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- _tmp17_ = _tmp13_;
-#line 1198 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- g_return_val_if_fail (_tmp17_, NULL);
-#line 1199 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1235 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ g_return_val_if_fail (_tmp12_, NULL);
+#line 1236 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ _tmp16_ = start;
+#line 1236 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ _tmp17_ = end;
+#line 1236 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ g_return_val_if_fail (_tmp16_ <= _tmp17_, NULL);
+#line 1237 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp18_ = start;
-#line 1199 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1237 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp19_ = end;
-#line 1199 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- g_return_val_if_fail (_tmp18_ <= _tmp19_, NULL);
-#line 1200 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1237 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp20_ = start;
-#line 1200 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- _tmp21_ = end;
-#line 1200 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- _tmp22_ = start;
-#line 1200 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- _tmp23_ = g_strndup (((gchar*) self) + _tmp20_, (gsize) (_tmp21_ - _tmp22_));
-#line 1200 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
- result = _tmp23_;
-#line 1200 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1237 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ _tmp21_ = g_strndup (((gchar*) self) + _tmp18_, (gsize) (_tmp19_ - _tmp20_));
+#line 1237 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
+ result = _tmp21_;
+#line 1237 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
return result;
-#line 692 "book.c"
+#line 984 "book.c"
}
@@ -734,56 +1026,56 @@ static GFile* book_make_indexed_file (Book* self, const gchar* uri, gint i) {
gchar* _tmp46_ = NULL;
const gchar* _tmp47_ = NULL;
GFile* _tmp48_ = NULL;
-#line 107 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 151 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (self != NULL, NULL);
-#line 107 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 151 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (uri != NULL, NULL);
-#line 109 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = book_get_n_pages (self);
-#line 109 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = _tmp0_;
-#line 109 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_tmp1_ == ((guint) 1)) {
-#line 748 "book.c"
+#line 1040 "book.c"
const gchar* _tmp2_ = NULL;
GFile* _tmp3_ = NULL;
-#line 110 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 154 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = uri;
-#line 110 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 154 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3_ = g_file_new_for_uri (_tmp2_);
-#line 110 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 154 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
result = _tmp3_;
-#line 110 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 154 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 759 "book.c"
+#line 1051 "book.c"
}
-#line 113 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 157 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp4_ = uri;
-#line 113 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 157 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_ = g_path_get_basename (_tmp4_);
-#line 113 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 157 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
basename = _tmp5_;
-#line 114 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp6_ = uri;
-#line 114 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp7_ = g_strdup (_tmp6_);
-#line 114 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
prefix = _tmp7_;
-#line 114 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp8_ = g_strdup ("");
-#line 114 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
suffix = _tmp8_;
-#line 115 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 159 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp9_ = basename;
-#line 115 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 159 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp10_ = string_last_index_of_char (_tmp9_, (gunichar) '.', 0);
-#line 115 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 159 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
extension_index = _tmp10_;
-#line 116 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 160 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp11_ = extension_index;
-#line 116 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 160 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_tmp11_ >= 0) {
-#line 787 "book.c"
+#line 1079 "book.c"
const gchar* _tmp12_ = NULL;
gint _tmp13_ = 0;
const gchar* _tmp14_ = NULL;
@@ -798,233 +1090,230 @@ static GFile* book_make_indexed_file (Book* self, const gchar* uri, gint i) {
gint _tmp23_ = 0;
gint _tmp24_ = 0;
gchar* _tmp25_ = NULL;
-#line 118 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp12_ = basename;
-#line 118 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp13_ = extension_index;
-#line 118 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp14_ = basename;
-#line 118 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp15_ = strlen (_tmp14_);
-#line 118 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp16_ = _tmp15_;
-#line 118 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp17_ = string_slice (_tmp12_, (glong) _tmp13_, (glong) _tmp16_);
-#line 118 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (suffix);
-#line 118 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
suffix = _tmp17_;
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp18_ = uri;
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp19_ = uri;
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp20_ = strlen (_tmp19_);
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp21_ = _tmp20_;
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp22_ = suffix;
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp23_ = strlen (_tmp22_);
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp24_ = _tmp23_;
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp25_ = string_slice (_tmp18_, (glong) 0, (glong) (_tmp21_ - _tmp24_));
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (prefix);
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 163 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
prefix = _tmp25_;
-#line 838 "book.c"
+#line 1130 "book.c"
}
-#line 121 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp26_ = book_get_n_pages (self);
-#line 121 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp27_ = _tmp26_;
-#line 121 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp28_ = g_strdup_printf ("%u", _tmp27_);
-#line 121 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp29_ = _tmp28_;
-#line 121 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp30_ = strlen (_tmp29_);
-#line 121 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp31_ = _tmp30_;
-#line 121 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp32_ = _tmp31_;
-#line 121 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (_tmp29_);
-#line 121 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
width = _tmp32_;
-#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 166 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp33_ = width;
-#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 166 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp34_ = g_strdup_printf ("%%0%dd", _tmp33_);
-#line 122 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 166 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
number_format = _tmp34_;
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp35_ = prefix;
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp36_ = g_strconcat (_tmp35_, "-", NULL);
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp37_ = _tmp36_;
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp38_ = number_format;
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp39_ = i;
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp40_ = g_strdup_printf (_tmp38_, _tmp39_ + 1);
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp41_ = _tmp40_;
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp42_ = g_strconcat (_tmp37_, _tmp41_, NULL);
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp43_ = _tmp42_;
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp44_ = suffix;
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp45_ = g_strconcat (_tmp43_, _tmp44_, NULL);
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp46_ = _tmp45_;
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (_tmp43_);
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (_tmp41_);
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (_tmp37_);
-#line 123 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
filename = _tmp46_;
-#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp47_ = filename;
-#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp48_ = g_file_new_for_uri (_tmp47_);
-#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
result = _tmp48_;
-#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (filename);
-#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (number_format);
-#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (suffix);
-#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (prefix);
-#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (basename);
-#line 124 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 914 "book.c"
+#line 1206 "book.c"
}
static void book_save_multi_file (Book* self, const gchar* type, gint quality, GFile* file, GError** error) {
GError * _inner_error_ = NULL;
-#line 127 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 171 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (self != NULL);
-#line 127 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 171 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (type != NULL);
-#line 127 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 171 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (file != NULL);
-#line 926 "book.c"
+#line 1218 "book.c"
{
gint i = 0;
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
i = 0;
-#line 931 "book.c"
+#line 1223 "book.c"
{
gboolean _tmp0_ = FALSE;
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = TRUE;
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
while (TRUE) {
-#line 938 "book.c"
- gboolean _tmp1_ = FALSE;
- gint _tmp3_ = 0;
+#line 1230 "book.c"
+ gint _tmp2_ = 0;
+ guint _tmp3_ = 0U;
guint _tmp4_ = 0U;
- guint _tmp5_ = 0U;
Page* page = NULL;
- gint _tmp6_ = 0;
+ gint _tmp5_ = 0;
+ Page* _tmp6_ = NULL;
Page* _tmp7_ = NULL;
- Page* _tmp8_ = NULL;
- const gchar* _tmp9_ = NULL;
- gint _tmp10_ = 0;
- GFile* _tmp11_ = NULL;
+ const gchar* _tmp8_ = NULL;
+ gint _tmp9_ = 0;
+ GFile* _tmp10_ = NULL;
+ gchar* _tmp11_ = NULL;
gchar* _tmp12_ = NULL;
- gchar* _tmp13_ = NULL;
- gint _tmp14_ = 0;
+ gint _tmp13_ = 0;
+ GFile* _tmp14_ = NULL;
GFile* _tmp15_ = NULL;
- GFile* _tmp16_ = NULL;
- gint _tmp17_ = 0;
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp1_ = _tmp0_;
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!_tmp1_) {
-#line 960 "book.c"
- gint _tmp2_ = 0;
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp2_ = i;
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- i = _tmp2_ + 1;
-#line 966 "book.c"
+ gint _tmp16_ = 0;
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp0_) {
+#line 1249 "book.c"
+ gint _tmp1_ = 0;
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp1_ = i;
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ i = _tmp1_ + 1;
+#line 1255 "book.c"
}
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = FALSE;
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp3_ = i;
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp4_ = book_get_n_pages (self);
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp5_ = _tmp4_;
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!(((guint) _tmp3_) < _tmp5_)) {
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp2_ = i;
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp3_ = book_get_n_pages (self);
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp4_ = _tmp3_;
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(((guint) _tmp2_) < _tmp4_)) {
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 980 "book.c"
+#line 1269 "book.c"
}
-#line 131 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp6_ = i;
-#line 131 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp7_ = book_get_page (self, _tmp6_);
-#line 131 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- page = _tmp7_;
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp8_ = page;
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp9_ = type;
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp10_ = quality;
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp11_ = file;
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp12_ = g_file_get_uri (_tmp11_);
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp13_ = _tmp12_;
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp14_ = i;
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp15_ = book_make_indexed_file (self, _tmp13_, _tmp14_);
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp16_ = _tmp15_;
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- page_save (_tmp8_, _tmp9_, _tmp10_, _tmp16_, &_inner_error_);
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_object_unref0 (_tmp16_);
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp13_);
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 175 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp5_ = i;
+#line 175 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp6_ = book_get_page (self, _tmp5_);
+#line 175 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ page = _tmp6_;
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp7_ = page;
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp8_ = type;
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp9_ = quality;
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp10_ = file;
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp11_ = g_file_get_uri (_tmp10_);
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp12_ = _tmp11_;
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp13_ = i;
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp14_ = book_make_indexed_file (self, _tmp12_, _tmp13_);
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp15_ = _tmp14_;
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ page_save (_tmp7_, _tmp8_, _tmp9_, _tmp15_, &_inner_error_);
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_object_unref0 (_tmp15_);
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp12_);
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_inner_error_ != NULL) {
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_propagate_error (error, _inner_error_);
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_page_unref0 (page);
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return;
-#line 1020 "book.c"
+#line 1309 "book.c"
}
-#line 133 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp17_ = i;
-#line 133 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- g_signal_emit_by_name (self, "saving", _tmp17_);
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 177 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp16_ = i;
+#line 177 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ g_signal_emit_by_name (self, "saving", _tmp16_);
+#line 173 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_page_unref0 (page);
-#line 1028 "book.c"
+#line 1317 "book.c"
}
}
}
@@ -1039,44 +1328,44 @@ static void book_save_ps_pdf_surface (Book* self, cairo_surface_t* surface, GdkP
gdouble _tmp3_ = 0.0;
GdkPixbuf* _tmp4_ = NULL;
cairo_pattern_t* _tmp5_ = NULL;
-#line 137 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (self != NULL);
-#line 137 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (surface != NULL);
-#line 137 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (image != NULL);
-#line 139 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 183 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = surface;
-#line 139 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 183 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = cairo_create (_tmp0_);
-#line 139 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 183 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
context = _tmp1_;
-#line 140 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = dpi;
-#line 140 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3_ = dpi;
-#line 140 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
cairo_scale (context, 72.0 / _tmp2_, 72.0 / _tmp3_);
-#line 141 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 185 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp4_ = image;
-#line 141 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 185 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
gdk_cairo_set_source_pixbuf (context, _tmp4_, (gdouble) 0, (gdouble) 0);
-#line 142 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 186 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_ = cairo_get_source (context);
-#line 142 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 186 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
cairo_pattern_set_filter (_tmp5_, CAIRO_FILTER_BEST);
-#line 143 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 187 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
cairo_paint (context);
-#line 137 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_cairo_destroy0 (context);
-#line 1073 "book.c"
+#line 1362 "book.c"
}
static gpointer _cairo_surface_reference0 (gpointer self) {
-#line 150 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return self ? cairo_surface_reference (self) : NULL;
-#line 1080 "book.c"
+#line 1369 "book.c"
}
@@ -1091,61 +1380,61 @@ static void book_save_ps (Book* self, GFile* file, GError** error) {
cairo_surface_t* _tmp4_ = NULL;
cairo_surface_t* _tmp5_ = NULL;
GError * _inner_error_ = NULL;
-#line 146 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 190 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (self != NULL);
-#line 146 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 190 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (file != NULL);
-#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = file;
-#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = g_file_replace (_tmp0_, NULL, FALSE, G_FILE_CREATE_NONE, NULL, &_inner_error_);
-#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
stream = _tmp1_;
-#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_inner_error_ != NULL) {
-#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_propagate_error (error, _inner_error_);
-#line 148 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return;
-#line 1111 "book.c"
+#line 1400 "book.c"
}
-#line 149 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = ps_writer_new (stream);
-#line 149 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
writer = _tmp2_;
-#line 150 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3_ = writer;
-#line 150 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp4_ = _tmp3_->surface;
-#line 150 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_ = _cairo_surface_reference0 (_tmp4_);
-#line 150 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
surface = _tmp5_;
-#line 1125 "book.c"
+#line 1414 "book.c"
{
gint i = 0;
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
i = 0;
-#line 1130 "book.c"
+#line 1419 "book.c"
{
gboolean _tmp6_ = FALSE;
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp6_ = TRUE;
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
while (TRUE) {
-#line 1137 "book.c"
- gboolean _tmp7_ = FALSE;
- gint _tmp9_ = 0;
+#line 1426 "book.c"
+ gint _tmp8_ = 0;
+ guint _tmp9_ = 0U;
guint _tmp10_ = 0U;
- guint _tmp11_ = 0U;
Page* page = NULL;
- gint _tmp12_ = 0;
- Page* _tmp13_ = NULL;
+ gint _tmp11_ = 0;
+ Page* _tmp12_ = NULL;
GdkPixbuf* image = NULL;
- Page* _tmp14_ = NULL;
- GdkPixbuf* _tmp15_ = NULL;
+ Page* _tmp13_ = NULL;
+ GdkPixbuf* _tmp14_ = NULL;
gdouble width = 0.0;
- GdkPixbuf* _tmp16_ = NULL;
+ GdkPixbuf* _tmp15_ = NULL;
+ gint _tmp16_ = 0;
gint _tmp17_ = 0;
Page* _tmp18_ = NULL;
gint _tmp19_ = 0;
@@ -1153,124 +1442,127 @@ static void book_save_ps (Book* self, GFile* file, GError** error) {
gdouble height = 0.0;
GdkPixbuf* _tmp21_ = NULL;
gint _tmp22_ = 0;
- Page* _tmp23_ = NULL;
- gint _tmp24_ = 0;
+ gint _tmp23_ = 0;
+ Page* _tmp24_ = NULL;
gint _tmp25_ = 0;
- cairo_surface_t* _tmp26_ = NULL;
- gdouble _tmp27_ = 0.0;
+ gint _tmp26_ = 0;
+ cairo_surface_t* _tmp27_ = NULL;
gdouble _tmp28_ = 0.0;
- cairo_surface_t* _tmp29_ = NULL;
- GdkPixbuf* _tmp30_ = NULL;
- Page* _tmp31_ = NULL;
- gint _tmp32_ = 0;
+ gdouble _tmp29_ = 0.0;
+ cairo_surface_t* _tmp30_ = NULL;
+ GdkPixbuf* _tmp31_ = NULL;
+ Page* _tmp32_ = NULL;
gint _tmp33_ = 0;
- cairo_surface_t* _tmp34_ = NULL;
- gint _tmp35_ = 0;
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp7_ = _tmp6_;
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!_tmp7_) {
-#line 1174 "book.c"
- gint _tmp8_ = 0;
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp8_ = i;
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- i = _tmp8_ + 1;
-#line 1180 "book.c"
+ gint _tmp34_ = 0;
+ cairo_surface_t* _tmp35_ = NULL;
+ gint _tmp36_ = 0;
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp6_) {
+#line 1462 "book.c"
+ gint _tmp7_ = 0;
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp7_ = i;
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ i = _tmp7_ + 1;
+#line 1468 "book.c"
}
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp6_ = FALSE;
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp9_ = i;
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp10_ = book_get_n_pages (self);
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp11_ = _tmp10_;
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!(((guint) _tmp9_) < _tmp11_)) {
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp8_ = i;
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp9_ = book_get_n_pages (self);
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp10_ = _tmp9_;
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(((guint) _tmp8_) < _tmp10_)) {
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 1194 "book.c"
+#line 1482 "book.c"
}
-#line 154 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp12_ = i;
-#line 154 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp13_ = book_get_page (self, _tmp12_);
-#line 154 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- page = _tmp13_;
-#line 155 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp14_ = page;
-#line 155 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp15_ = page_get_image (_tmp14_, TRUE);
-#line 155 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- image = _tmp15_;
-#line 156 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp16_ = image;
-#line 156 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp17_ = gdk_pixbuf_get_width (_tmp16_);
-#line 156 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 198 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp11_ = i;
+#line 198 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp12_ = book_get_page (self, _tmp11_);
+#line 198 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ page = _tmp12_;
+#line 199 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp13_ = page;
+#line 199 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp14_ = page_get_image (_tmp13_, TRUE);
+#line 199 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ image = _tmp14_;
+#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp15_ = image;
+#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp16_ = gdk_pixbuf_get_width (_tmp15_);
+#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp17_ = _tmp16_;
+#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp18_ = page;
-#line 156 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp19_ = page_get_dpi (_tmp18_);
-#line 156 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp20_ = _tmp19_;
-#line 156 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 200 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
width = (_tmp17_ * 72.0) / _tmp20_;
-#line 157 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp21_ = image;
-#line 157 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp22_ = gdk_pixbuf_get_height (_tmp21_);
-#line 157 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp23_ = page;
-#line 157 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp24_ = page_get_dpi (_tmp23_);
-#line 157 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp25_ = _tmp24_;
-#line 157 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- height = (_tmp22_ * 72.0) / _tmp25_;
-#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp26_ = surface;
-#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp27_ = width;
-#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp28_ = height;
-#line 158 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- cairo_ps_surface_set_size (_tmp26_, _tmp27_, _tmp28_);
-#line 159 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp29_ = surface;
-#line 159 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp30_ = image;
-#line 159 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp31_ = page;
-#line 159 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp32_ = page_get_dpi (_tmp31_);
-#line 159 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp33_ = _tmp32_;
-#line 159 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- book_save_ps_pdf_surface (self, _tmp29_, _tmp30_, (gdouble) _tmp33_);
-#line 160 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp34_ = surface;
-#line 160 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- cairo_surface_show_page (_tmp34_);
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp35_ = i;
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- g_signal_emit_by_name (self, "saving", _tmp35_);
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp23_ = _tmp22_;
+#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp24_ = page;
+#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp25_ = page_get_dpi (_tmp24_);
+#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp26_ = _tmp25_;
+#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ height = (_tmp23_ * 72.0) / _tmp26_;
+#line 202 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp27_ = surface;
+#line 202 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp28_ = width;
+#line 202 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp29_ = height;
+#line 202 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ cairo_ps_surface_set_size (_tmp27_, _tmp28_, _tmp29_);
+#line 203 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp30_ = surface;
+#line 203 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp31_ = image;
+#line 203 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp32_ = page;
+#line 203 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp33_ = page_get_dpi (_tmp32_);
+#line 203 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp34_ = _tmp33_;
+#line 203 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ book_save_ps_pdf_surface (self, _tmp30_, _tmp31_, (gdouble) _tmp34_);
+#line 204 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp35_ = surface;
+#line 204 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ cairo_surface_show_page (_tmp35_);
+#line 205 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp36_ = i;
+#line 205 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ g_signal_emit_by_name (self, "saving", _tmp36_);
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_object_unref0 (image);
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_page_unref0 (page);
-#line 1264 "book.c"
+#line 1556 "book.c"
}
}
}
-#line 146 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 190 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_cairo_surface_destroy0 (surface);
-#line 146 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 190 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_ps_writer_unref0 (writer);
-#line 146 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 190 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_object_unref0 (stream);
-#line 1274 "book.c"
+#line 1566 "book.c"
}
@@ -1298,140 +1590,140 @@ static guint8* book_compress_zlib (Book* self, guint8* data, int data_length1, i
gint _tmp14_ = 0;
guint8* _tmp15_ = NULL;
gint _tmp15__length1 = 0;
-#line 165 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 209 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (self != NULL, NULL);
-#line 167 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 211 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
deflateInit (&stream, (gint) Z_BEST_COMPRESSION);
-#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 212 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = data;
-#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 212 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0__length1 = data_length1;
-#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 212 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = g_new0 (guint8, _tmp0__length1);
-#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 212 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
out_data = _tmp1_;
-#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 212 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
out_data_length1 = _tmp0__length1;
-#line 168 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 212 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_out_data_size_ = out_data_length1;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 214 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = data;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 214 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2__length1 = data_length1;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 214 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
stream.next_in = _tmp2_;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 214 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
stream.avail_in = _tmp2__length1;
-#line 171 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3_ = out_data;
-#line 171 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3__length1 = out_data_length1;
-#line 171 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
stream.next_out = _tmp3_;
-#line 171 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
stream.avail_out = _tmp3__length1;
-#line 172 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 216 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
while (TRUE) {
-#line 1336 "book.c"
+#line 1628 "book.c"
z_stream _tmp4_ = {0};
guint _tmp5_ = 0U;
gint _tmp6_ = 0;
-#line 172 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 216 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp4_ = stream;
-#line 172 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 216 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_ = _tmp4_.avail_in;
-#line 172 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 216 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (!(_tmp5_ > ((guint) 0))) {
-#line 172 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 216 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 1348 "book.c"
+#line 1640 "book.c"
}
-#line 174 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 218 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp6_ = deflate (&stream, (gint) Z_FINISH);
-#line 174 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 218 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_tmp6_ == ((gint) Z_STREAM_ERROR)) {
-#line 175 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 219 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 1356 "book.c"
+#line 1648 "book.c"
}
}
-#line 178 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 222 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp7_ = stream;
-#line 178 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 222 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp8_ = _tmp7_.avail_in;
-#line 178 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 222 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_tmp8_ > ((guint) 0)) {
-#line 1365 "book.c"
+#line 1657 "book.c"
guint8* _tmp9_ = NULL;
gint _tmp9__length1 = 0;
-#line 179 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp9_ = NULL;
-#line 179 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp9__length1 = 0;
-#line 179 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (result_length1) {
-#line 179 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
*result_length1 = _tmp9__length1;
-#line 1376 "book.c"
+#line 1668 "book.c"
}
-#line 179 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
result = _tmp9_;
-#line 179 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
out_data = (g_free (out_data), NULL);
-#line 179 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
deflateEnd (&stream);
-#line 179 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 223 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 1386 "book.c"
+#line 1678 "book.c"
}
-#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp10_ = data;
-#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp10__length1 = data_length1;
-#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp11_ = stream;
-#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp12_ = _tmp11_.avail_out;
-#line 181 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
n_written = _tmp10__length1 - _tmp12_;
-#line 182 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp13_ = n_written;
-#line 182 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp14_ = (gint) _tmp13_;
-#line 182 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
out_data = g_renew (guint8, out_data, (gint) _tmp13_);
-#line 182 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
(_tmp14_ > out_data_length1) ? memset (out_data + out_data_length1, 0, sizeof (guint8) * (_tmp14_ - out_data_length1)) : NULL;
-#line 182 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
out_data_length1 = _tmp14_;
-#line 182 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_out_data_size_ = _tmp14_;
-#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp15_ = out_data;
-#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp15__length1 = out_data_length1;
-#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (result_length1) {
-#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
*result_length1 = _tmp15__length1;
-#line 1418 "book.c"
+#line 1710 "book.c"
}
-#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
result = _tmp15_;
-#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
deflateEnd (&stream);
-#line 184 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 1426 "book.c"
+#line 1718 "book.c"
}
static gboolean _book_write_pixbuf_data_gdk_pixbuf_save_func (guint8* buf, gsize buf_length1, GError** error, gpointer self) {
gboolean result;
- result = book_write_pixbuf_data (self, buf, buf_length1, error);
-#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ result = book_write_pixbuf_data ((Book*) self, buf, buf_length1, error);
+#line 240 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 1435 "book.c"
+#line 1727 "book.c"
}
@@ -1466,84 +1758,84 @@ static guint8* book_compress_jpeg (Book* self, GdkPixbuf* image, gint quality, g
guint8* _tmp17_ = NULL;
gint _tmp17__length1 = 0;
GError * _inner_error_ = NULL;
-#line 189 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 233 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (self != NULL, NULL);
-#line 189 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 233 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (image != NULL, NULL);
-#line 191 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 235 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = g_byte_array_new ();
-#line 191 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 235 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_byte_array_unref0 (self->priv->jpeg_data);
-#line 191 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 235 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self->priv->jpeg_data = _tmp0_;
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = g_strdup ("quality");
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = g_strdup ("density-unit");
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3_ = g_strdup ("x-density");
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp4_ = g_strdup ("y-density");
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_ = g_new0 (gchar*, 5 + 1);
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_[0] = _tmp1_;
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_[1] = _tmp2_;
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_[2] = _tmp3_;
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_[3] = _tmp4_;
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_[4] = NULL;
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
keys = _tmp5_;
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
keys_length1 = 5;
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_keys_size_ = keys_length1;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp6_ = quality;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp7_ = g_strdup_printf ("%d", _tmp6_);
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp8_ = g_strdup ("dots-per-inch");
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp9_ = dpi;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp10_ = g_strdup_printf ("%d", _tmp9_);
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp11_ = dpi;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp12_ = g_strdup_printf ("%d", _tmp11_);
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp13_ = g_new0 (gchar*, 5 + 1);
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp13_[0] = _tmp7_;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp13_[1] = _tmp8_;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp13_[2] = _tmp10_;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp13_[3] = _tmp12_;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp13_[4] = NULL;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
values = _tmp13_;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
values_length1 = 5;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_values_size_ = values_length1;
-#line 1538 "book.c"
+#line 1830 "book.c"
{
GdkPixbuf* _tmp14_ = NULL;
-#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 240 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp14_ = image;
-#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 240 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
gdk_pixbuf_save_to_callbackv (_tmp14_, _book_write_pixbuf_data_gdk_pixbuf_save_func, self, "jpeg", keys, values, &_inner_error_);
-#line 196 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 240 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_inner_error_ != NULL) {
-#line 1547 "book.c"
+#line 1839 "book.c"
goto __catch0_g_error;
}
}
@@ -1551,66 +1843,68 @@ static guint8* book_compress_jpeg (Book* self, GdkPixbuf* image, gint quality, g
__catch0_g_error:
{
GError* e = NULL;
-#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
e = _inner_error_;
-#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_inner_error_ = NULL;
-#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_error_free0 (e);
-#line 1561 "book.c"
+#line 1853 "book.c"
}
__finally0:
-#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_inner_error_ != NULL) {
-#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL);
-#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL);
-#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
-#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_clear_error (&_inner_error_);
-#line 194 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return NULL;
-#line 1576 "book.c"
+#line 1868 "book.c"
}
-#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp15_ = self->priv->jpeg_data;
-#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp16_ = _tmp15_->data;
-#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp16__length1 = _tmp15_->len;
-#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp15_->data = NULL;
-#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp15_->len = 0;
+#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
data = _tmp16_;
-#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
data_length1 = _tmp16__length1;
-#line 201 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 245 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_data_size_ = data_length1;
-#line 202 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 246 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_byte_array_unref0 (self->priv->jpeg_data);
-#line 202 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 246 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self->priv->jpeg_data = NULL;
-#line 204 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp17_ = data;
-#line 204 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp17__length1 = data_length1;
-#line 204 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (result_length1) {
-#line 204 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
*result_length1 = _tmp17__length1;
-#line 1604 "book.c"
+#line 1898 "book.c"
}
-#line 204 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
result = _tmp17_;
-#line 204 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL);
-#line 204 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL);
-#line 204 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 248 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 1614 "book.c"
+#line 1908 "book.c"
}
@@ -1619,65 +1913,57 @@ static gboolean book_write_pixbuf_data (Book* self, guint8* buf, int buf_length1
GByteArray* _tmp0_ = NULL;
guint8* _tmp1_ = NULL;
gint _tmp1__length1 = 0;
-#line 207 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 251 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (self != NULL, FALSE);
-#line 209 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 253 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = self->priv->jpeg_data;
-#line 209 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 253 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = buf;
-#line 209 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 253 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1__length1 = buf_length1;
-#line 209 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 253 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_byte_array_append (_tmp0_, _tmp1_, _tmp1__length1);
-#line 210 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 254 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
result = TRUE;
-#line 210 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 254 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 1637 "book.c"
+#line 1931 "book.c"
}
static guint8* _vala_array_dup1 (guint8* self, int length) {
-#line 409 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 459 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return g_memdup (self, length * sizeof (guint8));
-#line 1644 "book.c"
+#line 1938 "book.c"
}
static guint8* _vala_array_dup2 (guint8* self, int length) {
-#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 466 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return g_memdup (self, length * sizeof (guint8));
-#line 1651 "book.c"
+#line 1945 "book.c"
}
static void book_save_pdf (Book* self, GFile* file, gint quality, GError** error) {
+ gchar* id = NULL;
+ gchar* _tmp0_ = NULL;
GFileOutputStream* stream = NULL;
- GFile* _tmp0_ = NULL;
- GFileOutputStream* _tmp1_ = NULL;
+ GFile* _tmp9_ = NULL;
+ GFileOutputStream* _tmp10_ = NULL;
PDFWriter* writer = NULL;
- PDFWriter* _tmp2_ = NULL;
- PDFWriter* _tmp3_ = NULL;
- PDFWriter* _tmp4_ = NULL;
- guint catalog_number = 0U;
- PDFWriter* _tmp5_ = NULL;
- guint _tmp6_ = 0U;
- PDFWriter* _tmp7_ = NULL;
- guint _tmp8_ = 0U;
- gchar* _tmp9_ = NULL;
- gchar* _tmp10_ = NULL;
PDFWriter* _tmp11_ = NULL;
PDFWriter* _tmp12_ = NULL;
PDFWriter* _tmp13_ = NULL;
- guint _tmp14_ = 0U;
- gchar* _tmp15_ = NULL;
- gchar* _tmp16_ = NULL;
- PDFWriter* _tmp17_ = NULL;
- PDFWriter* _tmp18_ = NULL;
- PDFWriter* _tmp19_ = NULL;
- guint pages_number = 0U;
+ guint catalog_number = 0U;
+ PDFWriter* _tmp14_ = NULL;
+ guint _tmp15_ = 0U;
+ PDFWriter* _tmp16_ = NULL;
+ guint _tmp17_ = 0U;
+ gchar* _tmp18_ = NULL;
+ gchar* _tmp19_ = NULL;
PDFWriter* _tmp20_ = NULL;
- guint _tmp21_ = 0U;
+ PDFWriter* _tmp21_ = NULL;
PDFWriter* _tmp22_ = NULL;
guint _tmp23_ = 0U;
gchar* _tmp24_ = NULL;
@@ -1685,789 +1971,869 @@ static void book_save_pdf (Book* self, GFile* file, gint quality, GError** error
PDFWriter* _tmp26_ = NULL;
PDFWriter* _tmp27_ = NULL;
PDFWriter* _tmp28_ = NULL;
- PDFWriter* _tmp40_ = NULL;
- PDFWriter* _tmp41_ = NULL;
- guint _tmp42_ = 0U;
- guint _tmp43_ = 0U;
- gchar* _tmp44_ = NULL;
- gchar* _tmp45_ = NULL;
- PDFWriter* _tmp46_ = NULL;
- PDFWriter* _tmp47_ = NULL;
- PDFWriter* _tmp361_ = NULL;
+ guint pages_number = 0U;
+ PDFWriter* _tmp29_ = NULL;
+ guint _tmp30_ = 0U;
+ PDFWriter* _tmp31_ = NULL;
+ guint _tmp32_ = 0U;
+ gchar* _tmp33_ = NULL;
+ gchar* _tmp34_ = NULL;
+ PDFWriter* _tmp35_ = NULL;
+ PDFWriter* _tmp36_ = NULL;
+ PDFWriter* _tmp37_ = NULL;
+ PDFWriter* _tmp48_ = NULL;
+ PDFWriter* _tmp49_ = NULL;
+ guint _tmp50_ = 0U;
+ guint _tmp51_ = 0U;
+ gchar* _tmp52_ = NULL;
+ gchar* _tmp53_ = NULL;
+ PDFWriter* _tmp54_ = NULL;
+ PDFWriter* _tmp55_ = NULL;
+ PDFWriter* _tmp366_ = NULL;
guint info_number = 0U;
- PDFWriter* _tmp362_ = NULL;
- guint _tmp363_ = 0U;
- PDFWriter* _tmp364_ = NULL;
- guint _tmp365_ = 0U;
- gchar* _tmp366_ = NULL;
- gchar* _tmp367_ = NULL;
- PDFWriter* _tmp368_ = NULL;
+ PDFWriter* _tmp367_ = NULL;
+ guint _tmp368_ = 0U;
PDFWriter* _tmp369_ = NULL;
- gchar* _tmp370_ = NULL;
+ guint _tmp370_ = 0U;
gchar* _tmp371_ = NULL;
- PDFWriter* _tmp372_ = NULL;
+ gchar* _tmp372_ = NULL;
PDFWriter* _tmp373_ = NULL;
- gsize xref_offset = 0UL;
PDFWriter* _tmp374_ = NULL;
- gsize _tmp375_ = 0UL;
- PDFWriter* _tmp376_ = NULL;
+ gchar* _tmp375_ = NULL;
+ gchar* _tmp376_ = NULL;
PDFWriter* _tmp377_ = NULL;
PDFWriter* _tmp378_ = NULL;
- GList* _tmp379_ = NULL;
- guint _tmp380_ = 0U;
- gchar* _tmp381_ = NULL;
- gchar* _tmp382_ = NULL;
+ PDFWriter* _tmp379_ = NULL;
+ gsize xref_offset = 0UL;
+ PDFWriter* _tmp380_ = NULL;
+ gsize _tmp381_ = 0UL;
+ PDFWriter* _tmp382_ = NULL;
PDFWriter* _tmp383_ = NULL;
- GList* _tmp384_ = NULL;
+ PDFWriter* _tmp384_ = NULL;
+ GList* _tmp385_ = NULL;
+ guint _tmp386_ = 0U;
+ gchar* _tmp387_ = NULL;
+ gchar* _tmp388_ = NULL;
PDFWriter* _tmp389_ = NULL;
PDFWriter* _tmp390_ = NULL;
- PDFWriter* _tmp391_ = NULL;
- PDFWriter* _tmp392_ = NULL;
- GList* _tmp393_ = NULL;
- guint _tmp394_ = 0U;
- gchar* _tmp395_ = NULL;
- gchar* _tmp396_ = NULL;
+ GList* _tmp391_ = NULL;
+ PDFWriter* _tmp396_ = NULL;
PDFWriter* _tmp397_ = NULL;
- guint _tmp398_ = 0U;
- gchar* _tmp399_ = NULL;
- gchar* _tmp400_ = NULL;
- PDFWriter* _tmp401_ = NULL;
+ PDFWriter* _tmp398_ = NULL;
+ PDFWriter* _tmp399_ = NULL;
+ PDFWriter* _tmp400_ = NULL;
+ GList* _tmp401_ = NULL;
guint _tmp402_ = 0U;
gchar* _tmp403_ = NULL;
gchar* _tmp404_ = NULL;
PDFWriter* _tmp405_ = NULL;
- PDFWriter* _tmp406_ = NULL;
- PDFWriter* _tmp407_ = NULL;
- gsize _tmp408_ = 0UL;
- gchar* _tmp409_ = NULL;
- gchar* _tmp410_ = NULL;
- PDFWriter* _tmp411_ = NULL;
+ guint _tmp406_ = 0U;
+ gchar* _tmp407_ = NULL;
+ gchar* _tmp408_ = NULL;
+ PDFWriter* _tmp409_ = NULL;
+ guint _tmp410_ = 0U;
+ gchar* _tmp411_ = NULL;
+ gchar* _tmp412_ = NULL;
+ PDFWriter* _tmp413_ = NULL;
+ const gchar* _tmp414_ = NULL;
+ const gchar* _tmp415_ = NULL;
+ gchar* _tmp416_ = NULL;
+ gchar* _tmp417_ = NULL;
+ PDFWriter* _tmp418_ = NULL;
+ PDFWriter* _tmp419_ = NULL;
+ PDFWriter* _tmp420_ = NULL;
+ gsize _tmp421_ = 0UL;
+ gchar* _tmp422_ = NULL;
+ gchar* _tmp423_ = NULL;
+ PDFWriter* _tmp424_ = NULL;
GError * _inner_error_ = NULL;
-#line 213 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (self != NULL);
-#line 213 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (file != NULL);
-#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp0_ = file;
-#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp1_ = g_file_replace (_tmp0_, NULL, FALSE, G_FILE_CREATE_NONE, NULL, &_inner_error_);
-#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- stream = _tmp1_;
-#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 260 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp0_ = g_strdup ("");
+#line 260 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ id = _tmp0_;
+#line 2059 "book.c"
+ {
+ gint i = 0;
+#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ i = 0;
+#line 2064 "book.c"
+ {
+ gboolean _tmp1_ = FALSE;
+#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp1_ = TRUE;
+#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ while (TRUE) {
+#line 2071 "book.c"
+ gint _tmp3_ = 0;
+ const gchar* _tmp4_ = NULL;
+ guint32 _tmp5_ = 0U;
+ gchar* _tmp6_ = NULL;
+ gchar* _tmp7_ = NULL;
+ gchar* _tmp8_ = NULL;
+#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp1_) {
+#line 2080 "book.c"
+ gint _tmp2_ = 0;
+#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp2_ = i;
+#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ i = _tmp2_ + 1;
+#line 2086 "book.c"
+ }
+#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp1_ = FALSE;
+#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp3_ = i;
+#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(_tmp3_ < 4)) {
+#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ break;
+#line 2096 "book.c"
+ }
+#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp4_ = id;
+#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp5_ = g_random_int ();
+#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp6_ = g_strdup_printf ("%08x", (guint) _tmp5_);
+#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp7_ = _tmp6_;
+#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp8_ = g_strconcat (_tmp4_, _tmp7_, NULL);
+#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (id);
+#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ id = _tmp8_;
+#line 262 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp7_);
+#line 2114 "book.c"
+ }
+ }
+ }
+#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp9_ = file;
+#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp10_ = g_file_replace (_tmp9_, NULL, FALSE, G_FILE_CREATE_NONE, NULL, &_inner_error_);
+#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ stream = _tmp10_;
+#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_inner_error_ != NULL) {
-#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_propagate_error (error, _inner_error_);
-#line 215 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (id);
+#line 264 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return;
-#line 1763 "book.c"
+#line 2132 "book.c"
}
-#line 216 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp2_ = pdf_writer_new (stream);
-#line 216 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- writer = _tmp2_;
-#line 219 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp3_ = writer;
-#line 219 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp3_, "%PDF-1.3\n");
-#line 222 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp4_ = writer;
-#line 222 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp4_, "%\xe2\xe3\xcf\xd3\n");
-#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp5_ = writer;
-#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp6_ = pdf_writer_start_object (_tmp5_);
-#line 225 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- catalog_number = _tmp6_;
-#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp7_ = writer;
-#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp8_ = catalog_number;
-#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp9_ = g_strdup_printf ("%u 0 obj\n", _tmp8_);
-#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp10_ = _tmp9_;
-#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp7_, _tmp10_);
-#line 226 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp10_);
-#line 227 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp11_ = writer;
-#line 227 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp11_, "<<\n");
-#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 265 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp11_ = pdf_writer_new (stream);
+#line 265 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ writer = _tmp11_;
+#line 268 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp12_ = writer;
-#line 228 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp12_, "/Type /Catalog\n");
-#line 230 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 268 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp12_, "%PDF-1.3\n");
+#line 271 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp13_ = writer;
-#line 230 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp14_ = catalog_number;
-#line 230 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp15_ = g_strdup_printf ("/Pages %u 0 R\n", _tmp14_ + 1);
-#line 230 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp16_ = _tmp15_;
-#line 230 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp13_, _tmp16_);
-#line 230 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp16_);
-#line 231 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp17_ = writer;
-#line 231 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp17_, ">>\n");
-#line 232 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp18_ = writer;
-#line 232 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp18_, "endobj\n");
-#line 250 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp19_ = writer;
-#line 250 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp19_, "\n");
-#line 251 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 271 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp13_, "%\xe2\xe3\xcf\xd3\n");
+#line 274 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp14_ = writer;
+#line 274 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp15_ = pdf_writer_start_object (_tmp14_);
+#line 274 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ catalog_number = _tmp15_;
+#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp16_ = writer;
+#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp17_ = catalog_number;
+#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp18_ = g_strdup_printf ("%u 0 obj\n", _tmp17_);
+#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp19_ = _tmp18_;
+#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp16_, _tmp19_);
+#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp19_);
+#line 276 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp20_ = writer;
-#line 251 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp21_ = pdf_writer_start_object (_tmp20_);
-#line 251 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pages_number = _tmp21_;
-#line 252 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 276 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp20_, "<<\n");
+#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp21_ = writer;
+#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp21_, "/Type /Catalog\n");
+#line 280 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp22_ = writer;
-#line 252 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp23_ = pages_number;
-#line 252 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp24_ = g_strdup_printf ("%u 0 obj\n", _tmp23_);
-#line 252 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 280 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp23_ = catalog_number;
+#line 280 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp24_ = g_strdup_printf ("/Pages %u 0 R\n", _tmp23_ + 1);
+#line 280 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp25_ = _tmp24_;
-#line 252 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 280 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
pdf_writer_write_string (_tmp22_, _tmp25_);
-#line 252 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 280 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (_tmp25_);
-#line 253 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 281 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp26_ = writer;
-#line 253 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp26_, "<<\n");
-#line 254 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 281 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp26_, ">>\n");
+#line 282 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp27_ = writer;
-#line 254 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp27_, "/Type /Pages\n");
-#line 255 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 282 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp27_, "endobj\n");
+#line 300 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp28_ = writer;
-#line 255 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp28_, "/Kids [");
-#line 1857 "book.c"
+#line 300 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp28_, "\n");
+#line 301 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp29_ = writer;
+#line 301 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp30_ = pdf_writer_start_object (_tmp29_);
+#line 301 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pages_number = _tmp30_;
+#line 302 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp31_ = writer;
+#line 302 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp32_ = pages_number;
+#line 302 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp33_ = g_strdup_printf ("%u 0 obj\n", _tmp32_);
+#line 302 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp34_ = _tmp33_;
+#line 302 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp31_, _tmp34_);
+#line 302 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp34_);
+#line 303 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp35_ = writer;
+#line 303 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp35_, "<<\n");
+#line 304 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp36_ = writer;
+#line 304 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp36_, "/Type /Pages\n");
+#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp37_ = writer;
+#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp37_, "/Kids [");
+#line 2226 "book.c"
{
gint i = 0;
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
i = 0;
-#line 1862 "book.c"
+#line 2231 "book.c"
{
- gboolean _tmp29_ = FALSE;
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp29_ = TRUE;
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ gboolean _tmp38_ = FALSE;
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp38_ = TRUE;
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
while (TRUE) {
-#line 1869 "book.c"
- gboolean _tmp30_ = FALSE;
- gint _tmp32_ = 0;
- guint _tmp33_ = 0U;
- guint _tmp34_ = 0U;
- PDFWriter* _tmp35_ = NULL;
- guint _tmp36_ = 0U;
- gint _tmp37_ = 0;
- gchar* _tmp38_ = NULL;
- gchar* _tmp39_ = NULL;
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp30_ = _tmp29_;
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!_tmp30_) {
-#line 1883 "book.c"
- gint _tmp31_ = 0;
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp31_ = i;
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- i = _tmp31_ + 1;
-#line 1889 "book.c"
+#line 2238 "book.c"
+ gint _tmp40_ = 0;
+ guint _tmp41_ = 0U;
+ guint _tmp42_ = 0U;
+ PDFWriter* _tmp43_ = NULL;
+ guint _tmp44_ = 0U;
+ gint _tmp45_ = 0;
+ gchar* _tmp46_ = NULL;
+ gchar* _tmp47_ = NULL;
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp38_) {
+#line 2249 "book.c"
+ gint _tmp39_ = 0;
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp39_ = i;
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ i = _tmp39_ + 1;
+#line 2255 "book.c"
}
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp29_ = FALSE;
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp32_ = i;
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp33_ = book_get_n_pages (self);
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp34_ = _tmp33_;
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!(((guint) _tmp32_) < _tmp34_)) {
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp38_ = FALSE;
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp40_ = i;
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp41_ = book_get_n_pages (self);
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp42_ = _tmp41_;
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(((guint) _tmp40_) < _tmp42_)) {
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 1903 "book.c"
+#line 2269 "book.c"
}
-#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp35_ = writer;
-#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp36_ = pages_number;
-#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp37_ = i;
-#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp38_ = g_strdup_printf (" %u 0 R", (_tmp36_ + 1) + (_tmp37_ * 3));
-#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp39_ = _tmp38_;
-#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp35_, _tmp39_);
-#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp39_);
-#line 1919 "book.c"
+#line 307 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp43_ = writer;
+#line 307 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp44_ = pages_number;
+#line 307 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp45_ = i;
+#line 307 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp46_ = g_strdup_printf (" %u 0 R", (_tmp44_ + 1) + (_tmp45_ * 3));
+#line 307 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp47_ = _tmp46_;
+#line 307 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp43_, _tmp47_);
+#line 307 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp47_);
+#line 2285 "book.c"
}
}
}
-#line 258 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp40_ = writer;
-#line 258 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp40_, " ]\n");
-#line 259 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp41_ = writer;
-#line 259 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp42_ = book_get_n_pages (self);
-#line 259 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp43_ = _tmp42_;
-#line 259 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp44_ = g_strdup_printf ("/Count %u\n", _tmp43_);
-#line 259 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp45_ = _tmp44_;
-#line 259 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp41_, _tmp45_);
-#line 259 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp45_);
-#line 260 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp46_ = writer;
-#line 260 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp46_, ">>\n");
-#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp47_ = writer;
-#line 261 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp47_, "endobj\n");
-#line 1949 "book.c"
+#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp48_ = writer;
+#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp48_, " ]\n");
+#line 309 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp49_ = writer;
+#line 309 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp50_ = book_get_n_pages (self);
+#line 309 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp51_ = _tmp50_;
+#line 309 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp52_ = g_strdup_printf ("/Count %u\n", _tmp51_);
+#line 309 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp53_ = _tmp52_;
+#line 309 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp49_, _tmp53_);
+#line 309 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp53_);
+#line 310 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp54_ = writer;
+#line 310 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp54_, ">>\n");
+#line 311 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp55_ = writer;
+#line 311 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp55_, "endobj\n");
+#line 2315 "book.c"
{
gint i = 0;
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
i = 0;
-#line 1954 "book.c"
+#line 2320 "book.c"
{
- gboolean _tmp48_ = FALSE;
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp48_ = TRUE;
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ gboolean _tmp56_ = FALSE;
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp56_ = TRUE;
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
while (TRUE) {
-#line 1961 "book.c"
- gboolean _tmp49_ = FALSE;
- gint _tmp51_ = 0;
- guint _tmp52_ = 0U;
- guint _tmp53_ = 0U;
+#line 2327 "book.c"
+ gint _tmp58_ = 0;
+ guint _tmp59_ = 0U;
+ guint _tmp60_ = 0U;
Page* page = NULL;
- gint _tmp54_ = 0;
- Page* _tmp55_ = NULL;
+ gint _tmp61_ = 0;
+ Page* _tmp62_ = NULL;
GdkPixbuf* image = NULL;
- Page* _tmp56_ = NULL;
- GdkPixbuf* _tmp57_ = NULL;
+ Page* _tmp63_ = NULL;
+ GdkPixbuf* _tmp64_ = NULL;
gint width = 0;
- GdkPixbuf* _tmp58_ = NULL;
- gint _tmp59_ = 0;
+ GdkPixbuf* _tmp65_ = NULL;
+ gint _tmp66_ = 0;
+ gint _tmp67_ = 0;
gint height = 0;
- GdkPixbuf* _tmp60_ = NULL;
- gint _tmp61_ = 0;
+ GdkPixbuf* _tmp68_ = NULL;
+ gint _tmp69_ = 0;
+ gint _tmp70_ = 0;
guint8* pixels = NULL;
- GdkPixbuf* _tmp62_ = NULL;
- guint8* _tmp63_ = NULL;
+ GdkPixbuf* _tmp71_ = NULL;
+ guint8* _tmp72_ = NULL;
gint pixels_length1 = 0;
gint _pixels_size_ = 0;
gdouble page_width = 0.0;
- gint _tmp64_ = 0;
- Page* _tmp65_ = NULL;
- gint _tmp66_ = 0;
- gint _tmp67_ = 0;
+ gint _tmp73_ = 0;
+ Page* _tmp74_ = NULL;
+ gint _tmp75_ = 0;
+ gint _tmp76_ = 0;
gdouble page_height = 0.0;
- gint _tmp68_ = 0;
- Page* _tmp69_ = NULL;
- gint _tmp70_ = 0;
- gint _tmp71_ = 0;
+ gint _tmp77_ = 0;
+ Page* _tmp78_ = NULL;
+ gint _tmp79_ = 0;
+ gint _tmp80_ = 0;
gint depth = 0;
gchar* color_space = NULL;
- gchar* _tmp72_ = NULL;
+ gchar* _tmp81_ = NULL;
gchar* filter = NULL;
gchar* width_buffer = NULL;
- gchar* _tmp73_ = NULL;
+ gchar* _tmp82_ = NULL;
gint width_buffer_length1 = 0;
gint _width_buffer_size_ = 0;
gchar* height_buffer = NULL;
- gchar* _tmp74_ = NULL;
+ gchar* _tmp83_ = NULL;
gint height_buffer_length1 = 0;
gint _height_buffer_size_ = 0;
guint8* data = NULL;
gint data_length1 = 0;
gint _data_size_ = 0;
- Page* _tmp75_ = NULL;
- gboolean _tmp76_ = FALSE;
- gboolean _tmp77_ = FALSE;
+ Page* _tmp84_ = NULL;
+ gboolean _tmp85_ = FALSE;
+ gboolean _tmp86_ = FALSE;
guint8* compressed_data = NULL;
- guint8* _tmp235_ = NULL;
- gint _tmp235__length1 = 0;
- gint _tmp236_ = 0;
- guint8* _tmp237_ = NULL;
+ guint8* _tmp240_ = NULL;
+ gint _tmp240__length1 = 0;
+ gint _tmp241_ = 0;
+ guint8* _tmp242_ = NULL;
gint compressed_data_length1 = 0;
gint _compressed_data_size_ = 0;
- guint8* _tmp238_ = NULL;
- gint _tmp238__length1 = 0;
- PDFWriter* _tmp256_ = NULL;
+ guint8* _tmp243_ = NULL;
+ gint _tmp243__length1 = 0;
+ PDFWriter* _tmp261_ = NULL;
guint number = 0U;
- PDFWriter* _tmp257_ = NULL;
- guint _tmp258_ = 0U;
- PDFWriter* _tmp259_ = NULL;
- guint _tmp260_ = 0U;
- gchar* _tmp261_ = NULL;
- gchar* _tmp262_ = NULL;
- PDFWriter* _tmp263_ = NULL;
+ PDFWriter* _tmp262_ = NULL;
+ guint _tmp263_ = 0U;
PDFWriter* _tmp264_ = NULL;
- PDFWriter* _tmp265_ = NULL;
- guint _tmp266_ = 0U;
+ guint _tmp265_ = 0U;
+ gchar* _tmp266_ = NULL;
gchar* _tmp267_ = NULL;
- gchar* _tmp268_ = NULL;
+ PDFWriter* _tmp268_ = NULL;
PDFWriter* _tmp269_ = NULL;
- gint _tmp270_ = 0;
+ PDFWriter* _tmp270_ = NULL;
guint _tmp271_ = 0U;
gchar* _tmp272_ = NULL;
gchar* _tmp273_ = NULL;
PDFWriter* _tmp274_ = NULL;
- gdouble _tmp275_ = 0.0;
- gchar* _tmp276_ = NULL;
- gint _tmp276__length1 = 0;
- const gchar* _tmp277_ = NULL;
- gdouble _tmp278_ = 0.0;
- gchar* _tmp279_ = NULL;
- gint _tmp279__length1 = 0;
- const gchar* _tmp280_ = NULL;
+ gint _tmp275_ = 0;
+ guint _tmp276_ = 0U;
+ gchar* _tmp277_ = NULL;
+ gchar* _tmp278_ = NULL;
+ PDFWriter* _tmp279_ = NULL;
+ gdouble _tmp280_ = 0.0;
gchar* _tmp281_ = NULL;
- gchar* _tmp282_ = NULL;
- PDFWriter* _tmp283_ = NULL;
- guint _tmp284_ = 0U;
- gchar* _tmp285_ = NULL;
+ gint _tmp281__length1 = 0;
+ const gchar* _tmp282_ = NULL;
+ gdouble _tmp283_ = 0.0;
+ gchar* _tmp284_ = NULL;
+ gint _tmp284__length1 = 0;
+ const gchar* _tmp285_ = NULL;
gchar* _tmp286_ = NULL;
- PDFWriter* _tmp287_ = NULL;
+ gchar* _tmp287_ = NULL;
PDFWriter* _tmp288_ = NULL;
- PDFWriter* _tmp289_ = NULL;
- PDFWriter* _tmp290_ = NULL;
- guint _tmp291_ = 0U;
+ guint _tmp289_ = 0U;
+ gchar* _tmp290_ = NULL;
+ gchar* _tmp291_ = NULL;
PDFWriter* _tmp292_ = NULL;
- guint _tmp293_ = 0U;
- gchar* _tmp294_ = NULL;
- gchar* _tmp295_ = NULL;
- PDFWriter* _tmp296_ = NULL;
+ PDFWriter* _tmp293_ = NULL;
+ PDFWriter* _tmp294_ = NULL;
+ PDFWriter* _tmp295_ = NULL;
+ guint _tmp296_ = 0U;
PDFWriter* _tmp297_ = NULL;
- PDFWriter* _tmp298_ = NULL;
- PDFWriter* _tmp299_ = NULL;
- gint _tmp300_ = 0;
- gchar* _tmp301_ = NULL;
- gchar* _tmp302_ = NULL;
+ guint _tmp298_ = 0U;
+ gchar* _tmp299_ = NULL;
+ gchar* _tmp300_ = NULL;
+ PDFWriter* _tmp301_ = NULL;
+ PDFWriter* _tmp302_ = NULL;
PDFWriter* _tmp303_ = NULL;
- gint _tmp304_ = 0;
- gchar* _tmp305_ = NULL;
+ PDFWriter* _tmp304_ = NULL;
+ gint _tmp305_ = 0;
gchar* _tmp306_ = NULL;
- PDFWriter* _tmp307_ = NULL;
- const gchar* _tmp308_ = NULL;
- gchar* _tmp309_ = NULL;
+ gchar* _tmp307_ = NULL;
+ PDFWriter* _tmp308_ = NULL;
+ gint _tmp309_ = 0;
gchar* _tmp310_ = NULL;
- PDFWriter* _tmp311_ = NULL;
- gint _tmp312_ = 0;
- gchar* _tmp313_ = NULL;
+ gchar* _tmp311_ = NULL;
+ PDFWriter* _tmp312_ = NULL;
+ const gchar* _tmp313_ = NULL;
gchar* _tmp314_ = NULL;
- PDFWriter* _tmp315_ = NULL;
- guint8* _tmp316_ = NULL;
- gint _tmp316__length1 = 0;
- gchar* _tmp317_ = NULL;
+ gchar* _tmp315_ = NULL;
+ PDFWriter* _tmp316_ = NULL;
+ gint _tmp317_ = 0;
gchar* _tmp318_ = NULL;
- const gchar* _tmp319_ = NULL;
- PDFWriter* _tmp324_ = NULL;
- PDFWriter* _tmp325_ = NULL;
- PDFWriter* _tmp326_ = NULL;
- guint8* _tmp327_ = NULL;
- gint _tmp327__length1 = 0;
- PDFWriter* _tmp328_ = NULL;
+ gchar* _tmp319_ = NULL;
+ PDFWriter* _tmp320_ = NULL;
+ guint8* _tmp321_ = NULL;
+ gint _tmp321__length1 = 0;
+ gchar* _tmp322_ = NULL;
+ gchar* _tmp323_ = NULL;
+ const gchar* _tmp324_ = NULL;
PDFWriter* _tmp329_ = NULL;
PDFWriter* _tmp330_ = NULL;
- gchar* command = NULL;
- gdouble _tmp331_ = 0.0;
- gchar* _tmp332_ = NULL;
+ PDFWriter* _tmp331_ = NULL;
+ guint8* _tmp332_ = NULL;
gint _tmp332__length1 = 0;
- const gchar* _tmp333_ = NULL;
- gdouble _tmp334_ = 0.0;
- gchar* _tmp335_ = NULL;
- gint _tmp335__length1 = 0;
- const gchar* _tmp336_ = NULL;
- gint _tmp337_ = 0;
- gchar* _tmp338_ = NULL;
- PDFWriter* _tmp339_ = NULL;
- PDFWriter* _tmp340_ = NULL;
- guint _tmp341_ = 0U;
- PDFWriter* _tmp342_ = NULL;
- guint _tmp343_ = 0U;
- gchar* _tmp344_ = NULL;
- gchar* _tmp345_ = NULL;
- PDFWriter* _tmp346_ = NULL;
+ PDFWriter* _tmp333_ = NULL;
+ PDFWriter* _tmp334_ = NULL;
+ PDFWriter* _tmp335_ = NULL;
+ gchar* command = NULL;
+ gdouble _tmp336_ = 0.0;
+ gchar* _tmp337_ = NULL;
+ gint _tmp337__length1 = 0;
+ const gchar* _tmp338_ = NULL;
+ gdouble _tmp339_ = 0.0;
+ gchar* _tmp340_ = NULL;
+ gint _tmp340__length1 = 0;
+ const gchar* _tmp341_ = NULL;
+ gint _tmp342_ = 0;
+ gchar* _tmp343_ = NULL;
+ PDFWriter* _tmp344_ = NULL;
+ PDFWriter* _tmp345_ = NULL;
+ guint _tmp346_ = 0U;
PDFWriter* _tmp347_ = NULL;
- const gchar* _tmp348_ = NULL;
- gint _tmp349_ = 0;
- gint _tmp350_ = 0;
- gchar* _tmp351_ = NULL;
- gchar* _tmp352_ = NULL;
- PDFWriter* _tmp353_ = NULL;
- PDFWriter* _tmp354_ = NULL;
- PDFWriter* _tmp355_ = NULL;
- const gchar* _tmp356_ = NULL;
- PDFWriter* _tmp357_ = NULL;
+ guint _tmp348_ = 0U;
+ gchar* _tmp349_ = NULL;
+ gchar* _tmp350_ = NULL;
+ PDFWriter* _tmp351_ = NULL;
+ PDFWriter* _tmp352_ = NULL;
+ const gchar* _tmp353_ = NULL;
+ gint _tmp354_ = 0;
+ gint _tmp355_ = 0;
+ gchar* _tmp356_ = NULL;
+ gchar* _tmp357_ = NULL;
PDFWriter* _tmp358_ = NULL;
PDFWriter* _tmp359_ = NULL;
- gint _tmp360_ = 0;
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp49_ = _tmp48_;
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!_tmp49_) {
-#line 2133 "book.c"
- gint _tmp50_ = 0;
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp50_ = i;
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- i = _tmp50_ + 1;
-#line 2139 "book.c"
+ PDFWriter* _tmp360_ = NULL;
+ const gchar* _tmp361_ = NULL;
+ PDFWriter* _tmp362_ = NULL;
+ PDFWriter* _tmp363_ = NULL;
+ PDFWriter* _tmp364_ = NULL;
+ gint _tmp365_ = 0;
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp56_) {
+#line 2498 "book.c"
+ gint _tmp57_ = 0;
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp57_ = i;
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ i = _tmp57_ + 1;
+#line 2504 "book.c"
}
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp48_ = FALSE;
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp51_ = i;
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp52_ = book_get_n_pages (self);
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp53_ = _tmp52_;
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!(((guint) _tmp51_) < _tmp53_)) {
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp56_ = FALSE;
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp58_ = i;
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp59_ = book_get_n_pages (self);
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp60_ = _tmp59_;
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(((guint) _tmp58_) < _tmp60_)) {
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 2153 "book.c"
+#line 2518 "book.c"
}
-#line 265 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp54_ = i;
-#line 265 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp55_ = book_get_page (self, _tmp54_);
-#line 265 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- page = _tmp55_;
-#line 266 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp56_ = page;
-#line 266 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp57_ = page_get_image (_tmp56_, TRUE);
-#line 266 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- image = _tmp57_;
-#line 267 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp58_ = image;
-#line 267 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp59_ = gdk_pixbuf_get_width (_tmp58_);
-#line 267 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- width = _tmp59_;
-#line 268 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp60_ = image;
-#line 268 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp61_ = gdk_pixbuf_get_height (_tmp60_);
-#line 268 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- height = _tmp61_;
-#line 269 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp62_ = image;
-#line 269 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp63_ = gdk_pixbuf_get_pixels (_tmp62_);
-#line 269 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pixels = _tmp63_;
-#line 269 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 315 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp61_ = i;
+#line 315 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp62_ = book_get_page (self, _tmp61_);
+#line 315 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ page = _tmp62_;
+#line 316 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp63_ = page;
+#line 316 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp64_ = page_get_image (_tmp63_, TRUE);
+#line 316 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ image = _tmp64_;
+#line 317 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp65_ = image;
+#line 317 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp66_ = gdk_pixbuf_get_width (_tmp65_);
+#line 317 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp67_ = _tmp66_;
+#line 317 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ width = _tmp67_;
+#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp68_ = image;
+#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp69_ = gdk_pixbuf_get_height (_tmp68_);
+#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp70_ = _tmp69_;
+#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ height = _tmp70_;
+#line 319 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp71_ = image;
+#line 319 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp72_ = gdk_pixbuf_get_pixels (_tmp71_);
+#line 319 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pixels = _tmp72_;
+#line 319 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
pixels_length1 = -1;
-#line 269 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 319 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_pixels_size_ = pixels_length1;
-#line 270 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp64_ = width;
-#line 270 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp65_ = page;
-#line 270 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp66_ = page_get_dpi (_tmp65_);
-#line 270 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp67_ = _tmp66_;
-#line 270 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- page_width = (_tmp64_ * 72.0) / _tmp67_;
-#line 271 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp68_ = height;
-#line 271 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp69_ = page;
-#line 271 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp70_ = page_get_dpi (_tmp69_);
-#line 271 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp71_ = _tmp70_;
-#line 271 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- page_height = (_tmp68_ * 72.0) / _tmp71_;
-#line 273 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 320 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp73_ = width;
+#line 320 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp74_ = page;
+#line 320 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp75_ = page_get_dpi (_tmp74_);
+#line 320 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp76_ = _tmp75_;
+#line 320 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ page_width = (_tmp73_ * 72.0) / _tmp76_;
+#line 321 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp77_ = height;
+#line 321 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp78_ = page;
+#line 321 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp79_ = page_get_dpi (_tmp78_);
+#line 321 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp80_ = _tmp79_;
+#line 321 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ page_height = (_tmp77_ * 72.0) / _tmp80_;
+#line 323 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
depth = 8;
-#line 274 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp72_ = g_strdup ("DeviceRGB");
-#line 274 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- color_space = _tmp72_;
-#line 275 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 324 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp81_ = g_strdup ("DeviceRGB");
+#line 324 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ color_space = _tmp81_;
+#line 325 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
filter = NULL;
-#line 276 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp73_ = g_new0 (gchar, G_ASCII_DTOSTR_BUF_SIZE);
-#line 276 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- width_buffer = _tmp73_;
-#line 276 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp82_ = g_new0 (gchar, G_ASCII_DTOSTR_BUF_SIZE);
+#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ width_buffer = _tmp82_;
+#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
width_buffer_length1 = G_ASCII_DTOSTR_BUF_SIZE;
-#line 276 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_width_buffer_size_ = width_buffer_length1;
-#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp74_ = g_new0 (gchar, G_ASCII_DTOSTR_BUF_SIZE);
-#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- height_buffer = _tmp74_;
-#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 327 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp83_ = g_new0 (gchar, G_ASCII_DTOSTR_BUF_SIZE);
+#line 327 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ height_buffer = _tmp83_;
+#line 327 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
height_buffer_length1 = G_ASCII_DTOSTR_BUF_SIZE;
-#line 277 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 327 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_height_buffer_size_ = height_buffer_length1;
-#line 279 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp75_ = page;
-#line 279 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp76_ = page_get_is_color (_tmp75_);
-#line 279 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp77_ = _tmp76_;
-#line 279 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp77_) {
-#line 2241 "book.c"
- gchar* _tmp78_ = NULL;
+#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp84_ = page;
+#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp85_ = page_get_is_color (_tmp84_);
+#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp86_ = _tmp85_;
+#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (_tmp86_) {
+#line 2610 "book.c"
+ gchar* _tmp87_ = NULL;
gint data_length = 0;
- gint _tmp79_ = 0;
- gint _tmp80_ = 0;
- gint _tmp81_ = 0;
- guint8* _tmp82_ = NULL;
-#line 281 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ gint _tmp88_ = 0;
+ gint _tmp89_ = 0;
+ gint _tmp90_ = 0;
+ guint8* _tmp91_ = NULL;
+#line 331 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
depth = 8;
-#line 282 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp78_ = g_strdup ("DeviceRGB");
-#line 282 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 332 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp87_ = g_strdup ("DeviceRGB");
+#line 332 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (color_space);
-#line 282 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- color_space = _tmp78_;
-#line 283 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp79_ = height;
-#line 283 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp80_ = width;
-#line 283 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data_length = (_tmp79_ * _tmp80_) * 3;
-#line 284 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp81_ = data_length;
-#line 284 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp82_ = g_new0 (guint8, _tmp81_);
-#line 284 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 332 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ color_space = _tmp87_;
+#line 333 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp88_ = height;
+#line 333 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp89_ = width;
+#line 333 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data_length = (_tmp88_ * _tmp89_) * 3;
+#line 334 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp90_ = data_length;
+#line 334 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp91_ = g_new0 (guint8, _tmp90_);
+#line 334 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
data = (g_free (data), NULL);
-#line 284 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data = _tmp82_;
-#line 284 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data_length1 = _tmp81_;
-#line 284 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 334 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data = _tmp91_;
+#line 334 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data_length1 = _tmp90_;
+#line 334 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_data_size_ = data_length1;
-#line 2274 "book.c"
+#line 2643 "book.c"
{
gint row = 0;
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
row = 0;
-#line 2279 "book.c"
+#line 2648 "book.c"
{
- gboolean _tmp83_ = FALSE;
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp83_ = TRUE;
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ gboolean _tmp92_ = FALSE;
+#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp92_ = TRUE;
+#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
while (TRUE) {
-#line 2286 "book.c"
- gboolean _tmp84_ = FALSE;
- gint _tmp86_ = 0;
- gint _tmp87_ = 0;
+#line 2655 "book.c"
+ gint _tmp94_ = 0;
+ gint _tmp95_ = 0;
gint in_offset = 0;
- gint _tmp88_ = 0;
- GdkPixbuf* _tmp89_ = NULL;
- gint _tmp90_ = 0;
+ gint _tmp96_ = 0;
+ GdkPixbuf* _tmp97_ = NULL;
+ gint _tmp98_ = 0;
+ gint _tmp99_ = 0;
gint out_offset = 0;
- gint _tmp91_ = 0;
- gint _tmp92_ = 0;
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp84_ = _tmp83_;
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!_tmp84_) {
-#line 2301 "book.c"
- gint _tmp85_ = 0;
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp85_ = row;
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- row = _tmp85_ + 1;
-#line 2307 "book.c"
+ gint _tmp100_ = 0;
+ gint _tmp101_ = 0;
+#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp92_) {
+#line 2668 "book.c"
+ gint _tmp93_ = 0;
+#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp93_ = row;
+#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ row = _tmp93_ + 1;
+#line 2674 "book.c"
}
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp83_ = FALSE;
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp86_ = row;
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp87_ = height;
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!(_tmp86_ < _tmp87_)) {
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp92_ = FALSE;
+#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp94_ = row;
+#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp95_ = height;
+#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(_tmp94_ < _tmp95_)) {
+#line 335 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 2319 "book.c"
+#line 2686 "book.c"
}
-#line 287 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp88_ = row;
-#line 287 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp89_ = image;
-#line 287 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp90_ = gdk_pixbuf_get_rowstride (_tmp89_);
-#line 287 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- in_offset = _tmp88_ * _tmp90_;
-#line 288 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp91_ = row;
-#line 288 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp92_ = width;
-#line 288 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- out_offset = (_tmp91_ * _tmp92_) * 3;
-#line 2335 "book.c"
+#line 337 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp96_ = row;
+#line 337 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp97_ = image;
+#line 337 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp98_ = gdk_pixbuf_get_rowstride (_tmp97_);
+#line 337 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp99_ = _tmp98_;
+#line 337 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ in_offset = _tmp96_ * _tmp99_;
+#line 338 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp100_ = row;
+#line 338 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp101_ = width;
+#line 338 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ out_offset = (_tmp100_ * _tmp101_) * 3;
+#line 2704 "book.c"
{
gint x = 0;
-#line 289 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
x = 0;
-#line 2340 "book.c"
+#line 2709 "book.c"
{
- gboolean _tmp93_ = FALSE;
-#line 289 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp93_ = TRUE;
-#line 289 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ gboolean _tmp102_ = FALSE;
+#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp102_ = TRUE;
+#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
while (TRUE) {
-#line 2347 "book.c"
- gboolean _tmp94_ = FALSE;
- gint _tmp96_ = 0;
- gint _tmp97_ = 0;
+#line 2716 "book.c"
+ gint _tmp104_ = 0;
+ gint _tmp105_ = 0;
gint in_o = 0;
- gint _tmp98_ = 0;
- gint _tmp99_ = 0;
+ gint _tmp106_ = 0;
+ gint _tmp107_ = 0;
gint out_o = 0;
- gint _tmp100_ = 0;
- gint _tmp101_ = 0;
- guint8* _tmp102_ = NULL;
- gint _tmp102__length1 = 0;
- gint _tmp103_ = 0;
- guint8* _tmp104_ = NULL;
- gint _tmp104__length1 = 0;
- gint _tmp105_ = 0;
- guint8 _tmp106_ = 0U;
- guint8 _tmp107_ = 0U;
- guint8* _tmp108_ = NULL;
- gint _tmp108__length1 = 0;
+ gint _tmp108_ = 0;
gint _tmp109_ = 0;
guint8* _tmp110_ = NULL;
gint _tmp110__length1 = 0;
gint _tmp111_ = 0;
- guint8 _tmp112_ = 0U;
- guint8 _tmp113_ = 0U;
- guint8* _tmp114_ = NULL;
- gint _tmp114__length1 = 0;
- gint _tmp115_ = 0;
+ guint8* _tmp112_ = NULL;
+ gint _tmp112__length1 = 0;
+ gint _tmp113_ = 0;
+ guint8 _tmp114_ = 0U;
+ guint8 _tmp115_ = 0U;
guint8* _tmp116_ = NULL;
gint _tmp116__length1 = 0;
gint _tmp117_ = 0;
- guint8 _tmp118_ = 0U;
- guint8 _tmp119_ = 0U;
-#line 289 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp94_ = _tmp93_;
-#line 289 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!_tmp94_) {
-#line 2385 "book.c"
- gint _tmp95_ = 0;
-#line 289 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp95_ = x;
-#line 289 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- x = _tmp95_ + 1;
-#line 2391 "book.c"
+ guint8* _tmp118_ = NULL;
+ gint _tmp118__length1 = 0;
+ gint _tmp119_ = 0;
+ guint8 _tmp120_ = 0U;
+ guint8 _tmp121_ = 0U;
+ guint8* _tmp122_ = NULL;
+ gint _tmp122__length1 = 0;
+ gint _tmp123_ = 0;
+ guint8* _tmp124_ = NULL;
+ gint _tmp124__length1 = 0;
+ gint _tmp125_ = 0;
+ guint8 _tmp126_ = 0U;
+ guint8 _tmp127_ = 0U;
+#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp102_) {
+#line 2751 "book.c"
+ gint _tmp103_ = 0;
+#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp103_ = x;
+#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ x = _tmp103_ + 1;
+#line 2757 "book.c"
}
-#line 289 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp93_ = FALSE;
-#line 289 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp96_ = x;
-#line 289 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp97_ = width;
-#line 289 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!(_tmp96_ < _tmp97_)) {
-#line 289 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp102_ = FALSE;
+#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp104_ = x;
+#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp105_ = width;
+#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(_tmp104_ < _tmp105_)) {
+#line 339 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 2403 "book.c"
+#line 2769 "book.c"
}
-#line 291 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp98_ = in_offset;
-#line 291 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp99_ = x;
-#line 291 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- in_o = _tmp98_ + (_tmp99_ * 3);
-#line 292 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp100_ = out_offset;
-#line 292 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp101_ = x;
-#line 292 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- out_o = _tmp100_ + (_tmp101_ * 3);
-#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp102_ = data;
-#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp102__length1 = data_length1;
-#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp103_ = out_o;
-#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp104_ = pixels;
-#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp104__length1 = pixels_length1;
-#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp105_ = in_o;
-#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp106_ = _tmp104_[_tmp105_];
-#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp102_[_tmp103_] = _tmp106_;
-#line 294 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp107_ = _tmp102_[_tmp103_];
-#line 295 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp108_ = data;
-#line 295 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp108__length1 = data_length1;
-#line 295 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp109_ = out_o;
-#line 295 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp110_ = pixels;
-#line 295 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp110__length1 = pixels_length1;
-#line 295 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp111_ = in_o;
-#line 295 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp112_ = _tmp110_[_tmp111_ + 1];
-#line 295 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp108_[_tmp109_ + 1] = _tmp112_;
-#line 295 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp113_ = _tmp108_[_tmp109_ + 1];
-#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp114_ = data;
-#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp114__length1 = data_length1;
-#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp115_ = out_o;
-#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp116_ = pixels;
-#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp116__length1 = pixels_length1;
-#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp117_ = in_o;
-#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp118_ = _tmp116_[_tmp117_ + 2];
-#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp114_[_tmp115_ + 2] = _tmp118_;
-#line 296 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp119_ = _tmp114_[_tmp115_ + 2];
-#line 2471 "book.c"
+#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp106_ = in_offset;
+#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp107_ = x;
+#line 341 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ in_o = _tmp106_ + (_tmp107_ * 3);
+#line 342 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp108_ = out_offset;
+#line 342 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp109_ = x;
+#line 342 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ out_o = _tmp108_ + (_tmp109_ * 3);
+#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp110_ = data;
+#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp110__length1 = data_length1;
+#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp111_ = out_o;
+#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp112_ = pixels;
+#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp112__length1 = pixels_length1;
+#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp113_ = in_o;
+#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp114_ = _tmp112_[_tmp113_];
+#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp110_[_tmp111_] = _tmp114_;
+#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp115_ = _tmp110_[_tmp111_];
+#line 345 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp116_ = data;
+#line 345 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp116__length1 = data_length1;
+#line 345 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp117_ = out_o;
+#line 345 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp118_ = pixels;
+#line 345 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp118__length1 = pixels_length1;
+#line 345 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp119_ = in_o;
+#line 345 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp120_ = _tmp118_[_tmp119_ + 1];
+#line 345 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp116_[_tmp117_ + 1] = _tmp120_;
+#line 345 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp121_ = _tmp116_[_tmp117_ + 1];
+#line 346 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp122_ = data;
+#line 346 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp122__length1 = data_length1;
+#line 346 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp123_ = out_o;
+#line 346 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp124_ = pixels;
+#line 346 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp124__length1 = pixels_length1;
+#line 346 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp125_ = in_o;
+#line 346 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp126_ = _tmp124_[_tmp125_ + 2];
+#line 346 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp122_[_tmp123_ + 2] = _tmp126_;
+#line 346 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp127_ = _tmp122_[_tmp123_ + 2];
+#line 2837 "book.c"
}
}
}
@@ -2475,301 +2841,298 @@ static void book_save_pdf (Book* self, GFile* file, gint quality, GError** error
}
}
} else {
- Page* _tmp120_ = NULL;
- gint _tmp121_ = 0;
- gint _tmp122_ = 0;
-#line 300 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp120_ = page;
-#line 300 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp121_ = page_get_depth (_tmp120_);
-#line 300 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp122_ = _tmp121_;
-#line 300 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp122_ == 2) {
-#line 2490 "book.c"
+ Page* _tmp128_ = NULL;
+ gint _tmp129_ = 0;
+ gint _tmp130_ = 0;
+#line 350 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp128_ = page;
+#line 350 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp129_ = page_get_depth (_tmp128_);
+#line 350 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp130_ = _tmp129_;
+#line 350 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (_tmp130_ == 2) {
+#line 2856 "book.c"
gint shift_count = 0;
- gchar* _tmp123_ = NULL;
+ gchar* _tmp131_ = NULL;
gint data_length = 0;
- gint _tmp124_ = 0;
- gint _tmp125_ = 0;
- gint _tmp126_ = 0;
- guint8* _tmp127_ = NULL;
+ gint _tmp132_ = 0;
+ gint _tmp133_ = 0;
+ gint _tmp134_ = 0;
+ guint8* _tmp135_ = NULL;
gint offset = 0;
-#line 302 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 352 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
shift_count = 6;
-#line 303 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
depth = 2;
-#line 304 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp123_ = g_strdup ("DeviceGray");
-#line 304 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 354 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp131_ = g_strdup ("DeviceGray");
+#line 354 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (color_space);
-#line 304 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- color_space = _tmp123_;
-#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp124_ = height;
-#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp125_ = width;
-#line 305 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data_length = _tmp124_ * (((_tmp125_ * 2) + 7) / 8);
-#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp126_ = data_length;
-#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp127_ = g_new0 (guint8, _tmp126_);
-#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 354 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ color_space = _tmp131_;
+#line 355 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp132_ = height;
+#line 355 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp133_ = width;
+#line 355 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data_length = _tmp132_ * (((_tmp133_ * 2) + 7) / 8);
+#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp134_ = data_length;
+#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp135_ = g_new0 (guint8, _tmp134_);
+#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
data = (g_free (data), NULL);
-#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data = _tmp127_;
-#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data_length1 = _tmp126_;
-#line 306 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data = _tmp135_;
+#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data_length1 = _tmp134_;
+#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_data_size_ = data_length1;
-#line 307 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 357 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
offset = 0;
-#line 2529 "book.c"
+#line 2895 "book.c"
{
gint row = 0;
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
row = 0;
-#line 2534 "book.c"
+#line 2900 "book.c"
{
- gboolean _tmp128_ = FALSE;
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp128_ = TRUE;
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ gboolean _tmp136_ = FALSE;
+#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp136_ = TRUE;
+#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
while (TRUE) {
-#line 2541 "book.c"
- gboolean _tmp129_ = FALSE;
- gint _tmp131_ = 0;
- gint _tmp132_ = 0;
- gint _tmp133_ = 0;
+#line 2907 "book.c"
+ gint _tmp138_ = 0;
+ gint _tmp139_ = 0;
+ gint _tmp140_ = 0;
gint in_offset = 0;
- gint _tmp135_ = 0;
- GdkPixbuf* _tmp136_ = NULL;
- gint _tmp137_ = 0;
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp129_ = _tmp128_;
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!_tmp129_) {
-#line 2554 "book.c"
- gint _tmp130_ = 0;
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp130_ = row;
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- row = _tmp130_ + 1;
-#line 2560 "book.c"
+ gint _tmp142_ = 0;
+ GdkPixbuf* _tmp143_ = NULL;
+ gint _tmp144_ = 0;
+ gint _tmp145_ = 0;
+#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp136_) {
+#line 2918 "book.c"
+ gint _tmp137_ = 0;
+#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp137_ = row;
+#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ row = _tmp137_ + 1;
+#line 2924 "book.c"
}
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp128_ = FALSE;
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp131_ = row;
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp132_ = height;
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!(_tmp131_ < _tmp132_)) {
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp136_ = FALSE;
+#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp138_ = row;
+#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp139_ = height;
+#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(_tmp138_ < _tmp139_)) {
+#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 2572 "book.c"
+#line 2936 "book.c"
}
-#line 311 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp133_ = shift_count;
-#line 311 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp133_ != 6) {
-#line 2578 "book.c"
- gint _tmp134_ = 0;
-#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp134_ = offset;
-#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- offset = _tmp134_ + 1;
-#line 314 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 361 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp140_ = shift_count;
+#line 361 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (_tmp140_ != 6) {
+#line 2942 "book.c"
+ gint _tmp141_ = 0;
+#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp141_ = offset;
+#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ offset = _tmp141_ + 1;
+#line 364 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
shift_count = 6;
-#line 2586 "book.c"
+#line 2950 "book.c"
}
-#line 317 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp135_ = row;
-#line 317 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp136_ = image;
-#line 317 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp137_ = gdk_pixbuf_get_rowstride (_tmp136_);
-#line 317 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- in_offset = _tmp135_ * _tmp137_;
-#line 2596 "book.c"
+#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp142_ = row;
+#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp143_ = image;
+#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp144_ = gdk_pixbuf_get_rowstride (_tmp143_);
+#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp145_ = _tmp144_;
+#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ in_offset = _tmp142_ * _tmp145_;
+#line 2962 "book.c"
{
gint x = 0;
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
x = 0;
-#line 2601 "book.c"
+#line 2967 "book.c"
{
- gboolean _tmp138_ = FALSE;
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp138_ = TRUE;
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ gboolean _tmp146_ = FALSE;
+#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp146_ = TRUE;
+#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
while (TRUE) {
-#line 2608 "book.c"
- gboolean _tmp139_ = FALSE;
- gint _tmp141_ = 0;
- gint _tmp142_ = 0;
- gint _tmp143_ = 0;
- guint8 p = 0U;
- guint8* _tmp147_ = NULL;
- gint _tmp147__length1 = 0;
+#line 2974 "book.c"
gint _tmp148_ = 0;
gint _tmp149_ = 0;
- guint8 _tmp150_ = 0U;
- guint8 _tmp151_ = 0U;
- gint _tmp166_ = 0;
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp139_ = _tmp138_;
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!_tmp139_) {
-#line 2625 "book.c"
- gint _tmp140_ = 0;
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp140_ = x;
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- x = _tmp140_ + 1;
-#line 2631 "book.c"
+ gint _tmp150_ = 0;
+ guint8 p = 0U;
+ guint8* _tmp154_ = NULL;
+ gint _tmp154__length1 = 0;
+ gint _tmp155_ = 0;
+ gint _tmp156_ = 0;
+ guint8 _tmp157_ = 0U;
+ guint8 _tmp158_ = 0U;
+ gint _tmp173_ = 0;
+#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp146_) {
+#line 2988 "book.c"
+ gint _tmp147_ = 0;
+#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp147_ = x;
+#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ x = _tmp147_ + 1;
+#line 2994 "book.c"
}
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp138_ = FALSE;
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp141_ = x;
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp142_ = width;
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!(_tmp141_ < _tmp142_)) {
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp146_ = FALSE;
+#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp148_ = x;
+#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp149_ = width;
+#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(_tmp148_ < _tmp149_)) {
+#line 368 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 2643 "book.c"
+#line 3006 "book.c"
}
-#line 321 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp143_ = shift_count;
-#line 321 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp143_ == 6) {
-#line 2649 "book.c"
- guint8* _tmp144_ = NULL;
- gint _tmp144__length1 = 0;
- gint _tmp145_ = 0;
- guint8 _tmp146_ = 0U;
-#line 322 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp144_ = data;
-#line 322 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp144__length1 = data_length1;
-#line 322 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp145_ = offset;
-#line 322 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp144_[_tmp145_] = (guint8) 0;
-#line 322 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp146_ = _tmp144_[_tmp145_];
-#line 2664 "book.c"
+#line 371 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp150_ = shift_count;
+#line 371 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (_tmp150_ == 6) {
+#line 3012 "book.c"
+ guint8* _tmp151_ = NULL;
+ gint _tmp151__length1 = 0;
+ gint _tmp152_ = 0;
+ guint8 _tmp153_ = 0U;
+#line 372 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp151_ = data;
+#line 372 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp151__length1 = data_length1;
+#line 372 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp152_ = offset;
+#line 372 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp151_[_tmp152_] = (guint8) 0;
+#line 372 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp153_ = _tmp151_[_tmp152_];
+#line 3027 "book.c"
}
-#line 325 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp147_ = pixels;
-#line 325 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp147__length1 = pixels_length1;
-#line 325 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp148_ = in_offset;
-#line 325 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp149_ = x;
-#line 325 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp150_ = _tmp147_[_tmp148_ + (_tmp149_ * 3)];
-#line 325 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- p = _tmp150_;
-#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp151_ = p;
-#line 326 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (((gint) _tmp151_) >= 192) {
-#line 2682 "book.c"
- guint8* _tmp152_ = NULL;
- gint _tmp152__length1 = 0;
- gint _tmp153_ = 0;
- gint _tmp154_ = 0;
- guint8 _tmp155_ = 0U;
-#line 327 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp152_ = data;
-#line 327 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp152__length1 = data_length1;
-#line 327 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp153_ = offset;
-#line 327 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp154_ = shift_count;
-#line 327 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp152_[_tmp153_] |= (guint8) (3 << _tmp154_);
-#line 327 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp155_ = _tmp152_[_tmp153_];
-#line 2700 "book.c"
+#line 375 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp154_ = pixels;
+#line 375 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp154__length1 = pixels_length1;
+#line 375 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp155_ = in_offset;
+#line 375 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp156_ = x;
+#line 375 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp157_ = _tmp154_[_tmp155_ + (_tmp156_ * 3)];
+#line 375 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ p = _tmp157_;
+#line 376 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp158_ = p;
+#line 376 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (((gint) _tmp158_) >= 192) {
+#line 3045 "book.c"
+ guint8* _tmp159_ = NULL;
+ gint _tmp159__length1 = 0;
+ gint _tmp160_ = 0;
+ gint _tmp161_ = 0;
+ guint8 _tmp162_ = 0U;
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp159_ = data;
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp159__length1 = data_length1;
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp160_ = offset;
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp161_ = shift_count;
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp159_[_tmp160_] |= (guint8) (3 << _tmp161_);
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp162_ = _tmp159_[_tmp160_];
+#line 3063 "book.c"
} else {
- guint8 _tmp156_ = 0U;
-#line 328 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp156_ = p;
-#line 328 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (((gint) _tmp156_) >= 128) {
-#line 2707 "book.c"
- guint8* _tmp157_ = NULL;
- gint _tmp157__length1 = 0;
- gint _tmp158_ = 0;
- gint _tmp159_ = 0;
- guint8 _tmp160_ = 0U;
-#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp157_ = data;
-#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp157__length1 = data_length1;
-#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp158_ = offset;
-#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp159_ = shift_count;
-#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp157_[_tmp158_] |= (guint8) (2 << _tmp159_);
-#line 329 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp160_ = _tmp157_[_tmp158_];
-#line 2725 "book.c"
+ guint8 _tmp163_ = 0U;
+#line 378 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp163_ = p;
+#line 378 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (((gint) _tmp163_) >= 128) {
+#line 3070 "book.c"
+ guint8* _tmp164_ = NULL;
+ gint _tmp164__length1 = 0;
+ gint _tmp165_ = 0;
+ gint _tmp166_ = 0;
+ guint8 _tmp167_ = 0U;
+#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp164_ = data;
+#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp164__length1 = data_length1;
+#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp165_ = offset;
+#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp166_ = shift_count;
+#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp164_[_tmp165_] |= (guint8) (2 << _tmp166_);
+#line 379 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp167_ = _tmp164_[_tmp165_];
+#line 3088 "book.c"
} else {
- guint8 _tmp161_ = 0U;
-#line 330 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp161_ = p;
-#line 330 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (((gint) _tmp161_) >= 64) {
-#line 2732 "book.c"
- guint8* _tmp162_ = NULL;
- gint _tmp162__length1 = 0;
- gint _tmp163_ = 0;
- gint _tmp164_ = 0;
- guint8 _tmp165_ = 0U;
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp162_ = data;
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp162__length1 = data_length1;
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp163_ = offset;
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp164_ = shift_count;
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp162_[_tmp163_] |= (guint8) (1 << _tmp164_);
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp165_ = _tmp162_[_tmp163_];
-#line 2750 "book.c"
+ guint8 _tmp168_ = 0U;
+#line 380 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp168_ = p;
+#line 380 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (((gint) _tmp168_) >= 64) {
+#line 3095 "book.c"
+ guint8* _tmp169_ = NULL;
+ gint _tmp169__length1 = 0;
+ gint _tmp170_ = 0;
+ gint _tmp171_ = 0;
+ guint8 _tmp172_ = 0U;
+#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp169_ = data;
+#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp169__length1 = data_length1;
+#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp170_ = offset;
+#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp171_ = shift_count;
+#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp169_[_tmp170_] |= (guint8) (1 << _tmp171_);
+#line 381 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp172_ = _tmp169_[_tmp170_];
+#line 3113 "book.c"
}
}
}
-#line 334 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp166_ = shift_count;
-#line 334 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp166_ == 0) {
-#line 2758 "book.c"
- gint _tmp167_ = 0;
-#line 336 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp167_ = offset;
-#line 336 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- offset = _tmp167_ + 1;
-#line 337 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 384 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp173_ = shift_count;
+#line 384 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (_tmp173_ == 0) {
+#line 3121 "book.c"
+ gint _tmp174_ = 0;
+#line 386 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp174_ = offset;
+#line 386 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ offset = _tmp174_ + 1;
+#line 387 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
shift_count = 6;
-#line 2766 "book.c"
+#line 3129 "book.c"
} else {
- gint _tmp168_ = 0;
-#line 340 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp168_ = shift_count;
-#line 340 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- shift_count = _tmp168_ - 2;
-#line 2773 "book.c"
+ gint _tmp175_ = 0;
+#line 390 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp175_ = shift_count;
+#line 390 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ shift_count = _tmp175_ - 2;
+#line 3136 "book.c"
}
}
}
@@ -2778,241 +3141,238 @@ static void book_save_pdf (Book* self, GFile* file, gint quality, GError** error
}
}
} else {
- Page* _tmp169_ = NULL;
- gint _tmp170_ = 0;
- gint _tmp171_ = 0;
-#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp169_ = page;
-#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp170_ = page_get_depth (_tmp169_);
-#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp171_ = _tmp170_;
-#line 344 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp171_ == 1) {
-#line 2793 "book.c"
+ Page* _tmp176_ = NULL;
+ gint _tmp177_ = 0;
+ gint _tmp178_ = 0;
+#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp176_ = page;
+#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp177_ = page_get_depth (_tmp176_);
+#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp178_ = _tmp177_;
+#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (_tmp178_ == 1) {
+#line 3156 "book.c"
gint mask = 0;
- gchar* _tmp172_ = NULL;
+ gchar* _tmp179_ = NULL;
gint data_length = 0;
- gint _tmp173_ = 0;
- gint _tmp174_ = 0;
- gint _tmp175_ = 0;
- guint8* _tmp176_ = NULL;
+ gint _tmp180_ = 0;
+ gint _tmp181_ = 0;
+ gint _tmp182_ = 0;
+ guint8* _tmp183_ = NULL;
gint offset = 0;
-#line 346 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 396 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
mask = 0x80;
-#line 348 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 398 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
depth = 1;
-#line 349 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp172_ = g_strdup ("DeviceGray");
-#line 349 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 399 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp179_ = g_strdup ("DeviceGray");
+#line 399 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (color_space);
-#line 349 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- color_space = _tmp172_;
-#line 350 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp173_ = height;
-#line 350 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp174_ = width;
-#line 350 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data_length = _tmp173_ * ((_tmp174_ + 7) / 8);
-#line 351 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp175_ = data_length;
-#line 351 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp176_ = g_new0 (guint8, _tmp175_);
-#line 351 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 399 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ color_space = _tmp179_;
+#line 400 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp180_ = height;
+#line 400 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp181_ = width;
+#line 400 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data_length = _tmp180_ * ((_tmp181_ + 7) / 8);
+#line 401 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp182_ = data_length;
+#line 401 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp183_ = g_new0 (guint8, _tmp182_);
+#line 401 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
data = (g_free (data), NULL);
-#line 351 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data = _tmp176_;
-#line 351 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data_length1 = _tmp175_;
-#line 351 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 401 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data = _tmp183_;
+#line 401 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data_length1 = _tmp182_;
+#line 401 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_data_size_ = data_length1;
-#line 352 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
offset = 0;
-#line 2832 "book.c"
+#line 3195 "book.c"
{
gint row = 0;
-#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
row = 0;
-#line 2837 "book.c"
+#line 3200 "book.c"
{
- gboolean _tmp177_ = FALSE;
-#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp177_ = TRUE;
-#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ gboolean _tmp184_ = FALSE;
+#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp184_ = TRUE;
+#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
while (TRUE) {
-#line 2844 "book.c"
- gboolean _tmp178_ = FALSE;
- gint _tmp180_ = 0;
- gint _tmp181_ = 0;
- gint _tmp182_ = 0;
- gint in_offset = 0;
- gint _tmp184_ = 0;
- GdkPixbuf* _tmp185_ = NULL;
+#line 3207 "book.c"
gint _tmp186_ = 0;
-#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp178_ = _tmp177_;
-#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!_tmp178_) {
-#line 2857 "book.c"
- gint _tmp179_ = 0;
-#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp179_ = row;
-#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- row = _tmp179_ + 1;
-#line 2863 "book.c"
+ gint _tmp187_ = 0;
+ gint _tmp188_ = 0;
+ gint in_offset = 0;
+ gint _tmp190_ = 0;
+ GdkPixbuf* _tmp191_ = NULL;
+ gint _tmp192_ = 0;
+ gint _tmp193_ = 0;
+#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp184_) {
+#line 3218 "book.c"
+ gint _tmp185_ = 0;
+#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp185_ = row;
+#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ row = _tmp185_ + 1;
+#line 3224 "book.c"
}
-#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp177_ = FALSE;
-#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp180_ = row;
-#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp181_ = height;
-#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!(_tmp180_ < _tmp181_)) {
-#line 353 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp184_ = FALSE;
+#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp186_ = row;
+#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp187_ = height;
+#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(_tmp186_ < _tmp187_)) {
+#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 2875 "book.c"
+#line 3236 "book.c"
}
-#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp182_ = mask;
-#line 356 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp182_ != 0x80) {
-#line 2881 "book.c"
- gint _tmp183_ = 0;
-#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp183_ = offset;
-#line 358 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- offset = _tmp183_ + 1;
-#line 359 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 406 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp188_ = mask;
+#line 406 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (_tmp188_ != 0x80) {
+#line 3242 "book.c"
+ gint _tmp189_ = 0;
+#line 408 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp189_ = offset;
+#line 408 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ offset = _tmp189_ + 1;
+#line 409 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
mask = 0x80;
-#line 2889 "book.c"
+#line 3250 "book.c"
}
-#line 362 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp184_ = row;
-#line 362 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp185_ = image;
-#line 362 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp186_ = gdk_pixbuf_get_rowstride (_tmp185_);
-#line 362 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- in_offset = _tmp184_ * _tmp186_;
-#line 2899 "book.c"
+#line 412 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp190_ = row;
+#line 412 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp191_ = image;
+#line 412 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp192_ = gdk_pixbuf_get_rowstride (_tmp191_);
+#line 412 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp193_ = _tmp192_;
+#line 412 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ in_offset = _tmp190_ * _tmp193_;
+#line 3262 "book.c"
{
gint x = 0;
-#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
x = 0;
-#line 2904 "book.c"
+#line 3267 "book.c"
{
- gboolean _tmp187_ = FALSE;
-#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp187_ = TRUE;
-#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ gboolean _tmp194_ = FALSE;
+#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp194_ = TRUE;
+#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
while (TRUE) {
-#line 2911 "book.c"
- gboolean _tmp188_ = FALSE;
- gint _tmp190_ = 0;
- gint _tmp191_ = 0;
- gint _tmp192_ = 0;
- guint8* _tmp196_ = NULL;
- gint _tmp196__length1 = 0;
+#line 3274 "book.c"
+ gint _tmp196_ = 0;
gint _tmp197_ = 0;
gint _tmp198_ = 0;
- guint8 _tmp199_ = 0U;
+ guint8* _tmp202_ = NULL;
+ gint _tmp202__length1 = 0;
+ gint _tmp203_ = 0;
gint _tmp204_ = 0;
- gint _tmp205_ = 0;
-#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp188_ = _tmp187_;
-#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!_tmp188_) {
-#line 2927 "book.c"
- gint _tmp189_ = 0;
-#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp189_ = x;
-#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- x = _tmp189_ + 1;
-#line 2933 "book.c"
+ guint8 _tmp205_ = 0U;
+ gint _tmp210_ = 0;
+ gint _tmp211_ = 0;
+#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp194_) {
+#line 3287 "book.c"
+ gint _tmp195_ = 0;
+#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp195_ = x;
+#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ x = _tmp195_ + 1;
+#line 3293 "book.c"
}
-#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp187_ = FALSE;
-#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp190_ = x;
-#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp191_ = width;
-#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!(_tmp190_ < _tmp191_)) {
-#line 363 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp194_ = FALSE;
+#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp196_ = x;
+#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp197_ = width;
+#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!(_tmp196_ < _tmp197_)) {
+#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 2945 "book.c"
+#line 3305 "book.c"
}
-#line 366 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp192_ = mask;
-#line 366 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp192_ == 0x80) {
-#line 2951 "book.c"
- guint8* _tmp193_ = NULL;
- gint _tmp193__length1 = 0;
- gint _tmp194_ = 0;
- guint8 _tmp195_ = 0U;
-#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp193_ = data;
-#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp193__length1 = data_length1;
-#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp194_ = offset;
-#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp193_[_tmp194_] = (guint8) 0;
-#line 367 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp195_ = _tmp193_[_tmp194_];
-#line 2966 "book.c"
+#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp198_ = mask;
+#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (_tmp198_ == 0x80) {
+#line 3311 "book.c"
+ guint8* _tmp199_ = NULL;
+ gint _tmp199__length1 = 0;
+ gint _tmp200_ = 0;
+ guint8 _tmp201_ = 0U;
+#line 417 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp199_ = data;
+#line 417 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp199__length1 = data_length1;
+#line 417 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp200_ = offset;
+#line 417 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp199_[_tmp200_] = (guint8) 0;
+#line 417 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp201_ = _tmp199_[_tmp200_];
+#line 3326 "book.c"
}
-#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp196_ = pixels;
-#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp196__length1 = pixels_length1;
-#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp197_ = in_offset;
-#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp198_ = x;
-#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp199_ = _tmp196_[_tmp197_ + (_tmp198_ * 3)];
-#line 370 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (((gint) _tmp199_) != 0) {
-#line 2980 "book.c"
- guint8* _tmp200_ = NULL;
- gint _tmp200__length1 = 0;
- gint _tmp201_ = 0;
- gint _tmp202_ = 0;
- guint8 _tmp203_ = 0U;
-#line 371 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp200_ = data;
-#line 371 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp200__length1 = data_length1;
-#line 371 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp201_ = offset;
-#line 371 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp202_ = mask;
-#line 371 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp200_[_tmp201_] |= (guint8) _tmp202_;
-#line 371 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp203_ = _tmp200_[_tmp201_];
-#line 2998 "book.c"
+#line 420 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp202_ = pixels;
+#line 420 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp202__length1 = pixels_length1;
+#line 420 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp203_ = in_offset;
+#line 420 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp204_ = x;
+#line 420 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp205_ = _tmp202_[_tmp203_ + (_tmp204_ * 3)];
+#line 420 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (((gint) _tmp205_) != 0) {
+#line 3340 "book.c"
+ guint8* _tmp206_ = NULL;
+ gint _tmp206__length1 = 0;
+ gint _tmp207_ = 0;
+ gint _tmp208_ = 0;
+ guint8 _tmp209_ = 0U;
+#line 421 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp206_ = data;
+#line 421 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp206__length1 = data_length1;
+#line 421 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp207_ = offset;
+#line 421 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp208_ = mask;
+#line 421 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp206_[_tmp207_] |= (guint8) _tmp208_;
+#line 421 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp209_ = _tmp206_[_tmp207_];
+#line 3358 "book.c"
}
-#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp204_ = mask;
-#line 374 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- mask = _tmp204_ >> 1;
-#line 375 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp205_ = mask;
-#line 375 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp205_ == 0) {
-#line 3008 "book.c"
- gint _tmp206_ = 0;
-#line 377 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp206_ = offset;
-#line 377 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- offset = _tmp206_ + 1;
-#line 378 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 424 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp210_ = mask;
+#line 424 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ mask = _tmp210_ >> 1;
+#line 425 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp211_ = mask;
+#line 425 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (_tmp211_ == 0) {
+#line 3368 "book.c"
+ gint _tmp212_ = 0;
+#line 427 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp212_ = offset;
+#line 427 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ offset = _tmp212_ + 1;
+#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
mask = 0x80;
-#line 3016 "book.c"
+#line 3376 "book.c"
}
}
}
@@ -3021,868 +3381,893 @@ static void book_save_pdf (Book* self, GFile* file, gint quality, GError** error
}
}
} else {
- gchar* _tmp207_ = NULL;
+ gchar* _tmp213_ = NULL;
gint data_length = 0;
- gint _tmp208_ = 0;
- gint _tmp209_ = 0;
- gint _tmp210_ = 0;
- guint8* _tmp211_ = NULL;
-#line 385 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ gint _tmp214_ = 0;
+ gint _tmp215_ = 0;
+ gint _tmp216_ = 0;
+ guint8* _tmp217_ = NULL;
+#line 435 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
depth = 8;
-#line 386 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp207_ = g_strdup ("DeviceGray");
-#line 386 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp213_ = g_strdup ("DeviceGray");
+#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_free0 (color_space);
-#line 386 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- color_space = _tmp207_;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp208_ = height;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp209_ = width;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data_length = _tmp208_ * _tmp209_;
-#line 388 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp210_ = data_length;
-#line 388 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp211_ = g_new0 (guint8, _tmp210_);
-#line 388 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ color_space = _tmp213_;
+#line 437 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp214_ = height;
+#line 437 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp215_ = width;
+#line 437 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data_length = _tmp214_ * _tmp215_;
+#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp216_ = data_length;
+#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp217_ = g_new0 (guint8, _tmp216_);
+#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
data = (g_free (data), NULL);
-#line 388 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data = _tmp211_;
-#line 388 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data_length1 = _tmp210_;
-#line 388 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data = _tmp217_;
+#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data_length1 = _tmp216_;
+#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_data_size_ = data_length1;
-#line 3057 "book.c"
+#line 3417 "book.c"
{
gint row = 0;
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 439 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
row = 0;
-#line 3062 "book.c"
+#line 3422 "book.c"
{
- gboolean _tmp212_ = FALSE;
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp212_ = TRUE;
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ gboolean _tmp218_ = FALSE;
+#line 439 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp218_ = TRUE;
+#line 439 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
while (TRUE) {
-#line 3069 "book.c"
- gboolean _tmp213_ = FALSE;
- gint _tmp215_ = 0;
- gint _tmp216_ = 0;
- gint in_offset = 0;
- gint _tmp217_ = 0;
- GdkPixbuf* _tmp218_ = NULL;
- gint _tmp219_ = 0;
- gint out_offset = 0;
+#line 3429 "book.c"
gint _tmp220_ = 0;
gint _tmp221_ = 0;
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp213_ = _tmp212_;
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!_tmp213_) {
-#line 3084 "book.c"
- gint _tmp214_ = 0;
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp214_ = row;
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- row = _tmp214_ + 1;
-#line 3090 "book.c"
- }
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp212_ = FALSE;
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp215_ = row;
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp216_ = height;
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!(_tmp215_ < _tmp216_)) {
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- break;
-#line 3102 "book.c"
+ gint in_offset = 0;
+ gint _tmp222_ = 0;
+ GdkPixbuf* _tmp223_ = NULL;
+ gint _tmp224_ = 0;
+ gint _tmp225_ = 0;
+ gint out_offset = 0;
+ gint _tmp226_ = 0;
+ gint _tmp227_ = 0;
+#line 439 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp218_) {
+#line 3442 "book.c"
+ gint _tmp219_ = 0;
+#line 439 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp219_ = row;
+#line 439 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ row = _tmp219_ + 1;
+#line 3448 "book.c"
}
-#line 391 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp217_ = row;
-#line 391 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp218_ = image;
-#line 391 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp219_ = gdk_pixbuf_get_rowstride (_tmp218_);
-#line 391 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- in_offset = _tmp217_ * _tmp219_;
-#line 392 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 439 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp218_ = FALSE;
+#line 439 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp220_ = row;
-#line 392 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp221_ = width;
-#line 392 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- out_offset = _tmp220_ * _tmp221_;
-#line 3118 "book.c"
- {
- gint x = 0;
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- x = 0;
-#line 3123 "book.c"
- {
- gboolean _tmp222_ = FALSE;
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp222_ = TRUE;
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- while (TRUE) {
-#line 3130 "book.c"
- gboolean _tmp223_ = FALSE;
- gint _tmp225_ = 0;
- gint _tmp226_ = 0;
- guint8* _tmp227_ = NULL;
- gint _tmp227__length1 = 0;
- gint _tmp228_ = 0;
- gint _tmp229_ = 0;
- guint8* _tmp230_ = NULL;
- gint _tmp230__length1 = 0;
- gint _tmp231_ = 0;
- gint _tmp232_ = 0;
- guint8 _tmp233_ = 0U;
- guint8 _tmp234_ = 0U;
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp223_ = _tmp222_;
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!_tmp223_) {
-#line 3148 "book.c"
- gint _tmp224_ = 0;
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp224_ = x;
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- x = _tmp224_ + 1;
-#line 3154 "book.c"
- }
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp222_ = FALSE;
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp225_ = x;
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp226_ = width;
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (!(_tmp225_ < _tmp226_)) {
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- break;
-#line 3166 "book.c"
- }
-#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp227_ = data;
-#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp227__length1 = data_length1;
-#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp228_ = out_offset;
-#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp229_ = x;
-#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp230_ = pixels;
-#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp230__length1 = pixels_length1;
-#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp231_ = in_offset;
-#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp232_ = x;
-#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp233_ = _tmp230_[_tmp231_ + (_tmp232_ * 3)];
-#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp227_[_tmp228_ + _tmp229_] = _tmp233_;
-#line 394 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp234_ = _tmp227_[_tmp228_ + _tmp229_];
-#line 3190 "book.c"
- }
- }
- }
- }
- }
- }
- }
- }
- }
-#line 399 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp235_ = data;
-#line 399 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp235__length1 = data_length1;
-#line 399 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp237_ = book_compress_zlib (self, _tmp235_, _tmp235__length1, &_tmp236_);
-#line 399 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- compressed_data = _tmp237_;
-#line 399 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- compressed_data_length1 = _tmp236_;
-#line 399 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _compressed_data_size_ = compressed_data_length1;
-#line 400 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp238_ = compressed_data;
-#line 400 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp238__length1 = compressed_data_length1;
-#line 400 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp238_ != NULL) {
-#line 3218 "book.c"
- gint _tmp239_ = 0;
- const gchar* _tmp252_ = NULL;
-#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp239_ = depth;
-#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp239_ > 1) {
-#line 3225 "book.c"
- guint8* jpeg_data = NULL;
- GdkPixbuf* _tmp240_ = NULL;
- gint _tmp241_ = 0;
- Page* _tmp242_ = NULL;
- gint _tmp243_ = 0;
- gint _tmp244_ = 0;
- gint _tmp245_ = 0;
- guint8* _tmp246_ = NULL;
- gint jpeg_data_length1 = 0;
- gint _jpeg_data_size_ = 0;
- guint8* _tmp247_ = NULL;
- gint _tmp247__length1 = 0;
- guint8* _tmp248_ = NULL;
- gint _tmp248__length1 = 0;
-#line 405 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp240_ = image;
-#line 405 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp241_ = quality;
-#line 405 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp242_ = page;
-#line 405 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp243_ = page_get_dpi (_tmp242_);
-#line 405 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp244_ = _tmp243_;
-#line 405 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp246_ = book_compress_jpeg (self, _tmp240_, _tmp241_, _tmp244_, &_tmp245_);
-#line 405 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- jpeg_data = _tmp246_;
-#line 405 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- jpeg_data_length1 = _tmp245_;
-#line 405 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _jpeg_data_size_ = jpeg_data_length1;
-#line 406 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp247_ = jpeg_data;
-#line 406 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp247__length1 = jpeg_data_length1;
-#line 406 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp248_ = compressed_data;
-#line 406 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp248__length1 = compressed_data_length1;
-#line 406 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp247__length1 < _tmp248__length1) {
-#line 3268 "book.c"
- gchar* _tmp249_ = NULL;
- guint8* _tmp250_ = NULL;
- gint _tmp250__length1 = 0;
- guint8* _tmp251_ = NULL;
- gint _tmp251__length1 = 0;
-#line 408 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp249_ = g_strdup ("DCTDecode");
-#line 408 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (filter);
-#line 408 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- filter = _tmp249_;
-#line 409 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp250_ = jpeg_data;
-#line 409 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp250__length1 = jpeg_data_length1;
-#line 409 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp251_ = (_tmp250_ != NULL) ? _vala_array_dup1 (_tmp250_, _tmp250__length1) : ((gpointer) _tmp250_);
-#line 409 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp251__length1 = _tmp250__length1;
-#line 409 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data = (g_free (data), NULL);
-#line 409 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data = _tmp251_;
-#line 409 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data_length1 = _tmp251__length1;
-#line 409 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _data_size_ = data_length1;
-#line 3296 "book.c"
- }
-#line 403 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- jpeg_data = (g_free (jpeg_data), NULL);
-#line 3300 "book.c"
- }
-#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp252_ = filter;
-#line 413 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp252_ == NULL) {
-#line 3306 "book.c"
- gchar* _tmp253_ = NULL;
- guint8* _tmp254_ = NULL;
- gint _tmp254__length1 = 0;
- guint8* _tmp255_ = NULL;
- gint _tmp255__length1 = 0;
-#line 415 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp253_ = g_strdup ("FlateDecode");
-#line 415 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (filter);
-#line 415 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- filter = _tmp253_;
-#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp254_ = compressed_data;
-#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp254__length1 = compressed_data_length1;
-#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp255_ = (_tmp254_ != NULL) ? _vala_array_dup2 (_tmp254_, _tmp254__length1) : ((gpointer) _tmp254_);
-#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp255__length1 = _tmp254__length1;
-#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data = (g_free (data), NULL);
-#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data = _tmp255_;
-#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data_length1 = _tmp255__length1;
-#line 416 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _data_size_ = data_length1;
-#line 3334 "book.c"
- }
- }
-#line 421 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp256_ = writer;
-#line 421 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp256_, "\n");
-#line 422 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp257_ = writer;
-#line 422 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp258_ = pdf_writer_start_object (_tmp257_);
-#line 422 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- number = _tmp258_;
-#line 423 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp259_ = writer;
-#line 423 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp260_ = number;
-#line 423 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp261_ = g_strdup_printf ("%u 0 obj\n", _tmp260_);
-#line 423 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp262_ = _tmp261_;
-#line 423 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp259_, _tmp262_);
-#line 423 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp262_);
-#line 424 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp263_ = writer;
-#line 424 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp263_, "<<\n");
-#line 425 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp264_ = writer;
-#line 425 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp264_, "/Type /Page\n");
-#line 426 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp265_ = writer;
-#line 426 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp266_ = pages_number;
-#line 426 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp267_ = g_strdup_printf ("/Parent %u 0 R\n", _tmp266_);
-#line 426 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp268_ = _tmp267_;
-#line 426 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp265_, _tmp268_);
-#line 426 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp268_);
-#line 427 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp269_ = writer;
-#line 427 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp270_ = i;
-#line 427 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp271_ = number;
-#line 427 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp272_ = g_strdup_printf ("/Resources << /XObject << /Im%d %u 0 R >> >>\n", _tmp270_, _tmp271_ + 1);
-#line 427 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp273_ = _tmp272_;
-#line 427 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp269_, _tmp273_);
-#line 427 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp273_);
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp274_ = writer;
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp275_ = page_width;
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp276_ = width_buffer;
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp276__length1 = width_buffer_length1;
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp277_ = g_ascii_formatd (_tmp276_, _tmp276__length1, "%.2f", _tmp275_);
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp278_ = page_height;
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp279_ = height_buffer;
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp279__length1 = height_buffer_length1;
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp280_ = g_ascii_formatd (_tmp279_, _tmp279__length1, "%.2f", _tmp278_);
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp281_ = g_strdup_printf ("/MediaBox [ 0 0 %s %s ]\n", _tmp277_, _tmp280_);
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp282_ = _tmp281_;
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp274_, _tmp282_);
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp282_);
-#line 429 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp283_ = writer;
-#line 429 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp284_ = number;
-#line 429 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp285_ = g_strdup_printf ("/Contents %u 0 R\n", _tmp284_ + 2);
-#line 429 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp286_ = _tmp285_;
-#line 429 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp283_, _tmp286_);
-#line 429 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp286_);
-#line 430 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp287_ = writer;
-#line 430 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp287_, ">>\n");
-#line 431 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp288_ = writer;
-#line 431 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp288_, "endobj\n");
-#line 434 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp289_ = writer;
-#line 434 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp289_, "\n");
-#line 435 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp290_ = writer;
-#line 435 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp291_ = pdf_writer_start_object (_tmp290_);
-#line 435 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- number = _tmp291_;
-#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp292_ = writer;
-#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp293_ = number;
-#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp294_ = g_strdup_printf ("%u 0 obj\n", _tmp293_);
-#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp295_ = _tmp294_;
-#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp292_, _tmp295_);
-#line 436 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp295_);
-#line 437 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp296_ = writer;
-#line 437 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp296_, "<<\n");
-#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp297_ = writer;
-#line 438 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp297_, "/Type /XObject\n");
#line 439 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp298_ = writer;
+ _tmp221_ = height;
#line 439 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp298_, "/Subtype /Image\n");
-#line 440 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp299_ = writer;
-#line 440 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp300_ = width;
-#line 440 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp301_ = g_strdup_printf ("/Width %d\n", _tmp300_);
-#line 440 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp302_ = _tmp301_;
-#line 440 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp299_, _tmp302_);
-#line 440 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp302_);
-#line 441 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp303_ = writer;
+ if (!(_tmp220_ < _tmp221_)) {
+#line 439 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ break;
+#line 3460 "book.c"
+ }
#line 441 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp304_ = height;
+ _tmp222_ = row;
#line 441 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp305_ = g_strdup_printf ("/Height %d\n", _tmp304_);
+ _tmp223_ = image;
#line 441 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp306_ = _tmp305_;
+ _tmp224_ = gdk_pixbuf_get_rowstride (_tmp223_);
#line 441 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp303_, _tmp306_);
+ _tmp225_ = _tmp224_;
#line 441 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp306_);
-#line 442 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp307_ = writer;
-#line 442 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp308_ = color_space;
+ in_offset = _tmp222_ * _tmp225_;
#line 442 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp309_ = g_strdup_printf ("/ColorSpace /%s\n", _tmp308_);
+ _tmp226_ = row;
#line 442 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp310_ = _tmp309_;
+ _tmp227_ = width;
#line 442 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp307_, _tmp310_);
-#line 442 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp310_);
+ out_offset = _tmp226_ * _tmp227_;
+#line 3478 "book.c"
+ {
+ gint x = 0;
+#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ x = 0;
+#line 3483 "book.c"
+ {
+ gboolean _tmp228_ = FALSE;
+#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp228_ = TRUE;
+#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ while (TRUE) {
+#line 3490 "book.c"
+ gint _tmp230_ = 0;
+ gint _tmp231_ = 0;
+ guint8* _tmp232_ = NULL;
+ gint _tmp232__length1 = 0;
+ gint _tmp233_ = 0;
+ gint _tmp234_ = 0;
+ guint8* _tmp235_ = NULL;
+ gint _tmp235__length1 = 0;
+ gint _tmp236_ = 0;
+ gint _tmp237_ = 0;
+ guint8 _tmp238_ = 0U;
+ guint8 _tmp239_ = 0U;
+#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (!_tmp228_) {
+#line 3505 "book.c"
+ gint _tmp229_ = 0;
#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp311_ = writer;
+ _tmp229_ = x;
+#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ x = _tmp229_ + 1;
+#line 3511 "book.c"
+ }
#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp312_ = depth;
+ _tmp228_ = FALSE;
#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp313_ = g_strdup_printf ("/BitsPerComponent %d\n", _tmp312_);
+ _tmp230_ = x;
#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp314_ = _tmp313_;
+ _tmp231_ = width;
#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp311_, _tmp314_);
+ if (!(_tmp230_ < _tmp231_)) {
#line 443 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp314_);
+ break;
+#line 3523 "book.c"
+ }
+#line 444 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp232_ = data;
#line 444 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp315_ = writer;
+ _tmp232__length1 = data_length1;
#line 444 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp316_ = data;
+ _tmp233_ = out_offset;
#line 444 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp316__length1 = data_length1;
+ _tmp234_ = x;
#line 444 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp317_ = g_strdup_printf ("/Length %d\n", _tmp316__length1);
+ _tmp235_ = pixels;
#line 444 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp318_ = _tmp317_;
+ _tmp235__length1 = pixels_length1;
#line 444 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp315_, _tmp318_);
+ _tmp236_ = in_offset;
#line 444 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp318_);
-#line 445 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp319_ = filter;
-#line 445 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- if (_tmp319_ != NULL) {
-#line 3539 "book.c"
- PDFWriter* _tmp320_ = NULL;
- const gchar* _tmp321_ = NULL;
- gchar* _tmp322_ = NULL;
- gchar* _tmp323_ = NULL;
-#line 446 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp320_ = writer;
-#line 446 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp321_ = filter;
-#line 446 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp322_ = g_strdup_printf ("/Filter /%s\n", _tmp321_);
-#line 446 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp323_ = _tmp322_;
-#line 446 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp320_, _tmp323_);
-#line 446 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp323_);
-#line 3556 "book.c"
+ _tmp237_ = x;
+#line 444 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp238_ = _tmp235_[_tmp236_ + (_tmp237_ * 3)];
+#line 444 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp232_[_tmp233_ + _tmp234_] = _tmp238_;
+#line 444 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp239_ = _tmp232_[_tmp233_ + _tmp234_];
+#line 3547 "book.c"
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
}
-#line 447 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp324_ = writer;
-#line 447 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp324_, ">>\n");
-#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp325_ = writer;
-#line 448 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp325_, "stream\n");
#line 449 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp326_ = writer;
+ _tmp240_ = data;
+#line 449 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp240__length1 = data_length1;
+#line 449 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp242_ = book_compress_zlib (self, _tmp240_, _tmp240__length1, &_tmp241_);
#line 449 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp327_ = data;
+ compressed_data = _tmp242_;
#line 449 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp327__length1 = data_length1;
+ compressed_data_length1 = _tmp241_;
#line 449 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write (_tmp326_, _tmp327_, _tmp327__length1);
+ _compressed_data_size_ = compressed_data_length1;
#line 450 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp328_ = writer;
+ _tmp243_ = compressed_data;
#line 450 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp328_, "\n");
-#line 451 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp329_ = writer;
-#line 451 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp329_, "endstream\n");
-#line 452 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp330_ = writer;
-#line 452 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp330_, "endobj\n");
-#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp331_ = page_width;
-#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp332_ = width_buffer;
+ _tmp243__length1 = compressed_data_length1;
+#line 450 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (_tmp243_ != NULL) {
+#line 3575 "book.c"
+ gint _tmp244_ = 0;
+ const gchar* _tmp257_ = NULL;
+#line 453 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp244_ = depth;
+#line 453 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (_tmp244_ > 1) {
+#line 3582 "book.c"
+ guint8* jpeg_data = NULL;
+ GdkPixbuf* _tmp245_ = NULL;
+ gint _tmp246_ = 0;
+ Page* _tmp247_ = NULL;
+ gint _tmp248_ = 0;
+ gint _tmp249_ = 0;
+ gint _tmp250_ = 0;
+ guint8* _tmp251_ = NULL;
+ gint jpeg_data_length1 = 0;
+ gint _jpeg_data_size_ = 0;
+ guint8* _tmp252_ = NULL;
+ gint _tmp252__length1 = 0;
+ guint8* _tmp253_ = NULL;
+ gint _tmp253__length1 = 0;
#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp332__length1 = width_buffer_length1;
+ _tmp245_ = image;
#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp333_ = g_ascii_formatd (_tmp332_, _tmp332__length1, "%f", _tmp331_);
+ _tmp246_ = quality;
#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp334_ = page_height;
+ _tmp247_ = page;
#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp335_ = height_buffer;
+ _tmp248_ = page_get_dpi (_tmp247_);
#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp335__length1 = height_buffer_length1;
+ _tmp249_ = _tmp248_;
#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp336_ = g_ascii_formatd (_tmp335_, _tmp335__length1, "%f", _tmp334_);
+ _tmp251_ = book_compress_jpeg (self, _tmp245_, _tmp246_, _tmp249_, &_tmp250_);
#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp337_ = i;
+ jpeg_data = _tmp251_;
#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp338_ = g_strdup_printf ("q\n%s 0 0 %s 0 0 cm\n/Im%d Do\nQ", _tmp333_, _tmp336_, _tmp337_);
+ jpeg_data_length1 = _tmp250_;
#line 455 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- command = _tmp338_;
+ _jpeg_data_size_ = jpeg_data_length1;
#line 456 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp339_ = writer;
+ _tmp252_ = jpeg_data;
#line 456 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp339_, "\n");
-#line 457 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp340_ = writer;
-#line 457 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp341_ = pdf_writer_start_object (_tmp340_);
-#line 457 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- number = _tmp341_;
-#line 458 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp342_ = writer;
-#line 458 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp343_ = number;
-#line 458 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp344_ = g_strdup_printf ("%u 0 obj\n", _tmp343_);
+ _tmp252__length1 = jpeg_data_length1;
+#line 456 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp253_ = compressed_data;
+#line 456 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp253__length1 = compressed_data_length1;
+#line 456 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ if (_tmp252__length1 < _tmp253__length1) {
+#line 3625 "book.c"
+ gchar* _tmp254_ = NULL;
+ guint8* _tmp255_ = NULL;
+ gint _tmp255__length1 = 0;
+ guint8* _tmp256_ = NULL;
+ gint _tmp256__length1 = 0;
#line 458 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp345_ = _tmp344_;
+ _tmp254_ = g_strdup ("DCTDecode");
#line 458 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp342_, _tmp345_);
+ _g_free0 (filter);
#line 458 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp345_);
+ filter = _tmp254_;
#line 459 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp346_ = writer;
+ _tmp255_ = jpeg_data;
#line 459 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp346_, "<<\n");
-#line 460 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp347_ = writer;
-#line 460 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp348_ = command;
-#line 460 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp349_ = strlen (_tmp348_);
-#line 460 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp350_ = _tmp349_;
-#line 460 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp351_ = g_strdup_printf ("/Length %d\n", _tmp350_ + 1);
-#line 460 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp352_ = _tmp351_;
-#line 460 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp347_, _tmp352_);
-#line 460 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp352_);
-#line 461 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp353_ = writer;
-#line 461 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp353_, ">>\n");
-#line 462 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp354_ = writer;
-#line 462 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp354_, "stream\n");
-#line 463 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp355_ = writer;
+ _tmp255__length1 = jpeg_data_length1;
+#line 459 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp256_ = (_tmp255_ != NULL) ? _vala_array_dup1 (_tmp255_, _tmp255__length1) : ((gpointer) _tmp255_);
+#line 459 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp256__length1 = _tmp255__length1;
+#line 459 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data = (g_free (data), NULL);
+#line 459 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data = _tmp256_;
+#line 459 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data_length1 = _tmp256__length1;
+#line 459 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _data_size_ = data_length1;
+#line 3653 "book.c"
+ }
+#line 453 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ jpeg_data = (g_free (jpeg_data), NULL);
+#line 3657 "book.c"
+ }
#line 463 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp356_ = command;
+ _tmp257_ = filter;
#line 463 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp355_, _tmp356_);
-#line 464 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp357_ = writer;
-#line 464 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp357_, "\n");
+ if (_tmp257_ == NULL) {
+#line 3663 "book.c"
+ gchar* _tmp258_ = NULL;
+ guint8* _tmp259_ = NULL;
+ gint _tmp259__length1 = 0;
+ guint8* _tmp260_ = NULL;
+ gint _tmp260__length1 = 0;
#line 465 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp358_ = writer;
+ _tmp258_ = g_strdup ("FlateDecode");
#line 465 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp358_, "endstream\n");
+ _g_free0 (filter);
+#line 465 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ filter = _tmp258_;
#line 466 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp359_ = writer;
+ _tmp259_ = compressed_data;
#line 466 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp359_, "endobj\n");
-#line 468 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp360_ = i;
-#line 468 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- g_signal_emit_by_name (self, "saving", _tmp360_);
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (command);
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- compressed_data = (g_free (compressed_data), NULL);
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- data = (g_free (data), NULL);
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- height_buffer = (g_free (height_buffer), NULL);
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- width_buffer = (g_free (width_buffer), NULL);
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (filter);
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (color_space);
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_object_unref0 (image);
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _page_unref0 (page);
-#line 3698 "book.c"
- }
- }
- }
+ _tmp259__length1 = compressed_data_length1;
+#line 466 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp260_ = (_tmp259_ != NULL) ? _vala_array_dup2 (_tmp259_, _tmp259__length1) : ((gpointer) _tmp259_);
+#line 466 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp260__length1 = _tmp259__length1;
+#line 466 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data = (g_free (data), NULL);
+#line 466 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data = _tmp260_;
+#line 466 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data_length1 = _tmp260__length1;
+#line 466 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _data_size_ = data_length1;
+#line 3691 "book.c"
+ }
+ }
+#line 471 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp261_ = writer;
+#line 471 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp261_, "\n");
+#line 472 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp262_ = writer;
#line 472 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp361_ = writer;
+ _tmp263_ = pdf_writer_start_object (_tmp262_);
#line 472 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp361_, "\n");
+ number = _tmp263_;
+#line 473 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp264_ = writer;
#line 473 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp362_ = writer;
+ _tmp265_ = number;
#line 473 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp363_ = pdf_writer_start_object (_tmp362_);
+ _tmp266_ = g_strdup_printf ("%u 0 obj\n", _tmp265_);
#line 473 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- info_number = _tmp363_;
-#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp364_ = writer;
-#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp365_ = info_number;
-#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp366_ = g_strdup_printf ("%u 0 obj\n", _tmp365_);
-#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp367_ = _tmp366_;
+ _tmp267_ = _tmp266_;
+#line 473 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp264_, _tmp267_);
+#line 473 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp267_);
#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp364_, _tmp367_);
+ _tmp268_ = writer;
#line 474 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp367_);
+ pdf_writer_write_string (_tmp268_, "<<\n");
#line 475 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp368_ = writer;
+ _tmp269_ = writer;
#line 475 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp368_, "<<\n");
+ pdf_writer_write_string (_tmp269_, "/Type /Page\n");
#line 476 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp369_ = writer;
+ _tmp270_ = writer;
+#line 476 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp271_ = pages_number;
#line 476 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp370_ = g_strdup_printf ("/Creator (Simple Scan %s)\n", VERSION);
+ _tmp272_ = g_strdup_printf ("/Parent %u 0 R\n", _tmp271_);
#line 476 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp371_ = _tmp370_;
+ _tmp273_ = _tmp272_;
#line 476 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp369_, _tmp371_);
+ pdf_writer_write_string (_tmp270_, _tmp273_);
#line 476 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp371_);
+ _g_free0 (_tmp273_);
+#line 477 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp274_ = writer;
+#line 477 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp275_ = i;
+#line 477 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp276_ = number;
+#line 477 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp277_ = g_strdup_printf ("/Resources << /XObject << /Im%d %u 0 R >> >>\n", _tmp275_, _tmp276_ + 1);
#line 477 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp372_ = writer;
+ _tmp278_ = _tmp277_;
#line 477 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp372_, ">>\n");
+ pdf_writer_write_string (_tmp274_, _tmp278_);
+#line 477 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp278_);
#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp373_ = writer;
+ _tmp279_ = writer;
#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp373_, "endobj\n");
-#line 481 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp374_ = writer;
+ _tmp280_ = page_width;
+#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp281_ = width_buffer;
+#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp281__length1 = width_buffer_length1;
+#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp282_ = g_ascii_formatd (_tmp281_, _tmp281__length1, "%.2f", _tmp280_);
+#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp283_ = page_height;
+#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp284_ = height_buffer;
+#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp284__length1 = height_buffer_length1;
+#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp285_ = g_ascii_formatd (_tmp284_, _tmp284__length1, "%.2f", _tmp283_);
+#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp286_ = g_strdup_printf ("/MediaBox [ 0 0 %s %s ]\n", _tmp282_, _tmp285_);
+#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp287_ = _tmp286_;
+#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp279_, _tmp287_);
+#line 478 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp287_);
+#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp288_ = writer;
+#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp289_ = number;
+#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp290_ = g_strdup_printf ("/Contents %u 0 R\n", _tmp289_ + 2);
+#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp291_ = _tmp290_;
+#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp288_, _tmp291_);
+#line 479 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp291_);
+#line 480 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp292_ = writer;
+#line 480 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp292_, ">>\n");
#line 481 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp375_ = _tmp374_->offset;
+ _tmp293_ = writer;
#line 481 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- xref_offset = _tmp375_;
-#line 482 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp376_ = writer;
-#line 482 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp376_, "xref\n");
-#line 483 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp377_ = writer;
-#line 483 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp378_ = writer;
-#line 483 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp379_ = _tmp378_->object_offsets;
-#line 483 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp380_ = g_list_length (_tmp379_);
-#line 483 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp381_ = g_strdup_printf ("1 %zu\n", (gsize) _tmp380_);
-#line 483 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp382_ = _tmp381_;
-#line 483 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp377_, _tmp382_);
-#line 483 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp382_);
+ pdf_writer_write_string (_tmp293_, "endobj\n");
#line 484 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp383_ = writer;
+ _tmp294_ = writer;
#line 484 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp384_ = _tmp383_->object_offsets;
-#line 3776 "book.c"
- {
- GList* offset_collection = NULL;
- GList* offset_it = NULL;
-#line 484 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- offset_collection = _tmp384_;
-#line 484 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- for (offset_it = offset_collection; offset_it != NULL; offset_it = offset_it->next) {
-#line 3784 "book.c"
- guint offset = 0U;
-#line 484 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- offset = (guint) ((guintptr) offset_it->data);
-#line 3788 "book.c"
- {
- PDFWriter* _tmp385_ = NULL;
- guint _tmp386_ = 0U;
- gchar* _tmp387_ = NULL;
- gchar* _tmp388_ = NULL;
+ pdf_writer_write_string (_tmp294_, "\n");
#line 485 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp385_ = writer;
+ _tmp295_ = writer;
#line 485 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp386_ = offset;
+ _tmp296_ = pdf_writer_start_object (_tmp295_);
#line 485 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp387_ = g_strdup_printf ("%010zu 00000 n \n", (gsize) _tmp386_);
-#line 485 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp388_ = _tmp387_;
-#line 485 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp385_, _tmp388_);
-#line 485 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp388_);
-#line 3806 "book.c"
- }
- }
- }
+ number = _tmp296_;
+#line 486 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp297_ = writer;
+#line 486 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp298_ = number;
+#line 486 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp299_ = g_strdup_printf ("%u 0 obj\n", _tmp298_);
+#line 486 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp300_ = _tmp299_;
+#line 486 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp297_, _tmp300_);
+#line 486 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp300_);
+#line 487 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp301_ = writer;
+#line 487 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp301_, "<<\n");
#line 488 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp389_ = writer;
+ _tmp302_ = writer;
#line 488 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp389_, "trailer\n");
+ pdf_writer_write_string (_tmp302_, "/Type /XObject\n");
#line 489 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp390_ = writer;
+ _tmp303_ = writer;
#line 489 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp390_, "<<\n");
+ pdf_writer_write_string (_tmp303_, "/Subtype /Image\n");
#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp391_ = writer;
+ _tmp304_ = writer;
#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp392_ = writer;
+ _tmp305_ = width;
#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp393_ = _tmp392_->object_offsets;
+ _tmp306_ = g_strdup_printf ("/Width %d\n", _tmp305_);
#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp394_ = g_list_length (_tmp393_);
+ _tmp307_ = _tmp306_;
#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp395_ = g_strdup_printf ("/Size %zu\n", (gsize) _tmp394_);
+ pdf_writer_write_string (_tmp304_, _tmp307_);
#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp396_ = _tmp395_;
-#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp391_, _tmp396_);
-#line 490 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp396_);
+ _g_free0 (_tmp307_);
#line 491 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp397_ = writer;
+ _tmp308_ = writer;
#line 491 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp398_ = info_number;
+ _tmp309_ = height;
#line 491 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp399_ = g_strdup_printf ("/Info %u 0 R\n", _tmp398_);
+ _tmp310_ = g_strdup_printf ("/Height %d\n", _tmp309_);
#line 491 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp400_ = _tmp399_;
+ _tmp311_ = _tmp310_;
#line 491 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp397_, _tmp400_);
+ pdf_writer_write_string (_tmp308_, _tmp311_);
#line 491 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp400_);
+ _g_free0 (_tmp311_);
#line 492 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp401_ = writer;
+ _tmp312_ = writer;
#line 492 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp402_ = catalog_number;
+ _tmp313_ = color_space;
#line 492 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp403_ = g_strdup_printf ("/Root %u 0 R\n", _tmp402_);
+ _tmp314_ = g_strdup_printf ("/ColorSpace /%s\n", _tmp313_);
#line 492 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp404_ = _tmp403_;
+ _tmp315_ = _tmp314_;
#line 492 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp401_, _tmp404_);
+ pdf_writer_write_string (_tmp312_, _tmp315_);
#line 492 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp404_);
+ _g_free0 (_tmp315_);
+#line 493 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp316_ = writer;
+#line 493 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp317_ = depth;
+#line 493 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp318_ = g_strdup_printf ("/BitsPerComponent %d\n", _tmp317_);
+#line 493 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp319_ = _tmp318_;
+#line 493 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp316_, _tmp319_);
+#line 493 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp319_);
#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp405_ = writer;
+ _tmp320_ = writer;
+#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp321_ = data;
+#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp321__length1 = data_length1;
+#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp322_ = g_strdup_printf ("/Length %d\n", _tmp321__length1);
#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp405_, ">>\n");
+ _tmp323_ = _tmp322_;
+#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp320_, _tmp323_);
+#line 494 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp323_);
#line 495 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp406_ = writer;
+ _tmp324_ = filter;
#line 495 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp406_, "startxref\n");
+ if (_tmp324_ != NULL) {
+#line 3896 "book.c"
+ PDFWriter* _tmp325_ = NULL;
+ const gchar* _tmp326_ = NULL;
+ gchar* _tmp327_ = NULL;
+ gchar* _tmp328_ = NULL;
#line 496 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp407_ = writer;
+ _tmp325_ = writer;
#line 496 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp408_ = xref_offset;
+ _tmp326_ = filter;
#line 496 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp409_ = g_strdup_printf ("%zu\n", _tmp408_);
+ _tmp327_ = g_strdup_printf ("/Filter /%s\n", _tmp326_);
#line 496 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp410_ = _tmp409_;
+ _tmp328_ = _tmp327_;
#line 496 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp407_, _tmp410_);
+ pdf_writer_write_string (_tmp325_, _tmp328_);
#line 496 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _g_free0 (_tmp410_);
+ _g_free0 (_tmp328_);
+#line 3913 "book.c"
+ }
#line 497 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- _tmp411_ = writer;
+ _tmp329_ = writer;
#line 497 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- pdf_writer_write_string (_tmp411_, "%%EOF\n");
-#line 213 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp329_, ">>\n");
+#line 498 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp330_ = writer;
+#line 498 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp330_, "stream\n");
+#line 499 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp331_ = writer;
+#line 499 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp332_ = data;
+#line 499 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp332__length1 = data_length1;
+#line 499 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write (_tmp331_, _tmp332_, _tmp332__length1);
+#line 500 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp333_ = writer;
+#line 500 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp333_, "\n");
+#line 501 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp334_ = writer;
+#line 501 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp334_, "endstream\n");
+#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp335_ = writer;
+#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp335_, "endobj\n");
+#line 505 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp336_ = page_width;
+#line 505 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp337_ = width_buffer;
+#line 505 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp337__length1 = width_buffer_length1;
+#line 505 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp338_ = g_ascii_formatd (_tmp337_, _tmp337__length1, "%f", _tmp336_);
+#line 505 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp339_ = page_height;
+#line 505 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp340_ = height_buffer;
+#line 505 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp340__length1 = height_buffer_length1;
+#line 505 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp341_ = g_ascii_formatd (_tmp340_, _tmp340__length1, "%f", _tmp339_);
+#line 505 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp342_ = i;
+#line 505 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp343_ = g_strdup_printf ("q\n%s 0 0 %s 0 0 cm\n/Im%d Do\nQ", _tmp338_, _tmp341_, _tmp342_);
+#line 505 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ command = _tmp343_;
+#line 506 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp344_ = writer;
+#line 506 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp344_, "\n");
+#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp345_ = writer;
+#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp346_ = pdf_writer_start_object (_tmp345_);
+#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ number = _tmp346_;
+#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp347_ = writer;
+#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp348_ = number;
+#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp349_ = g_strdup_printf ("%u 0 obj\n", _tmp348_);
+#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp350_ = _tmp349_;
+#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp347_, _tmp350_);
+#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp350_);
+#line 509 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp351_ = writer;
+#line 509 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp351_, "<<\n");
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp352_ = writer;
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp353_ = command;
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp354_ = strlen (_tmp353_);
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp355_ = _tmp354_;
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp356_ = g_strdup_printf ("/Length %d\n", _tmp355_);
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp357_ = _tmp356_;
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp352_, _tmp357_);
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp357_);
+#line 511 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp358_ = writer;
+#line 511 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp358_, ">>\n");
+#line 512 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp359_ = writer;
+#line 512 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp359_, "stream\n");
+#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp360_ = writer;
+#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp361_ = command;
+#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp360_, _tmp361_);
+#line 514 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp362_ = writer;
+#line 514 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp362_, "\n");
+#line 515 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp363_ = writer;
+#line 515 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp363_, "endstream\n");
+#line 516 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp364_ = writer;
+#line 516 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp364_, "endobj\n");
+#line 518 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp365_ = i;
+#line 518 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ g_signal_emit_by_name (self, "saving", _tmp365_);
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (command);
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ compressed_data = (g_free (compressed_data), NULL);
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ data = (g_free (data), NULL);
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ height_buffer = (g_free (height_buffer), NULL);
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ width_buffer = (g_free (width_buffer), NULL);
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (filter);
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (color_space);
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_object_unref0 (image);
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _page_unref0 (page);
+#line 4055 "book.c"
+ }
+ }
+ }
+#line 522 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp366_ = writer;
+#line 522 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp366_, "\n");
+#line 523 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp367_ = writer;
+#line 523 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp368_ = pdf_writer_start_object (_tmp367_);
+#line 523 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ info_number = _tmp368_;
+#line 524 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp369_ = writer;
+#line 524 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp370_ = info_number;
+#line 524 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp371_ = g_strdup_printf ("%u 0 obj\n", _tmp370_);
+#line 524 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp372_ = _tmp371_;
+#line 524 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp369_, _tmp372_);
+#line 524 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp372_);
+#line 525 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp373_ = writer;
+#line 525 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp373_, "<<\n");
+#line 526 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp374_ = writer;
+#line 526 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp375_ = g_strdup_printf ("/Creator (Simple Scan %s)\n", VERSION);
+#line 526 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp376_ = _tmp375_;
+#line 526 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp374_, _tmp376_);
+#line 526 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp376_);
+#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp377_ = writer;
+#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp377_, ">>\n");
+#line 528 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp378_ = writer;
+#line 528 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp378_, "endobj\n");
+#line 531 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp379_ = writer;
+#line 531 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp379_, "\n");
+#line 532 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp380_ = writer;
+#line 532 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp381_ = _tmp380_->offset;
+#line 532 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ xref_offset = _tmp381_;
+#line 533 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp382_ = writer;
+#line 533 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp382_, "xref\n");
+#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp383_ = writer;
+#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp384_ = writer;
+#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp385_ = _tmp384_->object_offsets;
+#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp386_ = g_list_length (_tmp385_);
+#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp387_ = g_strdup_printf ("0 %zu\n", (gsize) (_tmp386_ + 1));
+#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp388_ = _tmp387_;
+#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp383_, _tmp388_);
+#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp388_);
+#line 535 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp389_ = writer;
+#line 535 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp389_, "0000000000 65535 f \n");
+#line 536 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp390_ = writer;
+#line 536 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp391_ = _tmp390_->object_offsets;
+#line 4141 "book.c"
+ {
+ GList* offset_collection = NULL;
+ GList* offset_it = NULL;
+#line 536 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ offset_collection = _tmp391_;
+#line 536 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ for (offset_it = offset_collection; offset_it != NULL; offset_it = offset_it->next) {
+#line 4149 "book.c"
+ guint offset = 0U;
+#line 536 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ offset = (guint) ((guintptr) offset_it->data);
+#line 4153 "book.c"
+ {
+ PDFWriter* _tmp392_ = NULL;
+ guint _tmp393_ = 0U;
+ gchar* _tmp394_ = NULL;
+ gchar* _tmp395_ = NULL;
+#line 537 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp392_ = writer;
+#line 537 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp393_ = offset;
+#line 537 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp394_ = g_strdup_printf ("%010zu 00000 n \n", (gsize) _tmp393_);
+#line 537 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp395_ = _tmp394_;
+#line 537 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp392_, _tmp395_);
+#line 537 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp395_);
+#line 4171 "book.c"
+ }
+ }
+ }
+#line 540 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp396_ = writer;
+#line 540 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp396_, "\n");
+#line 541 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp397_ = writer;
+#line 541 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp397_, "trailer\n");
+#line 542 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp398_ = writer;
+#line 542 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp398_, "<<\n");
+#line 543 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp399_ = writer;
+#line 543 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp400_ = writer;
+#line 543 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp401_ = _tmp400_->object_offsets;
+#line 543 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp402_ = g_list_length (_tmp401_);
+#line 543 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp403_ = g_strdup_printf ("/Size %zu\n", (gsize) (_tmp402_ + 1));
+#line 543 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp404_ = _tmp403_;
+#line 543 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp399_, _tmp404_);
+#line 543 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp404_);
+#line 544 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp405_ = writer;
+#line 544 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp406_ = info_number;
+#line 544 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp407_ = g_strdup_printf ("/Info %u 0 R\n", _tmp406_);
+#line 544 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp408_ = _tmp407_;
+#line 544 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp405_, _tmp408_);
+#line 544 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp408_);
+#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp409_ = writer;
+#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp410_ = catalog_number;
+#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp411_ = g_strdup_printf ("/Root %u 0 R\n", _tmp410_);
+#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp412_ = _tmp411_;
+#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp409_, _tmp412_);
+#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp412_);
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp413_ = writer;
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp414_ = id;
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp415_ = id;
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp416_ = g_strdup_printf ("/ID [<%s> <%s>]\n", _tmp414_, _tmp415_);
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp417_ = _tmp416_;
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp413_, _tmp417_);
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp417_);
+#line 547 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp418_ = writer;
+#line 547 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp418_, ">>\n");
+#line 548 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp419_ = writer;
+#line 548 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp419_, "startxref\n");
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp420_ = writer;
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp421_ = xref_offset;
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp422_ = g_strdup_printf ("%zu\n", _tmp421_);
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp423_ = _tmp422_;
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp420_, _tmp423_);
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (_tmp423_);
+#line 550 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _tmp424_ = writer;
+#line 550 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ pdf_writer_write_string (_tmp424_, "%%EOF\n");
+#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_pdf_writer_unref0 (writer);
-#line 213 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_object_unref0 (stream);
-#line 3886 "book.c"
+#line 257 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ _g_free0 (id);
+#line 4271 "book.c"
}
@@ -3890,110 +4275,110 @@ void book_save (Book* self, const gchar* type, gint quality, GFile* file, GError
const gchar* _tmp0_ = NULL;
const gchar* _tmp1_ = NULL;
GQuark _tmp3_ = 0U;
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
static GQuark _tmp2_label0 = 0;
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
static GQuark _tmp2_label1 = 0;
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
static GQuark _tmp2_label2 = 0;
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
static GQuark _tmp2_label3 = 0;
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
static GQuark _tmp2_label4 = 0;
-#line 3904 "book.c"
+#line 4289 "book.c"
GError * _inner_error_ = NULL;
-#line 500 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 553 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (self != NULL);
-#line 500 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 553 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (type != NULL);
-#line 500 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 553 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (file != NULL);
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = type;
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = _tmp0_;
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3_ = (NULL == _tmp1_) ? 0 : g_quark_from_string (_tmp1_);
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (((_tmp3_ == ((0 != _tmp2_label0) ? _tmp2_label0 : (_tmp2_label0 = g_quark_from_static_string ("jpeg")))) || (_tmp3_ == ((0 != _tmp2_label1) ? _tmp2_label1 : (_tmp2_label1 = g_quark_from_static_string ("png"))))) || (_tmp3_ == ((0 != _tmp2_label2) ? _tmp2_label2 : (_tmp2_label2 = g_quark_from_static_string ("tiff"))))) {
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
switch (0) {
-#line 3922 "book.c"
+#line 4307 "book.c"
default:
{
const gchar* _tmp4_ = NULL;
gint _tmp5_ = 0;
GFile* _tmp6_ = NULL;
-#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp4_ = type;
-#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_ = quality;
-#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp6_ = file;
-#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
book_save_multi_file (self, _tmp4_, _tmp5_, _tmp6_, &_inner_error_);
-#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_inner_error_ != NULL) {
-#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_propagate_error (error, _inner_error_);
-#line 507 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return;
-#line 3942 "book.c"
+#line 4327 "book.c"
}
-#line 508 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 561 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 3946 "book.c"
+#line 4331 "book.c"
}
}
} else if (_tmp3_ == ((0 != _tmp2_label3) ? _tmp2_label3 : (_tmp2_label3 = g_quark_from_static_string ("ps")))) {
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
switch (0) {
-#line 3952 "book.c"
+#line 4337 "book.c"
default:
{
GFile* _tmp7_ = NULL;
-#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 563 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp7_ = file;
-#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 563 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
book_save_ps (self, _tmp7_, &_inner_error_);
-#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 563 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_inner_error_ != NULL) {
-#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 563 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_propagate_error (error, _inner_error_);
-#line 510 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 563 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return;
-#line 3966 "book.c"
+#line 4351 "book.c"
}
-#line 511 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 564 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 3970 "book.c"
+#line 4355 "book.c"
}
}
} else if (_tmp3_ == ((0 != _tmp2_label4) ? _tmp2_label4 : (_tmp2_label4 = g_quark_from_static_string ("pdf")))) {
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
switch (0) {
-#line 3976 "book.c"
+#line 4361 "book.c"
default:
{
GFile* _tmp8_ = NULL;
gint _tmp9_ = 0;
-#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 566 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp8_ = file;
-#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 566 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp9_ = quality;
-#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 566 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
book_save_pdf (self, _tmp8_, _tmp9_, &_inner_error_);
-#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 566 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_inner_error_ != NULL) {
-#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 566 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_propagate_error (error, _inner_error_);
-#line 513 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 566 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return;
-#line 3993 "book.c"
+#line 4378 "book.c"
}
-#line 514 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 567 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
break;
-#line 3997 "book.c"
+#line 4382 "book.c"
}
}
}
@@ -4014,7 +4399,7 @@ guint book_get_n_pages (Book* self) {
result = _tmp1_;
#line 16 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 4018 "book.c"
+#line 4403 "book.c"
}
@@ -4029,7 +4414,7 @@ gboolean book_get_needs_saving (Book* self) {
result = _tmp0_;
#line 21 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 4033 "book.c"
+#line 4418 "book.c"
}
@@ -4047,7 +4432,7 @@ void book_set_needs_saving (Book* self, gboolean value) {
if (_tmp0_ == _tmp1_) {
#line 25 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return;
-#line 4051 "book.c"
+#line 4436 "book.c"
}
#line 26 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = value;
@@ -4055,7 +4440,7 @@ void book_set_needs_saving (Book* self, gboolean value) {
self->priv->needs_saving_ = _tmp2_;
#line 27 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_signal_emit_by_name (self, "needs-saving-changed");
-#line 4059 "book.c"
+#line 4444 "book.c"
}
@@ -4074,26 +4459,26 @@ static void g_cclosure_user_marshal_VOID__PAGE (GClosure * closure, GValue * ret
data1 = closure->data;
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
data2 = param_values->data[0].v_pointer;
-#line 4078 "book.c"
+#line 4463 "book.c"
} else {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
data1 = param_values->data[0].v_pointer;
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
data2 = closure->data;
-#line 4084 "book.c"
+#line 4469 "book.c"
}
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
callback = (GMarshalFunc_VOID__PAGE) (marshal_data ? marshal_data : cc->callback);
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
callback (data1, value_get_page (param_values + 1), data2);
-#line 4090 "book.c"
+#line 4475 "book.c"
}
static void value_book_init (GValue* value) {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = NULL;
-#line 4097 "book.c"
+#line 4482 "book.c"
}
@@ -4102,7 +4487,7 @@ static void value_book_free_value (GValue* value) {
if (value->data[0].v_pointer) {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
book_unref (value->data[0].v_pointer);
-#line 4106 "book.c"
+#line 4491 "book.c"
}
}
@@ -4112,11 +4497,11 @@ static void value_book_copy_value (const GValue* src_value, GValue* dest_value)
if (src_value->data[0].v_pointer) {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
dest_value->data[0].v_pointer = book_ref (src_value->data[0].v_pointer);
-#line 4116 "book.c"
+#line 4501 "book.c"
} else {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
dest_value->data[0].v_pointer = NULL;
-#line 4120 "book.c"
+#line 4505 "book.c"
}
}
@@ -4124,37 +4509,37 @@ static void value_book_copy_value (const GValue* src_value, GValue* dest_value)
static gpointer value_book_peek_pointer (const GValue* value) {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return value->data[0].v_pointer;
-#line 4128 "book.c"
+#line 4513 "book.c"
}
static gchar* value_book_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (collect_values[0].v_pointer) {
-#line 4135 "book.c"
+#line 4520 "book.c"
Book* object;
object = collect_values[0].v_pointer;
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (object->parent_instance.g_class == NULL) {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
-#line 4142 "book.c"
+#line 4527 "book.c"
} else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
-#line 4146 "book.c"
+#line 4531 "book.c"
}
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = book_ref (object);
-#line 4150 "book.c"
+#line 4535 "book.c"
} else {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = NULL;
-#line 4154 "book.c"
+#line 4539 "book.c"
}
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return NULL;
-#line 4158 "book.c"
+#line 4543 "book.c"
}
@@ -4165,25 +4550,25 @@ static gchar* value_book_lcopy_value (const GValue* value, guint n_collect_value
if (!object_p) {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value));
-#line 4169 "book.c"
+#line 4554 "book.c"
}
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (!value->data[0].v_pointer) {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
*object_p = NULL;
-#line 4175 "book.c"
+#line 4560 "book.c"
} else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
*object_p = value->data[0].v_pointer;
-#line 4179 "book.c"
+#line 4564 "book.c"
} else {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
*object_p = book_ref (value->data[0].v_pointer);
-#line 4183 "book.c"
+#line 4568 "book.c"
}
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return NULL;
-#line 4187 "book.c"
+#line 4572 "book.c"
}
@@ -4197,7 +4582,7 @@ GParamSpec* param_spec_book (const gchar* name, const gchar* nick, const gchar*
G_PARAM_SPEC (spec)->value_type = object_type;
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return G_PARAM_SPEC (spec);
-#line 4201 "book.c"
+#line 4586 "book.c"
}
@@ -4206,7 +4591,7 @@ gpointer value_get_book (const GValue* value) {
g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_BOOK), NULL);
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return value->data[0].v_pointer;
-#line 4210 "book.c"
+#line 4595 "book.c"
}
@@ -4226,17 +4611,17 @@ void value_set_book (GValue* value, gpointer v_object) {
value->data[0].v_pointer = v_object;
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
book_ref (value->data[0].v_pointer);
-#line 4230 "book.c"
+#line 4615 "book.c"
} else {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = NULL;
-#line 4234 "book.c"
+#line 4619 "book.c"
}
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (old) {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
book_unref (old);
-#line 4240 "book.c"
+#line 4625 "book.c"
}
}
@@ -4255,17 +4640,17 @@ void value_take_book (GValue* value, gpointer v_object) {
g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = v_object;
-#line 4259 "book.c"
+#line 4644 "book.c"
} else {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = NULL;
-#line 4263 "book.c"
+#line 4648 "book.c"
}
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (old) {
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
book_unref (old);
-#line 4269 "book.c"
+#line 4654 "book.c"
}
}
@@ -4289,7 +4674,7 @@ static void book_class_init (BookClass * klass) {
g_signal_new ("needs_saving_changed", TYPE_BOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_signal_new ("saving", TYPE_BOOK, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__INT, G_TYPE_NONE, 1, G_TYPE_INT);
-#line 4293 "book.c"
+#line 4678 "book.c"
}
@@ -4298,7 +4683,7 @@ static void book_instance_init (Book * self) {
self->priv = BOOK_GET_PRIVATE (self);
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self->ref_count = 1;
-#line 4302 "book.c"
+#line 4687 "book.c"
}
@@ -4309,7 +4694,7 @@ static void book_finalize (Book* obj) {
self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_BOOK, Book);
#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = self->priv->pages;
-#line 4313 "book.c"
+#line 4698 "book.c"
{
GList* page_collection = NULL;
GList* page_it = NULL;
@@ -4317,14 +4702,14 @@ static void book_finalize (Book* obj) {
page_collection = _tmp0_;
#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
for (page_it = page_collection; page_it != NULL; page_it = page_it->next) {
-#line 4321 "book.c"
+#line 4706 "book.c"
Page* _tmp1_ = NULL;
Page* page = NULL;
#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = _page_ref0 ((Page*) page_it->data);
#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
page = _tmp1_;
-#line 4328 "book.c"
+#line 4713 "book.c"
{
Page* _tmp2_ = NULL;
guint _tmp3_ = 0U;
@@ -4344,15 +4729,15 @@ static void book_finalize (Book* obj) {
g_signal_handlers_disconnect_matched (_tmp4_, G_SIGNAL_MATCH_ID | G_SIGNAL_MATCH_FUNC | G_SIGNAL_MATCH_DATA, _tmp5_, 0, NULL, (GCallback) _book_page_changed_cb_page_crop_changed, self);
#line 45 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_page_unref0 (page);
-#line 4348 "book.c"
+#line 4733 "book.c"
}
}
}
#line 14 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
__g_list_free__page_unref0_0 (self->priv->pages);
-#line 187 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 231 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_byte_array_unref0 (self->priv->jpeg_data);
-#line 4356 "book.c"
+#line 4741 "book.c"
}
@@ -4377,7 +4762,7 @@ gpointer book_ref (gpointer instance) {
g_atomic_int_inc (&self->ref_count);
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return instance;
-#line 4381 "book.c"
+#line 4766 "book.c"
}
@@ -4390,15 +4775,15 @@ void book_unref (gpointer instance) {
BOOK_GET_CLASS (self)->finalize (self);
#line 12 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_type_free_instance ((GTypeInstance *) self);
-#line 4394 "book.c"
+#line 4779 "book.c"
}
}
static gpointer _g_object_ref0 (gpointer self) {
-#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return self ? g_object_ref (self) : NULL;
-#line 4402 "book.c"
+#line 4787 "book.c"
}
@@ -4406,28 +4791,28 @@ PDFWriter* pdf_writer_construct (GType object_type, GFileOutputStream* stream) {
PDFWriter* self = NULL;
GFileOutputStream* _tmp0_ = NULL;
GFileOutputStream* _tmp1_ = NULL;
-#line 525 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (stream != NULL, NULL);
-#line 525 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self = (PDFWriter*) g_type_create_instance (object_type);
-#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = stream;
-#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = _g_object_ref0 (_tmp0_);
-#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_object_unref0 (self->priv->stream);
-#line 527 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 580 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self->priv->stream = _tmp1_;
-#line 525 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return self;
-#line 4424 "book.c"
+#line 4809 "book.c"
}
PDFWriter* pdf_writer_new (GFileOutputStream* stream) {
-#line 525 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return pdf_writer_construct (TYPE_PDF_WRITER, stream);
-#line 4431 "book.c"
+#line 4816 "book.c"
}
@@ -4436,24 +4821,24 @@ void pdf_writer_write (PDFWriter* self, guint8* data, int data_length1) {
guint8* _tmp5_ = NULL;
gint _tmp5__length1 = 0;
GError * _inner_error_ = NULL;
-#line 530 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (self != NULL);
-#line 4442 "book.c"
+#line 4827 "book.c"
{
GFileOutputStream* _tmp0_ = NULL;
guint8* _tmp1_ = NULL;
gint _tmp1__length1 = 0;
-#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 587 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = self->priv->stream;
-#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 587 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = data;
-#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 587 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1__length1 = data_length1;
-#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 587 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_output_stream_write_all ((GOutputStream*) _tmp0_, _tmp1_, (gsize) _tmp1__length1, NULL, NULL, &_inner_error_);
-#line 534 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 587 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_inner_error_ != NULL) {
-#line 4457 "book.c"
+#line 4842 "book.c"
goto __catch1_g_error;
}
}
@@ -4463,40 +4848,40 @@ void pdf_writer_write (PDFWriter* self, guint8* data, int data_length1) {
GError* e = NULL;
GError* _tmp2_ = NULL;
const gchar* _tmp3_ = NULL;
-#line 532 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
e = _inner_error_;
-#line 532 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_inner_error_ = NULL;
-#line 538 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 591 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = e;
-#line 538 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 591 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3_ = _tmp2_->message;
-#line 538 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- g_warning ("book.vala:538: Error writing PDF: %s", _tmp3_);
-#line 532 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 591 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ g_warning ("book.vala:591: Error writing PDF: %s", _tmp3_);
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_error_free0 (e);
-#line 4479 "book.c"
+#line 4864 "book.c"
}
__finally1:
-#line 532 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_inner_error_ != NULL) {
-#line 532 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
-#line 532 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_clear_error (&_inner_error_);
-#line 532 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return;
-#line 4490 "book.c"
+#line 4875 "book.c"
}
-#line 540 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 593 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp4_ = self->offset;
-#line 540 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 593 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5_ = data;
-#line 540 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 593 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp5__length1 = data_length1;
-#line 540 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 593 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self->offset = _tmp4_ + _tmp5__length1;
-#line 4500 "book.c"
+#line 4885 "book.c"
}
@@ -4515,49 +4900,49 @@ static gchar* string_to_utf8 (const gchar* self, int* result_length1) {
gint _tmp6_ = 0;
gchar* _tmp7_ = NULL;
gint _tmp7__length1 = 0;
-#line 1266 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1303 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
g_return_val_if_fail (self != NULL, NULL);
-#line 1267 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1304 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp0_ = strlen (self);
-#line 1267 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1304 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp1_ = _tmp0_;
-#line 1267 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1304 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp2_ = g_new0 (gchar, _tmp1_ + 1);
-#line 1267 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1304 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_result_ = _tmp2_;
-#line 1267 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1304 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_result__length1 = _tmp1_ + 1;
-#line 1267 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1304 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
__result__size_ = _result__length1;
-#line 1268 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1305 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp3_ = _result__length1;
-#line 1268 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1305 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_result__length1 = _tmp3_ - 1;
-#line 1269 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1306 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp4_ = _result_;
-#line 1269 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1306 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp4__length1 = _result__length1;
-#line 1269 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1306 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp5_ = strlen (self);
-#line 1269 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1306 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp6_ = _tmp5_;
-#line 1269 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1306 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
memcpy (_tmp4_, self, (gsize) _tmp6_);
-#line 1270 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1307 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp7_ = _result_;
-#line 1270 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1307 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
_tmp7__length1 = _result__length1;
-#line 1270 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1307 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
if (result_length1) {
-#line 1270 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1307 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
*result_length1 = _tmp7__length1;
-#line 4555 "book.c"
+#line 4940 "book.c"
}
-#line 1270 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1307 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
result = _tmp7_;
-#line 1270 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
+#line 1307 "/usr/share/vala-0.24/vapi/glib-2.0.vapi"
return result;
-#line 4561 "book.c"
+#line 4946 "book.c"
}
@@ -4567,23 +4952,23 @@ void pdf_writer_write_string (PDFWriter* self, const gchar* text) {
gchar* _tmp2_ = NULL;
guint8* _tmp3_ = NULL;
gint _tmp3__length1 = 0;
-#line 543 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 596 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (self != NULL);
-#line 543 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 596 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (text != NULL);
-#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 598 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = text;
-#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 598 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = string_to_utf8 (_tmp0_, &_tmp1_);
-#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 598 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3_ = (guint8*) _tmp2_;
-#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 598 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3__length1 = (_tmp1_ * sizeof (gchar)) / sizeof (guint8);
-#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 598 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
pdf_writer_write (self, _tmp3_, (_tmp1_ * sizeof (gchar)) / sizeof (guint8));
-#line 545 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 598 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3_ = (g_free (_tmp3_), NULL);
-#line 4587 "book.c"
+#line 4972 "book.c"
}
@@ -4592,235 +4977,235 @@ guint pdf_writer_start_object (PDFWriter* self) {
gsize _tmp0_ = 0UL;
GList* _tmp1_ = NULL;
guint _tmp2_ = 0U;
-#line 548 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 601 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (self != NULL, 0U);
-#line 550 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 603 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = self->offset;
-#line 550 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 603 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self->object_offsets = g_list_append (self->object_offsets, (gpointer) ((guintptr) ((guint) _tmp0_)));
-#line 551 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 604 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = self->object_offsets;
-#line 551 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 604 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = g_list_length (_tmp1_);
-#line 551 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 604 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
result = _tmp2_;
-#line 551 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 604 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 4610 "book.c"
+#line 4995 "book.c"
}
static void value_pdf_writer_init (GValue* value) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = NULL;
-#line 4617 "book.c"
+#line 5002 "book.c"
}
static void value_pdf_writer_free_value (GValue* value) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (value->data[0].v_pointer) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
pdf_writer_unref (value->data[0].v_pointer);
-#line 4626 "book.c"
+#line 5011 "book.c"
}
}
static void value_pdf_writer_copy_value (const GValue* src_value, GValue* dest_value) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (src_value->data[0].v_pointer) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
dest_value->data[0].v_pointer = pdf_writer_ref (src_value->data[0].v_pointer);
-#line 4636 "book.c"
+#line 5021 "book.c"
} else {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
dest_value->data[0].v_pointer = NULL;
-#line 4640 "book.c"
+#line 5025 "book.c"
}
}
static gpointer value_pdf_writer_peek_pointer (const GValue* value) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return value->data[0].v_pointer;
-#line 4648 "book.c"
+#line 5033 "book.c"
}
static gchar* value_pdf_writer_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (collect_values[0].v_pointer) {
-#line 4655 "book.c"
+#line 5040 "book.c"
PDFWriter* object;
object = collect_values[0].v_pointer;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (object->parent_instance.g_class == NULL) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
-#line 4662 "book.c"
+#line 5047 "book.c"
} else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
-#line 4666 "book.c"
+#line 5051 "book.c"
}
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = pdf_writer_ref (object);
-#line 4670 "book.c"
+#line 5055 "book.c"
} else {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = NULL;
-#line 4674 "book.c"
+#line 5059 "book.c"
}
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return NULL;
-#line 4678 "book.c"
+#line 5063 "book.c"
}
static gchar* value_pdf_writer_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
PDFWriter** object_p;
object_p = collect_values[0].v_pointer;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (!object_p) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value));
-#line 4689 "book.c"
+#line 5074 "book.c"
}
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (!value->data[0].v_pointer) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
*object_p = NULL;
-#line 4695 "book.c"
+#line 5080 "book.c"
} else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
*object_p = value->data[0].v_pointer;
-#line 4699 "book.c"
+#line 5084 "book.c"
} else {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
*object_p = pdf_writer_ref (value->data[0].v_pointer);
-#line 4703 "book.c"
+#line 5088 "book.c"
}
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return NULL;
-#line 4707 "book.c"
+#line 5092 "book.c"
}
GParamSpec* param_spec_pdf_writer (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) {
ParamSpecPDFWriter* spec;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (g_type_is_a (object_type, TYPE_PDF_WRITER), NULL);
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags);
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
G_PARAM_SPEC (spec)->value_type = object_type;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return G_PARAM_SPEC (spec);
-#line 4721 "book.c"
+#line 5106 "book.c"
}
gpointer value_get_pdf_writer (const GValue* value) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PDF_WRITER), NULL);
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return value->data[0].v_pointer;
-#line 4730 "book.c"
+#line 5115 "book.c"
}
void value_set_pdf_writer (GValue* value, gpointer v_object) {
PDFWriter* old;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PDF_WRITER));
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
old = value->data[0].v_pointer;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (v_object) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PDF_WRITER));
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = v_object;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
pdf_writer_ref (value->data[0].v_pointer);
-#line 4750 "book.c"
+#line 5135 "book.c"
} else {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = NULL;
-#line 4754 "book.c"
+#line 5139 "book.c"
}
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (old) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
pdf_writer_unref (old);
-#line 4760 "book.c"
+#line 5145 "book.c"
}
}
void value_take_pdf_writer (GValue* value, gpointer v_object) {
PDFWriter* old;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PDF_WRITER));
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
old = value->data[0].v_pointer;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (v_object) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PDF_WRITER));
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = v_object;
-#line 4779 "book.c"
+#line 5164 "book.c"
} else {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = NULL;
-#line 4783 "book.c"
+#line 5168 "book.c"
}
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (old) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
pdf_writer_unref (old);
-#line 4789 "book.c"
+#line 5174 "book.c"
}
}
static void pdf_writer_class_init (PDFWriterClass * klass) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
pdf_writer_parent_class = g_type_class_peek_parent (klass);
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
PDF_WRITER_CLASS (klass)->finalize = pdf_writer_finalize;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_type_class_add_private (klass, sizeof (PDFWriterPrivate));
-#line 4801 "book.c"
+#line 5186 "book.c"
}
static void pdf_writer_instance_init (PDFWriter * self) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self->priv = PDF_WRITER_GET_PRIVATE (self);
-#line 521 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 574 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self->offset = (gsize) 0;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self->ref_count = 1;
-#line 4812 "book.c"
+#line 5197 "book.c"
}
static void pdf_writer_finalize (PDFWriter* obj) {
PDFWriter * self;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_PDF_WRITER, PDFWriter);
-#line 522 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 575 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_list_free0 (self->object_offsets);
-#line 523 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 576 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_object_unref0 (self->priv->stream);
-#line 4824 "book.c"
+#line 5209 "book.c"
}
@@ -4841,34 +5226,34 @@ GType pdf_writer_get_type (void) {
gpointer pdf_writer_ref (gpointer instance) {
PDFWriter* self;
self = instance;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_atomic_int_inc (&self->ref_count);
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return instance;
-#line 4849 "book.c"
+#line 5234 "book.c"
}
void pdf_writer_unref (gpointer instance) {
PDFWriter* self;
self = instance;
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (g_atomic_int_dec_and_test (&self->ref_count)) {
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
PDF_WRITER_GET_CLASS (self)->finalize (self);
-#line 519 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_type_free_instance ((GTypeInstance *) self);
-#line 4862 "book.c"
+#line 5247 "book.c"
}
}
static cairo_status_t _ps_writer_write_cairo_data_cairo_write_func_t (gpointer self, guchar* data, int data_length1) {
cairo_status_t result;
- result = ps_writer_write_cairo_data (self, data, data_length1);
-#line 563 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ result = ps_writer_write_cairo_data ((PsWriter*) self, data, data_length1);
+#line 616 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 4872 "book.c"
+#line 5257 "book.c"
}
@@ -4877,58 +5262,58 @@ PsWriter* ps_writer_construct (GType object_type, GFileOutputStream* stream) {
GFileOutputStream* _tmp0_ = NULL;
GFileOutputStream* _tmp1_ = NULL;
cairo_surface_t* _tmp2_ = NULL;
-#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 613 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (stream != NULL, NULL);
-#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 613 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self = (PsWriter*) g_type_create_instance (object_type);
-#line 562 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 615 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = stream;
-#line 562 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 615 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = _g_object_ref0 (_tmp0_);
-#line 562 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 615 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_object_unref0 (self->stream);
-#line 562 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 615 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self->stream = _tmp1_;
-#line 563 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 616 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = cairo_ps_surface_create_for_stream (_ps_writer_write_cairo_data_cairo_write_func_t, self, (gdouble) 0, (gdouble) 0);
-#line 563 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 616 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_cairo_surface_destroy0 (self->surface);
-#line 563 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 616 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self->surface = _tmp2_;
-#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 613 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return self;
-#line 4901 "book.c"
+#line 5286 "book.c"
}
PsWriter* ps_writer_new (GFileOutputStream* stream) {
-#line 560 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 613 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return ps_writer_construct (TYPE_PS_WRITER, stream);
-#line 4908 "book.c"
+#line 5293 "book.c"
}
static cairo_status_t ps_writer_write_cairo_data (PsWriter* self, guint8* data, int data_length1) {
cairo_status_t result = 0;
GError * _inner_error_ = NULL;
-#line 566 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 619 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (self != NULL, 0);
-#line 4917 "book.c"
+#line 5302 "book.c"
{
GFileOutputStream* _tmp0_ = NULL;
guint8* _tmp1_ = NULL;
gint _tmp1__length1 = 0;
-#line 570 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 623 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp0_ = self->stream;
-#line 570 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 623 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1_ = data;
-#line 570 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 623 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp1__length1 = data_length1;
-#line 570 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 623 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_output_stream_write_all ((GOutputStream*) _tmp0_, _tmp1_, (gsize) _tmp1__length1, NULL, NULL, &_inner_error_);
-#line 570 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 623 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_inner_error_ != NULL) {
-#line 4932 "book.c"
+#line 5317 "book.c"
goto __catch2_g_error;
}
}
@@ -4938,248 +5323,248 @@ static cairo_status_t ps_writer_write_cairo_data (PsWriter* self, guint8* data,
GError* e = NULL;
GError* _tmp2_ = NULL;
const gchar* _tmp3_ = NULL;
-#line 568 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
e = _inner_error_;
-#line 568 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_inner_error_ = NULL;
-#line 574 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp2_ = e;
-#line 574 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_tmp3_ = _tmp2_->message;
-#line 574 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
- g_warning ("book.vala:574: Error writing data: %s", _tmp3_);
-#line 575 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 627 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+ g_warning ("book.vala:627: Error writing data: %s", _tmp3_);
+#line 628 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
result = CAIRO_STATUS_WRITE_ERROR;
-#line 575 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 628 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_error_free0 (e);
-#line 575 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 628 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 4958 "book.c"
+#line 5343 "book.c"
}
__finally2:
-#line 568 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (_inner_error_ != NULL) {
-#line 568 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_critical ("file %s: line %d: uncaught error: %s (%s, %d)", __FILE__, __LINE__, _inner_error_->message, g_quark_to_string (_inner_error_->domain), _inner_error_->code);
-#line 568 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_clear_error (&_inner_error_);
-#line 568 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return 0;
-#line 4969 "book.c"
+#line 5354 "book.c"
}
-#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 631 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
result = CAIRO_STATUS_SUCCESS;
-#line 578 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 631 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return result;
-#line 4975 "book.c"
+#line 5360 "book.c"
}
static void value_ps_writer_init (GValue* value) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = NULL;
-#line 4982 "book.c"
+#line 5367 "book.c"
}
static void value_ps_writer_free_value (GValue* value) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (value->data[0].v_pointer) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
ps_writer_unref (value->data[0].v_pointer);
-#line 4991 "book.c"
+#line 5376 "book.c"
}
}
static void value_ps_writer_copy_value (const GValue* src_value, GValue* dest_value) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (src_value->data[0].v_pointer) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
dest_value->data[0].v_pointer = ps_writer_ref (src_value->data[0].v_pointer);
-#line 5001 "book.c"
+#line 5386 "book.c"
} else {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
dest_value->data[0].v_pointer = NULL;
-#line 5005 "book.c"
+#line 5390 "book.c"
}
}
static gpointer value_ps_writer_peek_pointer (const GValue* value) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return value->data[0].v_pointer;
-#line 5013 "book.c"
+#line 5398 "book.c"
}
static gchar* value_ps_writer_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (collect_values[0].v_pointer) {
-#line 5020 "book.c"
+#line 5405 "book.c"
PsWriter* object;
object = collect_values[0].v_pointer;
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (object->parent_instance.g_class == NULL) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
-#line 5027 "book.c"
+#line 5412 "book.c"
} else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return g_strconcat ("invalid object type `", g_type_name (G_TYPE_FROM_INSTANCE (object)), "' for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
-#line 5031 "book.c"
+#line 5416 "book.c"
}
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = ps_writer_ref (object);
-#line 5035 "book.c"
+#line 5420 "book.c"
} else {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = NULL;
-#line 5039 "book.c"
+#line 5424 "book.c"
}
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return NULL;
-#line 5043 "book.c"
+#line 5428 "book.c"
}
static gchar* value_ps_writer_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
PsWriter** object_p;
object_p = collect_values[0].v_pointer;
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (!object_p) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value));
-#line 5054 "book.c"
+#line 5439 "book.c"
}
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (!value->data[0].v_pointer) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
*object_p = NULL;
-#line 5060 "book.c"
+#line 5445 "book.c"
} else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
*object_p = value->data[0].v_pointer;
-#line 5064 "book.c"
+#line 5449 "book.c"
} else {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
*object_p = ps_writer_ref (value->data[0].v_pointer);
-#line 5068 "book.c"
+#line 5453 "book.c"
}
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return NULL;
-#line 5072 "book.c"
+#line 5457 "book.c"
}
GParamSpec* param_spec_ps_writer (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) {
ParamSpecPsWriter* spec;
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (g_type_is_a (object_type, TYPE_PS_WRITER), NULL);
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags);
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
G_PARAM_SPEC (spec)->value_type = object_type;
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return G_PARAM_SPEC (spec);
-#line 5086 "book.c"
+#line 5471 "book.c"
}
gpointer value_get_ps_writer (const GValue* value) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PS_WRITER), NULL);
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return value->data[0].v_pointer;
-#line 5095 "book.c"
+#line 5480 "book.c"
}
void value_set_ps_writer (GValue* value, gpointer v_object) {
PsWriter* old;
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PS_WRITER));
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
old = value->data[0].v_pointer;
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (v_object) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PS_WRITER));
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = v_object;
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
ps_writer_ref (value->data[0].v_pointer);
-#line 5115 "book.c"
+#line 5500 "book.c"
} else {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = NULL;
-#line 5119 "book.c"
+#line 5504 "book.c"
}
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (old) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
ps_writer_unref (old);
-#line 5125 "book.c"
+#line 5510 "book.c"
}
}
void value_take_ps_writer (GValue* value, gpointer v_object) {
PsWriter* old;
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PS_WRITER));
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
old = value->data[0].v_pointer;
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (v_object) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PS_WRITER));
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = v_object;
-#line 5144 "book.c"
+#line 5529 "book.c"
} else {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
value->data[0].v_pointer = NULL;
-#line 5148 "book.c"
+#line 5533 "book.c"
}
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (old) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
ps_writer_unref (old);
-#line 5154 "book.c"
+#line 5539 "book.c"
}
}
static void ps_writer_class_init (PsWriterClass * klass) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
ps_writer_parent_class = g_type_class_peek_parent (klass);
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
PS_WRITER_CLASS (klass)->finalize = ps_writer_finalize;
-#line 5164 "book.c"
+#line 5549 "book.c"
}
static void ps_writer_instance_init (PsWriter * self) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self->ref_count = 1;
-#line 5171 "book.c"
+#line 5556 "book.c"
}
static void ps_writer_finalize (PsWriter* obj) {
PsWriter * self;
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_PS_WRITER, PsWriter);
-#line 557 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 610 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_cairo_surface_destroy0 (self->surface);
-#line 558 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 611 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
_g_object_unref0 (self->stream);
-#line 5183 "book.c"
+#line 5568 "book.c"
}
@@ -5200,24 +5585,24 @@ GType ps_writer_get_type (void) {
gpointer ps_writer_ref (gpointer instance) {
PsWriter* self;
self = instance;
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_atomic_int_inc (&self->ref_count);
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
return instance;
-#line 5208 "book.c"
+#line 5593 "book.c"
}
void ps_writer_unref (gpointer instance) {
PsWriter* self;
self = instance;
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
if (g_atomic_int_dec_and_test (&self->ref_count)) {
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
PS_WRITER_GET_CLASS (self)->finalize (self);
-#line 555 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
+#line 608 "/home/bob/bzr/simple-scan/trunk/src/book.vala"
g_type_free_instance ((GTypeInstance *) self);
-#line 5221 "book.c"
+#line 5606 "book.c"
}
}