File indexing completed on 2025-02-21 10:04:02
0001
0002
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019
0020
0021
0022
0023
0024
0025
0026
0027
0028
0029 #if !defined(HB_OT_H_IN) && !defined(HB_NO_SINGLE_HEADER_ERROR)
0030 #error "Include <hb-ot.h> instead."
0031 #endif
0032
0033 #ifndef HB_OT_COLOR_H
0034 #define HB_OT_COLOR_H
0035
0036 #include "hb.h"
0037 #include "hb-ot-name.h"
0038
0039 HB_BEGIN_DECLS
0040
0041
0042
0043
0044
0045
0046 HB_EXTERN hb_bool_t
0047 hb_ot_color_has_palettes (hb_face_t *face);
0048
0049 HB_EXTERN unsigned int
0050 hb_ot_color_palette_get_count (hb_face_t *face);
0051
0052 HB_EXTERN hb_ot_name_id_t
0053 hb_ot_color_palette_get_name_id (hb_face_t *face,
0054 unsigned int palette_index);
0055
0056 HB_EXTERN hb_ot_name_id_t
0057 hb_ot_color_palette_color_get_name_id (hb_face_t *face,
0058 unsigned int color_index);
0059
0060
0061
0062
0063
0064
0065
0066
0067
0068
0069
0070
0071
0072
0073 typedef enum {
0074 HB_OT_COLOR_PALETTE_FLAG_DEFAULT = 0x00000000u,
0075 HB_OT_COLOR_PALETTE_FLAG_USABLE_WITH_LIGHT_BACKGROUND = 0x00000001u,
0076 HB_OT_COLOR_PALETTE_FLAG_USABLE_WITH_DARK_BACKGROUND = 0x00000002u
0077 } hb_ot_color_palette_flags_t;
0078
0079 HB_EXTERN hb_ot_color_palette_flags_t
0080 hb_ot_color_palette_get_flags (hb_face_t *face,
0081 unsigned int palette_index);
0082
0083 HB_EXTERN unsigned int
0084 hb_ot_color_palette_get_colors (hb_face_t *face,
0085 unsigned int palette_index,
0086 unsigned int start_offset,
0087 unsigned int *color_count,
0088 hb_color_t *colors );
0089
0090
0091
0092
0093
0094
0095 HB_EXTERN hb_bool_t
0096 hb_ot_color_has_layers (hb_face_t *face);
0097
0098
0099
0100
0101
0102
0103
0104
0105
0106
0107
0108
0109
0110
0111 typedef struct hb_ot_color_layer_t {
0112 hb_codepoint_t glyph;
0113 unsigned int color_index;
0114 } hb_ot_color_layer_t;
0115
0116 HB_EXTERN unsigned int
0117 hb_ot_color_glyph_get_layers (hb_face_t *face,
0118 hb_codepoint_t glyph,
0119 unsigned int start_offset,
0120 unsigned int *layer_count,
0121 hb_ot_color_layer_t *layers );
0122
0123
0124
0125 HB_EXTERN hb_bool_t
0126 hb_ot_color_has_paint (hb_face_t *face);
0127
0128 HB_EXTERN hb_bool_t
0129 hb_ot_color_glyph_has_paint (hb_face_t *face,
0130 hb_codepoint_t glyph);
0131
0132
0133
0134
0135
0136 HB_EXTERN hb_bool_t
0137 hb_ot_color_has_svg (hb_face_t *face);
0138
0139 HB_EXTERN hb_blob_t *
0140 hb_ot_color_glyph_reference_svg (hb_face_t *face, hb_codepoint_t glyph);
0141
0142
0143
0144
0145
0146 HB_EXTERN hb_bool_t
0147 hb_ot_color_has_png (hb_face_t *face);
0148
0149 HB_EXTERN hb_blob_t *
0150 hb_ot_color_glyph_reference_png (hb_font_t *font, hb_codepoint_t glyph);
0151
0152
0153 HB_END_DECLS
0154
0155 #endif