hb-shape-plan.h revision 15400:b5409ce1e4fe
123353Sdfr/* 223353Sdfr * Copyright �� 2012 Google, Inc. 323353Sdfr * 423353Sdfr * This is part of HarfBuzz, a text shaping library. 523353Sdfr * 623353Sdfr * Permission is hereby granted, without written agreement and without 723353Sdfr * license or royalty fees, to use, copy, modify, and distribute this 823353Sdfr * software and its documentation for any purpose, provided that the 923353Sdfr * above copyright notice and the following two paragraphs appear in 1023353Sdfr * all copies of this software. 1123353Sdfr * 1223353Sdfr * IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE TO ANY PARTY FOR 1323353Sdfr * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES 1423353Sdfr * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN 1523353Sdfr * IF THE COPYRIGHT HOLDER HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH 1623353Sdfr * DAMAGE. 1723353Sdfr * 1823353Sdfr * THE COPYRIGHT HOLDER SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, 1923353Sdfr * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND 2023353Sdfr * FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS 2123353Sdfr * ON AN "AS IS" BASIS, AND THE COPYRIGHT HOLDER HAS NO OBLIGATION TO 2223353Sdfr * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. 2323353Sdfr * 2423353Sdfr * Google Author(s): Behdad Esfahbod 2523353Sdfr */ 2623353Sdfr 2723353Sdfr#ifndef HB_H_IN 2823353Sdfr#error "Include <hb.h> instead." 2950476Speter#endif 3023353Sdfr 31201538Sbrueffer#ifndef HB_SHAPE_PLAN_H 32206622Suqs#define HB_SHAPE_PLAN_H 3323353Sdfr 3423353Sdfr#include "hb-common.h" 3523353Sdfr#include "hb-font.h" 3623353Sdfr 3723353SdfrHB_BEGIN_DECLS 3884306Sru 3984306Srutypedef struct hb_shape_plan_t hb_shape_plan_t; 4084306Sru 4123353SdfrHB_EXTERN hb_shape_plan_t * 4251140Salfredhb_shape_plan_create (hb_face_t *face, 4323353Sdfr const hb_segment_properties_t *props, 44139852Skeramida const hb_feature_t *user_features, 45139852Skeramida unsigned int num_user_features, 46139852Skeramida const char * const *shaper_list); 4723353Sdfr 48139852SkeramidaHB_EXTERN hb_shape_plan_t * 4951140Salfredhb_shape_plan_create_cached (hb_face_t *face, 50115440Shmp const hb_segment_properties_t *props, 51107788Sru const hb_feature_t *user_features, 52115440Shmp unsigned int num_user_features, 5323353Sdfr const char * const *shaper_list); 54115440Shmp 5523353SdfrHB_EXTERN hb_shape_plan_t * 5623353Sdfrhb_shape_plan_get_empty (void); 5723353Sdfr 58107788SruHB_EXTERN hb_shape_plan_t * 59121382Shmphb_shape_plan_reference (hb_shape_plan_t *shape_plan); 60121382Shmp 61107788SruHB_EXTERN void 62107788Sruhb_shape_plan_destroy (hb_shape_plan_t *shape_plan); 63121382Shmp 64121382ShmpHB_EXTERN hb_bool_t 65107788Sruhb_shape_plan_set_user_data (hb_shape_plan_t *shape_plan, 6623353Sdfr hb_user_data_key_t *key, 6723353Sdfr void * data, 68139852Skeramida hb_destroy_func_t destroy, 69139852Skeramida hb_bool_t replace); 70139852Skeramida 7151140SalfredHB_EXTERN void * 7261684Salexhb_shape_plan_get_user_data (hb_shape_plan_t *shape_plan, 7323353Sdfr hb_user_data_key_t *key); 7423353Sdfr 7523353Sdfr 7623353SdfrHB_EXTERN hb_bool_t 7723353Sdfrhb_shape_plan_execute (hb_shape_plan_t *shape_plan, 7879366Sru hb_font_t *font, 79201538Sbrueffer hb_buffer_t *buffer, 8029966Swosch const hb_feature_t *features, 8123353Sdfr unsigned int num_features); 82121414Shmp 8334504ScharnierHB_EXTERN const char * 84hb_shape_plan_get_shaper (hb_shape_plan_t *shape_plan); 85 86 87HB_END_DECLS 88 89#endif /* HB_SHAPE_PLAN_H */ 90