[Github-comments] [geany/geany] Added support for scoped function calltips (#1177)

elextr notifications at xxxxx
Sat Aug 13 23:19:20 UTC 2016


> @@ -2045,8 +2114,13 @@ gboolean editor_show_calltip(GeanyEditor *editor, gint pos)
>  	editor_find_current_word(editor, pos - 1, word, sizeof word, NULL);
>  	if (word[0] == '\0')
>  		return FALSE;
> -
> -	str = find_calltip(word, editor->document->file_type);
> +	
> +	scope[0] = '\0';
> +	//const gchar *sname;
> +	//symbols_get_current_scope(editor->document, &sname);
> +	//printf("Current scope: %s\n", sname);
> +	read_scope_prefix(editor, pos - 1, scope, sizeof scope, NULL);
> +	str = find_calltip(word, scope, editor->document->file_type);

`symbols_get_current_scope()` returns a somewhat limited view of the lexical scope IIUC, so its not what you want until you need to resolve the highest level name in your prefix.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/geany/geany/pull/1177/files/a3a392a6a34312247351a7f7da8b599e17adb327#r74693414
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.geany.org/pipermail/github-comments/attachments/20160813/c72f7a82/attachment.html>


More information about the Github-comments mailing list