forked from enlightenment/enlightenment
update hinting api - fix config dialog
SVN revision: 20849
This commit is contained in:
parent
1a52807e5e
commit
8c517a39aa
|
@ -15,13 +15,19 @@ EAPI void
|
|||
e_canvas_add(Ecore_Evas *ee)
|
||||
{
|
||||
Evas *e;
|
||||
|
||||
|
||||
_e_canvases = evas_list_prepend(_e_canvases, ee);
|
||||
e = ecore_evas_get(ee);
|
||||
evas_image_cache_set(e, e_config->image_cache * 1024);
|
||||
evas_font_cache_set(e, e_config->font_cache * 1024);
|
||||
e_path_evas_append(path_fonts, e);
|
||||
if (e_config->font_hinting == 0)
|
||||
evas_font_hinting_set(e, EVAS_FONT_HINTING_BYTECODE);
|
||||
else if (e_config->font_hinting == 1)
|
||||
evas_font_hinting_set(e, EVAS_FONT_HINTING_AUTO);
|
||||
else if (e_config->font_hinting == 2)
|
||||
evas_font_hinting_set(e, EVAS_FONT_HINTING_NONE);
|
||||
|
||||
// evas_image_cache_flush(e);
|
||||
// evas_image_cache_reload(e);
|
||||
}
|
||||
|
|
|
@ -1674,13 +1674,6 @@ e_config_init(void)
|
|||
E_CONFIG_LIMIT(e_config->cfgdlg_default_mode, 0, 1);
|
||||
E_CONFIG_LIMIT(e_config->font_hinting, 0, 2);
|
||||
|
||||
if (e_config->font_hinting == 0)
|
||||
evas_imaging_font_hinting_set(EVAS_FONT_HINTING_BYTECODE);
|
||||
else if (e_config->font_hinting == 1)
|
||||
evas_imaging_font_hinting_set(EVAS_FONT_HINTING_AUTO);
|
||||
else if (e_config->font_hinting == 2)
|
||||
evas_imaging_font_hinting_set(EVAS_FONT_HINTING_NONE);
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
|
|
@ -86,19 +86,19 @@ _basic_create_widgets(E_Config_Dialog *cfd, Evas *evas, E_Config_Dialog_Data *cf
|
|||
|
||||
o = e_widget_list_add(evas, 0, 0);
|
||||
rg = e_widget_radio_group_new(&(cfdata->hinting));
|
||||
if (evas_imaging_font_hinting_can_hint(EVAS_FONT_HINTING_BYTECODE))
|
||||
if (evas_font_hinting_can_hint(evas, EVAS_FONT_HINTING_BYTECODE))
|
||||
{
|
||||
ob = e_widget_radio_add(evas, _("Bytecode Hinting"), EVAS_FONT_HINTING_BYTECODE, rg);
|
||||
ob = e_widget_radio_add(evas, _("Bytecode Hinting"), 0, rg);
|
||||
e_widget_list_object_append(o, ob, 1, 1, 0.5);
|
||||
}
|
||||
if (evas_imaging_font_hinting_can_hint(EVAS_FONT_HINTING_AUTO))
|
||||
if (evas_font_hinting_can_hint(evas, EVAS_FONT_HINTING_AUTO))
|
||||
{
|
||||
ob = e_widget_radio_add(evas, _("Automatic Hinting"), EVAS_FONT_HINTING_AUTO, rg);
|
||||
ob = e_widget_radio_add(evas, _("Automatic Hinting"), 1, rg);
|
||||
e_widget_list_object_append(o, ob, 1, 1, 0.5);
|
||||
}
|
||||
if (evas_imaging_font_hinting_can_hint(EVAS_FONT_HINTING_NONE))
|
||||
if (evas_font_hinting_can_hint(evas, EVAS_FONT_HINTING_NONE))
|
||||
{
|
||||
ob = e_widget_radio_add(evas, _("No Hinting"), EVAS_FONT_HINTING_NONE, rg);
|
||||
ob = e_widget_radio_add(evas, _("No Hinting"), 2, rg);
|
||||
e_widget_list_object_append(o, ob, 1, 1, 0.5);
|
||||
}
|
||||
return o;
|
||||
|
|
Loading…
Reference in New Issue