/[zanavi_public1]/navit/navit/font/freetype/font_freetype.h
ZANavi

Contents of /navit/navit/font/freetype/font_freetype.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 2 - (show annotations) (download)
Fri Oct 28 21:19:04 2011 UTC (12 years, 5 months ago) by zoff99
File MIME type: text/plain
File size: 1884 byte(s)
import files
1 /**
2 * Navit, a modular navigation system.
3 * Copyright (C) 2005-2011 Navit Team
4 *
5 * This program is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU General Public License
7 * version 2 as published by the Free Software Foundation.
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, write to the
16 * Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17 * Boston, MA 02110-1301, USA.
18 */
19 struct font_freetype_font;
20 struct font_freetype_glyph;
21
22 struct font_freetype_methods {
23 struct font_freetype_font *(*font_new) (struct graphics_priv * gr,
24 struct
25 graphics_font_methods *
26 meth, char *font, int size,
27 int flags);
28 void (*get_text_bbox) (struct graphics_priv * gr,
29 struct font_freetype_font * font,
30 char *text, int dx, int dy,
31 struct point * ret, int estimate);
32 struct font_freetype_text *(*text_new) (char *text,
33 struct font_freetype_font *
34 font, int dx, int dy);
35 void (*text_destroy) (struct font_freetype_text * text);
36 int (*get_shadow) (struct font_freetype_glyph * glyph,
37 unsigned char *data, int depth, int stride, struct color *fg, struct color *tr);
38 int (*get_glyph) (struct font_freetype_glyph * glyph,
39 unsigned char *data, int depth, int stride,
40 struct color * fg, struct color * bg, struct color *tr);
41 };
42
43 struct font_freetype_glyph {
44 int x, y, w, h, dx, dy;
45 unsigned char *pixmap;
46 };
47
48 struct font_freetype_text {
49 int x1, y1;
50 int x2, y2;
51 int x3, y3;
52 int x4, y4;
53 int glyph_count;
54 struct font_freetype_glyph *glyph[0];
55 };

   
Visit the ZANavi Wiki