SF.net SVN: geany: [955] trunk/src/utils.c

ntrel at users.sourceforge.net ntrel at xxxxx
Wed Nov 1 16:39:56 UTC 2006


Revision: 955
          http://svn.sourceforge.net/geany/?rev=955&view=rev
Author:   ntrel
Date:     2006-11-01 08:39:52 -0800 (Wed, 01 Nov 2006)

Log Message:
-----------
Prevent end of line char showing for current function.

Modified Paths:
--------------
    trunk/src/utils.c

Modified: trunk/src/utils.c
===================================================================
--- trunk/src/utils.c	2006-11-01 16:18:26 UTC (rev 954)
+++ trunk/src/utils.c	2006-11-01 16:39:52 UTC (rev 955)
@@ -529,16 +529,13 @@
 	start = end;
 	c = 0;
 	// Use tmp to find SCE_C_IDENTIFIER or SCE_C_GLOBALCLASS chars
-	while (((tmp = sci_get_style_at(sci, start)) == SCE_C_IDENTIFIER
+	while (start >= 0 && ((tmp = sci_get_style_at(sci, start)) == SCE_C_IDENTIFIER
 		 ||  tmp == SCE_C_GLOBALCLASS
 		 || (c = sci_get_char_at(sci, start)) == '~'
 		 ||  c == ':'))
 		start--;
-	if (start < 0) start = 0;
+	if (start != 0 && start < end) start++;	// correct for last non-matching char
 
-	if (sci_get_char_at(sci, start) == ' ') start++; // skip possible whitespace
-	if (sci_get_char_at(sci, start) == '*') start++; // skip possible * char
-
 	if (start == end) return NULL;
 	cur_tag = g_malloc(end - start + 2);
 	sci_get_text_range(sci, start, end + 1, cur_tag);


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