forked from enlightenment/efl
hmm. forgot to translate text coords form queries.. and some glyph vs char
pos bugs SVN revision: 6526
This commit is contained in:
parent
866bf9121e
commit
d1d3b62ebe
|
@ -320,8 +320,6 @@ extern "C" {
|
|||
double evas_object_text_horiz_advance_get(Evas_Object *obj);
|
||||
double evas_object_text_vert_advance_get (Evas_Object *obj);
|
||||
double evas_object_text_inset_get (Evas_Object *obj);
|
||||
double evas_object_text_horiz_advance_get(Evas_Object *obj);
|
||||
double evas_object_text_vert_advance_get (Evas_Object *obj);
|
||||
int evas_object_text_char_pos_get (Evas_Object *obj, int pos, double *cx, double *cy, double *cw, double *ch);
|
||||
int evas_object_text_char_coords_get (Evas_Object *obj, double x, double y, double *cx, double *cy, double *cw, double *ch);
|
||||
|
||||
|
|
|
@ -203,7 +203,6 @@ evas_object_text_font_set(Evas_Object *obj, char *font, double size)
|
|||
free(font_tmp);
|
||||
}
|
||||
}
|
||||
//_WIN32_WCE
|
||||
done: ;
|
||||
}
|
||||
if (o->cur.font) free(o->cur.font);
|
||||
|
@ -487,6 +486,7 @@ evas_object_text_char_pos_get(Evas_Object *obj, int pos, double *cx, double *cy,
|
|||
pos,
|
||||
&x, &y,
|
||||
&w, &h);
|
||||
y += o->max_ascent;
|
||||
if (cx) *cx = x;
|
||||
if (cy) *cy = y;
|
||||
if (cw) *cw = w;
|
||||
|
@ -510,9 +510,10 @@ evas_object_text_char_coords_get(Evas_Object *obj, double x, double y, double *c
|
|||
ret = obj->layer->evas->engine.func->font_char_at_coords_get(obj->layer->evas->engine.data.output,
|
||||
o->engine_data,
|
||||
o->cur.text,
|
||||
x, y,
|
||||
x, y - o->max_ascent,
|
||||
&rx, &ry,
|
||||
&rw, &rh);
|
||||
ry += o->max_ascent;
|
||||
if (cx) *cx = rx;
|
||||
if (cy) *cy = ry;
|
||||
if (cw) *cw = rw;
|
||||
|
|
|
@ -157,7 +157,7 @@ evas_common_font_query_char_coords(RGBA_Font *fn, const char *text, int pos, int
|
|||
chr_y = (pen_y >> 8) + fg->glyph_out->top;
|
||||
chr_w = fg->glyph_out->bitmap.width;
|
||||
|
||||
if (gl == pos)
|
||||
if (chr == pos)
|
||||
{
|
||||
if (cx) *cx = chr_x;
|
||||
if (cy) *cy = - evas_common_font_max_ascent_get(fn);
|
||||
|
|
|
@ -33,7 +33,7 @@ typedef enum _Evas_Callback_Type
|
|||
EVAS_CALLBACK_RESTACK
|
||||
} Evas_Callback_Type;
|
||||
|
||||
typedef struct _Evas_Rectangle Evas_Rectangle;
|
||||
typedef struct _Evas_Rectangle Evas_Rectangle;
|
||||
|
||||
typedef struct _Evas Evas;
|
||||
typedef struct _Evas_Layer Evas_Layer;
|
||||
|
|
Loading…
Reference in New Issue