SF.net SVN: geany: [1430] trunk
eht16 at users.sourceforge.net
eht16 at xxxxx
Fri Mar 30 10:38:13 UTC 2007
Revision: 1430
http://svn.sourceforge.net/geany/?rev=1430&view=rev
Author: eht16
Date: 2007-03-30 03:38:13 -0700 (Fri, 30 Mar 2007)
Log Message:
-----------
Fixed warning about shadowing a local variable.
Add keybinding for switching to the search bar (as suggested by Nikolas Arend).
Modified Paths:
--------------
trunk/ChangeLog
trunk/doc/geany.docbook
trunk/src/keybindings.c
trunk/src/keybindings.h
trunk/src/sci_cb.c
Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog 2007-03-29 14:39:04 UTC (rev 1429)
+++ trunk/ChangeLog 2007-03-30 10:38:13 UTC (rev 1430)
@@ -1,3 +1,11 @@
+2007-03-30 Enrico Tröger <enrico.troeger at uvena.de>
+
+ * src/sci_cb.c: Fixed warning about shadowing a local variable.
+ * doc_geany.docbook, src/keybindings.c, src/keybindings.h:
+ Add keybinding for switching to the search bar
+ (as suggested by Nikolas Arend).
+
+
2007-03-29 Nick Treleaven <nick.treleaven at btinternet.com>
* src/sci_cb.c:
Modified: trunk/doc/geany.docbook
===================================================================
--- trunk/doc/geany.docbook 2007-03-29 14:39:04 UTC (rev 1429)
+++ trunk/doc/geany.docbook 2007-03-30 10:38:13 UTC (rev 1430)
@@ -1421,6 +1421,10 @@
<entry>Switches to VTE widget.</entry>
</row>
<row>
+ <entry>Switch to Search Bar</entry>
+ <entry>Switches to the search bar in the toolbar (if visible).</entry>
+ </row>
+ <row>
<entry>Switch to left document</entry>
<entry>Switches to the previous open document.</entry>
</row>
Modified: trunk/src/keybindings.c
===================================================================
--- trunk/src/keybindings.c 2007-03-29 14:39:04 UTC (rev 1429)
+++ trunk/src/keybindings.c 2007-03-30 10:38:13 UTC (rev 1430)
@@ -90,6 +90,7 @@
static void cb_func_switch_editor(guint key_id);
static void cb_func_switch_scribble(guint key_id);
static void cb_func_switch_vte(guint key_id);
+static void cb_func_switch_search_bar(guint key_id);
static void cb_func_switch_tableft(guint key_id);
static void cb_func_switch_tabright(guint key_id);
static void cb_func_switch_tablastused(guint key_id);
@@ -207,6 +208,8 @@
GDK_F6, 0, "switch_scribble", _("Switch to Scribble"));
keys[GEANY_KEYS_SWITCH_VTE] = fill(cb_func_switch_vte,
GDK_F4, 0, "switch_vte", _("Switch to VTE"));
+ keys[GEANY_KEYS_SWITCH_SEARCH_BAR] = fill(cb_func_switch_search_bar,
+ GDK_F7, 0, "switch_search_bar", _("Switch to Search Bar"));
keys[GEANY_KEYS_SWITCH_TABLEFT] = fill(cb_func_switch_tableft,
GDK_Page_Up, GDK_CONTROL_MASK, "switch_tableft", _("Switch to left document"));
keys[GEANY_KEYS_SWITCH_TABRIGHT] = fill(cb_func_switch_tabright,
@@ -918,6 +921,12 @@
gtk_widget_grab_focus(lookup_widget(app->window, "textview_scribble"));
}
+static void cb_func_switch_search_bar(G_GNUC_UNUSED guint key_id)
+{
+ if (app->toolbar_visible && app->pref_toolbar_show_search)
+ gtk_widget_grab_focus(lookup_widget(app->window, "entry1"));
+}
+
static void cb_func_switch_vte(G_GNUC_UNUSED guint key_id)
{
#ifdef HAVE_VTE
Modified: trunk/src/keybindings.h
===================================================================
--- trunk/src/keybindings.h 2007-03-29 14:39:04 UTC (rev 1429)
+++ trunk/src/keybindings.h 2007-03-30 10:38:13 UTC (rev 1430)
@@ -100,6 +100,7 @@
GEANY_KEYS_SWITCH_EDITOR,
GEANY_KEYS_SWITCH_SCRIBBLE,
GEANY_KEYS_SWITCH_VTE,
+ GEANY_KEYS_SWITCH_SEARCH_BAR,
GEANY_KEYS_SWITCH_TABLEFT,
GEANY_KEYS_SWITCH_TABRIGHT,
GEANY_KEYS_SWITCH_TABLASTUSED,
Modified: trunk/src/sci_cb.c
===================================================================
--- trunk/src/sci_cb.c 2007-03-29 14:39:04 UTC (rev 1429)
+++ trunk/src/sci_cb.c 2007-03-30 10:38:13 UTC (rev 1430)
@@ -396,9 +396,9 @@
// in place indentation of one tab or equivalent spaces
-static void do_indent(gchar *buf, gsize len, guint *index)
+static void do_indent(gchar *buf, gsize len, guint *idx)
{
- guint j = *index;
+ guint j = *idx;
if (app->pref_editor_use_tabs)
{
@@ -411,7 +411,7 @@
for (k = 0; k < (guint) app->pref_editor_tab_width && k < len - 1; k++)
buf[j++] = ' ';
}
- *index = j;
+ *idx = j;
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Commits
mailing list