Mercurial > MadButterfly
comparison src/shape_text.c @ 280:c8b6ca46950b mbtext
Add merged result
author | wycc |
---|---|
date | Sat, 31 Jan 2009 12:29:50 +0800 |
parents | 86a5ae82ccf2 |
children | 248a40d51473 |
comparison
equal
deleted
inserted
replaced
279:86a5ae82ccf2 | 280:c8b6ca46950b |
---|---|
105 x = text->x; | 105 x = text->x; |
106 y = text->y; | 106 y = text->y; |
107 coord_trans_pos(shape->coord, &x, &y); | 107 coord_trans_pos(shape->coord, &x, &y); |
108 r = get_extents(text, &extents); | 108 r = get_extents(text, &extents); |
109 | 109 |
110 printf("x=%f y=%f text=%s ascent=%d,descent=%d,width=%d height=%d\n", x,y,text->data,PANGO_ASCENT(extents), PANGO_DESCENT(extents), extents.width, extents.height); | 110 //printf("x=%f y=%f text=%s ascent=%d,descent=%d,width=%d height=%d\n", x,y,text->data,PANGO_ASCENT(extents), PANGO_DESCENT(extents), extents.width, extents.height); |
111 ASSERT(r == OK); | 111 ASSERT(r == OK); |
112 | 112 |
113 text->d_x = x; | 113 text->d_x = x; |
114 text->d_y = y-text->font_size; | 114 text->d_y = y-text->font_size; |
115 shw = shape->stroke_width / 2; | 115 shw = shape->stroke_width / 2; |