Enlightenment CVS committal
Author : raster
Project : e17
Module : libs/evas
Dir : e17/libs/evas/src/lib/engines/common
Modified Files:
evas_font_draw.c
Log Message:
aaaah DONT use inlined bitmaps.. we want it ALL aa'd
===================================================================
RCS file:
/cvsroot/enlightenment/e17/libs/evas/src/lib/engines/common/evas_font_draw.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -3 -r1.3 -r1.4
--- evas_font_draw.c 9 Jan 2003 07:41:22 -0000 1.3
+++ evas_font_draw.c 5 Jun 2003 02:59:19 -0000 1.4
@@ -19,7 +19,7 @@
fg = evas_hash_find(fn->glyphs, key);
if (fg) return fg;
- error = FT_Load_Glyph(fn->ft.face, index, FT_LOAD_DEFAULT);
+ error = FT_Load_Glyph(fn->ft.face, index, FT_LOAD_NO_BITMAP);
if (error) return NULL;
fg = malloc(sizeof(struct _RGBA_Font_Glyph));
@@ -126,42 +126,41 @@
data = fg->glyph_out->bitmap.buffer;
j = fg->glyph_out->bitmap.pitch;
w = fg->glyph_out->bitmap.width;
- /* BUG: freetype 2.1.3 has a bug - workaround */
- /* ft2.1.3 is giving me rowstrides for some fonts in */
- /* some point sises of.... 1 !!!! this is wrong. */
- /* second guess it and "fixup" here */
if (j < w) j = w;
- /* end BUG workaround */
h = fg->glyph_out->bitmap.rows;
- if ((j > 0) && (chr_x + w > ext_x))
+ if ((fg->glyph_out->bitmap.pixel_mode == ft_pixel_mode_grays) &&
+ (fg->glyph_out->bitmap.num_grays == 256))
{
- for (i = 0; i < h; i++)
+ if ((j > 0) && (chr_x + w > ext_x))
{
- int dx, dy;
- int in_x, in_w;
-
- in_x = 0;
- in_w = 0;
- dx = chr_x;
- dy = y - (chr_y - i - y);
- if ((dx < (ext_x + ext_w)) &&
- (dy >= (ext_y)) &&
- (dy < (ext_y + ext_h)))
+ for (i = 0; i < h; i++)
{
- if (dx + w > (ext_x + ext_w))
- in_w += (dx + w) - (ext_x + ext_w);
- if (dx < ext_x)
+ int dx, dy;
+ int in_x, in_w;
+
+ in_x = 0;
+ in_w = 0;
+ dx = chr_x;
+ dy = y - (chr_y - i - y);
+ if ((dx < (ext_x + ext_w)) &&
+ (dy >= (ext_y)) &&
+ (dy < (ext_y + ext_h)))
{
- in_w += ext_x - dx;
- in_x = ext_x - dx;
- dx = ext_x;
- }
- if (in_w < w)
- {
- func(data + (i * j) + in_x,
- im + (dy * im_w) + dx,
- w - in_w,
- dc->col.col);
+ if (dx + w > (ext_x + ext_w))
+ in_w += (dx + w) - (ext_x + ext_w);
+ if (dx < ext_x)
+ {
+ in_w += ext_x - dx;
+ in_x = ext_x - dx;
+ dx = ext_x;
+ }
+ if (in_w < w)
+ {
+ func(data + (i * j) + in_x,
+ im + (dy * im_w) + dx,
+ w - in_w,
+ dc->col.col);
+ }
}
}
}
-------------------------------------------------------
This SF.net email is sponsored by: Etnus, makers of TotalView, The best
thread debugger on the planet. Designed with thread debugging features
you've never dreamed of, try TotalView 6 free at www.etnus.com.
_______________________________________________
enlightenment-cvs mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/enlightenment-cvs