Mercurial > geeqie.yaz
comparison src/print.c @ 1437:a3d3208b0c50
gint -> gboolean.
author | zas_ |
---|---|
date | Sun, 15 Mar 2009 07:07:52 +0000 |
parents | 79937bc55f3a |
children | f879e7d94c6d |
comparison
equal
deleted
inserted
replaced
1436:d7a6fb7a90dd | 1437:a3d3208b0c50 |
---|---|
1523 } | 1523 } |
1524 | 1524 |
1525 static gint print_job_rgb_page_done(PrintWindow *pw) | 1525 static gint print_job_rgb_page_done(PrintWindow *pw) |
1526 { | 1526 { |
1527 gchar *pathl; | 1527 gchar *pathl; |
1528 gint ret = FALSE; | 1528 gboolean ret = FALSE; |
1529 | 1529 |
1530 if (!pw->job_pixbuf) return FALSE; | 1530 if (!pw->job_pixbuf) return FALSE; |
1531 | 1531 |
1532 pathl = path_from_utf8(pw->job_path); | 1532 pathl = path_from_utf8(pw->job_path); |
1533 | 1533 |
1622 dpi = (gdouble)int_dpi / PANGO_SCALE; | 1622 dpi = (gdouble)int_dpi / PANGO_SCALE; |
1623 } | 1623 } |
1624 | 1624 |
1625 if (dpi < 25.0) | 1625 if (dpi < 25.0) |
1626 { | 1626 { |
1627 static gint warned = FALSE; | 1627 static gboolean warned = FALSE; |
1628 gdouble fallback_dpi = 96.0; | 1628 gdouble fallback_dpi = 96.0; |
1629 | 1629 |
1630 if (!warned) | 1630 if (!warned) |
1631 { | 1631 { |
1632 if (dpi == 0.0) | 1632 if (dpi == 0.0) |
1907 | 1907 |
1908 static gint print_job_page_image(PrintWindow *pw, GdkPixbuf *pixbuf, | 1908 static gint print_job_page_image(PrintWindow *pw, GdkPixbuf *pixbuf, |
1909 gdouble x, gdouble y, gdouble w, gdouble h, | 1909 gdouble x, gdouble y, gdouble w, gdouble h, |
1910 gdouble offx, gdouble offy) | 1910 gdouble offx, gdouble offy) |
1911 { | 1911 { |
1912 gint success = FALSE; | 1912 gboolean success = FALSE; |
1913 | 1913 |
1914 if (w <= 0.0 || h <= 0.0) return TRUE; | 1914 if (w <= 0.0 || h <= 0.0) return TRUE; |
1915 | 1915 |
1916 switch (pw->job_format) | 1916 switch (pw->job_format) |
1917 { | 1917 { |
1931 | 1931 |
1932 static gint print_job_page_text(PrintWindow *pw, const gchar *text, gdouble point_size, | 1932 static gint print_job_page_text(PrintWindow *pw, const gchar *text, gdouble point_size, |
1933 gdouble x, gdouble y, gdouble width, | 1933 gdouble x, gdouble y, gdouble width, |
1934 guint8 r, guint8 g, guint8 b) | 1934 guint8 r, guint8 g, guint8 b) |
1935 { | 1935 { |
1936 gint success = TRUE; | 1936 gboolean success = TRUE; |
1937 | 1937 |
1938 if (!text) return TRUE; | 1938 if (!text) return TRUE; |
1939 | 1939 |
1940 switch (pw->job_format) | 1940 switch (pw->job_format) |
1941 { | 1941 { |
2032 static gint print_job_text_image(PrintWindow *pw, const gchar *path, | 2032 static gint print_job_text_image(PrintWindow *pw, const gchar *path, |
2033 gdouble x, gdouble y, gdouble width, | 2033 gdouble x, gdouble y, gdouble width, |
2034 gint sw, gint sh, gint proof) | 2034 gint sw, gint sh, gint proof) |
2035 { | 2035 { |
2036 GString *string; | 2036 GString *string; |
2037 gint space = FALSE; | 2037 gboolean space = FALSE; |
2038 gint newline = FALSE; | 2038 gboolean newline = FALSE; |
2039 gint ret; | 2039 gint ret; |
2040 | 2040 |
2041 if (pw->text_fields == 0) return TRUE; | 2041 if (pw->text_fields == 0) return TRUE; |
2042 | 2042 |
2043 string = g_string_new(""); | 2043 string = g_string_new(""); |
2095 | 2095 |
2096 static void print_job_render_image_loader_done(ImageLoader *il, gpointer data) | 2096 static void print_job_render_image_loader_done(ImageLoader *il, gpointer data) |
2097 { | 2097 { |
2098 PrintWindow *pw = data; | 2098 PrintWindow *pw = data; |
2099 GdkPixbuf *pixbuf; | 2099 GdkPixbuf *pixbuf; |
2100 gint success = TRUE; | 2100 gboolean success = TRUE; |
2101 | 2101 |
2102 pixbuf = image_loader_get_pixbuf(il); | 2102 pixbuf = image_loader_get_pixbuf(il); |
2103 if (pixbuf) | 2103 if (pixbuf) |
2104 { | 2104 { |
2105 gdouble sw, sh; | 2105 gdouble sw, sh; |
2234 gdouble x, y; | 2234 gdouble x, y; |
2235 gdouble w, h; | 2235 gdouble w, h; |
2236 gdouble proof_w, proof_h; | 2236 gdouble proof_w, proof_h; |
2237 gdouble icon_w, icon_h; | 2237 gdouble icon_w, icon_h; |
2238 gdouble scale; | 2238 gdouble scale; |
2239 gint success = TRUE; | 2239 gboolean success = TRUE; |
2240 | 2240 |
2241 if (pw->proof_columns < 1 || pw->proof_rows < 1) | 2241 if (pw->proof_columns < 1 || pw->proof_rows < 1) |
2242 { | 2242 { |
2243 image_loader_free(pw->job_loader); | 2243 image_loader_free(pw->job_loader); |
2244 pw->job_loader = NULL; | 2244 pw->job_loader = NULL; |
2434 if (finished) print_job_done(pw); | 2434 if (finished) print_job_done(pw); |
2435 } | 2435 } |
2436 | 2436 |
2437 static gint print_job_init(PrintWindow *pw) | 2437 static gint print_job_init(PrintWindow *pw) |
2438 { | 2438 { |
2439 gint success = FALSE; | 2439 gboolean success = FALSE; |
2440 | 2440 |
2441 pw->job_page = 0; | 2441 pw->job_page = 0; |
2442 | 2442 |
2443 switch (pw->job_format) | 2443 switch (pw->job_format) |
2444 { | 2444 { |
2457 return success; | 2457 return success; |
2458 } | 2458 } |
2459 | 2459 |
2460 static gint print_job_finish(PrintWindow *pw) | 2460 static gint print_job_finish(PrintWindow *pw) |
2461 { | 2461 { |
2462 gint success = FALSE; | 2462 gboolean success = FALSE; |
2463 | 2463 |
2464 switch (pw->job_format) | 2464 switch (pw->job_format) |
2465 { | 2465 { |
2466 case RENDER_FORMAT_RGB: | 2466 case RENDER_FORMAT_RGB: |
2467 success = TRUE; | 2467 success = TRUE; |
3044 } | 3044 } |
3045 } | 3045 } |
3046 | 3046 |
3047 static void print_output_set(PrintWindow *pw, PrintOutput output) | 3047 static void print_output_set(PrintWindow *pw, PrintOutput output) |
3048 { | 3048 { |
3049 gint use_file = FALSE; | 3049 gboolean use_file = FALSE; |
3050 gint use_custom = FALSE; | 3050 gboolean use_custom = FALSE; |
3051 gint use_format = FALSE; | 3051 gboolean use_format = FALSE; |
3052 | 3052 |
3053 pw->output = output; | 3053 pw->output = output; |
3054 | 3054 |
3055 switch (pw->output) | 3055 switch (pw->output) |
3056 { | 3056 { |