[AdgADim] Added "angle1" and "angle2" properties
[adg.git] / adg / adg-dim-private.h
blobcadf0f24954abe1cfd4a544eaef677d98838c33c
1 /* ADG - Automatic Drawing Generation
2 * Copyright (C) 2007,2008,2009 Nicola Fontana <ntd at entidi.it>
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version.
9 * This library 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 GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the
16 * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17 * Boston, MA 02110-1301, USA.
21 #ifndef __ADG_DIM_PRIVATE_H__
22 #define __ADG_DIM_PRIVATE_H__
24 #include <adg/adg-style.h>
25 #include <adg/adg-pair.h>
28 G_BEGIN_DECLS
30 typedef struct _AdgTextCache AdgTextCache;
31 typedef struct _AdgDimPrivate AdgDimPrivate;
33 struct _AdgTextCache {
34 const char *utf8;
35 int utf8_len;
36 cairo_glyph_t *glyphs;
37 int num_glyphs;
38 cairo_text_cluster_t *clusters;
39 int num_clusters;
40 cairo_text_cluster_flags_t cluster_flags;
41 cairo_text_extents_t extents;
44 struct _AdgDimPrivate {
45 /* Properties */
46 AdgPair ref1;
47 AdgPair ref2;
48 AdgPair pos1;
49 AdgPair pos2;
50 gdouble level;
51 gchar *quote;
52 gchar *tolerance_up;
53 gchar *tolerance_down;
54 gchar *note;
56 /* Cache */
57 AdgPair org;
58 gdouble angle;
59 AdgTextCache quote_cache;
60 AdgTextCache tolerance_up_cache;
61 AdgTextCache tolerance_down_cache;
62 AdgTextCache note_cache;
65 G_END_DECLS
68 #endif /* __ADG_DIM_PRIVATE_H__ */