SF.net SVN: geany:[2874] trunk

ntrel at users.sourceforge.net ntrel at xxxxx
Mon Aug 11 16:53:07 UTC 2008


Revision: 2874
          http://geany.svn.sourceforge.net/geany/?rev=2874&view=rev
Author:   ntrel
Date:     2008-08-11 16:53:03 +0000 (Mon, 11 Aug 2008)

Log Message:
-----------
Rename GeanyIndentPrefs::tab_width to hard_tab_width, and update
keyfile key name.

Modified Paths:
--------------
    trunk/ChangeLog
    trunk/src/editor.c
    trunk/src/editor.h
    trunk/src/keyfile.c
    trunk/src/plugindata.h
    trunk/src/prefs.c

Modified: trunk/ChangeLog
===================================================================
--- trunk/ChangeLog	2008-08-11 16:44:19 UTC (rev 2873)
+++ trunk/ChangeLog	2008-08-11 16:53:03 UTC (rev 2874)
@@ -12,6 +12,10 @@
    is_code_style().
  * plugins/export.c:
    Fix using correct hard tab width for HTML export, not just LaTeX.
+ * src/prefs.c, src/plugindata.h, src/keyfile.c, src/editor.c,
+   src/editor.h:
+   Rename GeanyIndentPrefs::tab_width to hard_tab_width, and update
+   keyfile key name.
 
 
 2008-08-08  Nick Treleaven  <nick(dot)treleaven(at)btinternet(dot)com>

Modified: trunk/src/editor.c
===================================================================
--- trunk/src/editor.c	2008-08-11 16:44:19 UTC (rev 2873)
+++ trunk/src/editor.c	2008-08-11 16:53:03 UTC (rev 2874)
@@ -712,7 +712,7 @@
 static gint get_tab_width(const GeanyIndentPrefs *indent_prefs)
 {
 	if (indent_prefs->type == GEANY_INDENT_TYPE_BOTH)
-		return indent_prefs->tab_width;
+		return indent_prefs->hard_tab_width;
 
 	return indent_prefs->width;	/* tab width = indent width */
 }
@@ -721,7 +721,7 @@
 /* Returns a string containing width chars of whitespace, filled with simple space
  * characters or with the right number of tab characters, according to the indent prefs.
  * (Result is filled with tabs *and* spaces if width isn't a multiple of
- * editor_prefs.tab_width). */
+ * the tab width). */
 static gchar *
 get_whitespace(const GeanyIndentPrefs *iprefs, gint width)
 {
@@ -3626,7 +3626,7 @@
 	sci_set_use_tabs(sci, use_tabs);
 
 	if (type == GEANY_INDENT_TYPE_BOTH)
-		sci_set_tab_width(sci, iprefs->tab_width);
+		sci_set_tab_width(sci, iprefs->hard_tab_width);
 	else
 		sci_set_tab_width(sci, iprefs->width);
 	SSM(sci, SCI_SETINDENT, iprefs->width, 0);

Modified: trunk/src/editor.h
===================================================================
--- trunk/src/editor.h	2008-08-11 16:44:19 UTC (rev 2873)
+++ trunk/src/editor.h	2008-08-11 16:53:03 UTC (rev 2874)
@@ -72,7 +72,7 @@
 	GeanyIndentType	type;				/**< Whether to use tabs, spaces or both to indent. */
 	/** Width of a tab, but only when using GEANY_INDENT_TYPE_BOTH.
 	 * To get the display tab width, use sci_get_tab_width(). */
-	gint			tab_width;
+	gint			hard_tab_width;
 	GeanyAutoIndent	auto_indent_mode;
 	gboolean		detect_type;
 }

Modified: trunk/src/keyfile.c
===================================================================
--- trunk/src/keyfile.c	2008-08-11 16:44:19 UTC (rev 2873)
+++ trunk/src/keyfile.c	2008-08-11 16:53:03 UTC (rev 2874)
@@ -146,7 +146,7 @@
 	SettingEntry items[] =
 	{
 		{&editor_prefs.indentation->width, PACKAGE, "pref_editor_tab_width", (gpointer)4},
-		{&editor_prefs.indentation->tab_width, PACKAGE, "indent_tab_width", (gpointer)8},
+		{&editor_prefs.indentation->hard_tab_width, PACKAGE, "indent_hard_tab_width", (gpointer)8},
 		{&editor_prefs.indentation->auto_indent_mode, PACKAGE, "indent_mode",
 			(gpointer)GEANY_AUTOINDENT_CURRENTCHARS},
 		{&editor_prefs.indentation->type, PACKAGE, "indent_type", (gpointer)GEANY_INDENT_TYPE_TABS},

Modified: trunk/src/plugindata.h
===================================================================
--- trunk/src/plugindata.h	2008-08-11 16:44:19 UTC (rev 2873)
+++ trunk/src/plugindata.h	2008-08-11 16:53:03 UTC (rev 2874)
@@ -36,7 +36,7 @@
 
 /* The API version should be incremented whenever any plugin data types below are
  * modified or appended to. */
-static const gint api_version = 86;
+static const gint api_version = 87;
 
 /* The ABI version should be incremented whenever existing fields in the plugin
  * data types below have to be changed or reordered. It should stay the same if fields

Modified: trunk/src/prefs.c
===================================================================
--- trunk/src/prefs.c	2008-08-11 16:44:19 UTC (rev 2873)
+++ trunk/src/prefs.c	2008-08-11 16:53:03 UTC (rev 2874)
@@ -144,7 +144,7 @@
 	PrefEntry items[] =
 	{
 		{"spin_indent_width", &editor_prefs.indentation->width},
-		{"spin_tab_width", &editor_prefs.indentation->tab_width},
+		{"spin_tab_width", &editor_prefs.indentation->hard_tab_width},
 	};
 
 	for (i = 0; i < G_N_ELEMENTS(items); i++)


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