Kaydet (Commit) 887f75bb authored tarafından Enrico Tröger's avatar Enrico Tröger

improved symbol list for filetype Perl

git-svn-id: https://geany.svn.sourceforge.net/svnroot/geany/trunk@321 ea778897-0a13-0410-b9d1-a72fbfd435f5
üst 5c4ea3ee
......@@ -15,7 +15,7 @@
*
* 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., 675 Mass Ave, Cambridge, MA 02139, USA.
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
*
* $Id$
*/
......@@ -99,6 +99,27 @@ void treeviews_init_tag_list(gint idx)
gtk_tree_store_set(doc_list[idx].tag_store, &(tv.tag_other), 0, _("Other"), -1);
break;
}
case GEANY_FILETYPES_PERL:
{
gtk_tree_store_append(doc_list[idx].tag_store, &(tv.tag_function), NULL);
gtk_tree_store_set(doc_list[idx].tag_store, &(tv.tag_function), 0, _("Function"), -1);
gtk_tree_store_append(doc_list[idx].tag_store, &(tv.tag_class), NULL);
gtk_tree_store_set(doc_list[idx].tag_store, &(tv.tag_class), 0, _("Package"), -1);
gtk_tree_store_append(doc_list[idx].tag_store, &(tv.tag_member), NULL);
gtk_tree_store_set(doc_list[idx].tag_store, &(tv.tag_member), 0, _("My"), -1);
gtk_tree_store_append(doc_list[idx].tag_store, &(tv.tag_macro), NULL);
gtk_tree_store_set(doc_list[idx].tag_store, &(tv.tag_macro), 0, _("Local"), -1);
gtk_tree_store_append(doc_list[idx].tag_store, &(tv.tag_variable), NULL);
gtk_tree_store_set(doc_list[idx].tag_store, &(tv.tag_variable), 0, _("Our"), -1);
/* gtk_tree_store_append(doc_list[idx].tag_store, &(tv.tag_struct), NULL);
gtk_tree_store_set(doc_list[idx].tag_store, &(tv.tag_struct), 0, _("Label"), -1);
gtk_tree_store_append(doc_list[idx].tag_store, &(tv.tag_namespace), NULL);
gtk_tree_store_set(doc_list[idx].tag_store, &(tv.tag_namespace), 0, _("Begin"), -1);
gtk_tree_store_append(doc_list[idx].tag_store, &(tv.tag_other), NULL);
gtk_tree_store_set(doc_list[idx].tag_store, &(tv.tag_other), 0, _("Other"), -1);
*/
break;
}
default:
{
gtk_tree_store_append(doc_list[idx].tag_store, &(tv.tag_function), NULL);
......
......@@ -104,9 +104,11 @@ static void findPerlTags (void)
vStringClear (name);
}
if (strncmp((const char*) cp, "our", (size_t) 3) == 0)
else if (strncmp((const char*) cp, "our", (size_t) 3) == 0)
{
cp += 3;
while (isspace (*cp)) cp++;
// skip something like my ($bla)
if (*(const char*) cp != '$' && ! isalpha(*(const char*) cp)) continue;
......@@ -125,9 +127,11 @@ static void findPerlTags (void)
makeSimpleTag (name, PerlKinds, K_OUR);
vStringClear (name);
}
if (strncmp((const char*) cp, "local", (size_t) 5) == 0)
else if (strncmp((const char*) cp, "local", (size_t) 5) == 0)
{
cp += 5;
while (isspace (*cp)) cp++;
// skip something like my($bla)
if (*(const char*) cp != '$' && ! isalpha(*(const char*) cp)) continue;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment