1 /* 2 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 3 * 4 * This code is free software; you can redistribute it and/or modify it 5 * under the terms of the GNU General Public License version 2 only, as 6 * published by the Free Software Foundation. Oracle designates this 7 * particular file as subject to the "Classpath" exception as provided 8 * by Oracle in the LICENSE file that accompanied this code. 9 * 10 * This code is distributed in the hope that it will be useful, but WITHOUT 11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 13 * version 2 for more details (a copy is included in the LICENSE file that 14 * accompanied this code). 15 * 16 * You should have received a copy of the GNU General Public License version 17 * 2 along with this work; if not, write to the Free Software Foundation, 18 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 19 * 20 * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA 21 * or visit www.oracle.com if you need additional information or have any 22 * questions. 23 */ 24 25 // This file is available under and governed by the GNU General Public 26 // License version 2 only, as published by the Free Software Foundation. 27 // However, the following notice accompanied the original version of this 28 // file: 29 // 30 /* 31 * Copyright © 2012 Google, Inc. 32 * 33 * This is part of HarfBuzz, a text shaping library. 34 * 35 * Permission is hereby granted, without written agreement and without 36 * license or royalty fees, to use, copy, modify, and distribute this 37 * software and its documentation for any purpose, provided that the 38 * above copyright notice and the following two paragraphs appear in 39 * all copies of this software. 40 * 41 * IN NO EVENT SHALL THE COPYRIGHT HOLDER BE LIABLE TO ANY PARTY FOR 42 * DIRECT, INDIRECT, SPECIAL, INCIDENTAL, OR CONSEQUENTIAL DAMAGES 43 * ARISING OUT OF THE USE OF THIS SOFTWARE AND ITS DOCUMENTATION, EVEN 44 * IF THE COPYRIGHT HOLDER HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH 45 * DAMAGE. 46 * 47 * THE COPYRIGHT HOLDER SPECIFICALLY DISCLAIMS ANY WARRANTIES, INCLUDING, 48 * BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND 49 * FITNESS FOR A PARTICULAR PURPOSE. THE SOFTWARE PROVIDED HEREUNDER IS 50 * ON AN "AS IS" BASIS, AND THE COPYRIGHT HOLDER HAS NO OBLIGATION TO 51 * PROVIDE MAINTENANCE, SUPPORT, UPDATES, ENHANCEMENTS, OR MODIFICATIONS. 52 * 53 * Google Author(s): Behdad Esfahbod 54 */ 55 56 #ifndef HB_H_IN 57 #error "Include <hb.h> instead." 58 #endif 59 60 #ifndef HB_SHAPE_PLAN_H 61 #define HB_SHAPE_PLAN_H 62 63 #include "hb-common.h" 64 #include "hb-font.h" 65 66 HB_BEGIN_DECLS 67 68 typedef struct hb_shape_plan_t hb_shape_plan_t; 69 70 hb_shape_plan_t * 71 hb_shape_plan_create (hb_face_t *face, 72 const hb_segment_properties_t *props, 73 const hb_feature_t *user_features, 74 unsigned int num_user_features, 75 const char * const *shaper_list); 76 77 hb_shape_plan_t * 78 hb_shape_plan_create_cached (hb_face_t *face, 79 const hb_segment_properties_t *props, 80 const hb_feature_t *user_features, 81 unsigned int num_user_features, 82 const char * const *shaper_list); 83 84 hb_shape_plan_t * 85 hb_shape_plan_get_empty (void); 86 87 hb_shape_plan_t * 88 hb_shape_plan_reference (hb_shape_plan_t *shape_plan); 89 90 void 91 hb_shape_plan_destroy (hb_shape_plan_t *shape_plan); 92 93 hb_bool_t 94 hb_shape_plan_set_user_data (hb_shape_plan_t *shape_plan, 95 hb_user_data_key_t *key, 96 void * data, 97 hb_destroy_func_t destroy, 98 hb_bool_t replace); 99 100 void * 101 hb_shape_plan_get_user_data (hb_shape_plan_t *shape_plan, 102 hb_user_data_key_t *key); 103 104 105 hb_bool_t 106 hb_shape_plan_execute (hb_shape_plan_t *shape_plan, 107 hb_font_t *font, 108 hb_buffer_t *buffer, 109 const hb_feature_t *features, 110 unsigned int num_features); 111 112 const char * 113 hb_shape_plan_get_shaper (hb_shape_plan_t *shape_plan); 114 115 116 HB_END_DECLS 117 118 #endif /* HB_SHAPE_PLAN_H */