work on missing value handling
[pspp] / src / output / tex-glyphs.h
1 /* PSPP - a program for statistical analysis.
2    Copyright (C) 2020 Free Software Foundation, Inc.
3
4    This program is free software: you can redistribute it and/or modify
5    it under the terms of the GNU General Public License as published by
6    the Free Software Foundation, either version 3 of the License, or
7    (at your option) any later version.
8
9    This program is distributed in the hope that it will be useful,
10    but WITHOUT ANY WARRANTY; without even the implied warranty of
11    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12    GNU General Public License for more details.
13
14    You should have received a copy of the GNU General Public License
15    along with this program.  If not, see <http://www.gnu.org/licenses/>. */
16
17 #ifndef TEX_GLYPHS_H
18 #define TEX_GLYPHS_H 1
19
20 #include "gl/unitypes.h"
21
22 #include "libpspp/hmap.h"
23
24
25 /* Keep these enums in sync with the definition of tex_macro in tex-glyphs.c */
26 enum tex_ancilliary
27   {
28    TEX_NONE,
29    TEX_VULGAR_FRAC,
30    TEX_OGONEK,
31    TEX_GUILLEMET_LEFT,
32    TEX_GUILLEMET_RIGHT,
33    TEX_DOT,
34    TEX_DOUBLE_ACUTE,
35    TEX_WASY
36   };
37
38 extern const char *tex_macro[];
39
40 struct tex_macro
41 {
42   struct hmap_node node;
43   enum tex_ancilliary index;
44 };
45
46
47 struct glyph
48 {
49   ucs4_t code_point;
50   const char *name;
51   enum tex_ancilliary macro;
52   const char *tex_rendering;
53 };
54
55 struct glyph_block
56 {
57   const struct glyph *start;
58   int n_glyphs;
59 };
60
61
62 extern const char *unsupported_glyph;
63
64 extern const struct glyph_block defined_blocks[] ;
65
66 #endif