jpayne@69: /* jpayne@69: * Copyright © 2013 Google, Inc. jpayne@69: * jpayne@69: * This is part of HarfBuzz, a text shaping library. jpayne@69: * jpayne@69: * Permission is hereby granted, without written agreement and without jpayne@69: * license or royalty fees, to use, copy, modify, and distribute this jpayne@69: * software and its documentation for any purpose, provided that the jpayne@69: * above copyright notice and the following two paragraphs appear in jpayne@69: * all copies of this software. jpayne@69: * jpayne@69: * IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE TO ANY PARTY FOR jpayne@69: * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES jpayne@69: * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN jpayne@69: * IF THE COPYRIGHT HOLDER HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH jpayne@69: * DAMAGE. jpayne@69: * jpayne@69: * THE COPYRIGHT HOLDER SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, jpayne@69: * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND jpayne@69: * FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS jpayne@69: * ON AN "AS IS" BASIS, AND THE COPYRIGHT HOLDER HAS NO OBLIGATION TO jpayne@69: * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. jpayne@69: * jpayne@69: * Google Author(s): Behdad Esfahbod jpayne@69: */ jpayne@69: jpayne@69: #ifndef HB_H_IN jpayne@69: #error "Include instead." jpayne@69: #endif jpayne@69: jpayne@69: #ifndef HB_DEPRECATED_H jpayne@69: #define HB_DEPRECATED_H jpayne@69: jpayne@69: #include "hb-common.h" jpayne@69: #include "hb-unicode.h" jpayne@69: #include "hb-font.h" jpayne@69: #include "hb-set.h" jpayne@69: jpayne@69: jpayne@69: /** jpayne@69: * SECTION:hb-deprecated jpayne@69: * @title: hb-deprecated jpayne@69: * @short_description: Deprecated API jpayne@69: * @include: hb.h jpayne@69: * jpayne@69: * These API have been deprecated in favor of newer API, or because they jpayne@69: * were deemed unnecessary. jpayne@69: **/ jpayne@69: jpayne@69: jpayne@69: HB_BEGIN_DECLS jpayne@69: jpayne@69: #ifndef HB_DISABLE_DEPRECATED jpayne@69: jpayne@69: jpayne@69: #define HB_SCRIPT_CANADIAN_ABORIGINAL HB_SCRIPT_CANADIAN_SYLLABICS jpayne@69: jpayne@69: #define HB_BUFFER_FLAGS_DEFAULT HB_BUFFER_FLAG_DEFAULT jpayne@69: #define HB_BUFFER_SERIALIZE_FLAGS_DEFAULT HB_BUFFER_SERIALIZE_FLAG_DEFAULT jpayne@69: jpayne@69: typedef hb_bool_t (*hb_font_get_glyph_func_t) (hb_font_t *font, void *font_data, jpayne@69: hb_codepoint_t unicode, hb_codepoint_t variation_selector, jpayne@69: hb_codepoint_t *glyph, jpayne@69: void *user_data); jpayne@69: jpayne@69: HB_EXTERN HB_DEPRECATED_FOR(hb_font_funcs_set_nominal_glyph_func and hb_font_funcs_set_variation_glyph_func) void jpayne@69: hb_font_funcs_set_glyph_func (hb_font_funcs_t *ffuncs, jpayne@69: hb_font_get_glyph_func_t func, jpayne@69: void *user_data, hb_destroy_func_t destroy); jpayne@69: jpayne@69: HB_EXTERN HB_DEPRECATED void jpayne@69: hb_set_invert (hb_set_t *set); jpayne@69: jpayne@69: /** jpayne@69: * hb_unicode_eastasian_width_func_t: jpayne@69: * jpayne@69: * Deprecated: 2.0.0 jpayne@69: */ jpayne@69: typedef unsigned int (*hb_unicode_eastasian_width_func_t) (hb_unicode_funcs_t *ufuncs, jpayne@69: hb_codepoint_t unicode, jpayne@69: void *user_data); jpayne@69: jpayne@69: /** jpayne@69: * hb_unicode_funcs_set_eastasian_width_func: jpayne@69: * @ufuncs: a Unicode function structure jpayne@69: * @func: (closure user_data) (destroy destroy) (scope notified): jpayne@69: * @user_data: jpayne@69: * @destroy: jpayne@69: * jpayne@69: * jpayne@69: * jpayne@69: * Since: 0.9.2 jpayne@69: * Deprecated: 2.0.0 jpayne@69: **/ jpayne@69: HB_EXTERN HB_DEPRECATED void jpayne@69: hb_unicode_funcs_set_eastasian_width_func (hb_unicode_funcs_t *ufuncs, jpayne@69: hb_unicode_eastasian_width_func_t func, jpayne@69: void *user_data, hb_destroy_func_t destroy); jpayne@69: jpayne@69: /** jpayne@69: * hb_unicode_eastasian_width: jpayne@69: * jpayne@69: * Since: 0.9.2 jpayne@69: * Deprecated: 2.0.0 jpayne@69: **/ jpayne@69: HB_EXTERN HB_DEPRECATED unsigned int jpayne@69: hb_unicode_eastasian_width (hb_unicode_funcs_t *ufuncs, jpayne@69: hb_codepoint_t unicode); jpayne@69: jpayne@69: jpayne@69: /** jpayne@69: * hb_unicode_decompose_compatibility_func_t: jpayne@69: * @ufuncs: a Unicode function structure jpayne@69: * @u: codepoint to decompose jpayne@69: * @decomposed: address of codepoint array (of length %HB_UNICODE_MAX_DECOMPOSITION_LEN) to write decomposition into jpayne@69: * @user_data: user data pointer as passed to hb_unicode_funcs_set_decompose_compatibility_func() jpayne@69: * jpayne@69: * Fully decompose @u to its Unicode compatibility decomposition. The codepoints of the decomposition will be written to @decomposed. jpayne@69: * The complete length of the decomposition will be returned. jpayne@69: * jpayne@69: * If @u has no compatibility decomposition, zero should be returned. jpayne@69: * jpayne@69: * The Unicode standard guarantees that a buffer of length %HB_UNICODE_MAX_DECOMPOSITION_LEN codepoints will always be sufficient for any jpayne@69: * compatibility decomposition plus an terminating value of 0. Consequently, @decompose must be allocated by the caller to be at least this length. Implementations jpayne@69: * of this function type must ensure that they do not write past the provided array. jpayne@69: * jpayne@69: * Return value: number of codepoints in the full compatibility decomposition of @u, or 0 if no decomposition available. jpayne@69: * jpayne@69: * Deprecated: 2.0.0 jpayne@69: */ jpayne@69: typedef unsigned int (*hb_unicode_decompose_compatibility_func_t) (hb_unicode_funcs_t *ufuncs, jpayne@69: hb_codepoint_t u, jpayne@69: hb_codepoint_t *decomposed, jpayne@69: void *user_data); jpayne@69: jpayne@69: /** jpayne@69: * HB_UNICODE_MAX_DECOMPOSITION_LEN: jpayne@69: * jpayne@69: * See Unicode 6.1 for details on the maximum decomposition length. jpayne@69: * jpayne@69: * Deprecated: 2.0.0 jpayne@69: */ jpayne@69: #define HB_UNICODE_MAX_DECOMPOSITION_LEN (18+1) /* codepoints */ jpayne@69: jpayne@69: /** jpayne@69: * hb_unicode_funcs_set_decompose_compatibility_func: jpayne@69: * @ufuncs: a Unicode function structure jpayne@69: * @func: (closure user_data) (destroy destroy) (scope notified): jpayne@69: * @user_data: jpayne@69: * @destroy: jpayne@69: * jpayne@69: * jpayne@69: * jpayne@69: * Since: 0.9.2 jpayne@69: * Deprecated: 2.0.0 jpayne@69: **/ jpayne@69: HB_EXTERN HB_DEPRECATED void jpayne@69: hb_unicode_funcs_set_decompose_compatibility_func (hb_unicode_funcs_t *ufuncs, jpayne@69: hb_unicode_decompose_compatibility_func_t func, jpayne@69: void *user_data, hb_destroy_func_t destroy); jpayne@69: jpayne@69: HB_EXTERN HB_DEPRECATED unsigned int jpayne@69: hb_unicode_decompose_compatibility (hb_unicode_funcs_t *ufuncs, jpayne@69: hb_codepoint_t u, jpayne@69: hb_codepoint_t *decomposed); jpayne@69: jpayne@69: jpayne@69: typedef hb_font_get_glyph_kerning_func_t hb_font_get_glyph_v_kerning_func_t; jpayne@69: jpayne@69: /** jpayne@69: * hb_font_funcs_set_glyph_v_kerning_func: jpayne@69: * @ffuncs: font functions. jpayne@69: * @func: (closure user_data) (destroy destroy) (scope notified): jpayne@69: * @user_data: jpayne@69: * @destroy: jpayne@69: * jpayne@69: * jpayne@69: * jpayne@69: * Since: 0.9.2 jpayne@69: * Deprecated: 2.0.0 jpayne@69: **/ jpayne@69: HB_EXTERN void jpayne@69: hb_font_funcs_set_glyph_v_kerning_func (hb_font_funcs_t *ffuncs, jpayne@69: hb_font_get_glyph_v_kerning_func_t func, jpayne@69: void *user_data, hb_destroy_func_t destroy); jpayne@69: jpayne@69: HB_EXTERN hb_position_t jpayne@69: hb_font_get_glyph_v_kerning (hb_font_t *font, jpayne@69: hb_codepoint_t top_glyph, hb_codepoint_t bottom_glyph); jpayne@69: jpayne@69: #endif jpayne@69: jpayne@69: HB_END_DECLS jpayne@69: jpayne@69: #endif /* HB_DEPRECATED_H */