GnuCash 2.3.0
Data Structures | Defines | Functions
gnc-plugin.h File Reference

Functions for adding plugins to a GnuCash window. More...

#include "gnc-main-window.h"
#include "gnc-plugin-page.h"
#include <gconf/gconf-client.h>

Go to the source code of this file.

Data Structures

struct  GncPlugin
struct  GncPluginClass
struct  action_toolbar_labels

Defines

#define GNC_TYPE_PLUGIN   (gnc_plugin_get_type ())
#define GNC_PLUGIN(o)   (G_TYPE_CHECK_INSTANCE_CAST ((o), GNC_TYPE_PLUGIN, GncPlugin))
#define GNC_PLUGIN_CLASS(klass)   (G_TYPE_CHECK_CLASS_CAST ((klass), GNC_TYPE_PLUGIN, GncPluginClass))
#define GNC_IS_PLUGIN(o)   (G_TYPE_CHECK_INSTANCE_TYPE ((o), GNC_TYPE_PLUGIN))
#define GNC_IS_PLUGIN_CLASS(klass)   (G_TYPE_CHECK_CLASS_TYPE ((klass), GNC_TYPE_PLUGIN))
#define GNC_PLUGIN_GET_CLASS(obj)   (G_TYPE_INSTANCE_GET_CLASS ((obj), GNC_PLUGIN, GncPluginClass))
#define GNC_PLUGIN_NAME   "GncPlugin"

Functions

GType gnc_plugin_get_type (void)
void gnc_plugin_add_to_window (GncPlugin *plugin, GncMainWindow *window, GQuark type)
void gnc_plugin_remove_from_window (GncPlugin *plugin, GncMainWindow *window, GQuark type)
const gchar * gnc_plugin_get_name (GncPlugin *plugin)
void gnc_plugin_init_short_names (GtkActionGroup *action_group, action_toolbar_labels *toolbar_labels)
void gnc_plugin_set_important_actions (GtkActionGroup *action_group, const gchar **name)
void gnc_plugin_update_actions (GtkActionGroup *action_group, const gchar **action_names, const gchar *property_name, gboolean value)
gint gnc_plugin_add_actions (GtkUIManager *ui_merge, GtkActionGroup *action_group, const gchar *filename)

Detailed Description

Functions for adding plugins to a GnuCash window.

Author:
Copyright (C) 2003 Jan Arne Petersen
Copyright (C) 2003,2005 David Hampton <hampton@employees.org>

A GncPlugin is the basic object for adding a menu item or items to the GnuCash user interface. This object should be instantiated once at startup time and passed to the plugin manager. Whenever a new window is opened, the main window code will ask the plugin manager for a list of all plugins, and will add each plugin to the new window by calling the gnc_plugin_add_to_window function. This function handles installing the plugin's actions, and then calls the plugin to allow it to perform any plugin specific actions. When a main window is closed, the gnc_plugin_remove_from_window function is called, which first calls the plugin to perform plugin specific actions and then removes the plugin's actions from the window.

Definition in file gnc-plugin.h.

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines