meson: Only perform macos checks on macos
[geany-mirror.git] / src / pluginutils.h
blobf34fa2b0fb3bcd0ef9fc5037e2af31b91e478e9f
1 /*
2 * pluginutils.h - this file is part of Geany, a fast and lightweight IDE
4 * Copyright 2009 The Geany contributors
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License along
17 * with this program; if not, write to the Free Software Foundation, Inc.,
18 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
22 #ifndef GEANY_PLUGIN_UTILS_H
23 #define GEANY_PLUGIN_UTILS_H 1
25 #ifdef HAVE_PLUGINS
27 #include "keybindings.h" /* GeanyKeyGroupCallback */
29 #include "gtkcompat.h"
31 G_BEGIN_DECLS
33 /* avoid including plugindata.h otherwise this redefines the GEANY() macro */
34 struct GeanyPlugin;
35 struct GeanyDocument;
37 gint geany_api_version(void);
39 void plugin_add_toolbar_item(struct GeanyPlugin *plugin, GtkToolItem *item);
41 void plugin_module_make_resident(struct GeanyPlugin *plugin);
43 void plugin_signal_connect(struct GeanyPlugin *plugin,
44 GObject *object, const gchar *signal_name, gboolean after,
45 GCallback callback, gpointer user_data);
47 guint plugin_timeout_add(struct GeanyPlugin *plugin, guint interval, GSourceFunc function,
48 gpointer data);
50 guint plugin_timeout_add_seconds(struct GeanyPlugin *plugin, guint interval, GSourceFunc function,
51 gpointer data);
53 guint plugin_idle_add(struct GeanyPlugin *plugin, GSourceFunc function, gpointer data);
55 struct GeanyKeyGroup *plugin_set_key_group(struct GeanyPlugin *plugin,
56 const gchar *section_name, gsize count, GeanyKeyGroupCallback callback);
58 GeanyKeyGroup *plugin_set_key_group_full(struct GeanyPlugin *plugin,
59 const gchar *section_name, gsize count, GeanyKeyGroupFunc cb, gpointer pdata, GDestroyNotify destroy_notify);
61 void plugin_show_configure(struct GeanyPlugin *plugin);
63 void plugin_builder_connect_signals(struct GeanyPlugin *plugin,
64 GtkBuilder *builder, gpointer user_data);
66 gpointer plugin_get_document_data(struct GeanyPlugin *plugin,
67 struct GeanyDocument *doc, const gchar *key);
69 void plugin_set_document_data(struct GeanyPlugin *plugin, struct GeanyDocument *doc,
70 const gchar *key, gpointer data);
72 void plugin_set_document_data_full(struct GeanyPlugin *plugin,
73 struct GeanyDocument *doc, const gchar *key, gpointer data,
74 GDestroyNotify free_func);
76 G_END_DECLS
78 #endif /* HAVE_PLUGINS */
79 #endif /* GEANY_PLUGIN_UTILS_H */