diff options
Diffstat (limited to 'plugins/changecase')
-rwxr-xr-x | plugins/changecase/Makefile.am | 18 | ||||
-rwxr-xr-x | plugins/changecase/changecase.pluma-plugin.desktop.in (renamed from plugins/changecase/changecase.gedit-plugin.desktop.in) | 4 | ||||
-rwxr-xr-x | plugins/changecase/gedit-changecase-plugin.h | 72 | ||||
-rwxr-xr-x | plugins/changecase/pluma-changecase-plugin.c (renamed from plugins/changecase/gedit-changecase-plugin.c) | 72 | ||||
-rwxr-xr-x | plugins/changecase/pluma-changecase-plugin.h | 72 |
5 files changed, 119 insertions, 119 deletions
diff --git a/plugins/changecase/Makefile.am b/plugins/changecase/Makefile.am index 1f165f9e..3886dc86 100755 --- a/plugins/changecase/Makefile.am +++ b/plugins/changecase/Makefile.am @@ -1,29 +1,29 @@ # changecase plugin -plugindir = $(GEDIT_PLUGINS_LIBS_DIR) +plugindir = $(PLUMA_PLUGINS_LIBS_DIR) INCLUDES = \ -I$(top_srcdir) \ - $(GEDIT_CFLAGS) \ + $(PLUMA_CFLAGS) \ $(WARN_CFLAGS) \ $(DISABLE_DEPRECATED_CFLAGS) plugin_LTLIBRARIES = libchangecase.la libchangecase_la_SOURCES = \ - gedit-changecase-plugin.h \ - gedit-changecase-plugin.c + pluma-changecase-plugin.h \ + pluma-changecase-plugin.c libchangecase_la_LDFLAGS = $(PLUGIN_LIBTOOL_FLAGS) -libchangecase_la_LIBADD = $(GEDIT_LIBS) +libchangecase_la_LIBADD = $(PLUMA_LIBS) -uidir = $(GEDIT_PLUGINS_DATA_DIR)/changecase +uidir = $(PLUMA_PLUGINS_DATA_DIR)/changecase ui_DATA = -plugin_in_files = changecase.gedit-plugin.desktop.in +plugin_in_files = changecase.pluma-plugin.desktop.in -%.gedit-plugin: %.gedit-plugin.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po) ; $(INTLTOOL_MERGE) $(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache +%.pluma-plugin: %.pluma-plugin.desktop.in $(INTLTOOL_MERGE) $(wildcard $(top_srcdir)/po/*po) ; $(INTLTOOL_MERGE) $(top_srcdir)/po $< $@ -d -u -c $(top_builddir)/po/.intltool-merge-cache -plugin_DATA = $(plugin_in_files:.gedit-plugin.desktop.in=.gedit-plugin) +plugin_DATA = $(plugin_in_files:.pluma-plugin.desktop.in=.pluma-plugin) EXTRA_DIST = $(ui_DATA) $(plugin_in_files) diff --git a/plugins/changecase/changecase.gedit-plugin.desktop.in b/plugins/changecase/changecase.pluma-plugin.desktop.in index 52a226f4..d049a9c1 100755 --- a/plugins/changecase/changecase.gedit-plugin.desktop.in +++ b/plugins/changecase/changecase.pluma-plugin.desktop.in @@ -1,8 +1,8 @@ -[Gedit Plugin] +[Pluma Plugin] Module=changecase IAge=2 _Name=Change Case _Description=Changes the case of selected text. Authors=Paolo Borelli <[email protected]> Copyright=Copyright © 2004-2005 Paolo Borelli -Website=http://www.gedit.org +Website=http://www.pluma.org diff --git a/plugins/changecase/gedit-changecase-plugin.h b/plugins/changecase/gedit-changecase-plugin.h deleted file mode 100755 index 9587928c..00000000 --- a/plugins/changecase/gedit-changecase-plugin.h +++ /dev/null @@ -1,72 +0,0 @@ -/* - * gedit-changecase-plugin.h - * - * Copyright (C) 2004-2005 - Paolo Borelli - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2, or (at your option) - * any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. - * - * $Id$ - */ - -#ifndef __GEDIT_CHANGECASE_PLUGIN_H__ -#define __GEDIT_CHANGECASE_PLUGIN_H__ - -#include <glib.h> -#include <glib-object.h> -#include <gedit/gedit-plugin.h> - -G_BEGIN_DECLS - -/* - * Type checking and casting macros - */ -#define GEDIT_TYPE_CHANGECASE_PLUGIN (gedit_changecase_plugin_get_type ()) -#define GEDIT_CHANGECASE_PLUGIN(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), GEDIT_TYPE_CHANGECASE_PLUGIN, GeditChangecasePlugin)) -#define GEDIT_CHANGECASE_PLUGIN_CLASS(k) (G_TYPE_CHECK_CLASS_CAST((k), GEDIT_TYPE_CHANGECASE_PLUGIN, GeditChangecasePluginClass)) -#define GEDIT_IS_CHANGECASE_PLUGIN(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), GEDIT_TYPE_CHANGECASE_PLUGIN)) -#define GEDIT_IS_CHANGECASE_PLUGIN_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), GEDIT_TYPE_CHANGECASE_PLUGIN)) -#define GEDIT_CHANGECASE_PLUGIN_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), GEDIT_TYPE_CHANGECASE_PLUGIN, GeditChangecasePluginClass)) - -/* - * Main object structure - */ -typedef struct _GeditChangecasePlugin GeditChangecasePlugin; - -struct _GeditChangecasePlugin -{ - GeditPlugin parent_instance; -}; - -/* - * Class definition - */ -typedef struct _GeditChangecasePluginClass GeditChangecasePluginClass; - -struct _GeditChangecasePluginClass -{ - GeditPluginClass parent_class; -}; - -/* - * Public methods - */ -GType gedit_changecase_plugin_get_type (void) G_GNUC_CONST; - -/* All the plugins must implement this function */ -G_MODULE_EXPORT GType register_gedit_plugin (GTypeModule *module); - -G_END_DECLS - -#endif /* __GEDIT_CHANGECASE_PLUGIN_H__ */ diff --git a/plugins/changecase/gedit-changecase-plugin.c b/plugins/changecase/pluma-changecase-plugin.c index 8544aeb0..735a6be1 100755 --- a/plugins/changecase/gedit-changecase-plugin.c +++ b/plugins/changecase/pluma-changecase-plugin.c @@ -1,5 +1,5 @@ /* - * gedit-changecase-plugin.c + * pluma-changecase-plugin.c * * Copyright (C) 2004-2005 - Paolo Borelli * @@ -24,16 +24,16 @@ #include <config.h> #endif -#include "gedit-changecase-plugin.h" +#include "pluma-changecase-plugin.h" #include <glib/gi18n-lib.h> #include <gmodule.h> -#include <gedit/gedit-debug.h> +#include <pluma/pluma-debug.h> -#define WINDOW_DATA_KEY "GeditChangecasePluginWindowData" +#define WINDOW_DATA_KEY "PlumaChangecasePluginWindowData" -GEDIT_PLUGIN_REGISTER_TYPE(GeditChangecasePlugin, gedit_changecase_plugin) +PLUMA_PLUGIN_REGISTER_TYPE(PlumaChangecasePlugin, pluma_changecase_plugin) typedef enum { TO_UPPER_CASE, @@ -149,15 +149,15 @@ do_title_case (GtkTextBuffer *buffer, } static void -change_case (GeditWindow *window, +change_case (PlumaWindow *window, ChangeCaseChoice choice) { - GeditDocument *doc; + PlumaDocument *doc; GtkTextIter start, end; - gedit_debug (DEBUG_PLUGINS); + pluma_debug (DEBUG_PLUGINS); - doc = gedit_window_get_active_document (window); + doc = pluma_window_get_active_document (window); g_return_if_fail (doc != NULL); if (!gtk_text_buffer_get_selection_bounds (GTK_TEXT_BUFFER (doc), @@ -191,28 +191,28 @@ change_case (GeditWindow *window, static void upper_case_cb (GtkAction *action, - GeditWindow *window) + PlumaWindow *window) { change_case (window, TO_UPPER_CASE); } static void lower_case_cb (GtkAction *action, - GeditWindow *window) + PlumaWindow *window) { change_case (window, TO_LOWER_CASE); } static void invert_case_cb (GtkAction *action, - GeditWindow *window) + PlumaWindow *window) { change_case (window, INVERT_CASE); } static void title_case_cb (GtkAction *action, - GeditWindow *window) + PlumaWindow *window) { change_case (window, TO_TITLE_CASE); } @@ -251,17 +251,17 @@ const gchar submenu[] = "</ui>"; static void -gedit_changecase_plugin_init (GeditChangecasePlugin *plugin) +pluma_changecase_plugin_init (PlumaChangecasePlugin *plugin) { - gedit_debug_message (DEBUG_PLUGINS, "GeditChangecasePlugin initializing"); + pluma_debug_message (DEBUG_PLUGINS, "PlumaChangecasePlugin initializing"); } static void -gedit_changecase_plugin_finalize (GObject *object) +pluma_changecase_plugin_finalize (GObject *object) { - G_OBJECT_CLASS (gedit_changecase_plugin_parent_class)->finalize (object); + G_OBJECT_CLASS (pluma_changecase_plugin_parent_class)->finalize (object); - gedit_debug_message (DEBUG_PLUGINS, "GeditChangecasePlugin finalizing"); + pluma_debug_message (DEBUG_PLUGINS, "PlumaChangecasePlugin finalizing"); } typedef struct @@ -279,16 +279,16 @@ free_window_data (WindowData *data) } static void -update_ui_real (GeditWindow *window, +update_ui_real (PlumaWindow *window, WindowData *data) { GtkTextView *view; GtkAction *action; gboolean sensitive = FALSE; - gedit_debug (DEBUG_PLUGINS); + pluma_debug (DEBUG_PLUGINS); - view = GTK_TEXT_VIEW (gedit_window_get_active_view (window)); + view = GTK_TEXT_VIEW (pluma_window_get_active_view (window)); if (view != NULL) { @@ -305,20 +305,20 @@ update_ui_real (GeditWindow *window, } static void -impl_activate (GeditPlugin *plugin, - GeditWindow *window) +impl_activate (PlumaPlugin *plugin, + PlumaWindow *window) { GtkUIManager *manager; WindowData *data; GError *error = NULL; - gedit_debug (DEBUG_PLUGINS); + pluma_debug (DEBUG_PLUGINS); data = g_slice_new (WindowData); - manager = gedit_window_get_ui_manager (window); + manager = pluma_window_get_ui_manager (window); - data->action_group = gtk_action_group_new ("GeditChangecasePluginActions"); + data->action_group = gtk_action_group_new ("PlumaChangecasePluginActions"); gtk_action_group_set_translation_domain (data->action_group, GETTEXT_PACKAGE); gtk_action_group_add_actions (data->action_group, @@ -348,15 +348,15 @@ impl_activate (GeditPlugin *plugin, } static void -impl_deactivate (GeditPlugin *plugin, - GeditWindow *window) +impl_deactivate (PlumaPlugin *plugin, + PlumaWindow *window) { GtkUIManager *manager; WindowData *data; - gedit_debug (DEBUG_PLUGINS); + pluma_debug (DEBUG_PLUGINS); - manager = gedit_window_get_ui_manager (window); + manager = pluma_window_get_ui_manager (window); data = (WindowData *) g_object_get_data (G_OBJECT (window), WINDOW_DATA_KEY); g_return_if_fail (data != NULL); @@ -368,12 +368,12 @@ impl_deactivate (GeditPlugin *plugin, } static void -impl_update_ui (GeditPlugin *plugin, - GeditWindow *window) +impl_update_ui (PlumaPlugin *plugin, + PlumaWindow *window) { WindowData *data; - gedit_debug (DEBUG_PLUGINS); + pluma_debug (DEBUG_PLUGINS); data = (WindowData *) g_object_get_data (G_OBJECT (window), WINDOW_DATA_KEY); g_return_if_fail (data != NULL); @@ -382,12 +382,12 @@ impl_update_ui (GeditPlugin *plugin, } static void -gedit_changecase_plugin_class_init (GeditChangecasePluginClass *klass) +pluma_changecase_plugin_class_init (PlumaChangecasePluginClass *klass) { GObjectClass *object_class = G_OBJECT_CLASS (klass); - GeditPluginClass *plugin_class = GEDIT_PLUGIN_CLASS (klass); + PlumaPluginClass *plugin_class = PLUMA_PLUGIN_CLASS (klass); - object_class->finalize = gedit_changecase_plugin_finalize; + object_class->finalize = pluma_changecase_plugin_finalize; plugin_class->activate = impl_activate; plugin_class->deactivate = impl_deactivate; diff --git a/plugins/changecase/pluma-changecase-plugin.h b/plugins/changecase/pluma-changecase-plugin.h new file mode 100755 index 00000000..56604352 --- /dev/null +++ b/plugins/changecase/pluma-changecase-plugin.h @@ -0,0 +1,72 @@ +/* + * pluma-changecase-plugin.h + * + * Copyright (C) 2004-2005 - Paolo Borelli + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; either version 2, or (at your option) + * any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. + * + * $Id$ + */ + +#ifndef __PLUMA_CHANGECASE_PLUGIN_H__ +#define __PLUMA_CHANGECASE_PLUGIN_H__ + +#include <glib.h> +#include <glib-object.h> +#include <pluma/pluma-plugin.h> + +G_BEGIN_DECLS + +/* + * Type checking and casting macros + */ +#define PLUMA_TYPE_CHANGECASE_PLUGIN (pluma_changecase_plugin_get_type ()) +#define PLUMA_CHANGECASE_PLUGIN(o) (G_TYPE_CHECK_INSTANCE_CAST ((o), PLUMA_TYPE_CHANGECASE_PLUGIN, PlumaChangecasePlugin)) +#define PLUMA_CHANGECASE_PLUGIN_CLASS(k) (G_TYPE_CHECK_CLASS_CAST((k), PLUMA_TYPE_CHANGECASE_PLUGIN, PlumaChangecasePluginClass)) +#define PLUMA_IS_CHANGECASE_PLUGIN(o) (G_TYPE_CHECK_INSTANCE_TYPE ((o), PLUMA_TYPE_CHANGECASE_PLUGIN)) +#define PLUMA_IS_CHANGECASE_PLUGIN_CLASS(k) (G_TYPE_CHECK_CLASS_TYPE ((k), PLUMA_TYPE_CHANGECASE_PLUGIN)) +#define PLUMA_CHANGECASE_PLUGIN_GET_CLASS(o) (G_TYPE_INSTANCE_GET_CLASS ((o), PLUMA_TYPE_CHANGECASE_PLUGIN, PlumaChangecasePluginClass)) + +/* + * Main object structure + */ +typedef struct _PlumaChangecasePlugin PlumaChangecasePlugin; + +struct _PlumaChangecasePlugin +{ + PlumaPlugin parent_instance; +}; + +/* + * Class definition + */ +typedef struct _PlumaChangecasePluginClass PlumaChangecasePluginClass; + +struct _PlumaChangecasePluginClass +{ + PlumaPluginClass parent_class; +}; + +/* + * Public methods + */ +GType pluma_changecase_plugin_get_type (void) G_GNUC_CONST; + +/* All the plugins must implement this function */ +G_MODULE_EXPORT GType register_pluma_plugin (GTypeModule *module); + +G_END_DECLS + +#endif /* __PLUMA_CHANGECASE_PLUGIN_H__ */ |