Do case insensitive search for lua scripts to load.
[obnox/wireshark/wip.git] / gtk / font_utils.h
1 /* font_utils.h
2  * Declarations of utilities to use for font manipulation
3  *
4  * $Id$
5  *
6  * Wireshark - Network traffic analyzer
7  * By Gerald Combs <gerald@wireshark.org>
8  * Copyright 1998 Gerald Combs
9  *
10  * This program is free software; you can redistribute it and/or
11  * modify it under the terms of the GNU General Public License
12  * as published by the Free Software Foundation; either version 2
13  * of the License, or (at your option) any later version.
14  *
15  * This program is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
18  * GNU General Public License for more details.
19  *
20  * You should have received a copy of the GNU General Public License
21  * along with this program; if not, write to the Free Software
22  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
23  */
24
25
26 /** @file
27  * Utilities for font manipulation. 
28  *
29  * There are two different fonts used:
30  * - the application font for menu's, dialog's and such
31  * - the user font for the packet panes
32  * 
33  * The user font is also available in regular (m_r_font) and bold (m_b_font) versions.
34  */
35
36 #ifndef __FONT_UTILS_H__
37 #define __FONT_UTILS_H__
38
39 /** Init the application and user fonts at program start. */
40 extern void font_init(void);
41
42 /** Return value from font_apply() */
43 typedef enum {
44         FA_SUCCESS,             /**< function succeeded */
45         FA_FONT_NOT_RESIZEABLE, /**< the chosen font isn't resizable */
46         FA_FONT_NOT_AVAILABLE   /**< the chosen font isn't available */
47 } fa_ret_t;
48
49 /** Applies a new user font, corresponding to the preferences font name and recent zoom level. 
50  *  Will also redraw the screen.
51  *
52  * @return if the new font could be set or not
53  */
54 extern fa_ret_t user_font_apply(void);
55
56 /** Test, if the given font name is available.
57  *
58  * @param font_name the font to test
59  * @return TRUE, if this font is available
60  */
61 extern gboolean user_font_test(gchar *font_name);
62
63 /** Get the regular user font.
64  *
65  * @return the regular user font
66  */
67 extern PangoFontDescription *user_font_get_regular(void);
68
69 /** Get the bold user font.
70  *
71  * @return the bold user font
72  */
73 extern PangoFontDescription *user_font_get_bold(void);
74
75 #endif