Fix the header guards for finch
[pidgin-git.git] / finch / gntplugin.h
blob9cd95cd8ca1b72f2afdca042156049a501918ae6
1 /* finch
3 * Finch is the legal property of its developers, whose names are too numerous
4 * to list here. Please refer to the COPYRIGHT file distributed with this
5 * source distribution.
7 * This program is free software; you can redistribute it and/or modify
8 * it under the terms of the GNU General Public License as published by
9 * the Free Software Foundation; either version 2 of the License, or
10 * (at your option) any later version.
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111-1301 USA
22 #ifndef FINCH_PLUGIN_H
23 #define FINCH_PLUGIN_H
25 /**
26 * SECTION:gntplugin
27 * @section_id: finch-gntplugin
28 * @short_description: <filename>gntplugin.h</filename>
29 * @title: Plugin API
32 #include <gnt.h>
34 #include <plugins.h>
35 #include <pluginpref.h>
37 #include <string.h>
39 #include "finch.h"
41 #define FINCH_TYPE_PLUGIN_INFO (finch_plugin_info_get_type())
42 #define FINCH_PLUGIN_INFO(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), FINCH_TYPE_PLUGIN_INFO, FinchPluginInfo))
43 #define FINCH_PLUGIN_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), FINCH_TYPE_PLUGIN_INFO, FinchPluginInfoClass))
44 #define FINCH_IS_PLUGIN_INFO(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), FINCH_TYPE_PLUGIN_INFO))
45 #define FINCH_IS_PLUGIN_INFO_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), FINCH_TYPE_PLUGIN_INFO))
46 #define FINCH_PLUGIN_INFO_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), FINCH_TYPE_PLUGIN_INFO, FinchPluginInfoClass))
48 typedef struct _FinchPluginInfo FinchPluginInfo;
49 typedef struct _FinchPluginInfoClass FinchPluginInfoClass;
51 typedef GntWidget* (*FinchPluginPrefFrameCb) (void);
53 /**
54 * FinchPluginInfo:
56 * Extends #PurplePluginInfo to hold UI information for finch.
58 struct _FinchPluginInfo {
59 PurplePluginInfo parent;
62 /**
63 * FinchPluginInfoClass:
65 * The base class for all #FinchPluginInfo's.
67 struct _FinchPluginInfoClass {
68 PurplePluginInfoClass parent_class;
70 /*< private >*/
71 void (*_gnt_reserved1)(void);
72 void (*_gnt_reserved2)(void);
73 void (*_gnt_reserved3)(void);
74 void (*_gnt_reserved4)(void);
77 /**********************************************************************
78 * Plugin Info API
79 **********************************************************************/
81 /**
82 * finch_plugin_info_get_type:
84 * Returns: The #GType for the #FinchPluginInfo object.
86 GType finch_plugin_info_get_type(void);
88 /**
89 * finch_plugin_info_new:
90 * @first_property: The first property name
91 * @...: The value of the first property, followed optionally by more
92 * name/value pairs, followed by %NULL
94 * Creates a new #FinchPluginInfo instance to be returned from
95 * #plugin_query of a finch plugin, using the provided name/value
96 * pairs.
98 * See purple_plugin_info_new() for a list of available property names.
99 * Additionally, you can provide the property
100 * <literal>"gnt-pref-frame-cb"</literal>, which should be a callback that
101 * returns a #GntWidget for the plugin's preferences
102 * (see #FinchPluginPrefFrameCb).
104 * See purple_plugin_info_new().
106 * Returns: A new #FinchPluginInfo instance.
108 FinchPluginInfo *finch_plugin_info_new(const char *first_property, ...)
109 G_GNUC_NULL_TERMINATED;
111 /**********************************************************************
112 * GNT Plugins API
113 **********************************************************************/
116 * finch_plugins_show_all:
118 * Show a list of plugins.
120 void finch_plugins_show_all(void);
123 * finch_plugins_save_loaded:
125 * Save the list of loaded plugins.
127 void finch_plugins_save_loaded(void);
129 #endif /* FINCH_PLUGIN_H */