At 11.59 +0200 2006-09-14, Johan Solve wrote:
>As an exercise I tried to modify John Gruber's Apache config CLM to recognize 
>virtual hosts as functions and code folding points.


James Harvard indirectly pointed out my problem:
>(By the way, it wasn't clear to me from reading the relevant part of the 
>manual that <key>Function Pattern</key> needed to go within the 'Language 
>Features' <dict> element, as opposed to the top level <dict>. That could just 
>be my unfamiliarity with plist files but if it was not clear to me then maybe 
>it would be equally unclear to others.)

Moving the function pattern to inside of Language Features fixed it.
So I have code folding working now for the Apache config CLM, but just as James 
I don't get folding points for nested "functions".

        <key>Language Features</key>
        <dict>
                <key>Function Pattern</key>
                
<string>(?si)&lt;(?P&lt;function_name&gt;\w+).*?&gt;(?P&lt;function&gt;.*?)&lt;/(?P=function_name)&gt;</string>

This pattern works for any file that has something that looks like html or xml, 
but only offers fold points at the root level of the file - no nesting.


--
     Johan Sölve    [FSA Member, Lasso Partner]
     Web Application/Lasso/FileMaker Developer
     MONTANIA SOFTWARE & SOLUTIONS
http://www.montania.se   mailto:[EMAIL PROTECTED]
 (spam-safe email address, replace '-' with 'a')

--
------------------------------------------------------------------
Have a feature request? Not sure the software's working correctly?
If so, please send mail to <[EMAIL PROTECTED]>, not to the list.
List FAQ: <http://www.barebones.com/support/lists/bbedit_talk.shtml>
List archives: <http://www.listsearch.com/BBEditTalk.lasso>
To unsubscribe, send mail to:  <[EMAIL PROTECTED]>

Reply via email to