ww-tedit-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ww-tedit-dev] scan function names for .c files


From: petar marinov
Subject: [ww-tedit-dev] scan function names for .c files
Date: Sun, 04 Jan 2004 19:39:01 -0800
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.4b) Gecko/20030507

Today I completed the function that scans for function names in .c files. it worked out nicely combined with some modifications in the syntax highlighting code.

from the syntax highlighting function:
-- I get all the comment areas marked;
-- I have all all the operators marked, this makes '{}' and '()' easier to pick; -- I have all lines that contain no {} characters a marked as such and not scanned;
-- I have the current {} nested level;

Matching parenthesis usually involves scanning a line or a few lines and is thus not very expensive.

Matching curly braces involves more of a scanning, for this the syntax highlighting keeps tab of the current nested level at the end of every line. This allowes for very fast calculation of the current nested level anywhere in a single line based on the value at the end of the previous line.

I will now work to produce output for the bookmarks manager and add new bookmarks filter to show the functions in a file.

-petar





reply via email to

[Prev in Thread] Current Thread [Next in Thread]