Revision: 1210
http://geany-plugins.svn.sourceforge.net/geany-plugins/?rev=1210&view=rev
Author: frlan
Date: 2010-03-27 09:41:47 +0000 (Sat, 27 Mar 2010)
Log Message:
-----------
GeanyLaTeX: Fix a minor problem on showing a tooltip in a wrong context
Modified Paths:
--------------
trunk/geanylatex/src/geanylatex.c
Modified: trunk/geanylatex/src/geanylatex.c
===================================================================
--- trunk/geanylatex/src/geanylatex.c 2010-03-27 09:41:23 UTC (rev 1209)
+++ trunk/geanylatex/src/geanylatex.c 2010-03-27 09:41:47 UTC (rev 1210)
@@ -1816,7 +1816,7 @@
menu_latex_insert_usepackage = gtk_menu_item_new_with_mnemonic(
_("Insert P_ackage"));
- ui_widget_set_tooltip_text(menu_latex_insert_environment,
+ ui_widget_set_tooltip_text(menu_latex_insert_usepackage,
_("A small dialog to insert \\usepackage{} into header of current file"));
gtk_container_add(GTK_CONTAINER(menu_latex_menu), menu_latex_insert_usepackage);
g_signal_connect(menu_latex_insert_usepackage, "activate",
@@ -1901,6 +1901,8 @@
G_CALLBACK(glatex_toggle_status), NULL);
init_keybindings();
+
+ /* Check whether the toolbar should be shown or not and do so*/
if (glatex_set_toolbar_active == TRUE)
{
glatex_toolbar = init_toolbar();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
Revision: 1209
http://geany-plugins.svn.sourceforge.net/geany-plugins/?rev=1209&view=rev
Author: frlan
Date: 2010-03-27 09:41:23 +0000 (Sat, 27 Mar 2010)
Log Message:
-----------
GeanyLaTeX: Redefine a couple of accelerators on menu
Modified Paths:
--------------
trunk/geanylatex/src/geanylatex.c
Modified: trunk/geanylatex/src/geanylatex.c
===================================================================
--- trunk/geanylatex/src/geanylatex.c 2010-03-27 09:40:58 UTC (rev 1208)
+++ trunk/geanylatex/src/geanylatex.c 2010-03-27 09:41:23 UTC (rev 1209)
@@ -1780,7 +1780,7 @@
g_signal_connect(menu_latex_wizard, "activate",
G_CALLBACK(glatex_wizard_activated), NULL);
- menu_latex_menu_special_char = gtk_menu_item_new_with_mnemonic(_("Insert _Special Character"));
+ menu_latex_menu_special_char = gtk_menu_item_new_with_mnemonic(_("I_nsert Special Character"));
ui_widget_set_tooltip_text(menu_latex_menu_special_char,
_("Helps to use some not very common letters and signs"));
gtk_container_add(GTK_CONTAINER(menu_latex_menu),
@@ -1815,7 +1815,7 @@
G_CALLBACK(glatex_insert_environment_dialog), NULL);
menu_latex_insert_usepackage = gtk_menu_item_new_with_mnemonic(
- _("Insert Package"));
+ _("Insert P_ackage"));
ui_widget_set_tooltip_text(menu_latex_insert_environment,
_("A small dialog to insert \\usepackage{} into header of current file"));
gtk_container_add(GTK_CONTAINER(menu_latex_menu), menu_latex_insert_usepackage);
@@ -1855,7 +1855,7 @@
}
/* Add font size menu */
- menu_latex_fontsize = gtk_menu_item_new_with_mnemonic(_("_Font size"));
+ menu_latex_fontsize = gtk_menu_item_new_with_mnemonic(_("F_ont size"));
gtk_container_add(GTK_CONTAINER(menu_latex_menu), menu_latex_fontsize);
menu_latex_fontsize_submenu = gtk_menu_new();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
Revision: 1208
http://geany-plugins.svn.sourceforge.net/geany-plugins/?rev=1208&view=rev
Author: frlan
Date: 2010-03-27 09:40:58 +0000 (Sat, 27 Mar 2010)
Log Message:
-----------
GeanyLaTeX: Missed to update ChageLog
Modified Paths:
--------------
trunk/geanylatex/ChangeLog
Modified: trunk/geanylatex/ChangeLog
===================================================================
--- trunk/geanylatex/ChangeLog 2010-03-27 01:37:16 UTC (rev 1207)
+++ trunk/geanylatex/ChangeLog 2010-03-27 09:40:58 UTC (rev 1208)
@@ -1,3 +1,8 @@
+2010-03-27 Frank Lanitz <frank(at)frank(dot)uvena(dot)de>
+
+ * Add a menu entry for inserting font sizes to document
+
+
2010-03-20 Frank Lanitz <frank(at)frank(dot)uvena(dot)de>
* Insert a keybinding and a dialog to insert a \usepackage{} line to header.
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
Revision: 1206
http://geany-plugins.svn.sourceforge.net/geany-plugins/?rev=1206&view=rev
Author: frlan
Date: 2010-03-27 01:36:53 +0000 (Sat, 27 Mar 2010)
Log Message:
-----------
GeanyLaTeX: Adding a menu entry for easy inserting font sizes into
LaTeX document
Modified Paths:
--------------
trunk/geanylatex/src/formatpatterns.c
trunk/geanylatex/src/formatutils.c
trunk/geanylatex/src/formatutils.h
trunk/geanylatex/src/geanylatex.c
Modified: trunk/geanylatex/src/formatpatterns.c
===================================================================
--- trunk/geanylatex/src/formatpatterns.c 2010-03-27 01:36:25 UTC (rev 1205)
+++ trunk/geanylatex/src/formatpatterns.c 2010-03-27 01:36:53 UTC (rev 1206)
@@ -1,7 +1,7 @@
/*
* formatpatterns.c
*
- * Copyright 2009-2010 Frank Lanitz <frank@Jupiter>
+ * Copyright 2009-2010 Frank Lanitz <frank(at)frank(dot)uvena(dot)de>
*
* 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
@@ -46,3 +46,29 @@
N_("Left side oriented"),
N_("Right side oriented")
};
+
+gchar *glatex_fontsize_pattern[] = {
+ "\\tiny",
+ "\\scriptsize",
+ "\\footnotesize",
+ "\\small",
+ "\\normalsize",
+ "\\large",
+ "\\Large",
+ "\\LARGE",
+ "\\huge",
+ "\\Huge"
+};
+
+const gchar *glatex_fontsize_labels[] = {
+ N_("tiny"),
+ N_("scriptsize"),
+ N_("footnotesize"),
+ N_("small"),
+ N_("normalsize"),
+ N_("large"),
+ N_("Large"),
+ N_("LARGE"),
+ N_("huge"),
+ N_("Huge")
+};
Modified: trunk/geanylatex/src/formatutils.c
===================================================================
--- trunk/geanylatex/src/formatutils.c 2010-03-27 01:36:25 UTC (rev 1205)
+++ trunk/geanylatex/src/formatutils.c 2010-03-27 01:36:53 UTC (rev 1206)
@@ -1,59 +1,76 @@
/*
- * formatutils.c
+ * formatutils.c
*
- * Copyright 2009-2010 Frank Lanitz <frank(at)frank(dot)uvena(dot)de>
+ * Copyright 2009-2010 Frank Lanitz <frank(at)frank(dot)uvena(dot)de>
*
- * 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 of the License, or
- * (at your option) any later version.
+ * 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 of the License, 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.
+ * 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., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
+ * 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., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
*/
#include "formatutils.h"
void glatex_insert_latex_format(G_GNUC_UNUSED GtkMenuItem * menuitem,
- G_GNUC_UNUSED gpointer gdata)
+ G_GNUC_UNUSED gpointer gdata)
{
- gint format = GPOINTER_TO_INT(gdata);
- GeanyDocument *doc = NULL;
+ gint format = GPOINTER_TO_INT(gdata);
+ GeanyDocument *doc = NULL;
doc = document_get_current();
if (doc != NULL)
{
- if (sci_has_selection(doc->editor->sci))
- {
- gchar *selection;
- gchar *replacement = NULL;
+ if (sci_has_selection(doc->editor->sci))
+ {
+ gchar *selection;
+ gchar *replacement = NULL;
- selection = sci_get_selection_contents(doc->editor->sci);
+ selection = sci_get_selection_contents(doc->editor->sci);
- replacement = g_strconcat(glatex_format_pattern[format],"{",
- selection, "}", NULL);
+ replacement = g_strconcat(glatex_format_pattern[format],"{",
+ selection, "}", NULL);
- sci_replace_sel(doc->editor->sci, replacement);
- g_free(selection);
+ sci_replace_sel(doc->editor->sci, replacement);
+ g_free(selection);
g_free(replacement);
- }
- else
- {
+ }
+ else
+ {
sci_start_undo_action(doc->editor->sci);
- glatex_insert_string(glatex_format_pattern[format], TRUE);
- glatex_insert_string("{", TRUE);
- glatex_insert_string("}", FALSE);
+ glatex_insert_string(glatex_format_pattern[format], TRUE);
+ glatex_insert_string("{", TRUE);
+ glatex_insert_string("}", FALSE);
sci_end_undo_action(doc->editor->sci);
}
- }
+ }
}
+void glatex_insert_latex_fontsize(G_GNUC_UNUSED GtkMenuItem * menuitem,
+ G_GNUC_UNUSED gpointer gdata)
+{
+ gint size = GPOINTER_TO_INT(gdata);
+ GeanyDocument *doc = NULL;
+ doc = document_get_current();
+
+ if (doc != NULL)
+ {
+ sci_start_undo_action(doc->editor->sci);
+ glatex_insert_string(glatex_fontsize_pattern[size], TRUE);
+ glatex_insert_string(" ", TRUE);
+ sci_end_undo_action(doc->editor->sci);
+ }
+}
+
+
Modified: trunk/geanylatex/src/formatutils.h
===================================================================
--- trunk/geanylatex/src/formatutils.h 2010-03-27 01:36:25 UTC (rev 1205)
+++ trunk/geanylatex/src/formatutils.h 2010-03-27 01:36:53 UTC (rev 1206)
@@ -1,22 +1,22 @@
/*
- * formatutils.h
+ * formatutils.h
*
- * Copyright 2009-2010 Frank Lanitz <frank(at)frank(dot)uvena(dot)de>
+ * Copyright 2009-2010 Frank Lanitz <frank(at)frank(dot)uvena(dot)de>
*
- * 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 of the License, or
- * (at your option) any later version.
+ * 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 of the License, 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.
+ * 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., 51 Franklin Street, Fifth Floor, Boston,
- * MA 02110-1301, USA.
+ * 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., 51 Franklin Street, Fifth Floor, Boston,
+ * MA 02110-1301, USA.
*/
#ifndef LATEXFORMATUTILS_H
@@ -25,21 +25,44 @@
#include "geanylatex.h"
enum {
- LATEX_ITALIC = 0,
- LATEX_BOLD,
- LATEX_UNDERLINE,
- LATEX_SLANTED,
- LATEX_TYPEWRITER,
- LATEX_SMALLCAPS,
- LATEX_EMPHASIS,
- LATEX_CENTER,
- LATEX_LEFT,
- LATEX_RIGHT,
+ LATEX_ITALIC = 0,
+ LATEX_BOLD,
+ LATEX_UNDERLINE,
+ LATEX_SLANTED,
+ LATEX_TYPEWRITER,
+ LATEX_SMALLCAPS,
+ LATEX_EMPHASIS,
+ LATEX_CENTER,
+ LATEX_LEFT,
+ LATEX_RIGHT,
LATEX_STYLES_END
};
+/* Couting from smalles on up to biggest default font size. Keep in mind:
+ * LATEX_FONTSIZE_LARGE1 -> large
+ * LATEX_FONTSIZE_LARGE2 -> Large
+ * LATEX_FONTSIZE_LARGE3 -> LARGE
+ * LATEX_FONTSIZE_HUGE1 -> huge
+ * LATEX_FONTSIZE_HUGE2 -> Huge */
+enum {
+ LATEX_FONTSIZE_TINY = 0,
+ LATEX_FONTSIZE_SCRIPTSIZE,
+ LATEX_FONTSIZE_FOOTNOTESIZE,
+ LATEX_FONTSIZE_SMALL,
+ LATEX_FONTSIZE_NORMALSIZE,
+ LATEX_FONTSIZE_LARGE1,
+ LATEX_FONTSIZE_LARGE2,
+ LATEX_FONTSIZE_LARGE3,
+ LATEX_FONTSIZE_HUGE1,
+ LATEX_FONTSIZE_HUGE2,
+ LATEX_FONTSIZE_END
+};
+
extern gchar* glatex_format_pattern[];
extern const gchar *glatex_format_labels[];
+extern const gchar *glatex_fontsize_labels[];
+extern gchar *glatex_fontsize_pattern[];
void glatex_insert_latex_format(GtkMenuItem * menuitem, gpointer gdata);
+void glatex_insert_latex_fontsize(GtkMenuItem * menuitem, gpointer gdata);
#endif
Modified: trunk/geanylatex/src/geanylatex.c
===================================================================
--- trunk/geanylatex/src/geanylatex.c 2010-03-27 01:36:25 UTC (rev 1205)
+++ trunk/geanylatex/src/geanylatex.c 2010-03-27 01:36:53 UTC (rev 1206)
@@ -49,6 +49,8 @@
static GtkWidget *menu_latex_bibtex_submenu = NULL;
static GtkWidget *menu_latex_format_insert = NULL;
static GtkWidget *menu_latex_format_insert_submenu = NULL;
+static GtkWidget *menu_latex_fontsize = NULL;
+static GtkWidget *menu_latex_fontsize_submenu = NULL;
static GtkWidget *menu_latex_insert_environment = NULL;
static GtkWidget *menu_latex_insert_usepackage = NULL;
static GtkWidget *menu_latex_replacement = NULL;
@@ -1852,6 +1854,23 @@
G_CALLBACK(glatex_insert_latex_format), GINT_TO_POINTER(i));
}
+ /* Add font size menu */
+ menu_latex_fontsize = gtk_menu_item_new_with_mnemonic(_("_Font size"));
+ gtk_container_add(GTK_CONTAINER(menu_latex_menu), menu_latex_fontsize);
+
+ menu_latex_fontsize_submenu = gtk_menu_new();
+ gtk_menu_item_set_submenu(GTK_MENU_ITEM(menu_latex_fontsize),
+ menu_latex_fontsize_submenu);
+
+ for (i = 0; i < LATEX_FONTSIZE_END; i++)
+ {
+ tmp = NULL;
+ tmp = gtk_menu_item_new_with_mnemonic(_(glatex_fontsize_labels[i]));
+ gtk_container_add(GTK_CONTAINER(menu_latex_fontsize_submenu), tmp);
+ g_signal_connect(tmp, "activate",
+ G_CALLBACK(glatex_insert_latex_fontsize), GINT_TO_POINTER(i));
+ }
+
/* Add menuitem for LaTeX replacement functions*/
menu_latex_replacement = gtk_menu_item_new_with_mnemonic(
_("_Special Character Replacement"));
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
Revision: 1205
http://geany-plugins.svn.sourceforge.net/geany-plugins/?rev=1205&view=rev
Author: frlan
Date: 2010-03-27 01:36:25 +0000 (Sat, 27 Mar 2010)
Log Message:
-----------
GeanyLaTeX: Minimal update of documentation for insert \usepackage{} feature
Modified Paths:
--------------
trunk/geanylatex/doc/geanylatex.tex
Modified: trunk/geanylatex/doc/geanylatex.tex
===================================================================
--- trunk/geanylatex/doc/geanylatex.tex 2010-03-27 01:36:00 UTC (rev 1204)
+++ trunk/geanylatex/doc/geanylatex.tex 2010-03-27 01:36:25 UTC (rev 1205)
@@ -486,7 +486,8 @@
\item right-aligned
\end{itemize}
-\subsection{Autocompletion of \textbackslash{}begin and \textbackslash{}begingroup}
+\subsection{Autocompletion of \textbackslash{}begin and
+ \textbackslash{}begingroup}
Since version 0.5 GeanyLaTeX{} is supporting autocompletion for
closing \textbackslash{}end and \textbackslash{}endgroup for begin
@@ -511,6 +512,17 @@
on \TeX{}-like file types.
+\subsection{Inserting \textbackslash{}usepackage\{\}-entry to header}
+
+From time you need to insert a new package into header of a document,
+but don't want to change to top of document and scroll back to where you were.
+
+Since version 0.5 Geany\LaTeX{} is offering an easy to use dialog
+which is taking over the package name and possible package options to
+insert them into header of document. Right now, its placed direct in
+top of the \texttt{\textbackslash{}begin\{document\}} statement if
+there is any.
+
\section{Configuration}
GeanyLaTeX{} can be configured in two major ways:
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
Revision: 1204
http://geany-plugins.svn.sourceforge.net/geany-plugins/?rev=1204&view=rev
Author: frlan
Date: 2010-03-27 01:36:00 +0000 (Sat, 27 Mar 2010)
Log Message:
-----------
GeanyLaTeX: Add another feature request to feeled endless TODO-list
Modified Paths:
--------------
trunk/geanylatex/TODO
Modified: trunk/geanylatex/TODO
===================================================================
--- trunk/geanylatex/TODO 2010-03-26 21:04:44 UTC (rev 1203)
+++ trunk/geanylatex/TODO 2010-03-27 01:36:00 UTC (rev 1204)
@@ -28,3 +28,4 @@
* Make special characters extensible through files
* Improve behaviour of levelup and leveldown of structures
* Autoinserting {} when typing \command+return
+* Adding a font size chooser to toolbar and menue
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.