summaryrefslogtreecommitdiff
path: root/src/page.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/page.c')
-rw-r--r--src/page.c6306
1 files changed, 3311 insertions, 2995 deletions
diff --git a/src/page.c b/src/page.c
index eee78d1..d870104 100644
--- a/src/page.c
+++ b/src/page.c
@@ -1,4 +1,4 @@
-/* page.c generated by valac 0.20.1, the Vala compiler
+/* page.c generated by valac 0.22.1, the Vala compiler
* generated from page.vala, do not modify */
/*
@@ -97,27 +97,27 @@ struct _PageClass {
};
struct _PagePrivate {
- gint dpi;
+ gint _dpi;
gint expected_rows;
- gint depth;
- gchar* color_profile;
- gint width;
- gint n_rows;
- gint rowstride;
- gint n_channels;
+ gint _depth;
+ gchar* _color_profile;
+ gint _scan_width;
+ gint _scan_height;
+ gint _rowstride;
+ gint _n_channels;
guchar* pixels;
gint pixels_length1;
gint _pixels_size_;
- gboolean scanning;
- gboolean has_data_;
- gint scan_line;
- ScanDirection scan_direction;
- gboolean has_crop_;
- gchar* crop_name;
- gint crop_x;
- gint crop_y;
- gint crop_width;
- gint crop_height;
+ gboolean _is_scanning;
+ gboolean _has_data;
+ gint _scan_line;
+ ScanDirection scan_direction_;
+ gboolean _has_crop;
+ gchar* _crop_name;
+ gint _crop_x;
+ gint _crop_y;
+ gint _crop_width;
+ gint _crop_height;
};
struct _ScanPageInfo {
@@ -194,6 +194,24 @@ enum {
};
Page* page_new (gint width, gint height, gint dpi, ScanDirection scan_direction);
Page* page_construct (GType object_type, gint width, gint height, gint dpi, ScanDirection scan_direction);
+static void page_set_scan_width (Page* self, gint value);
+static void page_set_scan_height (Page* self, gint value);
+static void page_set_dpi (Page* self, gint value);
+void page_set_scan_direction (Page* self, ScanDirection value);
+Page* page_new_from_data (gint scan_width, gint scan_height, gint rowstride, gint n_channels, gint depth, gint dpi, ScanDirection scan_direction, const gchar* color_profile, guchar* pixels, int pixels_length1, gboolean has_crop, const gchar* crop_name, gint crop_x, gint crop_y, gint crop_width, gint crop_height);
+Page* page_construct_from_data (GType object_type, gint scan_width, gint scan_height, gint rowstride, gint n_channels, gint depth, gint dpi, ScanDirection scan_direction, const gchar* color_profile, guchar* pixels, int pixels_length1, gboolean has_crop, const gchar* crop_name, gint crop_x, gint crop_y, gint crop_width, gint crop_height);
+static void page_set_rowstride (Page* self, gint value);
+static void page_set_n_channels (Page* self, gint value);
+static void page_set_depth (Page* self, gint value);
+void page_set_color_profile (Page* self, const gchar* value);
+static guchar* _vala_array_dup3 (guchar* self, int length);
+static void page_set_has_data (Page* self, gboolean value);
+static void page_set_has_crop (Page* self, gboolean value);
+static void page_set_crop_name (Page* self, const gchar* value);
+static void page_set_crop_x (Page* self, gint value);
+static void page_set_crop_y (Page* self, gint value);
+static void page_set_crop_width (Page* self, gint value);
+static void page_set_crop_height (Page* self, gint value);
gpointer scan_page_info_ref (gpointer instance);
void scan_page_info_unref (gpointer instance);
GParamSpec* param_spec_scan_page_info (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
@@ -202,11 +220,13 @@ void value_take_scan_page_info (GValue* value, gpointer v_object);
gpointer value_get_scan_page_info (const GValue* value);
GType scan_page_info_get_type (void) G_GNUC_CONST;
void page_set_page_info (Page* self, ScanPageInfo* info);
+gint page_get_scan_height (Page* self);
+gint page_get_scan_width (Page* self);
+gint page_get_depth (Page* self);
+gint page_get_n_channels (Page* self);
+gint page_get_rowstride (Page* self);
void page_start (Page* self);
-gboolean page_is_scanning (Page* self);
-gboolean page_has_data (Page* self);
-gboolean page_is_color (Page* self);
-gint page_get_scan_line (Page* self);
+static void page_set_is_scanning (Page* self, gboolean value);
gpointer scan_line_ref (gpointer instance);
void scan_line_unref (gpointer instance);
GParamSpec* param_spec_scan_line (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
@@ -215,42 +235,34 @@ void value_take_scan_line (GValue* value, gpointer v_object);
gpointer value_get_scan_line (const GValue* value);
GType scan_line_get_type (void) G_GNUC_CONST;
static void page_parse_line (Page* self, ScanLine* line, gint n, gboolean* size_changed);
-gint page_get_scan_height (Page* self);
+static void page_set_scan_line (Page* self, gint value);
void page_parse_scan_line (Page* self, ScanLine* line);
void page_finish (Page* self);
-ScanDirection page_get_scan_direction (Page* self);
-static void page_set_scan_direction (Page* self, ScanDirection direction);
-gint page_get_width (Page* self);
-gint page_get_height (Page* self);
+gint page_get_scan_line (Page* self);
void page_rotate_left (Page* self);
+ScanDirection page_get_scan_direction (Page* self);
void page_rotate_right (Page* self);
-gint page_get_dpi (Page* self);
-gboolean page_is_landscape (Page* self);
-gint page_get_depth (Page* self);
-gint page_get_n_channels (Page* self);
-gint page_get_rowstride (Page* self);
-gint page_get_scan_width (Page* self);
-void page_set_color_profile (Page* self, const gchar* color_profile);
-gchar* page_get_color_profile (Page* self);
void page_set_no_crop (Page* self);
+gboolean page_get_has_crop (Page* self);
void page_set_custom_crop (Page* self, gint width, gint height);
+const gchar* page_get_crop_name (Page* self);
+gint page_get_crop_width (Page* self);
+gint page_get_crop_height (Page* self);
void page_set_named_crop (Page* self, const gchar* name);
+gint page_get_width (Page* self);
+gint page_get_height (Page* self);
+gint page_get_dpi (Page* self);
void page_move_crop (Page* self, gint x, gint y);
void page_rotate_crop (Page* self);
-gboolean page_has_crop (Page* self);
-void page_get_crop (Page* self, gint* x, gint* y, gint* width, gint* height);
-gchar* page_get_named_crop (Page* self);
+gint page_get_crop_x (Page* self);
+gint page_get_crop_y (Page* self);
guchar* page_get_pixels (Page* self, int* result_length1);
-void page_set_pixels (Page* self, guchar* new_pixels, int new_pixels_length1);
-static guchar* _vala_array_dup3 (guchar* self, int length);
static guchar page_get_sample (Page* self, guchar* pixels, int pixels_length1, gint offset, gint x, gint depth, gint n_channels, gint channel);
static void page_get_pixel (Page* self, gint x, gint y, guchar* pixel, int pixel_length1, gint offset);
GdkPixbuf* page_get_image (Page* self, gboolean apply_crop);
static gchar* page_get_icc_data_encoded (Page* self, const gchar* icc_profile_filename);
void page_copy_to_clipboard (Page* self, GtkWindow* window);
void page_save (Page* self, const gchar* type, gint quality, GFile* file, GError** error);
-PixbufWriter* pixbuf_writer_new (GFileOutputStream* stream);
-PixbufWriter* pixbuf_writer_construct (GType object_type, GFileOutputStream* stream);
gpointer pixbuf_writer_ref (gpointer instance);
void pixbuf_writer_unref (gpointer instance);
GParamSpec* param_spec_pixbuf_writer (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags);
@@ -258,7 +270,14 @@ void value_set_pixbuf_writer (GValue* value, gpointer v_object);
void value_take_pixbuf_writer (GValue* value, gpointer v_object);
gpointer value_get_pixbuf_writer (const GValue* value);
GType pixbuf_writer_get_type (void) G_GNUC_CONST;
+PixbufWriter* pixbuf_writer_new (GFileOutputStream* stream);
+PixbufWriter* pixbuf_writer_construct (GType object_type, GFileOutputStream* stream);
+const gchar* page_get_color_profile (Page* self);
void pixbuf_writer_save (PixbufWriter* self, GdkPixbuf* image, const gchar* type, gchar** option_keys, int option_keys_length1, gchar** option_values, int option_values_length1, GError** error);
+gboolean page_get_is_landscape (Page* self);
+gboolean page_get_is_scanning (Page* self);
+gboolean page_get_has_data (Page* self);
+gboolean page_get_is_color (Page* self);
static void page_finalize (Page* obj);
enum {
PIXBUF_WRITER_DUMMY_PROPERTY
@@ -285,2674 +304,2125 @@ GType scan_direction_get_type (void) {
Page* page_construct (GType object_type, gint width, gint height, gint dpi, ScanDirection scan_direction) {
Page* self = NULL;
gboolean _tmp0_ = FALSE;
- ScanDirection _tmp1_;
- gboolean _tmp3_;
- gint _tmp8_;
- ScanDirection _tmp9_;
-#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ ScanDirection _tmp1_ = 0;
+ gboolean _tmp3_ = FALSE;
+ gint _tmp8_ = 0;
+ ScanDirection _tmp9_ = 0;
+#line 174 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self = (Page*) g_type_create_instance (object_type);
-#line 70 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = scan_direction;
-#line 70 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp1_ == SCAN_DIRECTION_TOP_TO_BOTTOM) {
-#line 70 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = TRUE;
-#line 301 "page.c"
+#line 320 "page.c"
} else {
- ScanDirection _tmp2_;
-#line 70 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ ScanDirection _tmp2_ = 0;
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp2_ = scan_direction;
-#line 70 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = _tmp2_ == SCAN_DIRECTION_BOTTOM_TO_TOP;
-#line 308 "page.c"
+#line 327 "page.c"
}
-#line 70 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = _tmp0_;
-#line 70 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp3_) {
-#line 314 "page.c"
- gint _tmp4_;
- gint _tmp5_;
-#line 72 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 333 "page.c"
+ gint _tmp4_ = 0;
+ gint _tmp5_ = 0;
+#line 178 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp4_ = width;
-#line 72 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->width = _tmp4_;
-#line 73 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 178 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_width (self, _tmp4_);
+#line 179 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp5_ = height;
-#line 73 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->n_rows = _tmp5_;
-#line 325 "page.c"
+#line 179 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_height (self, _tmp5_);
+#line 344 "page.c"
} else {
- gint _tmp6_;
- gint _tmp7_;
-#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint _tmp6_ = 0;
+ gint _tmp7_ = 0;
+#line 183 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp6_ = height;
-#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->width = _tmp6_;
-#line 78 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 183 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_width (self, _tmp6_);
+#line 184 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp7_ = width;
-#line 78 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->n_rows = _tmp7_;
-#line 337 "page.c"
+#line 184 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_height (self, _tmp7_);
+#line 356 "page.c"
}
-#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 186 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp8_ = dpi;
-#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->dpi = _tmp8_;
-#line 81 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 186 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_dpi (self, _tmp8_);
+#line 187 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp9_ = scan_direction;
-#line 81 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->scan_direction = _tmp9_;
-#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 187 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_direction (self, _tmp9_);
+#line 174 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return self;
-#line 349 "page.c"
+#line 368 "page.c"
}
Page* page_new (gint width, gint height, gint dpi, ScanDirection scan_direction) {
-#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 174 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return page_construct (TYPE_PAGE, width, height, dpi, scan_direction);
-#line 356 "page.c"
+#line 375 "page.c"
+}
+
+
+static guchar* _vala_array_dup3 (guchar* self, int length) {
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return g_memdup (self, length * sizeof (guchar));
+#line 382 "page.c"
+}
+
+
+Page* page_construct_from_data (GType object_type, gint scan_width, gint scan_height, gint rowstride, gint n_channels, gint depth, gint dpi, ScanDirection scan_direction, const gchar* color_profile, guchar* pixels, int pixels_length1, gboolean has_crop, const gchar* crop_name, gint crop_x, gint crop_y, gint crop_width, gint crop_height) {
+ Page* self = NULL;
+ gint _tmp0_ = 0;
+ gint _tmp1_ = 0;
+ gint _tmp2_ = 0;
+ gint _tmp3_ = 0;
+ gint _tmp4_ = 0;
+ gint _tmp5_ = 0;
+ gint _tmp6_ = 0;
+ ScanDirection _tmp7_ = 0;
+ const gchar* _tmp8_ = NULL;
+ guchar* _tmp9_ = NULL;
+ gint _tmp9__length1 = 0;
+ guchar* _tmp10_ = NULL;
+ gint _tmp10__length1 = 0;
+ guchar* _tmp11_ = NULL;
+ gint _tmp11__length1 = 0;
+ gboolean _tmp12_ = FALSE;
+ const gchar* _tmp13_ = NULL;
+ gint _tmp14_ = 0;
+ gint _tmp15_ = 0;
+ gint _tmp16_ = 0;
+ gint _tmp17_ = 0;
+#line 190 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self = (Page*) g_type_create_instance (object_type);
+#line 206 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = scan_width;
+#line 206 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_width (self, _tmp0_);
+#line 207 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp1_ = scan_height;
+#line 207 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_height (self, _tmp1_);
+#line 208 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp2_ = scan_height;
+#line 208 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->expected_rows = _tmp2_;
+#line 209 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp3_ = rowstride;
+#line 209 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_rowstride (self, _tmp3_);
+#line 210 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp4_ = n_channels;
+#line 210 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_n_channels (self, _tmp4_);
+#line 211 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp5_ = depth;
+#line 211 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_depth (self, _tmp5_);
+#line 212 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp6_ = dpi;
+#line 212 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_dpi (self, _tmp6_);
+#line 213 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp7_ = scan_direction;
+#line 213 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_direction (self, _tmp7_);
+#line 214 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp8_ = color_profile;
+#line 214 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_color_profile (self, _tmp8_);
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp9_ = pixels;
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp9__length1 = pixels_length1;
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp10_ = (_tmp9_ != NULL) ? _vala_array_dup3 (_tmp9_, _tmp9__length1) : ((gpointer) _tmp9_);
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp10__length1 = _tmp9__length1;
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->pixels = (g_free (self->priv->pixels), NULL);
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->pixels = _tmp10_;
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->pixels_length1 = _tmp10__length1;
+#line 215 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_pixels_size_ = self->priv->pixels_length1;
+#line 216 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp11_ = pixels;
+#line 216 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp11__length1 = pixels_length1;
+#line 216 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_has_data (self, _tmp11_ != NULL);
+#line 217 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp12_ = has_crop;
+#line 217 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_has_crop (self, _tmp12_);
+#line 218 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp13_ = crop_name;
+#line 218 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_name (self, _tmp13_);
+#line 219 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp14_ = crop_x;
+#line 219 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_x (self, _tmp14_);
+#line 220 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp15_ = crop_y;
+#line 220 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_y (self, _tmp15_);
+#line 221 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp16_ = crop_width;
+#line 221 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_width (self, _tmp16_);
+#line 222 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp17_ = crop_height;
+#line 222 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_height (self, _tmp17_);
+#line 190 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return self;
+#line 495 "page.c"
+}
+
+
+Page* page_new_from_data (gint scan_width, gint scan_height, gint rowstride, gint n_channels, gint depth, gint dpi, ScanDirection scan_direction, const gchar* color_profile, guchar* pixels, int pixels_length1, gboolean has_crop, const gchar* crop_name, gint crop_x, gint crop_y, gint crop_width, gint crop_height) {
+#line 190 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return page_construct_from_data (TYPE_PAGE, scan_width, scan_height, rowstride, n_channels, depth, dpi, scan_direction, color_profile, pixels, pixels_length1, has_crop, crop_name, crop_x, crop_y, crop_width, crop_height);
+#line 502 "page.c"
}
void page_set_page_info (Page* self, ScanPageInfo* info) {
- ScanPageInfo* _tmp0_;
- gint _tmp1_;
- ScanPageInfo* _tmp2_;
- gdouble _tmp3_;
- ScanPageInfo* _tmp4_;
- gint _tmp5_;
- ScanPageInfo* _tmp6_;
- gint _tmp7_;
- gint _tmp8_;
- ScanPageInfo* _tmp10_;
- gint _tmp11_;
- ScanPageInfo* _tmp12_;
- gint _tmp13_;
- gint _tmp14_;
- gint _tmp15_;
- gint _tmp16_;
- gint _tmp17_;
- gint _tmp18_;
+ ScanPageInfo* _tmp0_ = NULL;
+ gint _tmp1_ = 0;
+ ScanPageInfo* _tmp2_ = NULL;
+ gdouble _tmp3_ = 0.0;
+ ScanPageInfo* _tmp4_ = NULL;
+ gint _tmp5_ = 0;
+ ScanPageInfo* _tmp6_ = NULL;
+ gint _tmp7_ = 0;
+ gint _tmp8_ = 0;
+ ScanPageInfo* _tmp10_ = NULL;
+ gint _tmp11_ = 0;
+ ScanPageInfo* _tmp12_ = NULL;
+ gint _tmp13_ = 0;
+ gint _tmp14_ = 0;
+ gint _tmp15_ = 0;
+ gint _tmp16_ = 0;
+ gint _tmp17_ = 0;
+ gint _tmp18_ = 0;
gint _tmp19_ = 0;
- guchar* _tmp20_;
- gint _tmp20__length1;
- gint _tmp21_;
-#line 84 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ guchar* _tmp20_ = NULL;
+ gint _tmp20__length1 = 0;
+ gint _tmp21_ = 0;
+#line 225 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 84 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 225 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (info != NULL);
-#line 86 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 227 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = info;
-#line 86 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 227 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = _tmp0_->height;
-#line 86 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 227 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->priv->expected_rows = _tmp1_;
-#line 87 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 228 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp2_ = info;
-#line 87 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 228 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = _tmp2_->dpi;
-#line 87 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->dpi = (gint) _tmp3_;
-#line 90 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 228 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_dpi (self, (gint) _tmp3_);
+#line 231 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp4_ = info;
-#line 90 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 231 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp5_ = _tmp4_->width;
-#line 90 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->width = _tmp5_;
-#line 91 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 231 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_width (self, _tmp5_);
+#line 232 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp6_ = info;
-#line 91 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 232 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp7_ = _tmp6_->height;
-#line 91 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->n_rows = _tmp7_;
-#line 93 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp8_ = self->priv->n_rows;
-#line 93 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 232 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_height (self, _tmp7_);
+#line 234 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp8_ = self->priv->_scan_height;
+#line 234 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp8_ < 0) {
-#line 415 "page.c"
- gint _tmp9_;
-#line 94 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp9_ = self->priv->width;
-#line 94 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->n_rows = _tmp9_ / 2;
-#line 421 "page.c"
+#line 561 "page.c"
+ gint _tmp9_ = 0;
+#line 235 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp9_ = self->priv->_scan_width;
+#line 235 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_height (self, _tmp9_ / 2);
+#line 567 "page.c"
}
-#line 95 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp10_ = info;
-#line 95 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp11_ = _tmp10_->depth;
-#line 95 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->depth = _tmp11_;
-#line 96 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 236 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_depth (self, _tmp11_);
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp12_ = info;
-#line 96 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp13_ = _tmp12_->n_channels;
-#line 96 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->n_channels = _tmp13_;
-#line 97 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp14_ = self->priv->width;
-#line 97 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp15_ = self->priv->depth;
-#line 97 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp16_ = self->priv->n_channels;
-#line 97 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->rowstride = (((_tmp14_ * _tmp15_) * _tmp16_) + 7) / 8;
-#line 98 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp17_ = self->priv->n_rows;
-#line 98 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp18_ = self->priv->rowstride;
-#line 98 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 237 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_n_channels (self, _tmp13_);
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp14_ = self->priv->_scan_width;
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp15_ = self->priv->_depth;
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp16_ = self->priv->_n_channels;
+#line 238 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_rowstride (self, (((_tmp14_ * _tmp15_) * _tmp16_) + 7) / 8);
+#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp17_ = self->priv->_scan_height;
+#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp18_ = self->priv->_rowstride;
+#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp19_ = _tmp17_ * _tmp18_;
-#line 98 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->priv->pixels = g_renew (guchar, self->priv->pixels, _tmp17_ * _tmp18_);
-#line 98 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
(_tmp19_ > self->priv->pixels_length1) ? memset (self->priv->pixels + self->priv->pixels_length1, 0, sizeof (guchar) * (_tmp19_ - self->priv->pixels_length1)) : NULL;
-#line 98 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->priv->pixels_length1 = _tmp19_;
-#line 98 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->priv->_pixels_size_ = _tmp19_;
-#line 99 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 240 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp20_ = self->priv->pixels;
-#line 99 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 240 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp20__length1 = self->priv->pixels_length1;
-#line 99 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 240 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (_tmp20_ != NULL);
-#line 102 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp21_ = self->priv->depth;
-#line 102 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 243 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp21_ = self->priv->_depth;
+#line 243 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp21_ == 1) {
-#line 467 "page.c"
- guchar* _tmp22_;
- gint _tmp22__length1;
- gint _tmp23_;
- gint _tmp24_;
-#line 103 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 613 "page.c"
+ guchar* _tmp22_ = NULL;
+ gint _tmp22__length1 = 0;
+ gint _tmp23_ = 0;
+ gint _tmp24_ = 0;
+#line 244 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp22_ = self->priv->pixels;
-#line 103 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 244 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp22__length1 = self->priv->pixels_length1;
-#line 103 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp23_ = self->priv->n_rows;
-#line 103 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp24_ = self->priv->rowstride;
-#line 103 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 244 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp23_ = self->priv->_scan_height;
+#line 244 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp24_ = self->priv->_rowstride;
+#line 244 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
memset (_tmp22_, 0x00, (gsize) (_tmp23_ * _tmp24_));
-#line 482 "page.c"
+#line 628 "page.c"
} else {
- guchar* _tmp25_;
- gint _tmp25__length1;
- gint _tmp26_;
- gint _tmp27_;
-#line 105 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ guchar* _tmp25_ = NULL;
+ gint _tmp25__length1 = 0;
+ gint _tmp26_ = 0;
+ gint _tmp27_ = 0;
+#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp25_ = self->priv->pixels;
-#line 105 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp25__length1 = self->priv->pixels_length1;
-#line 105 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp26_ = self->priv->n_rows;
-#line 105 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp27_ = self->priv->rowstride;
-#line 105 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp26_ = self->priv->_scan_height;
+#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp27_ = self->priv->_rowstride;
+#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
memset (_tmp25_, 0xFF, (gsize) (_tmp26_ * _tmp27_));
-#line 498 "page.c"
+#line 644 "page.c"
}
-#line 107 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 248 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "size-changed");
-#line 108 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 249 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "pixels-changed");
-#line 504 "page.c"
+#line 650 "page.c"
}
void page_start (Page* self) {
-#line 111 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 252 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 113 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->scanning = TRUE;
-#line 114 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 254 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_is_scanning (self, TRUE);
+#line 255 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "scan-line-changed");
-#line 515 "page.c"
-}
-
-
-gboolean page_is_scanning (Page* self) {
- gboolean result = FALSE;
- gboolean _tmp0_;
-#line 117 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, FALSE);
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->scanning;
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_;
-#line 119 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 530 "page.c"
-}
-
-
-gboolean page_has_data (Page* self) {
- gboolean result = FALSE;
- gboolean _tmp0_;
-#line 122 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, FALSE);
-#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->has_data_;
-#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_;
-#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 545 "page.c"
-}
-
-
-gboolean page_is_color (Page* self) {
- gboolean result = FALSE;
- gint _tmp0_;
-#line 127 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, FALSE);
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->n_channels;
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_ > 1;
-#line 129 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 560 "page.c"
-}
-
-
-gint page_get_scan_line (Page* self) {
- gint result = 0;
- gint _tmp0_;
-#line 132 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, 0);
-#line 134 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->scan_line;
-#line 134 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_;
-#line 134 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 575 "page.c"
+#line 661 "page.c"
}
static void page_parse_line (Page* self, ScanLine* line, gint n, gboolean* size_changed) {
gboolean _vala_size_changed = FALSE;
gint line_number = 0;
- ScanLine* _tmp0_;
- gint _tmp1_;
- gint _tmp2_;
- gint _tmp13_;
- gint _tmp14_;
- gint offset;
- gint _tmp15_;
- ScanLine* _tmp16_;
- gint _tmp17_;
- gint line_offset;
- gint _tmp33_;
-#line 137 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ ScanLine* _tmp0_ = NULL;
+ gint _tmp1_ = 0;
+ gint _tmp2_ = 0;
+ gint offset = 0;
+ gint _tmp13_ = 0;
+ gint _tmp14_ = 0;
+ gint line_offset = 0;
+ gint _tmp15_ = 0;
+ ScanLine* _tmp16_ = NULL;
+ gint _tmp17_ = 0;
+ gint _tmp33_ = 0;
+#line 258 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 137 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 258 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (line != NULL);
-#line 141 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 260 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = line;
-#line 141 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 260 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = _tmp0_->number;
-#line 141 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 260 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp2_ = n;
-#line 141 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 260 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
line_number = _tmp1_ + _tmp2_;
-#line 144 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 263 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_vala_size_changed = FALSE;
-#line 145 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 264 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
while (TRUE) {
-#line 609 "page.c"
- gint _tmp3_;
+#line 695 "page.c"
+ gint _tmp3_ = 0;
gint _tmp4_ = 0;
gint rows = 0;
- gint _tmp5_;
- gint _tmp6_;
- gint _tmp7_;
- gint _tmp8_;
- gint _tmp9_;
- gint _tmp10_;
- gint _tmp11_;
+ gint _tmp5_ = 0;
+ gint _tmp6_ = 0;
+ gint _tmp7_ = 0;
+ gint _tmp8_ = 0;
+ gint _tmp9_ = 0;
+ gint _tmp10_ = 0;
+ gint _tmp11_ = 0;
gint _tmp12_ = 0;
-#line 145 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 264 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = line_number;
-#line 145 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp4_ = page_get_scan_height (self);
-#line 145 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 264 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp4_ = self->priv->_scan_height;
+#line 264 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (!(_tmp3_ >= _tmp4_)) {
-#line 145 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 264 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 629 "page.c"
+#line 715 "page.c"
}
-#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp5_ = self->priv->n_rows;
-#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 267 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp5_ = self->priv->_scan_height;
+#line 267 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
rows = _tmp5_;
-#line 151 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 268 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp6_ = rows;
-#line 151 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp7_ = self->priv->width;
-#line 151 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->n_rows = _tmp6_ + (_tmp7_ / 2);
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 268 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp7_ = self->priv->_scan_width;
+#line 268 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_height (self, _tmp6_ + (_tmp7_ / 2));
+#line 269 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp8_ = rows;
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp9_ = self->priv->n_rows;
-#line 152 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_debug ("page.vala:152: Extending image from %d lines to %d lines", _tmp8_, _tmp9_);
-#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp10_ = self->priv->n_rows;
-#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp11_ = self->priv->rowstride;
-#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 269 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp9_ = self->priv->_scan_height;
+#line 269 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_debug ("page.vala:269: Extending image from %d lines to %d lines", _tmp8_, _tmp9_);
+#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp10_ = self->priv->_scan_height;
+#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp11_ = self->priv->_rowstride;
+#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp12_ = _tmp10_ * _tmp11_;
-#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->priv->pixels = g_renew (guchar, self->priv->pixels, _tmp10_ * _tmp11_);
-#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
(_tmp12_ > self->priv->pixels_length1) ? memset (self->priv->pixels + self->priv->pixels_length1, 0, sizeof (guchar) * (_tmp12_ - self->priv->pixels_length1)) : NULL;
-#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->priv->pixels_length1 = _tmp12_;
-#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 270 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->priv->_pixels_size_ = _tmp12_;
-#line 155 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 272 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_vala_size_changed = TRUE;
-#line 663 "page.c"
+#line 749 "page.c"
}
-#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 276 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp13_ = line_number;
-#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp14_ = self->priv->rowstride;
-#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 276 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp14_ = self->priv->_rowstride;
+#line 276 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
offset = _tmp13_ * _tmp14_;
-#line 160 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 277 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp15_ = n;
-#line 160 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 277 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp16_ = line;
-#line 160 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 277 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp17_ = _tmp16_->data_length;
-#line 160 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 277 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
line_offset = _tmp15_ * _tmp17_;
-#line 679 "page.c"
+#line 765 "page.c"
{
- gint i;
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint i = 0;
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
i = 0;
-#line 684 "page.c"
+#line 770 "page.c"
{
- gboolean _tmp18_;
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gboolean _tmp18_ = FALSE;
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp18_ = TRUE;
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
while (TRUE) {
-#line 691 "page.c"
- gboolean _tmp19_;
- gint _tmp21_;
- ScanLine* _tmp22_;
- gint _tmp23_;
- guchar* _tmp24_;
- gint _tmp24__length1;
- gint _tmp25_;
- gint _tmp26_;
- ScanLine* _tmp27_;
- guchar* _tmp28_;
- gint _tmp28__length1;
- gint _tmp29_;
- gint _tmp30_;
- guchar _tmp31_;
- guchar _tmp32_;
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 777 "page.c"
+ gboolean _tmp19_ = FALSE;
+ gint _tmp21_ = 0;
+ ScanLine* _tmp22_ = NULL;
+ gint _tmp23_ = 0;
+ guchar* _tmp24_ = NULL;
+ gint _tmp24__length1 = 0;
+ gint _tmp25_ = 0;
+ gint _tmp26_ = 0;
+ ScanLine* _tmp27_ = NULL;
+ guchar* _tmp28_ = NULL;
+ gint _tmp28__length1 = 0;
+ gint _tmp29_ = 0;
+ gint _tmp30_ = 0;
+ guchar _tmp31_ = '\0';
+ guchar _tmp32_ = '\0';
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp19_ = _tmp18_;
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (!_tmp19_) {
-#line 711 "page.c"
- gint _tmp20_;
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 797 "page.c"
+ gint _tmp20_ = 0;
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp20_ = i;
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
i = _tmp20_ + 1;
-#line 717 "page.c"
+#line 803 "page.c"
}
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp18_ = FALSE;
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp21_ = i;
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp22_ = line;
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp23_ = _tmp22_->data_length;
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (!(_tmp21_ < _tmp23_)) {
-#line 161 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 731 "page.c"
+#line 817 "page.c"
}
-#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp24_ = self->priv->pixels;
-#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp24__length1 = self->priv->pixels_length1;
-#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp25_ = offset;
-#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp26_ = i;
-#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp27_ = line;
-#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp28_ = _tmp27_->data;
-#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp28__length1 = _tmp27_->data_length1;
-#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp29_ = line_offset;
-#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp30_ = i;
-#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp31_ = _tmp28_[_tmp29_ + _tmp30_];
-#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp24_[_tmp25_ + _tmp26_] = _tmp31_;
-#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp32_ = _tmp24_[_tmp25_ + _tmp26_];
-#line 757 "page.c"
+#line 843 "page.c"
}
}
}
-#line 164 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 281 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp33_ = line_number;
-#line 164 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->scan_line = _tmp33_;
-#line 137 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 281 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_line (self, _tmp33_);
+#line 258 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (size_changed) {
-#line 137 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 258 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
*size_changed = _vala_size_changed;
-#line 769 "page.c"
+#line 855 "page.c"
}
}
void page_parse_scan_line (Page* self, ScanLine* line) {
- gboolean size_has_changed;
- gboolean _tmp9_;
-#line 167 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gboolean size_has_changed = FALSE;
+ gboolean _tmp9_ = FALSE;
+#line 284 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 167 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 284 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (line != NULL);
-#line 169 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 286 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
size_has_changed = FALSE;
-#line 783 "page.c"
+#line 869 "page.c"
{
- gint i;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint i = 0;
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
i = 0;
-#line 788 "page.c"
+#line 874 "page.c"
{
- gboolean _tmp0_;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gboolean _tmp0_ = FALSE;
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = TRUE;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
while (TRUE) {
-#line 795 "page.c"
- gboolean _tmp1_;
- gint _tmp3_;
- ScanLine* _tmp4_;
- gint _tmp5_;
- ScanLine* _tmp6_;
- gint _tmp7_;
+#line 881 "page.c"
+ gboolean _tmp1_ = FALSE;
+ gint _tmp3_ = 0;
+ ScanLine* _tmp4_ = NULL;
+ gint _tmp5_ = 0;
+ ScanLine* _tmp6_ = NULL;
+ gint _tmp7_ = 0;
gboolean _tmp8_ = FALSE;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = _tmp0_;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (!_tmp1_) {
-#line 807 "page.c"
- gint _tmp2_;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 893 "page.c"
+ gint _tmp2_ = 0;
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp2_ = i;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
i = _tmp2_ + 1;
-#line 813 "page.c"
+#line 899 "page.c"
}
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = FALSE;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = i;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp4_ = line;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp5_ = _tmp4_->n_lines;
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (!(_tmp3_ < _tmp5_)) {
-#line 170 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 827 "page.c"
+#line 913 "page.c"
}
-#line 171 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 288 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp6_ = line;
-#line 171 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 288 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp7_ = i;
-#line 171 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 288 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
page_parse_line (self, _tmp6_, _tmp7_, &_tmp8_);
-#line 171 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 288 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
size_has_changed = _tmp8_;
-#line 837 "page.c"
+#line 923 "page.c"
}
}
}
-#line 173 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->has_data_ = TRUE;
-#line 175 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 290 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_has_data (self, TRUE);
+#line 292 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp9_ = size_has_changed;
-#line 175 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 292 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp9_) {
-#line 176 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 293 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "size-changed");
-#line 849 "page.c"
+#line 935 "page.c"
}
-#line 177 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 294 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "scan-line-changed");
-#line 178 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 295 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "pixels-changed");
-#line 855 "page.c"
+#line 941 "page.c"
}
void page_finish (Page* self) {
- gboolean size_has_changed;
+ gboolean size_has_changed = FALSE;
gboolean _tmp0_ = FALSE;
- gint _tmp1_;
- gboolean _tmp4_;
- gboolean _tmp12_;
-#line 181 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint _tmp1_ = 0;
+ gboolean _tmp4_ = FALSE;
+ gboolean _tmp12_ = FALSE;
+#line 298 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 183 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 300 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
size_has_changed = FALSE;
-#line 186 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 303 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = self->priv->expected_rows;
-#line 186 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 303 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp1_ < 0) {
-#line 873 "page.c"
- gint _tmp2_;
+#line 959 "page.c"
+ gint _tmp2_ = 0;
gint _tmp3_ = 0;
-#line 187 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp2_ = self->priv->scan_line;
-#line 187 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp3_ = page_get_scan_height (self);
-#line 187 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 304 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp2_ = self->priv->_scan_line;
+#line 304 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp3_ = self->priv->_scan_height;
+#line 304 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = _tmp2_ != _tmp3_;
-#line 882 "page.c"
+#line 968 "page.c"
} else {
-#line 186 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 303 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = FALSE;
-#line 886 "page.c"
+#line 972 "page.c"
}
-#line 186 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 303 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp4_ = _tmp0_;
-#line 186 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 303 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp4_) {
-#line 892 "page.c"
+#line 978 "page.c"
gint rows = 0;
- gint _tmp5_;
- gint _tmp6_;
- gint _tmp7_;
- gint _tmp8_;
+ gint _tmp5_ = 0;
+ gint _tmp6_ = 0;
+ gint _tmp7_ = 0;
+ gint _tmp8_ = 0;
gint _tmp9_ = 0;
- gint _tmp10_;
- gint _tmp11_;
-#line 191 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp5_ = self->priv->n_rows;
-#line 191 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint _tmp10_ = 0;
+ gint _tmp11_ = 0;
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp5_ = self->priv->_scan_height;
+#line 306 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
rows = _tmp5_;
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp6_ = self->priv->scan_line;
-#line 192 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->n_rows = _tmp6_;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp7_ = self->priv->n_rows;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp8_ = self->priv->rowstride;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 307 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp6_ = self->priv->_scan_line;
+#line 307 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_height (self, _tmp6_);
+#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp7_ = self->priv->_scan_height;
+#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp8_ = self->priv->_rowstride;
+#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp9_ = _tmp7_ * _tmp8_;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->priv->pixels = g_renew (guchar, self->priv->pixels, _tmp7_ * _tmp8_);
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
(_tmp9_ > self->priv->pixels_length1) ? memset (self->priv->pixels + self->priv->pixels_length1, 0, sizeof (guchar) * (_tmp9_ - self->priv->pixels_length1)) : NULL;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->priv->pixels_length1 = _tmp9_;
-#line 193 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->priv->_pixels_size_ = _tmp9_;
-#line 194 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 309 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp10_ = rows;
-#line 194 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp11_ = self->priv->n_rows;
-#line 194 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_debug ("page.vala:194: Trimming page from %d lines to %d lines", _tmp10_, _tmp11_);
-#line 196 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 309 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp11_ = self->priv->_scan_height;
+#line 309 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_debug ("page.vala:309: Trimming page from %d lines to %d lines", _tmp10_, _tmp11_);
+#line 311 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
size_has_changed = TRUE;
-#line 931 "page.c"
+#line 1017 "page.c"
}
-#line 198 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->scanning = FALSE;
-#line 200 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 313 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_is_scanning (self, FALSE);
+#line 315 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp12_ = size_has_changed;
-#line 200 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 315 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp12_) {
-#line 201 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 316 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "size-changed");
-#line 941 "page.c"
+#line 1027 "page.c"
}
-#line 202 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 317 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "scan-line-changed");
-#line 203 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 318 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "scan-finished");
-#line 947 "page.c"
-}
-
-
-ScanDirection page_get_scan_direction (Page* self) {
- ScanDirection result = 0;
- ScanDirection _tmp0_;
-#line 206 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, 0);
-#line 208 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->scan_direction;
-#line 208 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_;
-#line 208 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 962 "page.c"
-}
-
-
-static void page_set_scan_direction (Page* self, ScanDirection direction) {
- gint left_steps = 0;
- gint t = 0;
- gboolean size_has_changed;
- gint width = 0;
- gint height = 0;
- ScanDirection _tmp0_;
- ScanDirection _tmp1_;
- ScanDirection _tmp2_;
- ScanDirection _tmp3_;
- gint _tmp4_;
- gint _tmp6_;
- gint _tmp7_ = 0;
- gint _tmp8_ = 0;
- gboolean _tmp9_;
- ScanDirection _tmp33_;
- gboolean _tmp34_;
- gboolean _tmp35_;
-#line 211 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_if_fail (self != NULL);
-#line 214 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- size_has_changed = FALSE;
-#line 217 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->scan_direction;
-#line 217 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = direction;
-#line 217 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp0_ == _tmp1_) {
-#line 218 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return;
-#line 996 "page.c"
- }
-#line 221 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp2_ = direction;
-#line 221 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp3_ = self->priv->scan_direction;
-#line 221 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- left_steps = (gint) (_tmp2_ - _tmp3_);
-#line 222 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp4_ = left_steps;
-#line 222 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp4_ < 0) {
-#line 1008 "page.c"
- gint _tmp5_;
-#line 223 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp5_ = left_steps;
-#line 223 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- left_steps = _tmp5_ + 4;
-#line 1014 "page.c"
- }
-#line 224 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp6_ = left_steps;
-#line 224 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp6_ != 2) {
-#line 225 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- size_has_changed = TRUE;
-#line 1022 "page.c"
- }
-#line 227 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp7_ = page_get_width (self);
-#line 227 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- width = _tmp7_;
-#line 228 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp8_ = page_get_height (self);
-#line 228 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- height = _tmp8_;
-#line 231 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp9_ = self->priv->has_crop_;
-#line 231 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp9_) {
-#line 1036 "page.c"
- gint _tmp10_;
-#line 233 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp10_ = left_steps;
-#line 233 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- switch (_tmp10_) {
-#line 233 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- case 1:
-#line 1044 "page.c"
- {
- gint _tmp11_;
- gint _tmp12_;
- gint _tmp13_;
- gint _tmp14_;
- gint _tmp15_;
- gint _tmp16_;
- gint _tmp17_;
- gint _tmp18_;
-#line 237 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp11_ = self->priv->crop_x;
-#line 237 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- t = _tmp11_;
-#line 238 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp12_ = self->priv->crop_y;
-#line 238 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_x = _tmp12_;
-#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp13_ = width;
-#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp14_ = t;
-#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp15_ = self->priv->crop_width;
-#line 239 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_y = _tmp13_ - (_tmp14_ + _tmp15_);
-#line 240 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp16_ = self->priv->crop_width;
-#line 240 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- t = _tmp16_;
-#line 241 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp17_ = self->priv->crop_height;
-#line 241 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_width = _tmp17_;
-#line 242 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp18_ = t;
-#line 242 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_height = _tmp18_;
-#line 243 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- break;
-#line 1084 "page.c"
- }
-#line 233 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- case 2:
-#line 1088 "page.c"
- {
- gint _tmp19_;
- gint _tmp20_;
- gint _tmp21_;
- gint _tmp22_;
- gint _tmp23_;
- gint _tmp24_;
-#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp19_ = width;
-#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp20_ = self->priv->crop_x;
-#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp21_ = self->priv->crop_width;
-#line 246 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_x = _tmp19_ - (_tmp20_ + _tmp21_);
-#line 247 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp22_ = width;
-#line 247 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp23_ = self->priv->crop_y;
-#line 247 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp24_ = self->priv->crop_height;
-#line 247 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_y = _tmp22_ - (_tmp23_ + _tmp24_);
-#line 248 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- break;
-#line 1114 "page.c"
- }
-#line 233 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- case 3:
-#line 1118 "page.c"
- {
- gint _tmp25_;
- gint _tmp26_;
- gint _tmp27_;
- gint _tmp28_;
- gint _tmp29_;
- gint _tmp30_;
- gint _tmp31_;
- gint _tmp32_;
-#line 251 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp25_ = self->priv->crop_y;
-#line 251 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- t = _tmp25_;
-#line 252 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp26_ = self->priv->crop_x;
-#line 252 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_y = _tmp26_;
-#line 253 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp27_ = height;
-#line 253 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp28_ = t;
-#line 253 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp29_ = self->priv->crop_height;
-#line 253 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_x = _tmp27_ - (_tmp28_ + _tmp29_);
-#line 254 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp30_ = self->priv->crop_width;
-#line 254 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- t = _tmp30_;
-#line 255 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp31_ = self->priv->crop_height;
-#line 255 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_width = _tmp31_;
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp32_ = t;
-#line 256 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_height = _tmp32_;
-#line 257 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- break;
-#line 1158 "page.c"
- }
- default:
-#line 233 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- break;
-#line 1163 "page.c"
- }
- }
-#line 261 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp33_ = direction;
-#line 261 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->scan_direction = _tmp33_;
-#line 262 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp34_ = size_has_changed;
-#line 262 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp34_) {
-#line 263 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_signal_emit_by_name (self, "size-changed");
-#line 1176 "page.c"
- }
-#line 264 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_signal_emit_by_name (self, "scan-direction-changed");
-#line 265 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp35_ = self->priv->has_crop_;
-#line 265 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp35_) {
-#line 266 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_signal_emit_by_name (self, "crop-changed");
-#line 1186 "page.c"
- }
+#line 1033 "page.c"
}
void page_rotate_left (Page* self) {
- ScanDirection _tmp0_;
- ScanDirection direction;
- ScanDirection _tmp1_;
- ScanDirection _tmp2_;
-#line 269 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ ScanDirection _tmp0_ = 0;
+ ScanDirection _tmp1_ = 0;
+#line 321 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 271 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->scan_direction;
-#line 271 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- direction = _tmp0_;
-#line 272 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = direction;
-#line 272 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = page_get_scan_direction (self);
+#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp1_ = _tmp0_;
+#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
switch (_tmp1_) {
-#line 272 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
case SCAN_DIRECTION_TOP_TO_BOTTOM:
-#line 1208 "page.c"
+#line 1050 "page.c"
{
-#line 275 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- direction = SCAN_DIRECTION_LEFT_TO_RIGHT;
-#line 276 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 326 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_direction (self, SCAN_DIRECTION_LEFT_TO_RIGHT);
+#line 327 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1214 "page.c"
+#line 1056 "page.c"
}
-#line 272 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
case SCAN_DIRECTION_LEFT_TO_RIGHT:
-#line 1218 "page.c"
+#line 1060 "page.c"
{
-#line 278 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- direction = SCAN_DIRECTION_BOTTOM_TO_TOP;
-#line 279 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 329 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_direction (self, SCAN_DIRECTION_BOTTOM_TO_TOP);
+#line 330 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1224 "page.c"
+#line 1066 "page.c"
}
-#line 272 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
case SCAN_DIRECTION_BOTTOM_TO_TOP:
-#line 1228 "page.c"
+#line 1070 "page.c"
{
-#line 281 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- direction = SCAN_DIRECTION_RIGHT_TO_LEFT;
-#line 282 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 332 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_direction (self, SCAN_DIRECTION_RIGHT_TO_LEFT);
+#line 333 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1234 "page.c"
+#line 1076 "page.c"
}
-#line 272 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
case SCAN_DIRECTION_RIGHT_TO_LEFT:
-#line 1238 "page.c"
+#line 1080 "page.c"
{
-#line 284 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- direction = SCAN_DIRECTION_TOP_TO_BOTTOM;
-#line 285 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 335 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_direction (self, SCAN_DIRECTION_TOP_TO_BOTTOM);
+#line 336 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1244 "page.c"
+#line 1086 "page.c"
}
default:
-#line 272 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1249 "page.c"
+#line 1091 "page.c"
}
-#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp2_ = direction;
-#line 287 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- page_set_scan_direction (self, _tmp2_);
-#line 1255 "page.c"
}
void page_rotate_right (Page* self) {
- ScanDirection _tmp0_;
- ScanDirection direction;
- ScanDirection _tmp1_;
- ScanDirection _tmp2_;
-#line 290 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ ScanDirection _tmp0_ = 0;
+ ScanDirection _tmp1_ = 0;
+#line 340 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 292 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->scan_direction;
-#line 292 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- direction = _tmp0_;
-#line 293 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = direction;
-#line 293 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = page_get_scan_direction (self);
+#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp1_ = _tmp0_;
+#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
switch (_tmp1_) {
-#line 293 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
case SCAN_DIRECTION_TOP_TO_BOTTOM:
-#line 1276 "page.c"
+#line 1109 "page.c"
{
-#line 296 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- direction = SCAN_DIRECTION_RIGHT_TO_LEFT;
-#line 297 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 345 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_direction (self, SCAN_DIRECTION_RIGHT_TO_LEFT);
+#line 346 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1282 "page.c"
+#line 1115 "page.c"
}
-#line 293 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
case SCAN_DIRECTION_LEFT_TO_RIGHT:
-#line 1286 "page.c"
+#line 1119 "page.c"
{
-#line 299 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- direction = SCAN_DIRECTION_TOP_TO_BOTTOM;
-#line 300 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 348 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_direction (self, SCAN_DIRECTION_TOP_TO_BOTTOM);
+#line 349 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1292 "page.c"
+#line 1125 "page.c"
}
-#line 293 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
case SCAN_DIRECTION_BOTTOM_TO_TOP:
-#line 1296 "page.c"
+#line 1129 "page.c"
{
-#line 302 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- direction = SCAN_DIRECTION_LEFT_TO_RIGHT;
-#line 303 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 351 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_direction (self, SCAN_DIRECTION_LEFT_TO_RIGHT);
+#line 352 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1302 "page.c"
+#line 1135 "page.c"
}
-#line 293 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
case SCAN_DIRECTION_RIGHT_TO_LEFT:
-#line 1306 "page.c"
+#line 1139 "page.c"
{
-#line 305 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- direction = SCAN_DIRECTION_BOTTOM_TO_TOP;
-#line 306 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 354 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_scan_direction (self, SCAN_DIRECTION_BOTTOM_TO_TOP);
+#line 355 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1312 "page.c"
+#line 1145 "page.c"
}
default:
-#line 293 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1317 "page.c"
- }
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp2_ = direction;
-#line 308 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- page_set_scan_direction (self, _tmp2_);
-#line 1323 "page.c"
-}
-
-
-gint page_get_dpi (Page* self) {
- gint result = 0;
- gint _tmp0_;
-#line 311 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, 0);
-#line 313 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->dpi;
-#line 313 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_;
-#line 313 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 1338 "page.c"
-}
-
-
-gboolean page_is_landscape (Page* self) {
- gboolean result = FALSE;
- gint _tmp0_ = 0;
- gint _tmp1_ = 0;
-#line 316 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, FALSE);
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = page_get_width (self);
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = page_get_height (self);
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_ > _tmp1_;
-#line 318 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 1356 "page.c"
-}
-
-
-gint page_get_width (Page* self) {
- gint result = 0;
- gboolean _tmp0_ = FALSE;
- ScanDirection _tmp1_;
- gboolean _tmp3_;
-#line 321 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, 0);
-#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = self->priv->scan_direction;
-#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp1_ == SCAN_DIRECTION_TOP_TO_BOTTOM) {
-#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = TRUE;
-#line 1373 "page.c"
- } else {
- ScanDirection _tmp2_;
-#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp2_ = self->priv->scan_direction;
-#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = _tmp2_ == SCAN_DIRECTION_BOTTOM_TO_TOP;
-#line 1380 "page.c"
- }
-#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp3_ = _tmp0_;
-#line 323 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp3_) {
-#line 1386 "page.c"
- gint _tmp4_;
-#line 324 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp4_ = self->priv->width;
-#line 324 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp4_;
-#line 324 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 1394 "page.c"
- } else {
- gint _tmp5_;
-#line 326 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp5_ = self->priv->n_rows;
-#line 326 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp5_;
-#line 326 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 1403 "page.c"
+#line 1150 "page.c"
}
}
-gint page_get_height (Page* self) {
- gint result = 0;
+void page_set_no_crop (Page* self) {
gboolean _tmp0_ = FALSE;
- ScanDirection _tmp1_;
- gboolean _tmp3_;
-#line 329 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, 0);
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = self->priv->scan_direction;
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp1_ == SCAN_DIRECTION_TOP_TO_BOTTOM) {
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = TRUE;
-#line 1421 "page.c"
- } else {
- ScanDirection _tmp2_;
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp2_ = self->priv->scan_direction;
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = _tmp2_ == SCAN_DIRECTION_BOTTOM_TO_TOP;
-#line 1428 "page.c"
- }
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp3_ = _tmp0_;
-#line 331 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp3_) {
-#line 1434 "page.c"
- gint _tmp4_;
-#line 332 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp4_ = self->priv->n_rows;
-#line 332 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp4_;
-#line 332 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 1442 "page.c"
- } else {
- gint _tmp5_;
-#line 334 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp5_ = self->priv->width;
-#line 334 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp5_;
-#line 334 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 1451 "page.c"
- }
-}
-
-
-gint page_get_depth (Page* self) {
- gint result = 0;
- gint _tmp0_;
-#line 337 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, 0);
-#line 339 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->depth;
-#line 339 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_;
-#line 339 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 1467 "page.c"
-}
-
-
-gint page_get_n_channels (Page* self) {
- gint result = 0;
- gint _tmp0_;
-#line 342 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, 0);
-#line 344 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->n_channels;
-#line 344 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_;
-#line 344 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 1482 "page.c"
-}
-
-
-gint page_get_rowstride (Page* self) {
- gint result = 0;
- gint _tmp0_;
-#line 347 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, 0);
-#line 349 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->rowstride;
-#line 349 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_;
-#line 349 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 1497 "page.c"
-}
-
-
-gint page_get_scan_width (Page* self) {
- gint result = 0;
- gint _tmp0_;
-#line 352 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, 0);
-#line 354 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->width;
-#line 354 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_;
-#line 354 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 1512 "page.c"
-}
-
-
-gint page_get_scan_height (Page* self) {
- gint result = 0;
- gint _tmp0_;
-#line 357 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, 0);
#line 359 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->n_rows;
-#line 359 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_;
-#line 359 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 1527 "page.c"
-}
-
-
-void page_set_color_profile (Page* self, const gchar* color_profile) {
- const gchar* _tmp0_;
- gchar* _tmp1_;
-#line 362 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_if_fail (self != NULL);
-#line 364 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = color_profile;
-#line 364 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = g_strdup (_tmp0_);
-#line 364 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _g_free0 (self->priv->color_profile);
-#line 364 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->color_profile = _tmp1_;
-#line 1544 "page.c"
-}
-
-
-gchar* page_get_color_profile (Page* self) {
- gchar* result = NULL;
- const gchar* _tmp0_;
- gchar* _tmp1_;
-#line 367 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, NULL);
-#line 369 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->color_profile;
-#line 369 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = g_strdup (_tmp0_);
-#line 369 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp1_;
-#line 369 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 1562 "page.c"
-}
-
-
-void page_set_no_crop (Page* self) {
- gboolean _tmp0_;
-#line 372 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 374 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->has_crop_;
-#line 374 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 361 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_has_crop;
+#line 361 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (!_tmp0_) {
-#line 375 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 362 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 1576 "page.c"
+#line 1165 "page.c"
}
-#line 376 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->has_crop_ = FALSE;
-#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 363 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_has_crop (self, FALSE);
+#line 364 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_name (self, NULL);
+#line 365 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_x (self, 0);
+#line 366 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_y (self, 0);
+#line 367 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_width (self, 0);
+#line 368 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_height (self, 0);
+#line 369 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "crop-changed");
-#line 1582 "page.c"
+#line 1181 "page.c"
}
void page_set_custom_crop (Page* self, gint width, gint height) {
- gint _tmp0_;
- gint _tmp1_;
+ gint _tmp0_ = 0;
+ gint _tmp1_ = 0;
gboolean _tmp2_ = FALSE;
gboolean _tmp3_ = FALSE;
gboolean _tmp4_ = FALSE;
- const gchar* _tmp5_;
- gboolean _tmp7_;
- gboolean _tmp10_;
- gboolean _tmp13_;
- gint _tmp14_;
- gint _tmp15_;
-#line 380 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ const gchar* _tmp5_ = NULL;
+ gboolean _tmp7_ = FALSE;
+ gboolean _tmp10_ = FALSE;
+ gboolean _tmp13_ = FALSE;
+ gint _tmp14_ = 0;
+ gint _tmp15_ = 0;
+#line 372 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 384 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 374 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = width;
-#line 384 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 374 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (_tmp0_ >= 1);
-#line 385 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 375 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = height;
-#line 385 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 375 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (_tmp1_ >= 1);
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp5_ = self->priv->crop_name;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp5_ = self->priv->_crop_name;
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp5_ == NULL) {
-#line 1612 "page.c"
- gboolean _tmp6_;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp6_ = self->priv->has_crop_;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 1211 "page.c"
+ gboolean _tmp6_ = FALSE;
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp6_ = self->priv->_has_crop;
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp4_ = _tmp6_;
-#line 1618 "page.c"
+#line 1217 "page.c"
} else {
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp4_ = FALSE;
-#line 1622 "page.c"
+#line 1221 "page.c"
}
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp7_ = _tmp4_;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp7_) {
-#line 1628 "page.c"
- gint _tmp8_;
- gint _tmp9_;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp8_ = self->priv->crop_width;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 1227 "page.c"
+ gint _tmp8_ = 0;
+ gint _tmp9_ = 0;
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp8_ = self->priv->_crop_width;
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp9_ = width;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = _tmp8_ == _tmp9_;
-#line 1637 "page.c"
+#line 1236 "page.c"
} else {
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = FALSE;
-#line 1641 "page.c"
+#line 1240 "page.c"
}
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp10_ = _tmp3_;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp10_) {
-#line 1647 "page.c"
- gint _tmp11_;
- gint _tmp12_;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp11_ = self->priv->crop_height;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 1246 "page.c"
+ gint _tmp11_ = 0;
+ gint _tmp12_ = 0;
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp11_ = self->priv->_crop_height;
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp12_ = height;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp2_ = _tmp11_ == _tmp12_;
-#line 1656 "page.c"
+#line 1255 "page.c"
} else {
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp2_ = FALSE;
-#line 1660 "page.c"
+#line 1259 "page.c"
}
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp13_ = _tmp2_;
-#line 387 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 377 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp13_) {
-#line 388 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 378 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 1668 "page.c"
+#line 1267 "page.c"
}
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _g_free0 (self->priv->crop_name);
-#line 389 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_name = NULL;
-#line 390 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->has_crop_ = TRUE;
-#line 392 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 379 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_name (self, NULL);
+#line 380 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_has_crop (self, TRUE);
+#line 382 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp14_ = width;
-#line 392 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_width = _tmp14_;
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 382 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_width (self, _tmp14_);
+#line 383 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp15_ = height;
-#line 393 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_height = _tmp15_;
-#line 406 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 383 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_height (self, _tmp15_);
+#line 396 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "crop-changed");
-#line 1686 "page.c"
+#line 1283 "page.c"
}
void page_set_named_crop (Page* self, const gchar* name) {
- gdouble width = 0.0;
- gdouble height = 0.0;
- const gchar* _tmp0_;
- const gchar* _tmp1_;
+ gdouble w = 0.0;
+ gdouble h = 0.0;
+ const gchar* _tmp0_ = NULL;
+ const gchar* _tmp1_ = NULL;
GQuark _tmp3_ = 0U;
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
static GQuark _tmp2_label0 = 0;
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
static GQuark _tmp2_label1 = 0;
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
static GQuark _tmp2_label2 = 0;
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
static GQuark _tmp2_label3 = 0;
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
static GQuark _tmp2_label4 = 0;
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
static GQuark _tmp2_label5 = 0;
-#line 1708 "page.c"
- const gchar* _tmp5_;
- gchar* _tmp6_;
+#line 1305 "page.c"
+ const gchar* _tmp5_ = NULL;
+ gint pw = 0;
+ gint _tmp6_ = 0;
gint _tmp7_ = 0;
- gint pw;
+ gint ph = 0;
gint _tmp8_ = 0;
- gint ph;
- gint _tmp9_;
- gint _tmp10_;
- gdouble _tmp14_;
- gint _tmp15_;
- gdouble _tmp16_;
- gint _tmp17_;
- gint _tmp18_;
- gint _tmp19_;
- gint _tmp22_;
- gint _tmp23_;
-#line 409 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint _tmp9_ = 0;
+ gint _tmp10_ = 0;
+ gint _tmp11_ = 0;
+ gdouble _tmp15_ = 0.0;
+ gint _tmp16_ = 0;
+ gdouble _tmp17_ = 0.0;
+ gint _tmp18_ = 0;
+ gint _tmp19_ = 0;
+ gint _tmp20_ = 0;
+ gint _tmp23_ = 0;
+ gint _tmp24_ = 0;
+#line 399 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 409 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 399 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (name != NULL);
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = name;
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = _tmp0_;
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = (NULL == _tmp1_) ? 0 : g_quark_from_string (_tmp1_);
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp3_ == ((0 != _tmp2_label0) ? _tmp2_label0 : (_tmp2_label0 = g_quark_from_static_string ("A4")))) {
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
switch (0) {
-#line 1739 "page.c"
+#line 1337 "page.c"
default:
{
-#line 415 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- width = 8.3;
-#line 416 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- height = 11.7;
-#line 417 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 405 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ w = 8.3;
+#line 406 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ h = 11.7;
+#line 407 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1748 "page.c"
+#line 1346 "page.c"
}
}
} else if (_tmp3_ == ((0 != _tmp2_label1) ? _tmp2_label1 : (_tmp2_label1 = g_quark_from_static_string ("A5")))) {
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
switch (0) {
-#line 1754 "page.c"
+#line 1352 "page.c"
default:
{
-#line 419 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- width = 5.8;
-#line 420 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- height = 8.3;
-#line 421 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 409 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ w = 5.8;
+#line 410 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ h = 8.3;
+#line 411 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1763 "page.c"
+#line 1361 "page.c"
}
}
} else if (_tmp3_ == ((0 != _tmp2_label2) ? _tmp2_label2 : (_tmp2_label2 = g_quark_from_static_string ("A6")))) {
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
switch (0) {
-#line 1769 "page.c"
+#line 1367 "page.c"
default:
{
-#line 423 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- width = 4.1;
-#line 424 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- height = 5.8;
-#line 425 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 413 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ w = 4.1;
+#line 414 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ h = 5.8;
+#line 415 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1778 "page.c"
+#line 1376 "page.c"
}
}
} else if (_tmp3_ == ((0 != _tmp2_label3) ? _tmp2_label3 : (_tmp2_label3 = g_quark_from_static_string ("letter")))) {
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
switch (0) {
-#line 1784 "page.c"
+#line 1382 "page.c"
default:
{
-#line 427 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- width = 8.5;
-#line 428 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- height = (gdouble) 11;
-#line 429 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 417 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ w = 8.5;
+#line 418 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ h = (gdouble) 11;
+#line 419 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1793 "page.c"
+#line 1391 "page.c"
}
}
} else if (_tmp3_ == ((0 != _tmp2_label4) ? _tmp2_label4 : (_tmp2_label4 = g_quark_from_static_string ("legal")))) {
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
switch (0) {
-#line 1799 "page.c"
+#line 1397 "page.c"
default:
{
-#line 431 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- width = 8.5;
-#line 432 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- height = (gdouble) 14;
-#line 433 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 421 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ w = 8.5;
+#line 422 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ h = (gdouble) 14;
+#line 423 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1808 "page.c"
+#line 1406 "page.c"
}
}
} else if (_tmp3_ == ((0 != _tmp2_label5) ? _tmp2_label5 : (_tmp2_label5 = g_quark_from_static_string ("4x6")))) {
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
switch (0) {
-#line 1814 "page.c"
+#line 1412 "page.c"
default:
{
-#line 435 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- width = (gdouble) 4;
-#line 436 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- height = (gdouble) 6;
-#line 437 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 425 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ w = (gdouble) 4;
+#line 426 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ h = (gdouble) 6;
+#line 427 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 1823 "page.c"
+#line 1421 "page.c"
}
}
} else {
-#line 412 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 402 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
switch (0) {
-#line 1829 "page.c"
+#line 1427 "page.c"
default:
{
- const gchar* _tmp4_;
-#line 439 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ const gchar* _tmp4_ = NULL;
+#line 429 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp4_ = name;
-#line 439 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_warning ("page.vala:439: Unknown paper size '%s'", _tmp4_);
-#line 440 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 429 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_warning ("page.vala:429: Unknown paper size '%s'", _tmp4_);
+#line 430 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 1839 "page.c"
+#line 1437 "page.c"
}
}
}
-#line 443 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 433 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp5_ = name;
-#line 443 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp6_ = g_strdup (_tmp5_);
-#line 443 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _g_free0 (self->priv->crop_name);
-#line 443 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_name = _tmp6_;
-#line 444 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->has_crop_ = TRUE;
-#line 446 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp7_ = page_get_width (self);
-#line 446 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 433 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_name (self, _tmp5_);
+#line 434 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_has_crop (self, TRUE);
+#line 436 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp6_ = page_get_width (self);
+#line 436 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp7_ = _tmp6_;
+#line 436 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
pw = _tmp7_;
-#line 447 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 437 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp8_ = page_get_height (self);
-#line 447 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- ph = _tmp8_;
-#line 450 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp9_ = pw;
-#line 450 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp10_ = ph;
-#line 450 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp9_ > _tmp10_) {
-#line 1867 "page.c"
+#line 437 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp9_ = _tmp8_;
+#line 437 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ ph = _tmp9_;
+#line 440 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp10_ = pw;
+#line 440 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp11_ = ph;
+#line 440 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp10_ > _tmp11_) {
+#line 1465 "page.c"
gdouble t = 0.0;
- gdouble _tmp11_;
- gdouble _tmp12_;
- gdouble _tmp13_;
-#line 453 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp11_ = width;
-#line 453 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- t = _tmp11_;
-#line 454 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp12_ = height;
-#line 454 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- width = _tmp12_;
-#line 455 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp13_ = t;
-#line 455 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- height = _tmp13_;
-#line 1884 "page.c"
+ gdouble _tmp12_ = 0.0;
+ gdouble _tmp13_ = 0.0;
+ gdouble _tmp14_ = 0.0;
+#line 442 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp12_ = w;
+#line 442 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ t = _tmp12_;
+#line 443 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp13_ = h;
+#line 443 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ w = _tmp13_;
+#line 444 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp14_ = t;
+#line 444 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ h = _tmp14_;
+#line 1482 "page.c"
}
-#line 459 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp14_ = width;
-#line 459 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp15_ = self->priv->dpi;
-#line 459 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_width = (gint) ((_tmp14_ * _tmp15_) + 0.5);
-#line 460 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp16_ = height;
-#line 460 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp17_ = self->priv->dpi;
-#line 460 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_height = (gint) ((_tmp16_ * _tmp17_) + 0.5);
-#line 462 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp18_ = self->priv->crop_width;
-#line 462 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp19_ = pw;
-#line 462 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp18_ < _tmp19_) {
-#line 1904 "page.c"
- gint _tmp20_;
- gint _tmp21_;
-#line 463 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp20_ = pw;
-#line 463 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp21_ = self->priv->crop_width;
-#line 463 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_x = (_tmp20_ - _tmp21_) / 2;
-#line 1913 "page.c"
+#line 448 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp15_ = w;
+#line 448 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp16_ = self->priv->_dpi;
+#line 448 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_width (self, (gint) ((_tmp15_ * _tmp16_) + 0.5));
+#line 449 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp17_ = h;
+#line 449 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp18_ = self->priv->_dpi;
+#line 449 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_height (self, (gint) ((_tmp17_ * _tmp18_) + 0.5));
+#line 451 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp19_ = self->priv->_crop_width;
+#line 451 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp20_ = pw;
+#line 451 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp19_ < _tmp20_) {
+#line 1502 "page.c"
+ gint _tmp21_ = 0;
+ gint _tmp22_ = 0;
+#line 452 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp21_ = pw;
+#line 452 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp22_ = self->priv->_crop_width;
+#line 452 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_x (self, (_tmp21_ - _tmp22_) / 2);
+#line 1511 "page.c"
} else {
-#line 465 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_x = 0;
-#line 1917 "page.c"
+#line 454 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_x (self, 0);
+#line 1515 "page.c"
}
-#line 466 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp22_ = self->priv->crop_height;
-#line 466 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp23_ = ph;
-#line 466 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp22_ < _tmp23_) {
-#line 1925 "page.c"
- gint _tmp24_;
- gint _tmp25_;
-#line 467 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp24_ = ph;
-#line 467 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp25_ = self->priv->crop_height;
-#line 467 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_y = (_tmp24_ - _tmp25_) / 2;
-#line 1934 "page.c"
+#line 455 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp23_ = self->priv->_crop_height;
+#line 455 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp24_ = ph;
+#line 455 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp23_ < _tmp24_) {
+#line 1523 "page.c"
+ gint _tmp25_ = 0;
+ gint _tmp26_ = 0;
+#line 456 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp25_ = ph;
+#line 456 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp26_ = self->priv->_crop_height;
+#line 456 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_y (self, (_tmp25_ - _tmp26_) / 2);
+#line 1532 "page.c"
} else {
-#line 469 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_y = 0;
-#line 1938 "page.c"
+#line 458 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_y (self, 0);
+#line 1536 "page.c"
}
-#line 470 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 459 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "crop-changed");
-#line 1942 "page.c"
+#line 1540 "page.c"
}
void page_move_crop (Page* self, gint x, gint y) {
- gint _tmp0_;
- gint _tmp1_;
- gint _tmp2_;
+ gint _tmp0_ = 0;
+ gint _tmp1_ = 0;
+ gint _tmp2_ = 0;
gint _tmp3_ = 0;
- gint _tmp4_;
+ gint _tmp4_ = 0;
gint _tmp5_ = 0;
- gint _tmp6_;
- gint _tmp7_;
-#line 473 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint _tmp6_ = 0;
+ gint _tmp7_ = 0;
+ gint _tmp8_ = 0;
+ gint _tmp9_ = 0;
+#line 462 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 475 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 464 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = x;
-#line 475 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 464 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (_tmp0_ >= 0);
-#line 476 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 465 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = y;
-#line 476 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 465 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (_tmp1_ >= 0);
-#line 477 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 466 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp2_ = x;
-#line 477 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 466 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = page_get_width (self);
-#line 477 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_if_fail (_tmp2_ < _tmp3_);
-#line 478 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp4_ = y;
-#line 478 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp5_ = page_get_height (self);
-#line 478 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_if_fail (_tmp4_ < _tmp5_);
-#line 480 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp6_ = x;
-#line 480 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_x = _tmp6_;
-#line 481 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp7_ = y;
-#line 481 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_y = _tmp7_;
-#line 482 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 466 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp4_ = _tmp3_;
+#line 466 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (_tmp2_ < _tmp4_);
+#line 467 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp5_ = y;
+#line 467 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp6_ = page_get_height (self);
+#line 467 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp7_ = _tmp6_;
+#line 467 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (_tmp5_ < _tmp7_);
+#line 469 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp8_ = x;
+#line 469 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_x (self, _tmp8_);
+#line 470 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp9_ = y;
+#line 470 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_y (self, _tmp9_);
+#line 471 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "crop-changed");
-#line 1987 "page.c"
+#line 1591 "page.c"
}
void page_rotate_crop (Page* self) {
+ gboolean _tmp0_ = FALSE;
gint t = 0;
- gboolean _tmp0_;
- gint _tmp1_;
- gint _tmp2_;
- gint _tmp3_;
- const gchar* _tmp4_;
-#line 485 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint _tmp1_ = 0;
+ gint _tmp2_ = 0;
+ gint _tmp3_ = 0;
+ const gchar* _tmp4_ = NULL;
+#line 474 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 489 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->has_crop_;
-#line 489 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 476 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_has_crop;
+#line 476 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (!_tmp0_) {
-#line 490 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 477 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 2006 "page.c"
+#line 1610 "page.c"
}
-#line 492 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = self->priv->crop_width;
-#line 492 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 479 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp1_ = self->priv->_crop_width;
+#line 479 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
t = _tmp1_;
-#line 493 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp2_ = self->priv->crop_height;
-#line 493 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_width = _tmp2_;
-#line 494 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 480 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp2_ = self->priv->_crop_height;
+#line 480 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_width (self, _tmp2_);
+#line 481 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = t;
-#line 494 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_height = _tmp3_;
-#line 497 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp4_ = self->priv->crop_name;
-#line 497 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 481 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_height (self, _tmp3_);
+#line 484 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp4_ = self->priv->_crop_name;
+#line 484 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp4_ == NULL) {
-#line 2024 "page.c"
+#line 1628 "page.c"
gint w = 0;
- gint h = 0;
gint _tmp5_ = 0;
gint _tmp6_ = 0;
- gint _tmp7_;
- gint _tmp8_;
- gint _tmp9_;
- gint _tmp12_;
- gint _tmp14_;
- gint _tmp15_;
- gint _tmp16_;
- gint _tmp19_;
-#line 501 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint h = 0;
+ gint _tmp7_ = 0;
+ gint _tmp8_ = 0;
+ gint _tmp9_ = 0;
+ gint _tmp10_ = 0;
+ gint _tmp11_ = 0;
+ gint _tmp14_ = 0;
+ gint _tmp16_ = 0;
+ gint _tmp17_ = 0;
+ gint _tmp18_ = 0;
+ gint _tmp21_ = 0;
+#line 486 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp5_ = page_get_width (self);
-#line 501 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- w = _tmp5_;
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp6_ = page_get_height (self);
-#line 502 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- h = _tmp6_;
-#line 504 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp7_ = self->priv->crop_x;
-#line 504 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp8_ = self->priv->crop_width;
-#line 504 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp9_ = w;
-#line 504 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if ((_tmp7_ + _tmp8_) > _tmp9_) {
-#line 2053 "page.c"
- gint _tmp10_;
- gint _tmp11_;
-#line 505 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp10_ = w;
-#line 505 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp11_ = self->priv->crop_width;
-#line 505 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_x = _tmp10_ - _tmp11_;
-#line 2062 "page.c"
+#line 486 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp6_ = _tmp5_;
+#line 486 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ w = _tmp6_;
+#line 487 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp7_ = page_get_height (self);
+#line 487 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp8_ = _tmp7_;
+#line 487 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ h = _tmp8_;
+#line 489 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp9_ = self->priv->_crop_x;
+#line 489 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp10_ = self->priv->_crop_width;
+#line 489 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp11_ = w;
+#line 489 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if ((_tmp9_ + _tmp10_) > _tmp11_) {
+#line 1663 "page.c"
+ gint _tmp12_ = 0;
+ gint _tmp13_ = 0;
+#line 490 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp12_ = w;
+#line 490 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp13_ = self->priv->_crop_width;
+#line 490 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_x (self, _tmp12_ - _tmp13_);
+#line 1672 "page.c"
}
-#line 506 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp12_ = self->priv->crop_x;
-#line 506 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp12_ < 0) {
-#line 2068 "page.c"
- gint _tmp13_;
-#line 508 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_x = 0;
-#line 509 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp13_ = w;
-#line 509 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_width = _tmp13_;
-#line 2076 "page.c"
+#line 491 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp14_ = self->priv->_crop_x;
+#line 491 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp14_ < 0) {
+#line 1678 "page.c"
+ gint _tmp15_ = 0;
+#line 493 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_x (self, 0);
+#line 494 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp15_ = w;
+#line 494 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_width (self, _tmp15_);
+#line 1686 "page.c"
}
-#line 511 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp14_ = self->priv->crop_y;
-#line 511 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp15_ = self->priv->crop_height;
-#line 511 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp16_ = h;
-#line 511 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if ((_tmp14_ + _tmp15_) > _tmp16_) {
-#line 2086 "page.c"
- gint _tmp17_;
- gint _tmp18_;
-#line 512 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp17_ = h;
-#line 512 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp18_ = self->priv->crop_height;
-#line 512 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_y = _tmp17_ - _tmp18_;
-#line 2095 "page.c"
+#line 496 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp16_ = self->priv->_crop_y;
+#line 496 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp17_ = self->priv->_crop_height;
+#line 496 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp18_ = h;
+#line 496 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if ((_tmp16_ + _tmp17_) > _tmp18_) {
+#line 1696 "page.c"
+ gint _tmp19_ = 0;
+ gint _tmp20_ = 0;
+#line 497 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp19_ = h;
+#line 497 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp20_ = self->priv->_crop_height;
+#line 497 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_y (self, _tmp19_ - _tmp20_);
+#line 1705 "page.c"
}
-#line 513 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp19_ = self->priv->crop_y;
-#line 513 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp19_ < 0) {
-#line 2101 "page.c"
- gint _tmp20_;
-#line 515 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_y = 0;
-#line 516 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp20_ = h;
-#line 516 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->crop_height = _tmp20_;
-#line 2109 "page.c"
+#line 498 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp21_ = self->priv->_crop_y;
+#line 498 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp21_ < 0) {
+#line 1711 "page.c"
+ gint _tmp22_ = 0;
+#line 500 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_y (self, 0);
+#line 501 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp22_ = h;
+#line 501 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_height (self, _tmp22_);
+#line 1719 "page.c"
}
}
-#line 520 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 505 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_emit_by_name (self, "crop-changed");
-#line 2114 "page.c"
-}
-
-
-gboolean page_has_crop (Page* self) {
- gboolean result = FALSE;
- gboolean _tmp0_;
-#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, FALSE);
-#line 525 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->has_crop_;
-#line 525 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp0_;
-#line 525 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 2129 "page.c"
-}
-
-
-void page_get_crop (Page* self, gint* x, gint* y, gint* width, gint* height) {
- gint _vala_x = 0;
- gint _vala_y = 0;
- gint _vala_width = 0;
- gint _vala_height = 0;
- gint _tmp0_;
- gint _tmp1_;
- gint _tmp2_;
- gint _tmp3_;
-#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_if_fail (self != NULL);
-#line 530 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->crop_x;
-#line 530 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _vala_x = _tmp0_;
-#line 531 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = self->priv->crop_y;
-#line 531 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _vala_y = _tmp1_;
-#line 532 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp2_ = self->priv->crop_width;
-#line 532 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _vala_width = _tmp2_;
-#line 533 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp3_ = self->priv->crop_height;
-#line 533 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _vala_height = _tmp3_;
-#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (x) {
-#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- *x = _vala_x;
-#line 2164 "page.c"
- }
-#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (y) {
-#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- *y = _vala_y;
-#line 2170 "page.c"
- }
-#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (width) {
-#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- *width = _vala_width;
-#line 2176 "page.c"
- }
-#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (height) {
-#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- *height = _vala_height;
-#line 2182 "page.c"
- }
-}
-
-
-gchar* page_get_named_crop (Page* self) {
- gchar* result = NULL;
- const gchar* _tmp0_;
- gchar* _tmp1_;
-#line 536 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_val_if_fail (self != NULL, NULL);
-#line 538 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = self->priv->crop_name;
-#line 538 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = g_strdup (_tmp0_);
-#line 538 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- result = _tmp1_;
-#line 538 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return result;
-#line 2201 "page.c"
+#line 1724 "page.c"
}
guchar* page_get_pixels (Page* self, int* result_length1) {
guchar* result = NULL;
- guchar* _tmp0_;
- gint _tmp0__length1;
- guchar* _tmp1_;
- gint _tmp1__length1;
-#line 541 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ guchar* _tmp0_ = NULL;
+ gint _tmp0__length1 = 0;
+ guchar* _tmp1_ = NULL;
+ gint _tmp1__length1 = 0;
+#line 508 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_val_if_fail (self != NULL, NULL);
-#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = self->priv->pixels;
-#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0__length1 = self->priv->pixels_length1;
-#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = _tmp0_;
-#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1__length1 = _tmp0__length1;
-#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (result_length1) {
-#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
*result_length1 = _tmp1__length1;
-#line 2225 "page.c"
+#line 1748 "page.c"
}
-#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
result = _tmp1_;
-#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 510 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return result;
-#line 2231 "page.c"
-}
-
-
-static guchar* _vala_array_dup3 (guchar* self, int length) {
-#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- return g_memdup (self, length * sizeof (guchar));
-#line 2238 "page.c"
-}
-
-
-void page_set_pixels (Page* self, guchar* new_pixels, int new_pixels_length1) {
- guchar* _tmp0_;
- gint _tmp0__length1;
- guchar* _tmp1_;
- gint _tmp1__length1;
- guchar* _tmp2_;
- gint _tmp2__length1;
-#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_return_if_fail (self != NULL);
-#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0_ = new_pixels;
-#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp0__length1 = new_pixels_length1;
-#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = (_tmp0_ != NULL) ? _vala_array_dup3 (_tmp0_, _tmp0__length1) : ((gpointer) _tmp0_);
-#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1__length1 = _tmp0__length1;
-#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->pixels = (g_free (self->priv->pixels), NULL);
-#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->pixels = _tmp1_;
-#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->pixels_length1 = _tmp1__length1;
-#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->_pixels_size_ = self->priv->pixels_length1;
-#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp2_ = new_pixels;
-#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp2__length1 = new_pixels_length1;
-#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->has_data_ = _tmp2_ != NULL;
-#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_signal_emit_by_name (self, "pixels-changed");
-#line 2275 "page.c"
+#line 1754 "page.c"
}
static guchar page_get_sample (Page* self, guchar* pixels, int pixels_length1, gint offset, gint x, gint depth, gint n_channels, gint channel) {
guchar result = '\0';
-#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 514 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_val_if_fail (self != NULL, '\0');
-#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 517 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
result = (guchar) 0xFF;
-#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 517 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return result;
-#line 2287 "page.c"
+#line 1766 "page.c"
}
static void page_get_pixel (Page* self, gint x, gint y, guchar* pixel, int pixel_length1, gint offset) {
ScanDirection _tmp0_ = 0;
- gint _tmp13_ = 0;
- gint depth;
+ ScanDirection _tmp1_ = 0;
+ gint line_offset = 0;
gint _tmp14_ = 0;
- gint n_channels;
gint _tmp15_ = 0;
- gint _tmp16_;
- gint line_offset;
- gboolean _tmp17_ = FALSE;
- gint _tmp18_;
- gboolean _tmp20_;
- guchar* _tmp104_;
- gint _tmp104__length1;
- gint _tmp105_;
- guchar* _tmp106_;
- gint _tmp106__length1;
- gint _tmp107_;
- gint _tmp108_;
- gint _tmp109_;
- gint _tmp110_;
+ gboolean _tmp16_ = FALSE;
+ gint _tmp17_ = 0;
+ gboolean _tmp19_ = FALSE;
+ guchar* _tmp103_ = NULL;
+ gint _tmp103__length1 = 0;
+ gint _tmp104_ = 0;
+ guchar* _tmp105_ = NULL;
+ gint _tmp105__length1 = 0;
+ gint _tmp106_ = 0;
+ gint _tmp107_ = 0;
+ gint _tmp108_ = 0;
+ gint _tmp109_ = 0;
+ guchar _tmp110_ = '\0';
guchar _tmp111_ = '\0';
- guchar _tmp112_;
- guchar* _tmp113_;
- gint _tmp113__length1;
- gint _tmp114_;
- guchar* _tmp115_;
- gint _tmp115__length1;
- gint _tmp116_;
- gint _tmp117_;
- gint _tmp118_;
- gint _tmp119_;
+ guchar* _tmp112_ = NULL;
+ gint _tmp112__length1 = 0;
+ gint _tmp113_ = 0;
+ guchar* _tmp114_ = NULL;
+ gint _tmp114__length1 = 0;
+ gint _tmp115_ = 0;
+ gint _tmp116_ = 0;
+ gint _tmp117_ = 0;
+ gint _tmp118_ = 0;
+ guchar _tmp119_ = '\0';
guchar _tmp120_ = '\0';
- guchar _tmp121_;
- guchar* _tmp122_;
- gint _tmp122__length1;
- gint _tmp123_;
- guchar* _tmp124_;
- gint _tmp124__length1;
- gint _tmp125_;
- gint _tmp126_;
- gint _tmp127_;
- gint _tmp128_;
+ guchar* _tmp121_ = NULL;
+ gint _tmp121__length1 = 0;
+ gint _tmp122_ = 0;
+ guchar* _tmp123_ = NULL;
+ gint _tmp123__length1 = 0;
+ gint _tmp124_ = 0;
+ gint _tmp125_ = 0;
+ gint _tmp126_ = 0;
+ gint _tmp127_ = 0;
+ guchar _tmp128_ = '\0';
guchar _tmp129_ = '\0';
- guchar _tmp130_;
-#line 561 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 521 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 563 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = page_get_scan_direction (self);
-#line 563 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- switch (_tmp0_) {
-#line 563 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp1_ = _tmp0_;
+#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ switch (_tmp1_) {
+#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
case SCAN_DIRECTION_TOP_TO_BOTTOM:
-#line 2344 "page.c"
+#line 1822 "page.c"
{
-#line 566 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 526 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 2348 "page.c"
+#line 1826 "page.c"
}
-#line 563 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
case SCAN_DIRECTION_BOTTOM_TO_TOP:
-#line 2352 "page.c"
+#line 1830 "page.c"
{
- gint _tmp1_ = 0;
- gint _tmp2_;
+ gint _tmp2_ = 0;
gint _tmp3_ = 0;
- gint _tmp4_;
-#line 568 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp1_ = page_get_scan_width (self);
-#line 568 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp2_ = x;
-#line 568 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- x = (_tmp1_ - _tmp2_) - 1;
-#line 569 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp3_ = page_get_scan_height (self);
-#line 569 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp4_ = y;
-#line 569 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- y = (_tmp3_ - _tmp4_) - 1;
-#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint _tmp4_ = 0;
+ gint _tmp5_ = 0;
+#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp2_ = self->priv->_scan_width;
+#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp3_ = x;
+#line 528 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ x = (_tmp2_ - _tmp3_) - 1;
+#line 529 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp4_ = self->priv->_scan_height;
+#line 529 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp5_ = y;
+#line 529 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ y = (_tmp4_ - _tmp5_) - 1;
+#line 530 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 2372 "page.c"
+#line 1850 "page.c"
}
-#line 563 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
case SCAN_DIRECTION_LEFT_TO_RIGHT:
-#line 2376 "page.c"
+#line 1854 "page.c"
{
- gint _tmp5_;
- gint t;
+ gint t = 0;
gint _tmp6_ = 0;
- gint _tmp7_;
- gint _tmp8_;
-#line 572 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp5_ = x;
-#line 572 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- t = _tmp5_;
-#line 573 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp6_ = page_get_scan_width (self);
-#line 573 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp7_ = y;
-#line 573 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- x = (_tmp6_ - _tmp7_) - 1;
-#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp8_ = t;
-#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- y = _tmp8_;
-#line 575 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint _tmp7_ = 0;
+ gint _tmp8_ = 0;
+ gint _tmp9_ = 0;
+#line 532 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp6_ = x;
+#line 532 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ t = _tmp6_;
+#line 533 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp7_ = self->priv->_scan_width;
+#line 533 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp8_ = y;
+#line 533 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ x = (_tmp7_ - _tmp8_) - 1;
+#line 534 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp9_ = t;
+#line 534 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ y = _tmp9_;
+#line 535 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 2399 "page.c"
+#line 1877 "page.c"
}
-#line 563 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
case SCAN_DIRECTION_RIGHT_TO_LEFT:
-#line 2403 "page.c"
+#line 1881 "page.c"
{
- gint _tmp9_;
- gint t;
- gint _tmp10_;
+ gint t = 0;
+ gint _tmp10_ = 0;
gint _tmp11_ = 0;
- gint _tmp12_;
-#line 577 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp9_ = x;
-#line 577 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- t = _tmp9_;
-#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp10_ = y;
-#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- x = _tmp10_;
-#line 579 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp11_ = page_get_scan_height (self);
-#line 579 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp12_ = t;
-#line 579 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- y = (_tmp11_ - _tmp12_) - 1;
-#line 580 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint _tmp12_ = 0;
+ gint _tmp13_ = 0;
+#line 537 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp10_ = x;
+#line 537 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ t = _tmp10_;
+#line 538 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp11_ = y;
+#line 538 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ x = _tmp11_;
+#line 539 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp12_ = self->priv->_scan_height;
+#line 539 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp13_ = t;
+#line 539 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ y = (_tmp12_ - _tmp13_) - 1;
+#line 540 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 2426 "page.c"
+#line 1904 "page.c"
}
default:
-#line 563 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 523 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 2431 "page.c"
+#line 1909 "page.c"
}
-#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp13_ = page_get_depth (self);
-#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- depth = _tmp13_;
-#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp14_ = page_get_n_channels (self);
-#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- n_channels = _tmp14_;
-#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp15_ = page_get_rowstride (self);
-#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp16_ = y;
-#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- line_offset = _tmp15_ * _tmp16_;
-#line 588 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp18_ = depth;
-#line 588 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp18_ == 8) {
-#line 2451 "page.c"
- gint _tmp19_;
-#line 588 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp19_ = n_channels;
-#line 588 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp17_ = _tmp19_ == 3;
-#line 2457 "page.c"
+#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp14_ = self->priv->_rowstride;
+#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp15_ = y;
+#line 543 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ line_offset = _tmp14_ * _tmp15_;
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp17_ = self->priv->_depth;
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp17_ == 8) {
+#line 1921 "page.c"
+ gint _tmp18_ = 0;
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp18_ = self->priv->_n_channels;
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp16_ = _tmp18_ == 3;
+#line 1927 "page.c"
} else {
-#line 588 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp17_ = FALSE;
-#line 2461 "page.c"
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp16_ = FALSE;
+#line 1931 "page.c"
}
-#line 588 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp20_ = _tmp17_;
-#line 588 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp20_) {
-#line 2467 "page.c"
- gint _tmp21_;
- gint _tmp22_;
- gint _tmp23_;
- gint o;
- guchar* _tmp24_;
- gint _tmp24__length1;
- gint _tmp25_;
- guchar* _tmp26_;
- gint _tmp26__length1;
- gint _tmp27_;
- guchar _tmp28_;
- guchar _tmp29_;
- guchar* _tmp30_;
- gint _tmp30__length1;
- gint _tmp31_;
- guchar* _tmp32_;
- gint _tmp32__length1;
- gint _tmp33_;
- guchar _tmp34_;
- guchar _tmp35_;
- guchar* _tmp36_;
- gint _tmp36__length1;
- gint _tmp37_;
- guchar* _tmp38_;
- gint _tmp38__length1;
- gint _tmp39_;
- guchar _tmp40_;
- guchar _tmp41_;
-#line 590 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp21_ = line_offset;
-#line 590 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp22_ = x;
-#line 590 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp23_ = n_channels;
-#line 590 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- o = _tmp21_ + (_tmp22_ * _tmp23_);
-#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp24_ = pixel;
-#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp24__length1 = pixel_length1;
-#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp25_ = offset;
-#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp26_ = self->priv->pixels;
-#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp26__length1 = self->priv->pixels_length1;
-#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp27_ = o;
-#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp28_ = _tmp26_[_tmp27_];
-#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp24_[_tmp25_ + 0] = _tmp28_;
-#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp29_ = _tmp24_[_tmp25_ + 0];
-#line 592 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp30_ = pixel;
-#line 592 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp30__length1 = pixel_length1;
-#line 592 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp31_ = offset;
-#line 592 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp32_ = self->priv->pixels;
-#line 592 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp32__length1 = self->priv->pixels_length1;
-#line 592 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp33_ = o;
-#line 592 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp34_ = _tmp32_[_tmp33_ + 1];
-#line 592 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp30_[_tmp31_ + 1] = _tmp34_;
-#line 592 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp35_ = _tmp30_[_tmp31_ + 1];
-#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp36_ = pixel;
-#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp36__length1 = pixel_length1;
-#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp37_ = offset;
-#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp38_ = self->priv->pixels;
-#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp38__length1 = self->priv->pixels_length1;
-#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp39_ = o;
-#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp40_ = _tmp38_[_tmp39_ + 2];
-#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp36_[_tmp37_ + 2] = _tmp40_;
-#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp41_ = _tmp36_[_tmp37_ + 2];
-#line 594 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp19_ = _tmp16_;
+#line 546 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp19_) {
+#line 1937 "page.c"
+ gint o = 0;
+ gint _tmp20_ = 0;
+ gint _tmp21_ = 0;
+ gint _tmp22_ = 0;
+ guchar* _tmp23_ = NULL;
+ gint _tmp23__length1 = 0;
+ gint _tmp24_ = 0;
+ guchar* _tmp25_ = NULL;
+ gint _tmp25__length1 = 0;
+ gint _tmp26_ = 0;
+ guchar _tmp27_ = '\0';
+ guchar _tmp28_ = '\0';
+ guchar* _tmp29_ = NULL;
+ gint _tmp29__length1 = 0;
+ gint _tmp30_ = 0;
+ guchar* _tmp31_ = NULL;
+ gint _tmp31__length1 = 0;
+ gint _tmp32_ = 0;
+ guchar _tmp33_ = '\0';
+ guchar _tmp34_ = '\0';
+ guchar* _tmp35_ = NULL;
+ gint _tmp35__length1 = 0;
+ gint _tmp36_ = 0;
+ guchar* _tmp37_ = NULL;
+ gint _tmp37__length1 = 0;
+ gint _tmp38_ = 0;
+ guchar _tmp39_ = '\0';
+ guchar _tmp40_ = '\0';
+#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp20_ = line_offset;
+#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp21_ = x;
+#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp22_ = self->priv->_n_channels;
+#line 548 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ o = _tmp20_ + (_tmp21_ * _tmp22_);
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp23_ = pixel;
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp23__length1 = pixel_length1;
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp24_ = offset;
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp25_ = self->priv->pixels;
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp25__length1 = self->priv->pixels_length1;
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp26_ = o;
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp27_ = _tmp25_[_tmp26_];
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp23_[_tmp24_ + 0] = _tmp27_;
+#line 549 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp28_ = _tmp23_[_tmp24_ + 0];
+#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp29_ = pixel;
+#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp29__length1 = pixel_length1;
+#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp30_ = offset;
+#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp31_ = self->priv->pixels;
+#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp31__length1 = self->priv->pixels_length1;
+#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp32_ = o;
+#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp33_ = _tmp31_[_tmp32_ + 1];
+#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp29_[_tmp30_ + 1] = _tmp33_;
+#line 550 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp34_ = _tmp29_[_tmp30_ + 1];
+#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp35_ = pixel;
+#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp35__length1 = pixel_length1;
+#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp36_ = offset;
+#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp37_ = self->priv->pixels;
+#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp37__length1 = self->priv->pixels_length1;
+#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp38_ = o;
+#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp39_ = _tmp37_[_tmp38_ + 2];
+#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp35_[_tmp36_ + 2] = _tmp39_;
+#line 551 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp40_ = _tmp35_[_tmp36_ + 2];
+#line 552 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 2560 "page.c"
+#line 2030 "page.c"
} else {
- gboolean _tmp42_ = FALSE;
- gint _tmp43_;
- gboolean _tmp45_;
-#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp43_ = depth;
-#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp43_ == 8) {
-#line 2569 "page.c"
- gint _tmp44_;
-#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp44_ = n_channels;
-#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp42_ = _tmp44_ == 1;
-#line 2575 "page.c"
+ gboolean _tmp41_ = FALSE;
+ gint _tmp42_ = 0;
+ gboolean _tmp44_ = FALSE;
+#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp42_ = self->priv->_depth;
+#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp42_ == 8) {
+#line 2039 "page.c"
+ gint _tmp43_ = 0;
+#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp43_ = self->priv->_n_channels;
+#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp41_ = _tmp43_ == 1;
+#line 2045 "page.c"
} else {
-#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp42_ = FALSE;
-#line 2579 "page.c"
+#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp41_ = FALSE;
+#line 2049 "page.c"
}
-#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp45_ = _tmp42_;
-#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp45_) {
-#line 2585 "page.c"
- guchar* _tmp46_;
- gint _tmp46__length1;
- gint _tmp47_;
- gint _tmp48_;
- guchar _tmp49_;
- guchar p;
- guchar* _tmp50_;
- gint _tmp50__length1;
- gint _tmp51_;
- guchar* _tmp52_;
- gint _tmp52__length1;
- gint _tmp53_;
- guchar* _tmp54_;
- gint _tmp54__length1;
- gint _tmp55_;
- guchar _tmp56_;
- guchar _tmp57_;
- guchar _tmp58_;
- guchar _tmp59_;
-#line 598 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp46_ = self->priv->pixels;
-#line 598 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp46__length1 = self->priv->pixels_length1;
-#line 598 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp47_ = line_offset;
-#line 598 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp48_ = x;
-#line 598 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp49_ = _tmp46_[_tmp47_ + _tmp48_];
-#line 598 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- p = _tmp49_;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp50_ = pixel;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp50__length1 = pixel_length1;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp51_ = offset;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp52_ = pixel;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp52__length1 = pixel_length1;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp53_ = offset;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp54_ = pixel;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp54__length1 = pixel_length1;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp55_ = offset;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp56_ = p;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp54_[_tmp55_ + 2] = _tmp56_;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp57_ = _tmp54_[_tmp55_ + 2];
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp52_[_tmp53_ + 1] = _tmp57_;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp58_ = _tmp52_[_tmp53_ + 1];
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp50_[_tmp51_ + 0] = _tmp58_;
-#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp59_ = _tmp50_[_tmp51_ + 0];
-#line 600 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp44_ = _tmp41_;
+#line 554 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp44_) {
+#line 2055 "page.c"
+ guchar p = '\0';
+ guchar* _tmp45_ = NULL;
+ gint _tmp45__length1 = 0;
+ gint _tmp46_ = 0;
+ gint _tmp47_ = 0;
+ guchar _tmp48_ = '\0';
+ guchar* _tmp49_ = NULL;
+ gint _tmp49__length1 = 0;
+ gint _tmp50_ = 0;
+ guchar* _tmp51_ = NULL;
+ gint _tmp51__length1 = 0;
+ gint _tmp52_ = 0;
+ guchar* _tmp53_ = NULL;
+ gint _tmp53__length1 = 0;
+ gint _tmp54_ = 0;
+ guchar _tmp55_ = '\0';
+ guchar _tmp56_ = '\0';
+ guchar _tmp57_ = '\0';
+ guchar _tmp58_ = '\0';
+#line 556 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp45_ = self->priv->pixels;
+#line 556 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp45__length1 = self->priv->pixels_length1;
+#line 556 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp46_ = line_offset;
+#line 556 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp47_ = x;
+#line 556 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp48_ = _tmp45_[_tmp46_ + _tmp47_];
+#line 556 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ p = _tmp48_;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp49_ = pixel;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp49__length1 = pixel_length1;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp50_ = offset;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp51_ = pixel;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp51__length1 = pixel_length1;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp52_ = offset;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp53_ = pixel;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp53__length1 = pixel_length1;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp54_ = offset;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp55_ = p;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp53_[_tmp54_ + 2] = _tmp55_;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp56_ = _tmp53_[_tmp54_ + 2];
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp51_[_tmp52_ + 1] = _tmp56_;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp57_ = _tmp51_[_tmp52_ + 1];
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp49_[_tmp50_ + 0] = _tmp57_;
+#line 557 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp58_ = _tmp49_[_tmp50_ + 0];
+#line 558 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 2651 "page.c"
+#line 2121 "page.c"
} else {
- gboolean _tmp60_ = FALSE;
- gint _tmp61_;
- gboolean _tmp63_;
-#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp61_ = depth;
-#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp61_ == 1) {
-#line 2660 "page.c"
- gint _tmp62_;
-#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp62_ = n_channels;
-#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp60_ = _tmp62_ == 1;
-#line 2666 "page.c"
+ gboolean _tmp59_ = FALSE;
+ gint _tmp60_ = 0;
+ gboolean _tmp62_ = FALSE;
+#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp60_ = self->priv->_depth;
+#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp60_ == 1) {
+#line 2130 "page.c"
+ gint _tmp61_ = 0;
+#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp61_ = self->priv->_n_channels;
+#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp59_ = _tmp61_ == 1;
+#line 2136 "page.c"
} else {
-#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp60_ = FALSE;
-#line 2670 "page.c"
+#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp59_ = FALSE;
+#line 2140 "page.c"
}
-#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp63_ = _tmp60_;
-#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp63_) {
-#line 2676 "page.c"
- guchar* _tmp64_;
- gint _tmp64__length1;
- gint _tmp65_;
- gint _tmp66_;
- guchar _tmp67_;
- guchar p;
- gint _tmp68_ = 0;
- guchar _tmp69_;
- gint _tmp70_;
- guchar* _tmp71_;
- gint _tmp71__length1;
- gint _tmp72_;
- guchar* _tmp73_;
- gint _tmp73__length1;
- gint _tmp74_;
- guchar* _tmp75_;
- gint _tmp75__length1;
- gint _tmp76_;
- gint _tmp77_;
- guchar _tmp78_;
- guchar _tmp79_;
- guchar _tmp80_;
-#line 606 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp64_ = self->priv->pixels;
-#line 606 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp64__length1 = self->priv->pixels_length1;
-#line 606 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp65_ = line_offset;
-#line 606 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp66_ = x;
-#line 606 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp67_ = _tmp64_[_tmp65_ + (_tmp66_ / 8)];
-#line 606 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- p = _tmp67_;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp69_ = p;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp70_ = x;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (((gint) (_tmp69_ & (0x80 >> (_tmp70_ % 8)))) != 0) {
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp68_ = 0x00;
-#line 2719 "page.c"
+#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp62_ = _tmp59_;
+#line 562 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp62_) {
+#line 2146 "page.c"
+ guchar p = '\0';
+ guchar* _tmp63_ = NULL;
+ gint _tmp63__length1 = 0;
+ gint _tmp64_ = 0;
+ gint _tmp65_ = 0;
+ guchar _tmp66_ = '\0';
+ gint _tmp67_ = 0;
+ guchar _tmp68_ = '\0';
+ gint _tmp69_ = 0;
+ guchar* _tmp70_ = NULL;
+ gint _tmp70__length1 = 0;
+ gint _tmp71_ = 0;
+ guchar* _tmp72_ = NULL;
+ gint _tmp72__length1 = 0;
+ gint _tmp73_ = 0;
+ guchar* _tmp74_ = NULL;
+ gint _tmp74__length1 = 0;
+ gint _tmp75_ = 0;
+ gint _tmp76_ = 0;
+ guchar _tmp77_ = '\0';
+ guchar _tmp78_ = '\0';
+ guchar _tmp79_ = '\0';
+#line 564 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp63_ = self->priv->pixels;
+#line 564 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp63__length1 = self->priv->pixels_length1;
+#line 564 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp64_ = line_offset;
+#line 564 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp65_ = x;
+#line 564 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp66_ = _tmp63_[_tmp64_ + (_tmp65_ / 8)];
+#line 564 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ p = _tmp66_;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp68_ = p;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp69_ = x;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (((gint) (_tmp68_ & (0x80 >> (_tmp69_ % 8)))) != 0) {
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp67_ = 0x00;
+#line 2189 "page.c"
} else {
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp68_ = 0xFF;
-#line 2723 "page.c"
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp67_ = 0xFF;
+#line 2193 "page.c"
}
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp71_ = pixel;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp71__length1 = pixel_length1;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp72_ = offset;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp73_ = pixel;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp73__length1 = pixel_length1;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp74_ = offset;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp75_ = pixel;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp75__length1 = pixel_length1;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp76_ = offset;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp77_ = _tmp68_;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp75_[_tmp76_ + 2] = (guchar) _tmp77_;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp78_ = _tmp75_[_tmp76_ + 2];
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp73_[_tmp74_ + 1] = _tmp78_;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp79_ = _tmp73_[_tmp74_ + 1];
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp71_[_tmp72_ + 0] = _tmp79_;
-#line 607 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp80_ = _tmp71_[_tmp72_ + 0];
-#line 608 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp70_ = pixel;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp70__length1 = pixel_length1;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp71_ = offset;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp72_ = pixel;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp72__length1 = pixel_length1;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp73_ = offset;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp74_ = pixel;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp74__length1 = pixel_length1;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp75_ = offset;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp76_ = _tmp67_;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp74_[_tmp75_ + 2] = (guchar) _tmp76_;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp77_ = _tmp74_[_tmp75_ + 2];
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp72_[_tmp73_ + 1] = _tmp77_;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp78_ = _tmp72_[_tmp73_ + 1];
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp70_[_tmp71_ + 0] = _tmp78_;
+#line 565 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp79_ = _tmp70_[_tmp71_ + 0];
+#line 566 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 2759 "page.c"
+#line 2229 "page.c"
} else {
- gboolean _tmp81_ = FALSE;
- gint _tmp82_;
- gboolean _tmp84_;
-#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp82_ = depth;
-#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp82_ == 2) {
-#line 2768 "page.c"
- gint _tmp83_;
-#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp83_ = n_channels;
-#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp81_ = _tmp83_ == 1;
-#line 2774 "page.c"
+ gboolean _tmp80_ = FALSE;
+ gint _tmp81_ = 0;
+ gboolean _tmp83_ = FALSE;
+#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp81_ = self->priv->_depth;
+#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp81_ == 2) {
+#line 2238 "page.c"
+ gint _tmp82_ = 0;
+#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp82_ = self->priv->_n_channels;
+#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp80_ = _tmp82_ == 1;
+#line 2244 "page.c"
} else {
-#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp81_ = FALSE;
-#line 2778 "page.c"
+#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp80_ = FALSE;
+#line 2248 "page.c"
}
-#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp84_ = _tmp81_;
-#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp84_) {
-#line 2784 "page.c"
- gint _tmp85_[4] = {0};
- gint block_shift[4];
- guchar* _tmp86_;
- gint _tmp86__length1;
- gint _tmp87_;
- gint _tmp88_;
- guchar _tmp89_;
- guchar p;
- guchar _tmp90_;
- gint _tmp91_;
- gint _tmp92_;
- gint sample;
- gint _tmp93_;
- guchar* _tmp94_;
- gint _tmp94__length1;
- gint _tmp95_;
- guchar* _tmp96_;
- gint _tmp96__length1;
- gint _tmp97_;
- guchar* _tmp98_;
- gint _tmp98__length1;
- gint _tmp99_;
- gint _tmp100_;
- guchar _tmp101_;
- guchar _tmp102_;
- guchar _tmp103_;
-#line 614 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp85_[0] = 6;
-#line 614 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp85_[1] = 4;
-#line 614 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp85_[2] = 2;
-#line 614 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp85_[3] = 0;
-#line 614 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- memcpy (block_shift, _tmp85_, 4 * sizeof (gint));
-#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp86_ = self->priv->pixels;
-#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp86__length1 = self->priv->pixels_length1;
-#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp87_ = line_offset;
-#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp88_ = x;
-#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp89_ = _tmp86_[_tmp87_ + (_tmp88_ / 4)];
-#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- p = _tmp89_;
-#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp90_ = p;
-#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp91_ = x;
-#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp92_ = block_shift[_tmp91_ % 4];
-#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- sample = (_tmp90_ >> _tmp92_) & 0x3;
-#line 618 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp93_ = sample;
-#line 618 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- sample = (_tmp93_ * 255) / 3;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp94_ = pixel;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp94__length1 = pixel_length1;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp95_ = offset;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp96_ = pixel;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp96__length1 = pixel_length1;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp97_ = offset;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp98_ = pixel;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp98__length1 = pixel_length1;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp99_ = offset;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp100_ = sample;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp98_[_tmp99_ + 2] = (guchar) _tmp100_;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp101_ = _tmp98_[_tmp99_ + 2];
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp96_[_tmp97_ + 1] = _tmp101_;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp102_ = _tmp96_[_tmp97_ + 1];
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp94_[_tmp95_ + 0] = _tmp102_;
-#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp103_ = _tmp94_[_tmp95_ + 0];
-#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp83_ = _tmp80_;
+#line 570 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp83_) {
+#line 2254 "page.c"
+ gint block_shift[4] = {0};
+ gint _tmp84_[4] = {0};
+ guchar p = '\0';
+ guchar* _tmp85_ = NULL;
+ gint _tmp85__length1 = 0;
+ gint _tmp86_ = 0;
+ gint _tmp87_ = 0;
+ guchar _tmp88_ = '\0';
+ gint sample = 0;
+ guchar _tmp89_ = '\0';
+ gint _tmp90_ = 0;
+ gint _tmp91_ = 0;
+ gint _tmp92_ = 0;
+ guchar* _tmp93_ = NULL;
+ gint _tmp93__length1 = 0;
+ gint _tmp94_ = 0;
+ guchar* _tmp95_ = NULL;
+ gint _tmp95__length1 = 0;
+ gint _tmp96_ = 0;
+ guchar* _tmp97_ = NULL;
+ gint _tmp97__length1 = 0;
+ gint _tmp98_ = 0;
+ gint _tmp99_ = 0;
+ guchar _tmp100_ = '\0';
+ guchar _tmp101_ = '\0';
+ guchar _tmp102_ = '\0';
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp84_[0] = 6;
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp84_[1] = 4;
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp84_[2] = 2;
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp84_[3] = 0;
+#line 572 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ memcpy (block_shift, _tmp84_, 4 * sizeof (gint));
+#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp85_ = self->priv->pixels;
+#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp85__length1 = self->priv->pixels_length1;
+#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp86_ = line_offset;
+#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp87_ = x;
+#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp88_ = _tmp85_[_tmp86_ + (_tmp87_ / 4)];
+#line 574 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ p = _tmp88_;
+#line 575 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp89_ = p;
+#line 575 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp90_ = x;
+#line 575 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp91_ = block_shift[_tmp90_ % 4];
+#line 575 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ sample = (_tmp89_ >> _tmp91_) & 0x3;
+#line 576 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp92_ = sample;
+#line 576 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ sample = (_tmp92_ * 255) / 3;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp93_ = pixel;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp93__length1 = pixel_length1;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp94_ = offset;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp95_ = pixel;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp95__length1 = pixel_length1;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp96_ = offset;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp97_ = pixel;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp97__length1 = pixel_length1;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp98_ = offset;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp99_ = sample;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp97_[_tmp98_ + 2] = (guchar) _tmp99_;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp100_ = _tmp97_[_tmp98_ + 2];
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp95_[_tmp96_ + 1] = _tmp100_;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp101_ = _tmp95_[_tmp96_ + 1];
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp93_[_tmp94_ + 0] = _tmp101_;
+#line 578 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp102_ = _tmp93_[_tmp94_ + 0];
+#line 579 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 2879 "page.c"
+#line 2349 "page.c"
}
}
}
}
-#line 625 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp104_ = pixel;
-#line 625 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp104__length1 = pixel_length1;
-#line 625 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp105_ = offset;
-#line 625 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp106_ = self->priv->pixels;
-#line 625 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp106__length1 = self->priv->pixels_length1;
-#line 625 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp107_ = line_offset;
-#line 625 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp108_ = x;
-#line 625 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp109_ = depth;
-#line 625 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp110_ = n_channels;
-#line 625 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp111_ = page_get_sample (self, _tmp106_, _tmp106__length1, _tmp107_, _tmp108_, _tmp109_, _tmp110_, 0);
-#line 625 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp104_[_tmp105_ + 0] = _tmp111_;
-#line 625 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp112_ = _tmp104_[_tmp105_ + 0];
-#line 626 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp113_ = pixel;
-#line 626 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp113__length1 = pixel_length1;
-#line 626 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp114_ = offset;
-#line 626 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp115_ = self->priv->pixels;
-#line 626 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp115__length1 = self->priv->pixels_length1;
-#line 626 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp116_ = line_offset;
-#line 626 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp117_ = x;
-#line 626 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp118_ = depth;
-#line 626 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp119_ = n_channels;
-#line 626 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp120_ = page_get_sample (self, _tmp115_, _tmp115__length1, _tmp116_, _tmp117_, _tmp118_, _tmp119_, 1);
-#line 626 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp113_[_tmp114_ + 1] = _tmp120_;
-#line 626 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp121_ = _tmp113_[_tmp114_ + 1];
-#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp122_ = pixel;
-#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp122__length1 = pixel_length1;
-#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp123_ = offset;
-#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp124_ = self->priv->pixels;
-#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp124__length1 = self->priv->pixels_length1;
-#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp125_ = line_offset;
-#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp126_ = x;
-#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp127_ = depth;
-#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp128_ = n_channels;
-#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp129_ = page_get_sample (self, _tmp124_, _tmp124__length1, _tmp125_, _tmp126_, _tmp127_, _tmp128_, 2);
-#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp122_[_tmp123_ + 2] = _tmp129_;
-#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp130_ = _tmp122_[_tmp123_ + 2];
-#line 2956 "page.c"
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp103_ = pixel;
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp103__length1 = pixel_length1;
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp104_ = offset;
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp105_ = self->priv->pixels;
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp105__length1 = self->priv->pixels_length1;
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp106_ = line_offset;
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp107_ = x;
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp108_ = self->priv->_depth;
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp109_ = self->priv->_n_channels;
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp110_ = page_get_sample (self, _tmp105_, _tmp105__length1, _tmp106_, _tmp107_, _tmp108_, _tmp109_, 0);
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp103_[_tmp104_ + 0] = _tmp110_;
+#line 583 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp111_ = _tmp103_[_tmp104_ + 0];
+#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp112_ = pixel;
+#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp112__length1 = pixel_length1;
+#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp113_ = offset;
+#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp114_ = self->priv->pixels;
+#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp114__length1 = self->priv->pixels_length1;
+#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp115_ = line_offset;
+#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp116_ = x;
+#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp117_ = self->priv->_depth;
+#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp118_ = self->priv->_n_channels;
+#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp119_ = page_get_sample (self, _tmp114_, _tmp114__length1, _tmp115_, _tmp116_, _tmp117_, _tmp118_, 1);
+#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp112_[_tmp113_ + 1] = _tmp119_;
+#line 584 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp120_ = _tmp112_[_tmp113_ + 1];
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp121_ = pixel;
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp121__length1 = pixel_length1;
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp122_ = offset;
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp123_ = self->priv->pixels;
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp123__length1 = self->priv->pixels_length1;
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp124_ = line_offset;
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp125_ = x;
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp126_ = self->priv->_depth;
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp127_ = self->priv->_n_channels;
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp128_ = page_get_sample (self, _tmp123_, _tmp123__length1, _tmp124_, _tmp125_, _tmp126_, _tmp127_, 2);
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp121_[_tmp122_ + 2] = _tmp128_;
+#line 585 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp129_ = _tmp121_[_tmp122_ + 2];
+#line 2426 "page.c"
}
@@ -2963,387 +2433,405 @@ GdkPixbuf* page_get_image (Page* self, gboolean apply_crop) {
gint t = 0;
gint b = 0;
gboolean _tmp0_ = FALSE;
- gboolean _tmp1_;
- gboolean _tmp3_;
- gint _tmp20_;
- gint _tmp21_;
- gint _tmp22_;
- gint _tmp23_;
- GdkPixbuf* _tmp24_;
- GdkPixbuf* image;
- GdkPixbuf* _tmp25_;
- guint8* _tmp26_ = NULL;
- guint8* image_pixels;
- gint image_pixels_length1;
- gint _image_pixels_size_;
-#line 630 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gboolean _tmp1_ = FALSE;
+ gboolean _tmp3_ = FALSE;
+ GdkPixbuf* image = NULL;
+ gint _tmp26_ = 0;
+ gint _tmp27_ = 0;
+ gint _tmp28_ = 0;
+ gint _tmp29_ = 0;
+ GdkPixbuf* _tmp30_ = NULL;
+ guint8* image_pixels = NULL;
+ GdkPixbuf* _tmp31_ = NULL;
+ guint8* _tmp32_ = NULL;
+ gint image_pixels_length1 = 0;
+ gint _image_pixels_size_ = 0;
+#line 588 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_val_if_fail (self != NULL, NULL);
-#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = apply_crop;
-#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp1_) {
-#line 2986 "page.c"
- gboolean _tmp2_;
-#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp2_ = self->priv->has_crop_;
-#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 2456 "page.c"
+ gboolean _tmp2_ = FALSE;
+#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp2_ = self->priv->_has_crop;
+#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = _tmp2_;
-#line 2992 "page.c"
+#line 2462 "page.c"
} else {
-#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = FALSE;
-#line 2996 "page.c"
+#line 2466 "page.c"
}
-#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = _tmp0_;
-#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 591 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp3_) {
-#line 3002 "page.c"
- gint _tmp4_;
- gint _tmp5_;
- gint _tmp6_;
- gint _tmp7_;
- gint _tmp8_;
- gint _tmp9_;
- gint _tmp10_;
- gint _tmp11_;
+#line 2472 "page.c"
+ gint _tmp4_ = 0;
+ gint _tmp5_ = 0;
+ gint _tmp6_ = 0;
+ gint _tmp7_ = 0;
+ gint _tmp8_ = 0;
+ gint _tmp9_ = 0;
+ gint _tmp10_ = 0;
+ gint _tmp11_ = 0;
gint _tmp12_ = 0;
- gint _tmp14_;
- gint _tmp15_;
+ gint _tmp13_ = 0;
gint _tmp16_ = 0;
-#line 635 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp4_ = self->priv->crop_x;
-#line 635 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint _tmp17_ = 0;
+ gint _tmp18_ = 0;
+ gint _tmp19_ = 0;
+#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp4_ = self->priv->_crop_x;
+#line 593 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
l = _tmp4_;
-#line 636 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 594 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp5_ = l;
-#line 636 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp6_ = self->priv->crop_width;
-#line 636 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 594 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp6_ = self->priv->_crop_width;
+#line 594 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
r = _tmp5_ + _tmp6_;
-#line 637 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp7_ = self->priv->crop_y;
-#line 637 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 595 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp7_ = self->priv->_crop_y;
+#line 595 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
t = _tmp7_;
-#line 638 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp8_ = t;
-#line 638 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp9_ = self->priv->crop_height;
-#line 638 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp9_ = self->priv->_crop_height;
+#line 596 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
b = _tmp8_ + _tmp9_;
-#line 640 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 598 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp10_ = l;
-#line 640 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 598 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp10_ < 0) {
-#line 641 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 599 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
l = 0;
-#line 3041 "page.c"
+#line 2513 "page.c"
}
-#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 600 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp11_ = r;
-#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 600 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp12_ = page_get_width (self);
-#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp11_ > _tmp12_) {
-#line 3049 "page.c"
- gint _tmp13_ = 0;
-#line 643 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp13_ = page_get_width (self);
-#line 643 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- r = _tmp13_;
-#line 3055 "page.c"
+#line 600 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp13_ = _tmp12_;
+#line 600 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp11_ > _tmp13_) {
+#line 2523 "page.c"
+ gint _tmp14_ = 0;
+ gint _tmp15_ = 0;
+#line 601 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp14_ = page_get_width (self);
+#line 601 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp15_ = _tmp14_;
+#line 601 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ r = _tmp15_;
+#line 2532 "page.c"
}
-#line 644 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp14_ = t;
-#line 644 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp14_ < 0) {
-#line 645 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 602 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp16_ = t;
+#line 602 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp16_ < 0) {
+#line 603 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
t = 0;
-#line 3063 "page.c"
+#line 2540 "page.c"
}
-#line 646 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp15_ = b;
-#line 646 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp16_ = page_get_height (self);
-#line 646 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (_tmp15_ > _tmp16_) {
-#line 3071 "page.c"
- gint _tmp17_ = 0;
-#line 647 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp17_ = page_get_height (self);
-#line 647 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- b = _tmp17_;
-#line 3077 "page.c"
+#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp17_ = b;
+#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp18_ = page_get_height (self);
+#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp19_ = _tmp18_;
+#line 604 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp17_ > _tmp19_) {
+#line 2550 "page.c"
+ gint _tmp20_ = 0;
+ gint _tmp21_ = 0;
+#line 605 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp20_ = page_get_height (self);
+#line 605 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp21_ = _tmp20_;
+#line 605 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ b = _tmp21_;
+#line 2559 "page.c"
}
} else {
- gint _tmp18_ = 0;
- gint _tmp19_ = 0;
-#line 651 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint _tmp22_ = 0;
+ gint _tmp23_ = 0;
+ gint _tmp24_ = 0;
+ gint _tmp25_ = 0;
+#line 609 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
l = 0;
-#line 652 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp18_ = page_get_width (self);
-#line 652 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- r = _tmp18_;
-#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 610 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp22_ = page_get_width (self);
+#line 610 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp23_ = _tmp22_;
+#line 610 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ r = _tmp23_;
+#line 611 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
t = 0;
-#line 654 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp19_ = page_get_height (self);
-#line 654 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- b = _tmp19_;
-#line 3094 "page.c"
+#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp24_ = page_get_height (self);
+#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp25_ = _tmp24_;
+#line 612 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ b = _tmp25_;
+#line 2582 "page.c"
}
-#line 657 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp20_ = r;
-#line 657 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp21_ = l;
-#line 657 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp22_ = b;
-#line 657 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp23_ = t;
-#line 657 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp24_ = gdk_pixbuf_new (GDK_COLORSPACE_RGB, FALSE, 8, _tmp20_ - _tmp21_, _tmp22_ - _tmp23_);
-#line 657 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- image = _tmp24_;
-#line 658 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp25_ = image;
-#line 658 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp26_ = gdk_pixbuf_get_pixels (_tmp25_);
-#line 658 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- image_pixels = _tmp26_;
-#line 658 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 615 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp26_ = r;
+#line 615 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp27_ = l;
+#line 615 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp28_ = b;
+#line 615 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp29_ = t;
+#line 615 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp30_ = gdk_pixbuf_new (GDK_COLORSPACE_RGB, FALSE, 8, _tmp26_ - _tmp27_, _tmp28_ - _tmp29_);
+#line 615 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ image = _tmp30_;
+#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp31_ = image;
+#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp32_ = gdk_pixbuf_get_pixels (_tmp31_);
+#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ image_pixels = _tmp32_;
+#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
image_pixels_length1 = -1;
-#line 658 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 616 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_image_pixels_size_ = image_pixels_length1;
-#line 3118 "page.c"
+#line 2606 "page.c"
{
- gint _tmp27_;
- gint y;
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp27_ = t;
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- y = _tmp27_;
-#line 3126 "page.c"
+ gint y = 0;
+ gint _tmp33_ = 0;
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp33_ = t;
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ y = _tmp33_;
+#line 2614 "page.c"
{
- gboolean _tmp28_;
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp28_ = TRUE;
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gboolean _tmp34_ = FALSE;
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp34_ = TRUE;
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
while (TRUE) {
-#line 3133 "page.c"
- gboolean _tmp29_;
- gint _tmp31_;
- gint _tmp32_;
- GdkPixbuf* _tmp33_;
- gint _tmp34_ = 0;
- gint _tmp35_;
- gint _tmp36_;
- gint offset;
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp29_ = _tmp28_;
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (!_tmp29_) {
-#line 3146 "page.c"
- gint _tmp30_;
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp30_ = y;
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- y = _tmp30_ + 1;
-#line 3152 "page.c"
+#line 2621 "page.c"
+ gboolean _tmp35_ = FALSE;
+ gint _tmp37_ = 0;
+ gint _tmp38_ = 0;
+ gint offset = 0;
+ GdkPixbuf* _tmp39_ = NULL;
+ gint _tmp40_ = 0;
+ gint _tmp41_ = 0;
+ gint _tmp42_ = 0;
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp35_ = _tmp34_;
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (!_tmp35_) {
+#line 2634 "page.c"
+ gint _tmp36_ = 0;
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp36_ = y;
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ y = _tmp36_ + 1;
+#line 2640 "page.c"
}
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp28_ = FALSE;
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp31_ = y;
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp32_ = b;
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (!(_tmp31_ < _tmp32_)) {
-#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp34_ = FALSE;
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp37_ = y;
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp38_ = b;
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (!(_tmp37_ < _tmp38_)) {
+#line 617 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 3164 "page.c"
+#line 2652 "page.c"
}
-#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp33_ = image;
-#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp34_ = gdk_pixbuf_get_rowstride (_tmp33_);
-#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp35_ = y;
-#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp36_ = t;
-#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- offset = _tmp34_ * (_tmp35_ - _tmp36_);
-#line 3176 "page.c"
+#line 619 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp39_ = image;
+#line 619 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp40_ = gdk_pixbuf_get_rowstride (_tmp39_);
+#line 619 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp41_ = y;
+#line 619 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp42_ = t;
+#line 619 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ offset = _tmp40_ * (_tmp41_ - _tmp42_);
+#line 2664 "page.c"
{
- gint _tmp37_;
- gint x;
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp37_ = l;
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- x = _tmp37_;
-#line 3184 "page.c"
+ gint x = 0;
+ gint _tmp43_ = 0;
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp43_ = l;
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ x = _tmp43_;
+#line 2672 "page.c"
{
- gboolean _tmp38_;
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp38_ = TRUE;
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gboolean _tmp44_ = FALSE;
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp44_ = TRUE;
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
while (TRUE) {
-#line 3191 "page.c"
- gboolean _tmp39_;
- gint _tmp41_;
- gint _tmp42_;
- gint _tmp43_;
- gint _tmp44_;
- guint8* _tmp45_;
- gint _tmp45__length1;
- gint _tmp46_;
- gint _tmp47_;
- gint _tmp48_;
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp39_ = _tmp38_;
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (!_tmp39_) {
-#line 3206 "page.c"
- gint _tmp40_;
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp40_ = x;
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- x = _tmp40_ + 1;
-#line 3212 "page.c"
+#line 2679 "page.c"
+ gboolean _tmp45_ = FALSE;
+ gint _tmp47_ = 0;
+ gint _tmp48_ = 0;
+ gint _tmp49_ = 0;
+ gint _tmp50_ = 0;
+ guint8* _tmp51_ = NULL;
+ gint _tmp51__length1 = 0;
+ gint _tmp52_ = 0;
+ gint _tmp53_ = 0;
+ gint _tmp54_ = 0;
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp45_ = _tmp44_;
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (!_tmp45_) {
+#line 2694 "page.c"
+ gint _tmp46_ = 0;
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp46_ = x;
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ x = _tmp46_ + 1;
+#line 2700 "page.c"
}
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp38_ = FALSE;
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp41_ = x;
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp42_ = r;
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- if (!(_tmp41_ < _tmp42_)) {
-#line 662 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp44_ = FALSE;
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp47_ = x;
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp48_ = r;
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (!(_tmp47_ < _tmp48_)) {
+#line 620 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
break;
-#line 3224 "page.c"
+#line 2712 "page.c"
}
-#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp43_ = x;
-#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp44_ = y;
-#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp45_ = image_pixels;
-#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp45__length1 = image_pixels_length1;
-#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp46_ = offset;
-#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp47_ = x;
-#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp48_ = l;
-#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- page_get_pixel (self, _tmp43_, _tmp44_, _tmp45_, _tmp45__length1, _tmp46_ + ((_tmp47_ - _tmp48_) * 3));
-#line 3242 "page.c"
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp49_ = x;
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp50_ = y;
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp51_ = image_pixels;
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp51__length1 = image_pixels_length1;
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp52_ = offset;
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp53_ = x;
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp54_ = l;
+#line 621 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_get_pixel (self, _tmp49_, _tmp50_, _tmp51_, _tmp51__length1, _tmp52_ + ((_tmp53_ - _tmp54_) * 3));
+#line 2730 "page.c"
}
}
}
}
}
}
-#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 624 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
result = image;
-#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 624 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return result;
-#line 3253 "page.c"
+#line 2741 "page.c"
}
static gchar* string_to_utf8 (const gchar* self, int* result_length1) {
gchar* result = NULL;
- gint _tmp0_;
- gint _tmp1_;
+ gchar* _result_ = NULL;
+ gint _tmp0_ = 0;
+ gint _tmp1_ = 0;
gchar* _tmp2_ = NULL;
- gchar* _result_;
- gint _result__length1;
- gint __result__size_;
- gint _tmp3_;
- gchar* _tmp4_;
- gint _tmp4__length1;
- gint _tmp5_;
- gint _tmp6_;
- gchar* _tmp7_;
- gint _tmp7__length1;
-#line 1267 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+ gint _result__length1 = 0;
+ gint __result__size_ = 0;
+ gint _tmp3_ = 0;
+ gchar* _tmp4_ = NULL;
+ gint _tmp4__length1 = 0;
+ gint _tmp5_ = 0;
+ gint _tmp6_ = 0;
+ gchar* _tmp7_ = NULL;
+ gint _tmp7__length1 = 0;
+#line 1266 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
g_return_val_if_fail (self != NULL, NULL);
-#line 1268 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1267 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_tmp0_ = strlen (self);
-#line 1268 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1267 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_tmp1_ = _tmp0_;
-#line 1268 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1267 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_tmp2_ = g_new0 (gchar, _tmp1_ + 1);
-#line 1268 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1267 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_result_ = _tmp2_;
-#line 1268 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1267 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_result__length1 = _tmp1_ + 1;
-#line 1268 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1267 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
__result__size_ = _result__length1;
-#line 1269 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1268 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_tmp3_ = _result__length1;
-#line 1269 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1268 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_result__length1 = _tmp3_ - 1;
-#line 1270 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1269 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_tmp4_ = _result_;
-#line 1270 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1269 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_tmp4__length1 = _result__length1;
-#line 1270 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1269 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_tmp5_ = strlen (self);
-#line 1270 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1269 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_tmp6_ = _tmp5_;
-#line 1270 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1269 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
memcpy (_tmp4_, self, (gsize) _tmp6_);
-#line 1271 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1270 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_tmp7_ = _result_;
-#line 1271 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1270 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
_tmp7__length1 = _result__length1;
-#line 1271 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1270 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
if (result_length1) {
-#line 1271 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1270 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
*result_length1 = _tmp7__length1;
-#line 3308 "page.c"
+#line 2796 "page.c"
}
-#line 1271 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1270 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
result = _tmp7_;
-#line 1271 "/usr/share/vala-0.20/vapi/glib-2.0.vapi"
+#line 1270 "/usr/share/vala-0.22/vapi/glib-2.0.vapi"
return result;
-#line 3314 "page.c"
+#line 2802 "page.c"
}
static gchar* page_get_icc_data_encoded (Page* self, const gchar* icc_profile_filename) {
gchar* result = NULL;
gchar* contents = NULL;
- const gchar* _tmp4_;
+ const gchar* _tmp4_ = NULL;
gint _tmp5_ = 0;
gchar* _tmp6_ = NULL;
- guchar* _tmp7_;
- gint _tmp7__length1;
+ guchar* _tmp7_ = NULL;
+ gint _tmp7__length1 = 0;
gchar* _tmp8_ = NULL;
- gchar* _tmp9_;
+ gchar* _tmp9_ = NULL;
GError * _inner_error_ = NULL;
-#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_val_if_fail (self != NULL, NULL);
-#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 627 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_val_if_fail (icc_profile_filename != NULL, NULL);
-#line 3333 "page.c"
+#line 2821 "page.c"
{
- const gchar* _tmp0_;
+ const gchar* _tmp0_ = NULL;
gchar* _tmp1_ = NULL;
-#line 675 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = icc_profile_filename;
-#line 675 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_file_get_contents (_tmp0_, &_tmp1_, NULL, &_inner_error_);
-#line 675 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_free0 (contents);
-#line 675 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
contents = _tmp1_;
-#line 675 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 633 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_inner_error_ != NULL) {
-#line 3347 "page.c"
+#line 2835 "page.c"
goto __catch3_g_error;
}
}
@@ -3351,615 +2839,1445 @@ static gchar* page_get_icc_data_encoded (Page* self, const gchar* icc_profile_fi
__catch3_g_error:
{
GError* e = NULL;
- GError* _tmp2_;
- const gchar* _tmp3_;
-#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ GError* _tmp2_ = NULL;
+ const gchar* _tmp3_ = NULL;
+#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
e = _inner_error_;
-#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_inner_error_ = NULL;
-#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 637 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp2_ = e;
-#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 637 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = _tmp2_->message;
-#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- g_warning ("page.vala:679: failed to get icc profile data: %s", _tmp3_);
-#line 680 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 637 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_warning ("page.vala:637: failed to get icc profile data: %s", _tmp3_);
+#line 638 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
result = NULL;
-#line 680 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 638 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_error_free0 (e);
-#line 680 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 638 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_free0 (contents);
-#line 680 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 638 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return result;
-#line 3375 "page.c"
+#line 2863 "page.c"
}
__finally3:
-#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_inner_error_ != NULL) {
-#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_free0 (contents);
-#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.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 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_clear_error (&_inner_error_);
-#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 631 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return NULL;
-#line 3388 "page.c"
+#line 2876 "page.c"
}
-#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp4_ = contents;
-#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp6_ = string_to_utf8 (_tmp4_, &_tmp5_);
-#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp7_ = (guchar*) _tmp6_;
-#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp7__length1 = (_tmp5_ * sizeof (gchar)) / sizeof (guchar);
-#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp8_ = g_base64_encode (_tmp7_, (_tmp5_ * sizeof (gchar)) / sizeof (guchar));
-#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp9_ = _tmp8_;
-#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp7_ = (g_free (_tmp7_), NULL);
-#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
result = _tmp9_;
-#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_free0 (contents);
-#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 642 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return result;
-#line 3410 "page.c"
+#line 2898 "page.c"
}
static gpointer _g_object_ref0 (gpointer self) {
-#line 689 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 647 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return self ? g_object_ref (self) : NULL;
-#line 3417 "page.c"
+#line 2905 "page.c"
}
void page_copy_to_clipboard (Page* self, GtkWindow* window) {
- GtkWindow* _tmp0_;
+ GdkDisplay* display = NULL;
+ GtkWindow* _tmp0_ = NULL;
GdkDisplay* _tmp1_ = NULL;
- GdkDisplay* _tmp2_;
- GdkDisplay* display;
+ GdkDisplay* _tmp2_ = NULL;
+ GtkClipboard* clipboard = NULL;
GtkClipboard* _tmp3_ = NULL;
- GtkClipboard* _tmp4_;
- GtkClipboard* clipboard;
+ GtkClipboard* _tmp4_ = NULL;
+ GdkPixbuf* image = NULL;
GdkPixbuf* _tmp5_ = NULL;
- GdkPixbuf* image;
-#line 687 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 645 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 687 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 645 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (window != NULL);
-#line 689 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 647 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = window;
-#line 689 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 647 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = gtk_widget_get_display ((GtkWidget*) _tmp0_);
-#line 689 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 647 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp2_ = _g_object_ref0 (_tmp1_);
-#line 689 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 647 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
display = _tmp2_;
-#line 690 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 648 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = gtk_clipboard_get_for_display (display, GDK_SELECTION_CLIPBOARD);
-#line 690 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 648 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp4_ = _g_object_ref0 (_tmp3_);
-#line 690 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 648 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
clipboard = _tmp4_;
-#line 691 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 649 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp5_ = page_get_image (self, TRUE);
-#line 691 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 649 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
image = _tmp5_;
-#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 650 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
gtk_clipboard_set_image (clipboard, image);
-#line 687 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 645 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (image);
-#line 687 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 645 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (clipboard);
-#line 687 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 645 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (display);
-#line 3461 "page.c"
+#line 2949 "page.c"
}
void page_save (Page* self, const gchar* type, gint quality, GFile* file, GError** error) {
- GFile* _tmp0_;
+ GFileOutputStream* stream = NULL;
+ GFile* _tmp0_ = NULL;
GFileOutputStream* _tmp1_ = NULL;
- GFileOutputStream* stream;
- GFileOutputStream* _tmp2_;
- PixbufWriter* _tmp3_;
- PixbufWriter* writer;
+ PixbufWriter* writer = NULL;
+ GFileOutputStream* _tmp2_ = NULL;
+ PixbufWriter* _tmp3_ = NULL;
+ GdkPixbuf* image = NULL;
GdkPixbuf* _tmp4_ = NULL;
- GdkPixbuf* image;
- gchar* icc_profile_data;
- const gchar* _tmp5_;
- GCompareFunc _tmp8_;
- const gchar* _tmp9_;
+ gchar* icc_profile_data = NULL;
+ const gchar* _tmp5_ = NULL;
+ GCompareFunc _tmp8_ = NULL;
+ const gchar* _tmp9_ = NULL;
gint _tmp10_ = 0;
GError * _inner_error_ = NULL;
-#line 695 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 695 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (type != NULL);
-#line 695 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (file != NULL);
-#line 697 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 655 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = file;
-#line 697 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 655 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = g_file_replace (_tmp0_, NULL, FALSE, G_FILE_CREATE_NONE, NULL, &_inner_error_);
-#line 697 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 655 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
stream = _tmp1_;
-#line 697 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 655 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_inner_error_ != NULL) {
-#line 697 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 655 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_propagate_error (error, _inner_error_);
-#line 697 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 655 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 3498 "page.c"
+#line 2986 "page.c"
}
-#line 698 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 656 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp2_ = stream;
-#line 698 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 656 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = pixbuf_writer_new (_tmp2_);
-#line 698 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 656 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
writer = _tmp3_;
-#line 699 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 657 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp4_ = page_get_image (self, TRUE);
-#line 699 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 657 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
image = _tmp4_;
-#line 701 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 659 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
icc_profile_data = NULL;
-#line 702 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp5_ = self->priv->color_profile;
-#line 702 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 660 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp5_ = self->priv->_color_profile;
+#line 660 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp5_ != NULL) {
-#line 3516 "page.c"
- const gchar* _tmp6_;
+#line 3004 "page.c"
+ const gchar* _tmp6_ = NULL;
gchar* _tmp7_ = NULL;
-#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp6_ = self->priv->color_profile;
-#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp6_ = self->priv->_color_profile;
+#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp7_ = page_get_icc_data_encoded (self, _tmp6_);
-#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_free0 (icc_profile_data);
-#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 661 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
icc_profile_data = _tmp7_;
-#line 3527 "page.c"
+#line 3015 "page.c"
}
-#line 705 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp8_ = g_strcmp0;
-#line 705 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp9_ = type;
-#line 705 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp10_ = _tmp8_ (_tmp9_, "jpeg");
-#line 705 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp10_ == 0) {
-#line 3537 "page.c"
- gchar* _tmp11_;
- gchar* _tmp12_;
- gchar* _tmp13_;
- gchar* _tmp14_;
- gchar* _tmp15_;
+#line 3025 "page.c"
+ gchar** keys = NULL;
+ gchar* _tmp11_ = NULL;
+ gchar* _tmp12_ = NULL;
+ gchar* _tmp13_ = NULL;
+ gchar* _tmp14_ = NULL;
+ gchar* _tmp15_ = NULL;
gchar** _tmp16_ = NULL;
- gchar** keys;
- gint keys_length1;
- gint _keys_size_;
- gint _tmp17_;
+ gint keys_length1 = 0;
+ gint _keys_size_ = 0;
+ gchar** values = NULL;
+ gint _tmp17_ = 0;
gchar* _tmp18_ = NULL;
- gchar* _tmp19_;
- gint _tmp20_;
+ gchar* _tmp19_ = NULL;
+ gint _tmp20_ = 0;
gchar* _tmp21_ = NULL;
- gint _tmp22_;
+ gint _tmp22_ = 0;
gchar* _tmp23_ = NULL;
- const gchar* _tmp24_;
- gchar* _tmp25_;
+ const gchar* _tmp24_ = NULL;
+ gchar* _tmp25_ = NULL;
gchar** _tmp26_ = NULL;
- gchar** values;
- gint values_length1;
- gint _values_size_;
- const gchar* _tmp27_;
- PixbufWriter* _tmp30_;
- GdkPixbuf* _tmp31_;
- gchar** _tmp32_;
- gint _tmp32__length1;
- gchar** _tmp33_;
- gint _tmp33__length1;
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint values_length1 = 0;
+ gint _values_size_ = 0;
+ const gchar* _tmp27_ = NULL;
+ PixbufWriter* _tmp30_ = NULL;
+ GdkPixbuf* _tmp31_ = NULL;
+ gchar** _tmp32_ = NULL;
+ gint _tmp32__length1 = 0;
+ gchar** _tmp33_ = NULL;
+ gint _tmp33__length1 = 0;
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp11_ = g_strdup ("quality");
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp12_ = g_strdup ("density-unit");
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp13_ = g_strdup ("x-density");
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp14_ = g_strdup ("y-density");
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp15_ = g_strdup ("icc-profile");
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp16_ = g_new0 (gchar*, 6 + 1);
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp16_[0] = _tmp11_;
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp16_[1] = _tmp12_;
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp16_[2] = _tmp13_;
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp16_[3] = _tmp14_;
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp16_[4] = _tmp15_;
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp16_[5] = NULL;
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
keys = _tmp16_;
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
keys_length1 = 6;
-#line 707 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 665 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_keys_size_ = keys_length1;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp17_ = quality;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp18_ = g_strdup_printf ("%d", _tmp17_);
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp19_ = g_strdup ("dots-per-inch");
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp20_ = self->priv->dpi;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp20_ = self->priv->_dpi;
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp21_ = g_strdup_printf ("%d", _tmp20_);
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _tmp22_ = self->priv->dpi;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp22_ = self->priv->_dpi;
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp23_ = g_strdup_printf ("%d", _tmp22_);
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp24_ = icc_profile_data;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp25_ = g_strdup (_tmp24_);
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp26_ = g_new0 (gchar*, 6 + 1);
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp26_[0] = _tmp18_;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp26_[1] = _tmp19_;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp26_[2] = _tmp21_;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp26_[3] = _tmp23_;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp26_[4] = _tmp25_;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp26_[5] = NULL;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
values = _tmp26_;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
values_length1 = 6;
-#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 666 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_values_size_ = values_length1;
-#line 709 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 667 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp27_ = icc_profile_data;
-#line 709 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 667 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp27_ == NULL) {
-#line 3639 "page.c"
- gchar** _tmp28_;
- gint _tmp28__length1;
- gchar* _tmp29_;
-#line 710 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 3127 "page.c"
+ gchar** _tmp28_ = NULL;
+ gint _tmp28__length1 = 0;
+ gchar* _tmp29_ = NULL;
+#line 668 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp28_ = keys;
-#line 710 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 668 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp28__length1 = keys_length1;
-#line 710 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 668 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_free0 (_tmp28_[4]);
-#line 710 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 668 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp28_[4] = NULL;
-#line 710 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 668 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp29_ = _tmp28_[4];
-#line 3653 "page.c"
+#line 3141 "page.c"
}
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp30_ = writer;
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp31_ = image;
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp32_ = keys;
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp32__length1 = keys_length1;
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp33_ = values;
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp33__length1 = values_length1;
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
pixbuf_writer_save (_tmp30_, _tmp31_, "jpeg", _tmp32_, _tmp32__length1, _tmp33_, _tmp33__length1, &_inner_error_);
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_inner_error_ != NULL) {
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_propagate_error (error, _inner_error_);
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL);
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL);
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_free0 (icc_profile_data);
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (image);
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_pixbuf_writer_unref0 (writer);
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (stream);
-#line 711 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 669 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 3687 "page.c"
+#line 3175 "page.c"
}
-#line 705 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL);
-#line 705 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 663 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL);
-#line 3693 "page.c"
+#line 3181 "page.c"
} else {
- GCompareFunc _tmp34_;
- const gchar* _tmp35_;
+ GCompareFunc _tmp34_ = NULL;
+ const gchar* _tmp35_ = NULL;
gint _tmp36_ = 0;
-#line 713 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 671 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp34_ = g_strcmp0;
-#line 713 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 671 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp35_ = type;
-#line 713 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 671 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp36_ = _tmp34_ (_tmp35_, "png");
-#line 713 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 671 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp36_ == 0) {
-#line 3706 "page.c"
- gchar* _tmp37_;
+#line 3194 "page.c"
+ gchar** keys = NULL;
+ gchar* _tmp37_ = NULL;
gchar** _tmp38_ = NULL;
- gchar** keys;
- gint keys_length1;
- gint _keys_size_;
- const gchar* _tmp39_;
- gchar* _tmp40_;
+ gint keys_length1 = 0;
+ gint _keys_size_ = 0;
+ gchar** values = NULL;
+ const gchar* _tmp39_ = NULL;
+ gchar* _tmp40_ = NULL;
gchar** _tmp41_ = NULL;
- gchar** values;
- gint values_length1;
- gint _values_size_;
- const gchar* _tmp42_;
- PixbufWriter* _tmp45_;
- GdkPixbuf* _tmp46_;
- gchar** _tmp47_;
- gint _tmp47__length1;
- gchar** _tmp48_;
- gint _tmp48__length1;
-#line 715 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint values_length1 = 0;
+ gint _values_size_ = 0;
+ const gchar* _tmp42_ = NULL;
+ PixbufWriter* _tmp45_ = NULL;
+ GdkPixbuf* _tmp46_ = NULL;
+ gchar** _tmp47_ = NULL;
+ gint _tmp47__length1 = 0;
+ gchar** _tmp48_ = NULL;
+ gint _tmp48__length1 = 0;
+#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp37_ = g_strdup ("icc-profile");
-#line 715 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp38_ = g_new0 (gchar*, 2 + 1);
-#line 715 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp38_[0] = _tmp37_;
-#line 715 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp38_[1] = NULL;
-#line 715 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
keys = _tmp38_;
-#line 715 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
keys_length1 = 2;
-#line 715 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 673 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_keys_size_ = keys_length1;
-#line 716 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp39_ = icc_profile_data;
-#line 716 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp40_ = g_strdup (_tmp39_);
-#line 716 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp41_ = g_new0 (gchar*, 2 + 1);
-#line 716 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp41_[0] = _tmp40_;
-#line 716 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp41_[1] = NULL;
-#line 716 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
values = _tmp41_;
-#line 716 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
values_length1 = 2;
-#line 716 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 674 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_values_size_ = values_length1;
-#line 717 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 675 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp42_ = icc_profile_data;
-#line 717 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 675 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp42_ == NULL) {
-#line 3759 "page.c"
- gchar** _tmp43_;
- gint _tmp43__length1;
- gchar* _tmp44_;
-#line 718 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 3247 "page.c"
+ gchar** _tmp43_ = NULL;
+ gint _tmp43__length1 = 0;
+ gchar* _tmp44_ = NULL;
+#line 676 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp43_ = keys;
-#line 718 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 676 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp43__length1 = keys_length1;
-#line 718 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 676 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_free0 (_tmp43_[0]);
-#line 718 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 676 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp43_[0] = NULL;
-#line 718 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 676 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp44_ = _tmp43_[0];
-#line 3773 "page.c"
+#line 3261 "page.c"
}
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp45_ = writer;
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp46_ = image;
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp47_ = keys;
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp47__length1 = keys_length1;
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp48_ = values;
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp48__length1 = values_length1;
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
pixbuf_writer_save (_tmp45_, _tmp46_, "png", _tmp47_, _tmp47__length1, _tmp48_, _tmp48__length1, &_inner_error_);
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_inner_error_ != NULL) {
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_propagate_error (error, _inner_error_);
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL);
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL);
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_free0 (icc_profile_data);
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (image);
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_pixbuf_writer_unref0 (writer);
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (stream);
-#line 719 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 677 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 3807 "page.c"
+#line 3295 "page.c"
}
-#line 713 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 671 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL);
-#line 713 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 671 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL);
-#line 3813 "page.c"
+#line 3301 "page.c"
} else {
- GCompareFunc _tmp49_;
- const gchar* _tmp50_;
+ GCompareFunc _tmp49_ = NULL;
+ const gchar* _tmp50_ = NULL;
gint _tmp51_ = 0;
-#line 721 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp49_ = g_strcmp0;
-#line 721 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp50_ = type;
-#line 721 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp51_ = _tmp49_ (_tmp50_, "tiff");
-#line 721 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp51_ == 0) {
-#line 3826 "page.c"
- gchar* _tmp52_;
- gchar* _tmp53_;
+#line 3314 "page.c"
+ gchar** keys = NULL;
+ gchar* _tmp52_ = NULL;
+ gchar* _tmp53_ = NULL;
gchar** _tmp54_ = NULL;
- gchar** keys;
- gint keys_length1;
- gint _keys_size_;
- gchar* _tmp55_;
- const gchar* _tmp56_;
- gchar* _tmp57_;
+ gint keys_length1 = 0;
+ gint _keys_size_ = 0;
+ gchar** values = NULL;
+ gchar* _tmp55_ = NULL;
+ const gchar* _tmp56_ = NULL;
+ gchar* _tmp57_ = NULL;
gchar** _tmp58_ = NULL;
- gchar** values;
- gint values_length1;
- gint _values_size_;
- const gchar* _tmp59_;
- PixbufWriter* _tmp62_;
- GdkPixbuf* _tmp63_;
- gchar** _tmp64_;
- gint _tmp64__length1;
- gchar** _tmp65_;
- gint _tmp65__length1;
-#line 723 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ gint values_length1 = 0;
+ gint _values_size_ = 0;
+ const gchar* _tmp59_ = NULL;
+ PixbufWriter* _tmp62_ = NULL;
+ GdkPixbuf* _tmp63_ = NULL;
+ gchar** _tmp64_ = NULL;
+ gint _tmp64__length1 = 0;
+ gchar** _tmp65_ = NULL;
+ gint _tmp65__length1 = 0;
+#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp52_ = g_strdup ("compression");
-#line 723 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp53_ = g_strdup ("icc-profile");
-#line 723 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp54_ = g_new0 (gchar*, 3 + 1);
-#line 723 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp54_[0] = _tmp52_;
-#line 723 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp54_[1] = _tmp53_;
-#line 723 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp54_[2] = NULL;
-#line 723 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
keys = _tmp54_;
-#line 723 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
keys_length1 = 3;
-#line 723 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 681 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_keys_size_ = keys_length1;
-#line 724 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp55_ = g_strdup ("8");
-#line 724 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp56_ = icc_profile_data;
-#line 724 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp57_ = g_strdup (_tmp56_);
-#line 724 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp58_ = g_new0 (gchar*, 3 + 1);
-#line 724 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp58_[0] = _tmp55_;
-#line 724 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp58_[1] = _tmp57_;
-#line 724 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp58_[2] = NULL;
-#line 724 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
values = _tmp58_;
-#line 724 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
values_length1 = 3;
-#line 724 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 682 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_values_size_ = values_length1;
-#line 725 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 683 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp59_ = icc_profile_data;
-#line 725 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 683 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_tmp59_ == NULL) {
-#line 3889 "page.c"
- gchar** _tmp60_;
- gint _tmp60__length1;
- gchar* _tmp61_;
-#line 726 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 3377 "page.c"
+ gchar** _tmp60_ = NULL;
+ gint _tmp60__length1 = 0;
+ gchar* _tmp61_ = NULL;
+#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp60_ = keys;
-#line 726 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp60__length1 = keys_length1;
-#line 726 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_free0 (_tmp60_[1]);
-#line 726 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp60_[1] = NULL;
-#line 726 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 684 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp61_ = _tmp60_[1];
-#line 3903 "page.c"
+#line 3391 "page.c"
}
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp62_ = writer;
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp63_ = image;
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp64_ = keys;
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp64__length1 = keys_length1;
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp65_ = values;
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp65__length1 = values_length1;
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
pixbuf_writer_save (_tmp62_, _tmp63_, "tiff", _tmp64_, _tmp64__length1, _tmp65_, _tmp65__length1, &_inner_error_);
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_inner_error_ != NULL) {
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_propagate_error (error, _inner_error_);
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL);
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL);
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_free0 (icc_profile_data);
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (image);
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_pixbuf_writer_unref0 (writer);
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (stream);
-#line 727 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 685 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 3937 "page.c"
+#line 3425 "page.c"
}
-#line 721 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
values = (_vala_array_free (values, values_length1, (GDestroyNotify) g_free), NULL);
-#line 721 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 679 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
keys = (_vala_array_free (keys, keys_length1, (GDestroyNotify) g_free), NULL);
-#line 3943 "page.c"
+#line 3431 "page.c"
} else {
}
}
}
-#line 695 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_free0 (icc_profile_data);
-#line 695 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (image);
-#line 695 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_pixbuf_writer_unref0 (writer);
-#line 695 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 653 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (stream);
-#line 3956 "page.c"
+#line 3444 "page.c"
+}
+
+
+gint page_get_width (Page* self) {
+ gint result;
+ gboolean _tmp0_ = FALSE;
+ ScanDirection _tmp1_ = 0;
+ ScanDirection _tmp2_ = 0;
+ gboolean _tmp5_ = FALSE;
+#line 25 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp1_ = page_get_scan_direction (self);
+#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp2_ = _tmp1_;
+#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp2_ == SCAN_DIRECTION_TOP_TO_BOTTOM) {
+#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = TRUE;
+#line 3464 "page.c"
+ } else {
+ ScanDirection _tmp3_ = 0;
+ ScanDirection _tmp4_ = 0;
+#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp3_ = page_get_scan_direction (self);
+#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp4_ = _tmp3_;
+#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = _tmp4_ == SCAN_DIRECTION_BOTTOM_TO_TOP;
+#line 3474 "page.c"
+ }
+#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp5_ = _tmp0_;
+#line 27 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp5_) {
+#line 3480 "page.c"
+ gint _tmp6_ = 0;
+#line 28 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp6_ = self->priv->_scan_width;
+#line 28 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp6_;
+#line 28 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3488 "page.c"
+ } else {
+ gint _tmp7_ = 0;
+#line 30 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp7_ = self->priv->_scan_height;
+#line 30 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp7_;
+#line 30 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3497 "page.c"
+ }
+}
+
+
+gint page_get_height (Page* self) {
+ gint result;
+ gboolean _tmp0_ = FALSE;
+ ScanDirection _tmp1_ = 0;
+ ScanDirection _tmp2_ = 0;
+ gboolean _tmp5_ = FALSE;
+#line 37 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp1_ = page_get_scan_direction (self);
+#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp2_ = _tmp1_;
+#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp2_ == SCAN_DIRECTION_TOP_TO_BOTTOM) {
+#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = TRUE;
+#line 3518 "page.c"
+ } else {
+ ScanDirection _tmp3_ = 0;
+ ScanDirection _tmp4_ = 0;
+#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp3_ = page_get_scan_direction (self);
+#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp4_ = _tmp3_;
+#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = _tmp4_ == SCAN_DIRECTION_BOTTOM_TO_TOP;
+#line 3528 "page.c"
+ }
+#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp5_ = _tmp0_;
+#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp5_) {
+#line 3534 "page.c"
+ gint _tmp6_ = 0;
+#line 40 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp6_ = self->priv->_scan_height;
+#line 40 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp6_;
+#line 40 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3542 "page.c"
+ } else {
+ gint _tmp7_ = 0;
+#line 42 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp7_ = self->priv->_scan_width;
+#line 42 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp7_;
+#line 42 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3551 "page.c"
+ }
+}
+
+
+gboolean page_get_is_landscape (Page* self) {
+ gboolean result;
+ gint _tmp0_ = 0;
+ gint _tmp1_ = 0;
+ gint _tmp2_ = 0;
+ gint _tmp3_ = 0;
+#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, FALSE);
+#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = page_get_width (self);
+#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp1_ = _tmp0_;
+#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp2_ = page_get_height (self);
+#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp3_ = _tmp2_;
+#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp1_ > _tmp3_;
+#line 47 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3576 "page.c"
+}
+
+
+gint page_get_dpi (Page* self) {
+ gint result;
+ gint _tmp0_ = 0;
+#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_dpi;
+#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3591 "page.c"
+}
+
+
+static void page_set_dpi (Page* self, gint value) {
+ gint _tmp0_ = 0;
+#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 50 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_dpi = _tmp0_;
+#line 3603 "page.c"
+}
+
+
+gint page_get_depth (Page* self) {
+ gint result;
+ gint _tmp0_ = 0;
+#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_depth;
+#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3618 "page.c"
+}
+
+
+static void page_set_depth (Page* self, gint value) {
+ gint _tmp0_ = 0;
+#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 56 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_depth = _tmp0_;
+#line 3630 "page.c"
+}
+
+
+const gchar* page_get_color_profile (Page* self) {
+ const gchar* result;
+ const gchar* _tmp0_ = NULL;
+#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, NULL);
+#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_color_profile;
+#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3645 "page.c"
+}
+
+
+void page_set_color_profile (Page* self, const gchar* value) {
+ const gchar* _tmp0_ = NULL;
+ gchar* _tmp1_ = NULL;
+#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp1_ = g_strdup (_tmp0_);
+#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _g_free0 (self->priv->_color_profile);
+#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_color_profile = _tmp1_;
+#line 3662 "page.c"
+}
+
+
+gint page_get_scan_width (Page* self) {
+ gint result;
+ gint _tmp0_ = 0;
+#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_scan_width;
+#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3677 "page.c"
+}
+
+
+static void page_set_scan_width (Page* self, gint value) {
+ gint _tmp0_ = 0;
+#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 62 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_scan_width = _tmp0_;
+#line 3689 "page.c"
+}
+
+
+gint page_get_scan_height (Page* self) {
+ gint result;
+ gint _tmp0_ = 0;
+#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_scan_height;
+#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3704 "page.c"
+}
+
+
+static void page_set_scan_height (Page* self, gint value) {
+ gint _tmp0_ = 0;
+#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 65 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_scan_height = _tmp0_;
+#line 3716 "page.c"
+}
+
+
+gint page_get_rowstride (Page* self) {
+ gint result;
+ gint _tmp0_ = 0;
+#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_rowstride;
+#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3731 "page.c"
+}
+
+
+static void page_set_rowstride (Page* self, gint value) {
+ gint _tmp0_ = 0;
+#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 68 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_rowstride = _tmp0_;
+#line 3743 "page.c"
+}
+
+
+gint page_get_n_channels (Page* self) {
+ gint result;
+ gint _tmp0_ = 0;
+#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_n_channels;
+#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3758 "page.c"
+}
+
+
+static void page_set_n_channels (Page* self, gint value) {
+ gint _tmp0_ = 0;
+#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 71 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_n_channels = _tmp0_;
+#line 3770 "page.c"
+}
+
+
+gboolean page_get_is_scanning (Page* self) {
+ gboolean result;
+ gboolean _tmp0_ = FALSE;
+#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, FALSE);
+#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_is_scanning;
+#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3785 "page.c"
+}
+
+
+static void page_set_is_scanning (Page* self, gboolean value) {
+ gboolean _tmp0_ = FALSE;
+#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 77 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_is_scanning = _tmp0_;
+#line 3797 "page.c"
+}
+
+
+gboolean page_get_has_data (Page* self) {
+ gboolean result;
+ gboolean _tmp0_ = FALSE;
+#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, FALSE);
+#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_has_data;
+#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3812 "page.c"
+}
+
+
+static void page_set_has_data (Page* self, gboolean value) {
+ gboolean _tmp0_ = FALSE;
+#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 80 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_has_data = _tmp0_;
+#line 3824 "page.c"
+}
+
+
+gint page_get_scan_line (Page* self) {
+ gint result;
+ gint _tmp0_ = 0;
+#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_scan_line;
+#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3839 "page.c"
+}
+
+
+static void page_set_scan_line (Page* self, gint value) {
+ gint _tmp0_ = 0;
+#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 83 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_scan_line = _tmp0_;
+#line 3851 "page.c"
+}
+
+
+gboolean page_get_is_color (Page* self) {
+ gboolean result;
+ gint _tmp0_ = 0;
+#line 86 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, FALSE);
+#line 86 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_n_channels;
+#line 86 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_ > 1;
+#line 86 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3866 "page.c"
+}
+
+
+ScanDirection page_get_scan_direction (Page* self) {
+ ScanDirection result;
+ ScanDirection _tmp0_ = 0;
+#line 92 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 92 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->scan_direction_;
+#line 92 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 92 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 3881 "page.c"
+}
+
+
+void page_set_scan_direction (Page* self, ScanDirection value) {
+ ScanDirection _tmp0_ = 0;
+ ScanDirection _tmp1_ = 0;
+ gboolean size_has_changed = FALSE;
+ gint left_steps = 0;
+ ScanDirection _tmp2_ = 0;
+ ScanDirection _tmp3_ = 0;
+ gint _tmp4_ = 0;
+ gint _tmp6_ = 0;
+ gboolean _tmp7_ = FALSE;
+ ScanDirection _tmp35_ = 0;
+ gboolean _tmp36_ = FALSE;
+ gboolean _tmp37_ = FALSE;
+#line 94 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 96 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->scan_direction_;
+#line 96 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp1_ = value;
+#line 96 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp0_ == _tmp1_) {
+#line 97 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return;
+#line 3908 "page.c"
+ }
+#line 100 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ size_has_changed = FALSE;
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp2_ = value;
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp3_ = self->priv->scan_direction_;
+#line 101 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ left_steps = (gint) (_tmp2_ - _tmp3_);
+#line 102 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp4_ = left_steps;
+#line 102 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp4_ < 0) {
+#line 3922 "page.c"
+ gint _tmp5_ = 0;
+#line 103 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp5_ = left_steps;
+#line 103 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ left_steps = _tmp5_ + 4;
+#line 3928 "page.c"
+ }
+#line 104 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp6_ = left_steps;
+#line 104 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp6_ != 2) {
+#line 105 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ size_has_changed = TRUE;
+#line 3936 "page.c"
+ }
+#line 108 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp7_ = self->priv->_has_crop;
+#line 108 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp7_) {
+#line 3942 "page.c"
+ gint _tmp8_ = 0;
+#line 110 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp8_ = left_steps;
+#line 110 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ switch (_tmp8_) {
+#line 110 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ case 1:
+#line 3950 "page.c"
+ {
+ gint t = 0;
+ gint _tmp9_ = 0;
+ gint _tmp10_ = 0;
+ gint _tmp11_ = 0;
+ gint _tmp12_ = 0;
+ gint _tmp13_ = 0;
+ gint _tmp14_ = 0;
+ gint _tmp15_ = 0;
+ gint _tmp16_ = 0;
+ gint _tmp17_ = 0;
+#line 114 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp9_ = self->priv->_crop_x;
+#line 114 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ t = _tmp9_;
+#line 115 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp10_ = self->priv->_crop_y;
+#line 115 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_x (self, _tmp10_);
+#line 116 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp11_ = page_get_width (self);
+#line 116 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp12_ = _tmp11_;
+#line 116 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp13_ = t;
+#line 116 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp14_ = self->priv->_crop_width;
+#line 116 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_y (self, _tmp12_ - (_tmp13_ + _tmp14_));
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp15_ = self->priv->_crop_width;
+#line 117 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ t = _tmp15_;
+#line 118 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp16_ = self->priv->_crop_height;
+#line 118 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_width (self, _tmp16_);
+#line 119 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp17_ = t;
+#line 119 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_height (self, _tmp17_);
+#line 120 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ break;
+#line 3994 "page.c"
+ }
+#line 110 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ case 2:
+#line 3998 "page.c"
+ {
+ gint _tmp18_ = 0;
+ gint _tmp19_ = 0;
+ gint _tmp20_ = 0;
+ gint _tmp21_ = 0;
+ gint _tmp22_ = 0;
+ gint _tmp23_ = 0;
+ gint _tmp24_ = 0;
+ gint _tmp25_ = 0;
+#line 123 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp18_ = page_get_width (self);
+#line 123 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp19_ = _tmp18_;
+#line 123 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp20_ = self->priv->_crop_x;
+#line 123 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp21_ = self->priv->_crop_width;
+#line 123 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_x (self, _tmp19_ - (_tmp20_ + _tmp21_));
+#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp22_ = page_get_width (self);
+#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp23_ = _tmp22_;
+#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp24_ = self->priv->_crop_y;
+#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp25_ = self->priv->_crop_height;
+#line 124 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_y (self, _tmp23_ - (_tmp24_ + _tmp25_));
+#line 125 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ break;
+#line 4030 "page.c"
+ }
+#line 110 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ case 3:
+#line 4034 "page.c"
+ {
+ gint t = 0;
+ gint _tmp26_ = 0;
+ gint _tmp27_ = 0;
+ gint _tmp28_ = 0;
+ gint _tmp29_ = 0;
+ gint _tmp30_ = 0;
+ gint _tmp31_ = 0;
+ gint _tmp32_ = 0;
+ gint _tmp33_ = 0;
+ gint _tmp34_ = 0;
+#line 128 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp26_ = self->priv->_crop_y;
+#line 128 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ t = _tmp26_;
+#line 129 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp27_ = self->priv->_crop_x;
+#line 129 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_y (self, _tmp27_);
+#line 130 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp28_ = page_get_height (self);
+#line 130 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp29_ = _tmp28_;
+#line 130 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp30_ = t;
+#line 130 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp31_ = self->priv->_crop_height;
+#line 130 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_x (self, _tmp29_ - (_tmp30_ + _tmp31_));
+#line 131 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp32_ = self->priv->_crop_width;
+#line 131 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ t = _tmp32_;
+#line 132 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp33_ = self->priv->_crop_height;
+#line 132 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_width (self, _tmp33_);
+#line 133 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp34_ = t;
+#line 133 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ page_set_crop_height (self, _tmp34_);
+#line 134 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ break;
+#line 4078 "page.c"
+ }
+ default:
+#line 110 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ break;
+#line 4083 "page.c"
+ }
+ }
+#line 138 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp35_ = value;
+#line 138 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->scan_direction_ = _tmp35_;
+#line 139 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp36_ = size_has_changed;
+#line 139 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp36_) {
+#line 140 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_signal_emit_by_name (self, "size-changed");
+#line 4096 "page.c"
+ }
+#line 141 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_signal_emit_by_name (self, "scan-direction-changed");
+#line 142 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp37_ = self->priv->_has_crop;
+#line 142 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ if (_tmp37_) {
+#line 143 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_signal_emit_by_name (self, "crop-changed");
+#line 4106 "page.c"
+ }
+}
+
+
+gboolean page_get_has_crop (Page* self) {
+ gboolean result;
+ gboolean _tmp0_ = FALSE;
+#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, FALSE);
+#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_has_crop;
+#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 4122 "page.c"
+}
+
+
+static void page_set_has_crop (Page* self, gboolean value) {
+ gboolean _tmp0_ = FALSE;
+#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 150 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_has_crop = _tmp0_;
+#line 4134 "page.c"
+}
+
+
+const gchar* page_get_crop_name (Page* self) {
+ const gchar* result;
+ const gchar* _tmp0_ = NULL;
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, NULL);
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_crop_name;
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 4149 "page.c"
+}
+
+
+static void page_set_crop_name (Page* self, const gchar* value) {
+ const gchar* _tmp0_ = NULL;
+ gchar* _tmp1_ = NULL;
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp1_ = g_strdup (_tmp0_);
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _g_free0 (self->priv->_crop_name);
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_crop_name = _tmp1_;
+#line 4166 "page.c"
+}
+
+
+gint page_get_crop_x (Page* self) {
+ gint result;
+ gint _tmp0_ = 0;
+#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_crop_x;
+#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 4181 "page.c"
+}
+
+
+static void page_set_crop_x (Page* self, gint value) {
+ gint _tmp0_ = 0;
+#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 156 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_crop_x = _tmp0_;
+#line 4193 "page.c"
+}
+
+
+gint page_get_crop_y (Page* self) {
+ gint result;
+ gint _tmp0_ = 0;
+#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_crop_y;
+#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 4208 "page.c"
+}
+
+
+static void page_set_crop_y (Page* self, gint value) {
+ gint _tmp0_ = 0;
+#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 159 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_crop_y = _tmp0_;
+#line 4220 "page.c"
+}
+
+
+gint page_get_crop_width (Page* self) {
+ gint result;
+ gint _tmp0_ = 0;
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_crop_width;
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 4235 "page.c"
+}
+
+
+static void page_set_crop_width (Page* self, gint value) {
+ gint _tmp0_ = 0;
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 162 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_crop_width = _tmp0_;
+#line 4247 "page.c"
+}
+
+
+gint page_get_crop_height (Page* self) {
+ gint result;
+ gint _tmp0_ = 0;
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_val_if_fail (self != NULL, 0);
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = self->priv->_crop_height;
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ result = _tmp0_;
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ return result;
+#line 4262 "page.c"
+}
+
+
+static void page_set_crop_height (Page* self, gint value) {
+ gint _tmp0_ = 0;
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ g_return_if_fail (self != NULL);
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _tmp0_ = value;
+#line 165 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ self->priv->_crop_height = _tmp0_;
+#line 4274 "page.c"
}
static void value_page_init (GValue* value) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = NULL;
-#line 3963 "page.c"
+#line 4281 "page.c"
}
@@ -3968,7 +4286,7 @@ static void value_page_free_value (GValue* value) {
if (value->data[0].v_pointer) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
page_unref (value->data[0].v_pointer);
-#line 3972 "page.c"
+#line 4290 "page.c"
}
}
@@ -3978,11 +4296,11 @@ static void value_page_copy_value (const GValue* src_value, GValue* dest_value)
if (src_value->data[0].v_pointer) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
dest_value->data[0].v_pointer = page_ref (src_value->data[0].v_pointer);
-#line 3982 "page.c"
+#line 4300 "page.c"
} else {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
dest_value->data[0].v_pointer = NULL;
-#line 3986 "page.c"
+#line 4304 "page.c"
}
}
@@ -3990,37 +4308,37 @@ static void value_page_copy_value (const GValue* src_value, GValue* dest_value)
static gpointer value_page_peek_pointer (const GValue* value) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return value->data[0].v_pointer;
-#line 3994 "page.c"
+#line 4312 "page.c"
}
static gchar* value_page_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (collect_values[0].v_pointer) {
-#line 4001 "page.c"
+#line 4319 "page.c"
Page* object;
object = collect_values[0].v_pointer;
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (object->parent_instance.g_class == NULL) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
-#line 4008 "page.c"
+#line 4326 "page.c"
} else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.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 4012 "page.c"
+#line 4330 "page.c"
}
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = page_ref (object);
-#line 4016 "page.c"
+#line 4334 "page.c"
} else {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = NULL;
-#line 4020 "page.c"
+#line 4338 "page.c"
}
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return NULL;
-#line 4024 "page.c"
+#line 4342 "page.c"
}
@@ -4031,25 +4349,25 @@ static gchar* value_page_lcopy_value (const GValue* value, guint n_collect_value
if (!object_p) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value));
-#line 4035 "page.c"
+#line 4353 "page.c"
}
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (!value->data[0].v_pointer) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
*object_p = NULL;
-#line 4041 "page.c"
+#line 4359 "page.c"
} else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
*object_p = value->data[0].v_pointer;
-#line 4045 "page.c"
+#line 4363 "page.c"
} else {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
*object_p = page_ref (value->data[0].v_pointer);
-#line 4049 "page.c"
+#line 4367 "page.c"
}
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return NULL;
-#line 4053 "page.c"
+#line 4371 "page.c"
}
@@ -4063,7 +4381,7 @@ GParamSpec* param_spec_page (const gchar* name, const gchar* nick, const gchar*
G_PARAM_SPEC (spec)->value_type = object_type;
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return G_PARAM_SPEC (spec);
-#line 4067 "page.c"
+#line 4385 "page.c"
}
@@ -4072,7 +4390,7 @@ gpointer value_get_page (const GValue* value) {
g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PAGE), NULL);
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return value->data[0].v_pointer;
-#line 4076 "page.c"
+#line 4394 "page.c"
}
@@ -4092,17 +4410,17 @@ void value_set_page (GValue* value, gpointer v_object) {
value->data[0].v_pointer = v_object;
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
page_ref (value->data[0].v_pointer);
-#line 4096 "page.c"
+#line 4414 "page.c"
} else {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = NULL;
-#line 4100 "page.c"
+#line 4418 "page.c"
}
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (old) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
page_unref (old);
-#line 4106 "page.c"
+#line 4424 "page.c"
}
}
@@ -4121,17 +4439,17 @@ void value_take_page (GValue* value, gpointer v_object) {
g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = v_object;
-#line 4125 "page.c"
+#line 4443 "page.c"
} else {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = NULL;
-#line 4129 "page.c"
+#line 4447 "page.c"
}
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (old) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
page_unref (old);
-#line 4135 "page.c"
+#line 4453 "page.c"
}
}
@@ -4155,18 +4473,16 @@ static void page_class_init (PageClass * klass) {
g_signal_new ("crop_changed", TYPE_PAGE, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_signal_new ("scan_finished", TYPE_PAGE, G_SIGNAL_RUN_LAST, 0, NULL, NULL, g_cclosure_marshal_VOID__VOID, G_TYPE_NONE, 0);
-#line 4159 "page.c"
+#line 4477 "page.c"
}
static void page_instance_init (Page * self) {
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->priv = PAGE_GET_PRIVATE (self);
-#line 51 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- self->priv->scan_direction = SCAN_DIRECTION_TOP_TO_BOTTOM;
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->ref_count = 1;
-#line 4170 "page.c"
+#line 4486 "page.c"
}
@@ -4174,13 +4490,13 @@ static void page_finalize (Page* obj) {
Page * self;
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_PAGE, Page);
-#line 32 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _g_free0 (self->priv->color_profile);
-#line 39 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 59 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _g_free0 (self->priv->_color_profile);
+#line 74 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->priv->pixels = (g_free (self->priv->pixels), NULL);
-#line 55 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
- _g_free0 (self->priv->crop_name);
-#line 4184 "page.c"
+#line 153 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ _g_free0 (self->priv->_crop_name);
+#line 4500 "page.c"
}
@@ -4205,7 +4521,7 @@ gpointer page_ref (gpointer instance) {
g_atomic_int_inc (&self->ref_count);
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return instance;
-#line 4209 "page.c"
+#line 4525 "page.c"
}
@@ -4218,323 +4534,323 @@ void page_unref (gpointer instance) {
PAGE_GET_CLASS (self)->finalize (self);
#line 20 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_type_free_instance ((GTypeInstance *) self);
-#line 4222 "page.c"
+#line 4538 "page.c"
}
}
PixbufWriter* pixbuf_writer_construct (GType object_type, GFileOutputStream* stream) {
PixbufWriter* self = NULL;
- GFileOutputStream* _tmp0_;
- GFileOutputStream* _tmp1_;
-#line 738 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+ GFileOutputStream* _tmp0_ = NULL;
+ GFileOutputStream* _tmp1_ = NULL;
+#line 696 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_val_if_fail (stream != NULL, NULL);
-#line 738 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 696 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self = (PixbufWriter*) g_type_create_instance (object_type);
-#line 740 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 698 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = stream;
-#line 740 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 698 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = _g_object_ref0 (_tmp0_);
-#line 740 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 698 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (self->stream);
-#line 740 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 698 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->stream = _tmp1_;
-#line 738 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 696 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return self;
-#line 4245 "page.c"
+#line 4561 "page.c"
}
PixbufWriter* pixbuf_writer_new (GFileOutputStream* stream) {
-#line 738 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 696 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return pixbuf_writer_construct (TYPE_PIXBUF_WRITER, stream);
-#line 4252 "page.c"
+#line 4568 "page.c"
}
static gboolean _pixbuf_writer_write_pixbuf_data_gdk_pixbuf_save_func (guint8* buf, gsize buf_length1, GError** error, gpointer self) {
gboolean result;
result = pixbuf_writer_write_pixbuf_data (self, buf, buf_length1, error);
-#line 745 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return result;
-#line 4261 "page.c"
+#line 4577 "page.c"
}
void pixbuf_writer_save (PixbufWriter* self, GdkPixbuf* image, const gchar* type, gchar** option_keys, int option_keys_length1, gchar** option_values, int option_values_length1, GError** error) {
- GdkPixbuf* _tmp0_;
- const gchar* _tmp1_;
- gchar** _tmp2_;
- gint _tmp2__length1;
- gchar** _tmp3_;
- gint _tmp3__length1;
+ GdkPixbuf* _tmp0_ = NULL;
+ const gchar* _tmp1_ = NULL;
+ gchar** _tmp2_ = NULL;
+ gint _tmp2__length1 = 0;
+ gchar** _tmp3_ = NULL;
+ gint _tmp3__length1 = 0;
GError * _inner_error_ = NULL;
-#line 743 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 701 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (self != NULL);
-#line 743 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 701 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (image != NULL);
-#line 743 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 701 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (type != NULL);
-#line 745 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = image;
-#line 745 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = type;
-#line 745 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp2_ = option_keys;
-#line 745 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp2__length1 = option_keys_length1;
-#line 745 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3_ = option_values;
-#line 745 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp3__length1 = option_values_length1;
-#line 745 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
gdk_pixbuf_save_to_callbackv (_tmp0_, _pixbuf_writer_write_pixbuf_data_gdk_pixbuf_save_func, self, _tmp1_, _tmp2_, _tmp3_, &_inner_error_);
-#line 745 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_inner_error_ != NULL) {
-#line 745 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_propagate_error (error, _inner_error_);
-#line 745 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 703 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return;
-#line 4299 "page.c"
+#line 4615 "page.c"
}
}
static gboolean pixbuf_writer_write_pixbuf_data (PixbufWriter* self, guint8* buf, int buf_length1, GError** error) {
gboolean result = FALSE;
- GFileOutputStream* _tmp0_;
- guint8* _tmp1_;
- gint _tmp1__length1;
+ GFileOutputStream* _tmp0_ = NULL;
+ guint8* _tmp1_ = NULL;
+ gint _tmp1__length1 = 0;
GError * _inner_error_ = NULL;
-#line 748 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 706 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_val_if_fail (self != NULL, FALSE);
-#line 750 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp0_ = self->stream;
-#line 750 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1_ = buf;
-#line 750 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_tmp1__length1 = buf_length1;
-#line 750 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_output_stream_write_all ((GOutputStream*) _tmp0_, _tmp1_, (gsize) _tmp1__length1, NULL, NULL, &_inner_error_);
-#line 750 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (_inner_error_ != NULL) {
-#line 750 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_propagate_error (error, _inner_error_);
-#line 750 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 708 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return FALSE;
-#line 4326 "page.c"
+#line 4642 "page.c"
}
-#line 751 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 709 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
result = TRUE;
-#line 751 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 709 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return result;
-#line 4332 "page.c"
+#line 4648 "page.c"
}
static void value_pixbuf_writer_init (GValue* value) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = NULL;
-#line 4339 "page.c"
+#line 4655 "page.c"
}
static void value_pixbuf_writer_free_value (GValue* value) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (value->data[0].v_pointer) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
pixbuf_writer_unref (value->data[0].v_pointer);
-#line 4348 "page.c"
+#line 4664 "page.c"
}
}
static void value_pixbuf_writer_copy_value (const GValue* src_value, GValue* dest_value) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (src_value->data[0].v_pointer) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
dest_value->data[0].v_pointer = pixbuf_writer_ref (src_value->data[0].v_pointer);
-#line 4358 "page.c"
+#line 4674 "page.c"
} else {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
dest_value->data[0].v_pointer = NULL;
-#line 4362 "page.c"
+#line 4678 "page.c"
}
}
static gpointer value_pixbuf_writer_peek_pointer (const GValue* value) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return value->data[0].v_pointer;
-#line 4370 "page.c"
+#line 4686 "page.c"
}
static gchar* value_pixbuf_writer_collect_value (GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (collect_values[0].v_pointer) {
-#line 4377 "page.c"
+#line 4693 "page.c"
PixbufWriter* object;
object = collect_values[0].v_pointer;
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (object->parent_instance.g_class == NULL) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return g_strconcat ("invalid unclassed object pointer for value type `", G_VALUE_TYPE_NAME (value), "'", NULL);
-#line 4384 "page.c"
+#line 4700 "page.c"
} else if (!g_value_type_compatible (G_TYPE_FROM_INSTANCE (object), G_VALUE_TYPE (value))) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.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 4388 "page.c"
+#line 4704 "page.c"
}
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = pixbuf_writer_ref (object);
-#line 4392 "page.c"
+#line 4708 "page.c"
} else {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = NULL;
-#line 4396 "page.c"
+#line 4712 "page.c"
}
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return NULL;
-#line 4400 "page.c"
+#line 4716 "page.c"
}
static gchar* value_pixbuf_writer_lcopy_value (const GValue* value, guint n_collect_values, GTypeCValue* collect_values, guint collect_flags) {
PixbufWriter** object_p;
object_p = collect_values[0].v_pointer;
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (!object_p) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return g_strdup_printf ("value location for `%s' passed as NULL", G_VALUE_TYPE_NAME (value));
-#line 4411 "page.c"
+#line 4727 "page.c"
}
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (!value->data[0].v_pointer) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
*object_p = NULL;
-#line 4417 "page.c"
+#line 4733 "page.c"
} else if (collect_flags & G_VALUE_NOCOPY_CONTENTS) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
*object_p = value->data[0].v_pointer;
-#line 4421 "page.c"
+#line 4737 "page.c"
} else {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
*object_p = pixbuf_writer_ref (value->data[0].v_pointer);
-#line 4425 "page.c"
+#line 4741 "page.c"
}
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return NULL;
-#line 4429 "page.c"
+#line 4745 "page.c"
}
GParamSpec* param_spec_pixbuf_writer (const gchar* name, const gchar* nick, const gchar* blurb, GType object_type, GParamFlags flags) {
ParamSpecPixbufWriter* spec;
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_val_if_fail (g_type_is_a (object_type, TYPE_PIXBUF_WRITER), NULL);
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
spec = g_param_spec_internal (G_TYPE_PARAM_OBJECT, name, nick, blurb, flags);
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
G_PARAM_SPEC (spec)->value_type = object_type;
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return G_PARAM_SPEC (spec);
-#line 4443 "page.c"
+#line 4759 "page.c"
}
gpointer value_get_pixbuf_writer (const GValue* value) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_val_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PIXBUF_WRITER), NULL);
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return value->data[0].v_pointer;
-#line 4452 "page.c"
+#line 4768 "page.c"
}
void value_set_pixbuf_writer (GValue* value, gpointer v_object) {
PixbufWriter* old;
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PIXBUF_WRITER));
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
old = value->data[0].v_pointer;
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (v_object) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PIXBUF_WRITER));
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = v_object;
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
pixbuf_writer_ref (value->data[0].v_pointer);
-#line 4472 "page.c"
+#line 4788 "page.c"
} else {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = NULL;
-#line 4476 "page.c"
+#line 4792 "page.c"
}
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (old) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
pixbuf_writer_unref (old);
-#line 4482 "page.c"
+#line 4798 "page.c"
}
}
void value_take_pixbuf_writer (GValue* value, gpointer v_object) {
PixbufWriter* old;
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (G_TYPE_CHECK_VALUE_TYPE (value, TYPE_PIXBUF_WRITER));
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
old = value->data[0].v_pointer;
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (v_object) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (G_TYPE_CHECK_INSTANCE_TYPE (v_object, TYPE_PIXBUF_WRITER));
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_return_if_fail (g_value_type_compatible (G_TYPE_FROM_INSTANCE (v_object), G_VALUE_TYPE (value)));
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = v_object;
-#line 4501 "page.c"
+#line 4817 "page.c"
} else {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
value->data[0].v_pointer = NULL;
-#line 4505 "page.c"
+#line 4821 "page.c"
}
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (old) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
pixbuf_writer_unref (old);
-#line 4511 "page.c"
+#line 4827 "page.c"
}
}
static void pixbuf_writer_class_init (PixbufWriterClass * klass) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
pixbuf_writer_parent_class = g_type_class_peek_parent (klass);
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
PIXBUF_WRITER_CLASS (klass)->finalize = pixbuf_writer_finalize;
-#line 4521 "page.c"
+#line 4837 "page.c"
}
static void pixbuf_writer_instance_init (PixbufWriter * self) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self->ref_count = 1;
-#line 4528 "page.c"
+#line 4844 "page.c"
}
static void pixbuf_writer_finalize (PixbufWriter* obj) {
PixbufWriter * self;
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
self = G_TYPE_CHECK_INSTANCE_CAST (obj, TYPE_PIXBUF_WRITER, PixbufWriter);
-#line 736 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 694 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
_g_object_unref0 (self->stream);
-#line 4538 "page.c"
+#line 4854 "page.c"
}
@@ -4555,24 +4871,24 @@ GType pixbuf_writer_get_type (void) {
gpointer pixbuf_writer_ref (gpointer instance) {
PixbufWriter* self;
self = instance;
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_atomic_int_inc (&self->ref_count);
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
return instance;
-#line 4563 "page.c"
+#line 4879 "page.c"
}
void pixbuf_writer_unref (gpointer instance) {
PixbufWriter* self;
self = instance;
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
if (g_atomic_int_dec_and_test (&self->ref_count)) {
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
PIXBUF_WRITER_GET_CLASS (self)->finalize (self);
-#line 734 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
+#line 692 "/home/bob/bzr/simple-scan/trunk/src/page.vala"
g_type_free_instance ((GTypeInstance *) self);
-#line 4576 "page.c"
+#line 4892 "page.c"
}
}