src/java.desktop/share/native/libfontmanager/harfbuzz/hb-font.h
changeset 54232 7c11a7cc7c1d
parent 50352 25db2c8f3cf8
--- a/src/java.desktop/share/native/libfontmanager/harfbuzz/hb-font.h	Wed Feb 27 18:46:55 2019 -0800
+++ b/src/java.desktop/share/native/libfontmanager/harfbuzz/hb-font.h	Fri Mar 01 16:59:19 2019 -0800
@@ -110,7 +110,7 @@
 /* func types */
 
 typedef hb_bool_t (*hb_font_get_font_extents_func_t) (hb_font_t *font, void *font_data,
-                                                       hb_font_extents_t *metrics,
+                                                       hb_font_extents_t *extents,
                                                        void *user_data);
 typedef hb_font_get_font_extents_func_t hb_font_get_font_h_extents_func_t;
 typedef hb_font_get_font_extents_func_t hb_font_get_font_v_extents_func_t;
@@ -125,6 +125,14 @@
                                                          hb_codepoint_t *glyph,
                                                          void *user_data);
 
+typedef unsigned int (*hb_font_get_nominal_glyphs_func_t) (hb_font_t *font, void *font_data,
+                                                           unsigned int count,
+                                                           const hb_codepoint_t *first_unicode,
+                                                           unsigned int unicode_stride,
+                                                           hb_codepoint_t *first_glyph,
+                                                           unsigned int glyph_stride,
+                                                           void *user_data);
+
 
 typedef hb_position_t (*hb_font_get_glyph_advance_func_t) (hb_font_t *font, void *font_data,
                                                            hb_codepoint_t glyph,
@@ -132,6 +140,16 @@
 typedef hb_font_get_glyph_advance_func_t hb_font_get_glyph_h_advance_func_t;
 typedef hb_font_get_glyph_advance_func_t hb_font_get_glyph_v_advance_func_t;
 
+typedef void (*hb_font_get_glyph_advances_func_t) (hb_font_t* font, void* font_data,
+                                                   unsigned int count,
+                                                   const hb_codepoint_t *first_glyph,
+                                                   unsigned glyph_stride,
+                                                   hb_position_t *first_advance,
+                                                   unsigned advance_stride,
+                                                   void *user_data);
+typedef hb_font_get_glyph_advances_func_t hb_font_get_glyph_h_advances_func_t;
+typedef hb_font_get_glyph_advances_func_t hb_font_get_glyph_v_advances_func_t;
+
 typedef hb_bool_t (*hb_font_get_glyph_origin_func_t) (hb_font_t *font, void *font_data,
                                                       hb_codepoint_t glyph,
                                                       hb_position_t *x, hb_position_t *y,
@@ -139,12 +157,6 @@
 typedef hb_font_get_glyph_origin_func_t hb_font_get_glyph_h_origin_func_t;
 typedef hb_font_get_glyph_origin_func_t hb_font_get_glyph_v_origin_func_t;
 
-typedef hb_position_t (*hb_font_get_glyph_kerning_func_t) (hb_font_t *font, void *font_data,
-                                                           hb_codepoint_t first_glyph, hb_codepoint_t second_glyph,
-                                                           void *user_data);
-typedef hb_font_get_glyph_kerning_func_t hb_font_get_glyph_h_kerning_func_t;
-typedef hb_font_get_glyph_kerning_func_t hb_font_get_glyph_v_kerning_func_t;
-
 
 typedef hb_bool_t (*hb_font_get_glyph_extents_func_t) (hb_font_t *font, void *font_data,
                                                        hb_codepoint_t glyph,
@@ -217,6 +229,22 @@
                                       void *user_data, hb_destroy_func_t destroy);
 
 /**
+ * hb_font_funcs_set_nominal_glyphs_func:
+ * @ffuncs: font functions.
+ * @func: (closure user_data) (destroy destroy) (scope notified):
+ * @user_data:
+ * @destroy:
+ *
+ *
+ *
+ * Since: 2.0.0
+ **/
+HB_EXTERN void
+hb_font_funcs_set_nominal_glyphs_func (hb_font_funcs_t *ffuncs,
+                                       hb_font_get_nominal_glyphs_func_t func,
+                                       void *user_data, hb_destroy_func_t destroy);
+
+/**
  * hb_font_funcs_set_variation_glyph_func:
  * @ffuncs: font functions.
  * @func: (closure user_data) (destroy destroy) (scope notified):
@@ -265,6 +293,38 @@
                                         void *user_data, hb_destroy_func_t destroy);
 
 /**
+ * hb_font_funcs_set_glyph_h_advances_func:
+ * @ffuncs: font functions.
+ * @func: (closure user_data) (destroy destroy) (scope notified):
+ * @user_data:
+ * @destroy:
+ *
+ *
+ *
+ * Since: 1.8.6
+ **/
+HB_EXTERN void
+hb_font_funcs_set_glyph_h_advances_func (hb_font_funcs_t *ffuncs,
+                                        hb_font_get_glyph_h_advances_func_t func,
+                                        void *user_data, hb_destroy_func_t destroy);
+
+/**
+ * hb_font_funcs_set_glyph_v_advances_func:
+ * @ffuncs: font functions.
+ * @func: (closure user_data) (destroy destroy) (scope notified):
+ * @user_data:
+ * @destroy:
+ *
+ *
+ *
+ * Since: 1.8.6
+ **/
+HB_EXTERN void
+hb_font_funcs_set_glyph_v_advances_func (hb_font_funcs_t *ffuncs,
+                                        hb_font_get_glyph_v_advances_func_t func,
+                                        void *user_data, hb_destroy_func_t destroy);
+
+/**
  * hb_font_funcs_set_glyph_h_origin_func:
  * @ffuncs: font functions.
  * @func: (closure user_data) (destroy destroy) (scope notified):
@@ -297,38 +357,6 @@
                                        void *user_data, hb_destroy_func_t destroy);
 
 /**
- * hb_font_funcs_set_glyph_h_kerning_func:
- * @ffuncs: font functions.
- * @func: (closure user_data) (destroy destroy) (scope notified):
- * @user_data:
- * @destroy:
- *
- *
- *
- * Since: 0.9.2
- **/
-HB_EXTERN void
-hb_font_funcs_set_glyph_h_kerning_func (hb_font_funcs_t *ffuncs,
-                                        hb_font_get_glyph_h_kerning_func_t func,
-                                        void *user_data, hb_destroy_func_t destroy);
-
-/**
- * hb_font_funcs_set_glyph_v_kerning_func:
- * @ffuncs: font functions.
- * @func: (closure user_data) (destroy destroy) (scope notified):
- * @user_data:
- * @destroy:
- *
- *
- *
- * Since: 0.9.2
- **/
-HB_EXTERN void
-hb_font_funcs_set_glyph_v_kerning_func (hb_font_funcs_t *ffuncs,
-                                        hb_font_get_glyph_v_kerning_func_t func,
-                                        void *user_data, hb_destroy_func_t destroy);
-
-/**
  * hb_font_funcs_set_glyph_extents_func:
  * @ffuncs: font functions.
  * @func: (closure user_data) (destroy destroy) (scope notified):
@@ -417,6 +445,21 @@
 hb_font_get_glyph_v_advance (hb_font_t *font,
                              hb_codepoint_t glyph);
 
+HB_EXTERN void
+hb_font_get_glyph_h_advances (hb_font_t* font,
+                              unsigned int count,
+                              const hb_codepoint_t *first_glyph,
+                              unsigned glyph_stride,
+                              hb_position_t *first_advance,
+                              unsigned advance_stride);
+HB_EXTERN void
+hb_font_get_glyph_v_advances (hb_font_t* font,
+                              unsigned int count,
+                              const hb_codepoint_t *first_glyph,
+                              unsigned glyph_stride,
+                              hb_position_t *first_advance,
+                              unsigned advance_stride);
+
 HB_EXTERN hb_bool_t
 hb_font_get_glyph_h_origin (hb_font_t *font,
                             hb_codepoint_t glyph,
@@ -426,13 +469,6 @@
                             hb_codepoint_t glyph,
                             hb_position_t *x, hb_position_t *y);
 
-HB_EXTERN hb_position_t
-hb_font_get_glyph_h_kerning (hb_font_t *font,
-                             hb_codepoint_t left_glyph, hb_codepoint_t right_glyph);
-HB_EXTERN hb_position_t
-hb_font_get_glyph_v_kerning (hb_font_t *font,
-                             hb_codepoint_t top_glyph, hb_codepoint_t bottom_glyph);
-
 HB_EXTERN hb_bool_t
 hb_font_get_glyph_extents (hb_font_t *font,
                            hb_codepoint_t glyph,
@@ -472,6 +508,14 @@
                                          hb_direction_t direction,
                                          hb_position_t *x, hb_position_t *y);
 HB_EXTERN void
+hb_font_get_glyph_advances_for_direction (hb_font_t* font,
+                                          hb_direction_t direction,
+                                          unsigned int count,
+                                          const hb_codepoint_t *first_glyph,
+                                          unsigned glyph_stride,
+                                          hb_position_t *first_advance,
+                                          unsigned advance_stride);
+HB_EXTERN void
 hb_font_get_glyph_origin_for_direction (hb_font_t *font,
                                         hb_codepoint_t glyph,
                                         hb_direction_t direction,
@@ -487,12 +531,6 @@
                                              hb_direction_t direction,
                                              hb_position_t *x, hb_position_t *y);
 
-HB_EXTERN void
-hb_font_get_glyph_kerning_for_direction (hb_font_t *font,
-                                         hb_codepoint_t first_glyph, hb_codepoint_t second_glyph,
-                                         hb_direction_t direction,
-                                         hb_position_t *x, hb_position_t *y);
-
 HB_EXTERN hb_bool_t
 hb_font_get_glyph_extents_for_origin (hb_font_t *font,
                                       hb_codepoint_t glyph,