discomfitor pushed a commit to branch master.

http://git.enlightenment.org/core/elementary.git/commit/?id=a168df690c4096b43dfd70c7130e52ae2ba8240c

commit a168df690c4096b43dfd70c7130e52ae2ba8240c
Author: Mike Blumenkrantz <[email protected]>
Date:   Thu Oct 30 16:24:11 2014 -0400

    config font hinting api added
    
    needed for e's internal use, not sure if worth exposing since there's an 
env variable
    
    @feature
---
 src/lib/elm_config.c | 22 ++++++++++++++++++++++
 src/lib/elm_config.h | 14 ++++++++++++++
 2 files changed, 36 insertions(+)

diff --git a/src/lib/elm_config.c b/src/lib/elm_config.c
index 193ec6b..e4b72da 100644
--- a/src/lib/elm_config.c
+++ b/src/lib/elm_config.c
@@ -2660,6 +2660,28 @@ elm_config_cache_image_cache_size_set(int size)
    _elm_recache();
 }
 
+EAPI void
+elm_config_font_hint_type_set(int type)
+{
+   Eina_List *l;
+   Evas_Object *win;
+
+   if ((type < 0) || (type > 2)) return;
+   _elm_config->font_hinting = type;
+
+   EINA_LIST_FOREACH(_elm_win_list, l, win)
+     {
+        Evas *e = evas_object_evas_get(win);
+
+        if (!_elm_config->font_hinting)
+          evas_font_hinting_set(e, EVAS_FONT_HINTING_NONE);
+        else if (_elm_config->font_hinting == 1)
+          evas_font_hinting_set(e, EVAS_FONT_HINTING_AUTO);
+        else if (_elm_config->font_hinting == 2)
+          evas_font_hinting_set(e, EVAS_FONT_HINTING_BYTECODE);
+     }
+}
+
 EAPI int
 elm_config_cache_edje_file_cache_size_get()
 {
diff --git a/src/lib/elm_config.h b/src/lib/elm_config.h
index 58d23df..ae16b4d 100644
--- a/src/lib/elm_config.h
+++ b/src/lib/elm_config.h
@@ -1024,6 +1024,20 @@ EAPI void             
elm_config_font_overlay_unset(const char *text_class);
 EAPI void             elm_config_font_overlay_apply(void);
 
 /**
+ * Apply the specified font hinting type.
+ * EVAS_FONT_HINTING_NONE < No font hinting
+ * EVAS_FONT_HINTING_AUTO < Automatic font hinting
+ * EVAS_FONT_HINTING_BYTECODE < Bytecode font hinting
+ *
+ * @ingroup Fonts
+ *
+ * This applies font hint changes to all windows of the current application.
+ *
+ * @since 1.13
+ */
+EAPI void elm_config_font_hint_type_set(int type);
+
+/**
  * Get the configured "finger size"
  *
  * @return The finger size

-- 


Reply via email to