Revision: 456 http://geany-plugins.svn.sourceforge.net/geany-plugins/?rev=456&view=rev Author: prublot Date: 2009-02-07 18:30:56 +0000 (Sat, 07 Feb 2009)
Log Message: ----------- add tooltips
Modified Paths: -------------- trunk/geany-mini-script/ChangeLog trunk/geany-mini-script/TODO trunk/geany-mini-script/configure.in trunk/geany-mini-script/po/de.po trunk/geany-mini-script/po/en.po trunk/geany-mini-script/po/fr.po trunk/geany-mini-script/src/gms.c trunk/geany-mini-script/src/gms_gui.c
Modified: trunk/geany-mini-script/ChangeLog =================================================================== --- trunk/geany-mini-script/ChangeLog 2009-02-07 15:55:27 UTC (rev 455) +++ trunk/geany-mini-script/ChangeLog 2009-02-07 18:30:56 UTC (rev 456) @@ -1,3 +1,7 @@ +2009-02-07 V0.3 + * localization + * add Tips on each button + 2009-01-03 V0.2 * using autotools * adding a help document ( ./doc/gms_help.pdf )
Modified: trunk/geany-mini-script/TODO =================================================================== --- trunk/geany-mini-script/TODO 2009-02-07 15:55:27 UTC (rev 455) +++ trunk/geany-mini-script/TODO 2009-02-07 18:30:56 UTC (rev 456) @@ -1,3 +1,2 @@ * highlighting the script ( shell,perl,sed,awk) -* internationalization
Modified: trunk/geany-mini-script/configure.in =================================================================== --- trunk/geany-mini-script/configure.in 2009-02-07 15:55:27 UTC (rev 455) +++ trunk/geany-mini-script/configure.in 2009-02-07 18:30:56 UTC (rev 456) @@ -1,6 +1,6 @@ dnl Process this file with autoconf to produce a configure script.
-AC_INIT([gms], [0.2], [burlot.p ascal@wanadoo.fr]) +AC_INIT([gms], [0.3], [burlot.p ascal@wanadoo.fr]) dnl AC_CONFIG_SRCDIR([src/gms.c srcgms_gui.c])
AM_INIT_AUTOMAKE([1.9 foreign])
Modified: trunk/geany-mini-script/po/de.po =================================================================== --- trunk/geany-mini-script/po/de.po 2009-02-07 15:55:27 UTC (rev 455) +++ trunk/geany-mini-script/po/de.po 2009-02-07 18:30:56 UTC (rev 456) @@ -7,23 +7,23 @@ msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-02-07 15:15+0100\n" -"PO-Revision-Date: 2009-02-07 16:09+0100\n" +"POT-Creation-Date: 2009-02-07 18:59+0100\n" +"PO-Revision-Date: 2009-02-07 19:01+0100\n" "Last-Translator: Burlot Pascal <prublot(at)users(dot)sourceforge(dot)net>\n" "Language-Team: LANGUAGE LL@li.org\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=utf-8\n" "Content-Transfer-Encoding: 8bit\n"
-#: ../src/gms_gui.c:284 +#: ../src/gms_gui.c:259 msgid "Load Mini-Script File" msgstr "Laden des mini Skriptes"
-#: ../src/gms_gui.c:342 +#: ../src/gms_gui.c:317 msgid "Save Mini-Script File" msgstr "Schutz des mini Skriptes "
-#: ../src/gms_gui.c:412 +#: ../src/gms_gui.c:362 msgid "" "<b>GMS : Geany Mini-Script filter Plugin</b>\n" "This plugin is a tools to apply a script filter on :\n" @@ -71,43 +71,71 @@ "Software Foundation; either version 2 of the License, \n" "or (at your option) any later version."
-#: ../src/gms_gui.c:488 +#: ../src/gms_gui.c:452 msgid "Mini-Script Filter" msgstr "Filter mini Skript"
+#: ../src/gms_gui.c:480 +msgid "Clear the mini-script window" +msgstr "Klären Sie das Minihandschrift-Fenster" + +#: ../src/gms_gui.c:485 +msgid "Load a mini-script into this window" +msgstr "Laden Sie eine Minihandschrift in dieses Fenster" + +#: ../src/gms_gui.c:490 +msgid "Save the mini-script into a file" +msgstr "Sparen(Retten) Sie die Minihandschrift in eine Datei" + +#: ../src/gms_gui.c:495 +msgid "Display a information about the mini-script plugin" +msgstr "Zeigen Sie eine Information über die Steck- Minihandschrift" + +#: ../src/gms_gui.c:503 +msgid "select the mini-script type" +msgstr "wählen Sie den Minihandschrift-Typ aus" + #. Hbox : Radio bouttons for choosing the input: #. selection/current document/all documents of the current session -#: ../src/gms_gui.c:562 +#: ../src/gms_gui.c:534 msgid "filter input" msgstr "Eingangsfilter "
-#: ../src/gms_gui.c:569 +#: ../src/gms_gui.c:536 +msgid "select the input of mini-script filter" +msgstr "wählen Sie den Eingang des Minihandschrift-Filters aus" + +#: ../src/gms_gui.c:542 msgid "selection" msgstr "Auswahl"
-#: ../src/gms_gui.c:570 +#: ../src/gms_gui.c:543 msgid "document" msgstr "dokument"
-#: ../src/gms_gui.c:571 +#: ../src/gms_gui.c:544 msgid "session" msgstr "session"
#. Hbox : Radio bouttons for choosing the output: #. current document/ or new document -#: ../src/gms_gui.c:580 +#: ../src/gms_gui.c:553 msgid "filter output" msgstr " filtrede herausgenommen"
-#: ../src/gms_gui.c:587 +#: ../src/gms_gui.c:555 +msgid "select the output of mini-script filter" +msgstr "wählen Sie die Produktion(Output) des Minihandschrift-Filters aus" + +#: ../src/gms_gui.c:561 msgid "Current Doc." msgstr " übliche Dok."
-#: ../src/gms_gui.c:588 +#: ../src/gms_gui.c:562 msgid "New Doc." msgstr "neues Dok."
-#: ../src/gms_gui.c:811 +#: ../src/gms_gui.c:788 msgid "script configuration" msgstr "Gestalt des Skriptes "
@@ -121,7 +149,7 @@ msgstr "GMS (Geany Steck- Minihandschrift-Filter )"
#: ../src/gms.c:74 -msgid "Pascal BURLOT, a Geany fan" +msgid "Pascal BURLOT, a Geany user" msgstr "Pascal BURLOT, der Benutzer von Geany "
#. Add an item to the Tools menu
Modified: trunk/geany-mini-script/po/en.po =================================================================== --- trunk/geany-mini-script/po/en.po 2009-02-07 15:55:27 UTC (rev 455) +++ trunk/geany-mini-script/po/en.po 2009-02-07 18:30:56 UTC (rev 456) @@ -7,23 +7,23 @@ msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-02-07 15:15+0100\n" -"PO-Revision-Date: 2009-02-07 16:10+0100\n" +"POT-Creation-Date: 2009-02-07 18:59+0100\n" +"PO-Revision-Date: 2009-02-07 18:59+0100\n" "Last-Translator: Burlot Pascal <prublot(at)users(dot)sourceforge(dot)net>\n" "Language-Team: LANGUAGE LL@li.org\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=utf-8\n" "Content-Transfer-Encoding: 8bit\n"
-#: ../src/gms_gui.c:284 +#: ../src/gms_gui.c:259 msgid "Load Mini-Script File" msgstr ""
-#: ../src/gms_gui.c:342 +#: ../src/gms_gui.c:317 msgid "Save Mini-Script File" msgstr ""
-#: ../src/gms_gui.c:412 +#: ../src/gms_gui.c:362 msgid "" "<b>GMS : Geany Mini-Script filter Plugin</b>\n" "This plugin is a tools to apply a script filter on :\n" @@ -49,43 +49,71 @@ "or (at your option) any later version." msgstr ""
-#: ../src/gms_gui.c:488 +#: ../src/gms_gui.c:452 msgid "Mini-Script Filter" msgstr ""
+#: ../src/gms_gui.c:480 +msgid "Clear the mini-script window" +msgstr "" + +#: ../src/gms_gui.c:485 +msgid "Load a mini-script into this window" +msgstr "" + +#: ../src/gms_gui.c:490 +msgid "Save the mini-script into a file" +msgstr "" + +#: ../src/gms_gui.c:495 +msgid "Display a information about the mini-script plugin" +msgstr "" + +#: ../src/gms_gui.c:503 +msgid "select the mini-script type" +msgstr "" + #. Hbox : Radio bouttons for choosing the input: #. selection/current document/all documents of the current session -#: ../src/gms_gui.c:562 +#: ../src/gms_gui.c:534 msgid "filter input" msgstr ""
-#: ../src/gms_gui.c:569 +#: ../src/gms_gui.c:536 +msgid "select the input of mini-script filter" +msgstr "" + +#: ../src/gms_gui.c:542 msgid "selection" msgstr ""
-#: ../src/gms_gui.c:570 +#: ../src/gms_gui.c:543 msgid "document" msgstr ""
-#: ../src/gms_gui.c:571 +#: ../src/gms_gui.c:544 msgid "session" msgstr ""
#. Hbox : Radio bouttons for choosing the output: #. current document/ or new document -#: ../src/gms_gui.c:580 +#: ../src/gms_gui.c:553 msgid "filter output" msgstr ""
-#: ../src/gms_gui.c:587 +#: ../src/gms_gui.c:555 +msgid "select the output of mini-script filter" +msgstr "" + +#: ../src/gms_gui.c:561 msgid "Current Doc." msgstr ""
-#: ../src/gms_gui.c:588 +#: ../src/gms_gui.c:562 msgid "New Doc." msgstr ""
-#: ../src/gms_gui.c:811 +#: ../src/gms_gui.c:788 msgid "script configuration" msgstr ""
@@ -99,7 +127,7 @@ msgstr ""
#: ../src/gms.c:74 -msgid "Pascal BURLOT, a Geany fan" +msgid "Pascal BURLOT, a Geany user" msgstr ""
#. Add an item to the Tools menu
Modified: trunk/geany-mini-script/po/fr.po =================================================================== --- trunk/geany-mini-script/po/fr.po 2009-02-07 15:55:27 UTC (rev 455) +++ trunk/geany-mini-script/po/fr.po 2009-02-07 18:30:56 UTC (rev 456) @@ -7,8 +7,8 @@ msgstr "" "Project-Id-Version: PACKAGE VERSION\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2009-02-07 15:15+0100\n" -"PO-Revision-Date: 2009-02-07 16:20+0100\n" +"POT-Creation-Date: 2009-02-07 18:59+0100\n" +"PO-Revision-Date: 2009-02-07 19:00+0100\n" "Last-Translator: Burlot Pascal <prublot(at)users(dot)sourceforge(dot)net>\n" "Language-Team: LANGUAGE LL@li.org\n" "MIME-Version: 1.0\n" @@ -18,15 +18,15 @@ "X-Poedit-Country: FRANCE\n" "X-Poedit-SourceCharset: utf-8\n"
-#: ../src/gms_gui.c:284 +#: ../src/gms_gui.c:259 msgid "Load Mini-Script File" -msgstr "Chargement du mini-script" +msgstr "Chargement du mini-script"
-#: ../src/gms_gui.c:342 +#: ../src/gms_gui.c:317 msgid "Save Mini-Script File" msgstr "Sauvegarde du Mini-script"
-#: ../src/gms_gui.c:412 +#: ../src/gms_gui.c:362 msgid "" "<b>GMS : Geany Mini-Script filter Plugin</b>\n" "This plugin is a tools to apply a script filter on :\n" @@ -74,43 +74,71 @@ "Software Foundation; either version 2 of the License,\n" "or (at your option) any later version."
-#: ../src/gms_gui.c:488 +#: ../src/gms_gui.c:452 msgid "Mini-Script Filter" msgstr "Filtre Mini-Script"
+#: ../src/gms_gui.c:480 +msgid "Clear the mini-script window" +msgstr "Efface la fenêtre du mini-script" + +#: ../src/gms_gui.c:485 +msgid "Load a mini-script into this window" +msgstr "Charge un fichier mini-script dans la fenêtre" + +#: ../src/gms_gui.c:490 +msgid "Save the mini-script into a file" +msgstr "Sauve le mini-script courant dans un fichier" + +#: ../src/gms_gui.c:495 +msgid "Display a information about the mini-script plugin" +msgstr "Affiche des informations à propos du plugin mini-script" + +#: ../src/gms_gui.c:503 +msgid "select the mini-script type" +msgstr "Sélectionne le type du mini-script" + #. Hbox : Radio bouttons for choosing the input: #. selection/current document/all documents of the current session -#: ../src/gms_gui.c:562 +#: ../src/gms_gui.c:534 msgid "filter input" msgstr "Entrée du filtre"
-#: ../src/gms_gui.c:569 +#: ../src/gms_gui.c:536 +msgid "select the input of mini-script filter" +msgstr "Sélectionne l'entrée du mini-script" + +#: ../src/gms_gui.c:542 msgid "selection" msgstr "sélection"
-#: ../src/gms_gui.c:570 +#: ../src/gms_gui.c:543 msgid "document" msgstr "document"
-#: ../src/gms_gui.c:571 +#: ../src/gms_gui.c:544 msgid "session" msgstr "session"
#. Hbox : Radio bouttons for choosing the output: #. current document/ or new document -#: ../src/gms_gui.c:580 +#: ../src/gms_gui.c:553 msgid "filter output" msgstr "sortie du filtre"
-#: ../src/gms_gui.c:587 +#: ../src/gms_gui.c:555 +msgid "select the output of mini-script filter" +msgstr "Sélectionne la sortie du mini-script" + +#: ../src/gms_gui.c:561 msgid "Current Doc." msgstr "Doc. courant"
-#: ../src/gms_gui.c:588 +#: ../src/gms_gui.c:562 msgid "New Doc." msgstr "Nouveau Doc."
-#: ../src/gms_gui.c:811 +#: ../src/gms_gui.c:788 msgid "script configuration" msgstr "Configuration du script"
@@ -124,7 +152,7 @@ msgstr "GMS ( plugin Geany Mini-Script)"
#: ../src/gms.c:74 -msgid "Pascal BURLOT, a Geany fan" +msgid "Pascal BURLOT, a Geany user" msgstr "Pascal BURLOT, un utilisateur de Geany"
#. Add an item to the Tools menu
Modified: trunk/geany-mini-script/src/gms.c =================================================================== --- trunk/geany-mini-script/src/gms.c 2009-02-07 15:55:27 UTC (rev 455) +++ trunk/geany-mini-script/src/gms.c 2009-02-07 18:30:56 UTC (rev 456) @@ -71,7 +71,7 @@
/* All plugins must set name, description, version and author. */ PLUGIN_SET_INFO(_("geany mini-script"), _("GMS (Geany Mini-Script filter plugin)"), - VERSION , _("Pascal BURLOT, a Geany fan")) + VERSION , _("Pascal BURLOT, a Geany user"))
static GtkWidget *gms_item = NULL ; static gms_handle_t gms_hnd = NULL ;
Modified: trunk/geany-mini-script/src/gms_gui.c =================================================================== --- trunk/geany-mini-script/src/gms_gui.c 2009-02-07 15:55:27 UTC (rev 455) +++ trunk/geany-mini-script/src/gms_gui.c 2009-02-07 18:30:56 UTC (rev 456) @@ -72,7 +72,7 @@
//! \brief definition of gui data structure typedef struct { - GtkWidget *dlg ; //!< Dialog widget + GtkWidget *dlg ; //!< Dialog widget GtkWidget *cb_st ; //!< Script type combobox GtkWidget *t_script ; //!< script text GtkWidget *rb_select ; //!< radio button : filtering the selection @@ -81,8 +81,8 @@ GtkWidget *rb_cdoc ; //!< radio button : the filter output is in the current document GtkWidget *rb_ndoc ; //!< radio button : the filter output is in the current document
- GtkWidget *e_script[GMS_NB_TYPE_SCRIPT] ; //!< entry for script configuration - + GtkWidget *e_script[GMS_NB_TYPE_SCRIPT] ; //!< entry for script configuration + GtkTooltips *tips ; //!< tips of button of the top bar PangoFontDescription *fontdesc; } gms_gui_t ;
@@ -397,6 +397,19 @@ * Global functions */
+static GtkWidget *new_button_from_stock( gboolean withtext, const gchar *stock_id ) +{ + GtkWidget *button ; + if ( withtext ) + button = gtk_button_new_from_stock( stock_id ) ; + else + { + button = gtk_button_new() ; + gtk_container_add( GTK_CONTAINER(button),gtk_image_new_from_stock(stock_id , GTK_ICON_SIZE_SMALL_TOOLBAR ) ); + } + return button ; +} + /** * \brief the function initializes the mini-script gui structure. */ @@ -426,11 +439,11 @@ GtkWidget *hb_rbo ; //!< Hbox for radio buttons
PangoTabArray* tabsarray ; - GdkScreen *ecran = gdk_screen_get_default(); gint width = gdk_screen_get_width(ecran) ; gint height = gdk_screen_get_height(ecran) ; gint i , size_pid ; + gboolean mode_txt_icon = FALSE ;
this->mw = mw ; this->cmd = g_string_new(""); ; @@ -453,26 +466,33 @@
gtk_window_set_default_size( GTK_WINDOW(this->w.dlg) , width/2 , height/2 ) ;
- // Hbox : type de script + + this->w.tips = gtk_tooltips_new (); + + // Hbox : type de script hb_st = gtk_hbox_new (FALSE, 0); gtk_container_set_border_width (GTK_CONTAINER (hb_st), 0); gtk_box_pack_start( vb_dlg , hb_st, FALSE, FALSE, 0);
- b_new = gtk_button_new_from_stock( GTK_STOCK_CLEAR ) ; + b_new = new_button_from_stock( mode_txt_icon, GTK_STOCK_CLEAR ) ; gtk_box_pack_start( GTK_BOX (hb_st), b_new, FALSE, FALSE, 0); g_signal_connect (G_OBJECT (b_new), "clicked",G_CALLBACK (gms_cb_new), (gpointer) this ); + gtk_tooltips_set_tip (GTK_TOOLTIPS (this->w.tips), b_new, _("Clear the mini-script window") , "");
- b_open = gtk_button_new_from_stock( GTK_STOCK_OPEN ) ; + b_open = new_button_from_stock( mode_txt_icon, GTK_STOCK_OPEN ) ; gtk_box_pack_start( GTK_BOX (hb_st), b_open, FALSE, FALSE, 0); g_signal_connect (G_OBJECT (b_open), "clicked",G_CALLBACK (gms_cb_load), (gpointer) this ); + gtk_tooltips_set_tip (GTK_TOOLTIPS (this->w.tips), b_open, _("Load a mini-script into this window"), "");
- b_save = gtk_button_new_from_stock( GTK_STOCK_SAVE_AS ) ; + b_save = new_button_from_stock( mode_txt_icon, GTK_STOCK_SAVE_AS ) ; gtk_box_pack_start( GTK_BOX (hb_st),b_save, FALSE, FALSE, 0); g_signal_connect (G_OBJECT (b_save), "clicked",G_CALLBACK (gms_cb_save), (gpointer) this ); + gtk_tooltips_set_tip (GTK_TOOLTIPS (this->w.tips), b_save, _("Save the mini-script into a file"), "");
- b_info = gtk_button_new_from_stock( GTK_STOCK_INFO) ; + b_info = new_button_from_stock( mode_txt_icon, GTK_STOCK_INFO ) ; gtk_box_pack_end( GTK_BOX (hb_st), b_info, FALSE, FALSE, 0); g_signal_connect (G_OBJECT (b_info), "clicked",G_CALLBACK (gms_cb_info), (gpointer) this ); + gtk_tooltips_set_tip (GTK_TOOLTIPS (this->w.tips), b_info, _("Display a information about the mini-script plugin"), "");
this->w.cb_st = gtk_combo_box_new_text() ; for ( i=0;i<GMS_NB_TYPE_SCRIPT ; i++ ) @@ -480,6 +500,7 @@ gtk_combo_box_set_active(GTK_COMBO_BOX(this->w.cb_st), 0 ); gtk_box_pack_start(GTK_BOX(hb_st), this->w.cb_st, FALSE, FALSE, 0); GTK_WIDGET_SET_FLAGS (this->w.cb_st, GTK_CAN_DEFAULT); + gtk_tooltips_set_tip (GTK_TOOLTIPS (this->w.tips), this->w.cb_st, _("select the mini-script type"), "");
// Scroll Box : script sb_script = gtk_scrolled_window_new (NULL,NULL); @@ -512,6 +533,7 @@ // selection/current document/all documents of the current session f_rbi = gtk_frame_new (_("filter input") ); gtk_box_pack_start( GTK_BOX (hb_rb), f_rbi, FALSE, FALSE, 0); + gtk_tooltips_set_tip (GTK_TOOLTIPS (this->w.tips), f_rbi, _("select the input of mini-script filter"), "");
hb_rbi = gtk_hbox_new (FALSE, 0); gtk_container_set_border_width (GTK_CONTAINER (hb_rbi), 0); @@ -530,6 +552,7 @@ // current document/ or new document f_rbo = gtk_frame_new (_("filter output") ); gtk_box_pack_start( GTK_BOX(hb_rb), f_rbo, FALSE, FALSE, 0); + gtk_tooltips_set_tip (GTK_TOOLTIPS (this->w.tips), f_rbo, _("select the output of mini-script filter"), "");
hb_rbo = gtk_hbox_new (FALSE, 0); gtk_container_set_border_width (GTK_CONTAINER(hb_rbo), 0); @@ -599,6 +622,9 @@ g_string_free(this->script_cmd[i] ,flag) ;
+ gtk_object_unref( GTK_OBJECT(this->w.tips) ); + this->w.tips = NULL ; + GMS_G_FREE( this ) ; } }
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
plugins-commits@lists.geany.org