summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDaniel Hirt <daniel.hirt@samsung.com>2015-08-23 13:49:01 +0300
committerDaniel Hirt <daniel.hirt@samsung.com>2015-08-31 12:49:38 +0300
commit3f1fdfeb86d123606537d1b919235c196e4c3b10 (patch)
treecccae021f43a77e168a5fe7378b0a73397f71578
parentb707c2cd27b67e30a66cd228c34cf7f4b31c7574 (diff)
evas_font_draw: remove unnecessary subtraction
We had chr_y = chr_y + y, but all usages of this value did (chr_y - y), which does not make a lot of sense when reading the code.
-rw-r--r--src/lib/evas/common/evas_font_draw.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/lib/evas/common/evas_font_draw.c b/src/lib/evas/common/evas_font_draw.c
index bbeecf61a5..af96e97cbd 100644
--- a/src/lib/evas/common/evas_font_draw.c
+++ b/src/lib/evas/common/evas_font_draw.c
@@ -142,7 +142,7 @@ evas_common_font_rgba_draw(RGBA_Image *dst, RGBA_Draw_Context *dc, int x, int y,
142 } 142 }
143 143
144 chr_x = x + glyph->x; 144 chr_x = x + glyph->x;
145 chr_y = y + glyph->y; 145 chr_y = glyph->y;
146 if (chr_x < (ext_x + ext_w)) 146 if (chr_x < (ext_x + ext_w))
147 { 147 {
148 if ((w > 0) && ((chr_x + w) > ext_x)) 148 if ((w > 0) && ((chr_x + w) > ext_x))
@@ -152,10 +152,10 @@ evas_common_font_rgba_draw(RGBA_Image *dst, RGBA_Draw_Context *dc, int x, int y,
152 if ((fg->ext_dat) && (dc->font_ext.func.gl_draw)) 152 if ((fg->ext_dat) && (dc->font_ext.func.gl_draw))
153 dc->font_ext.func.gl_draw(dc->font_ext.data, dst, 153 dc->font_ext.func.gl_draw(dc->font_ext.data, dst,
154 dc, fg, 154 dc, fg,
155 chr_x, y - (chr_y - y)); 155 chr_x, y - chr_y);
156 else 156 else
157 evas_common_font_glyph_draw(fg, dc, dst, im_w, 157 evas_common_font_glyph_draw(fg, dc, dst, im_w,
158 chr_x, y - (chr_y - y), 158 chr_x, y - chr_y,
159 ext_x, ext_y, 159 ext_x, ext_y,
160 ext_w, ext_h); 160 ext_w, ext_h);
161 } 161 }
@@ -164,11 +164,11 @@ evas_common_font_rgba_draw(RGBA_Image *dst, RGBA_Draw_Context *dc, int x, int y,
164 if (dc->font_ext.func.gl_image_draw) 164 if (dc->font_ext.func.gl_image_draw)
165 dc->font_ext.func.gl_image_draw 165 dc->font_ext.func.gl_image_draw
166 (dc->font_ext.data, fg->ext_dat, 0, 0, w, h, 166 (dc->font_ext.data, fg->ext_dat, 0, 0, w, h,
167 chr_x, y - (chr_y - y), w, h, EINA_TRUE); 167 chr_x, y - chr_y, w, h, EINA_TRUE);
168 else 168 else
169 _evas_font_image_draw 169 _evas_font_image_draw
170 (dc, dst, fg->ext_dat, 0, 0, w, h, 170 (dc, dst, fg->ext_dat, 0, 0, w, h,
171 chr_x, y - (chr_y - y), w, h, EINA_TRUE); 171 chr_x, y - chr_y, w, h, EINA_TRUE);
172 } 172 }
173 } 173 }
174 } 174 }