On 11 Sep 2006, at 12:26, Patrick Woolsey wrote:
Per Appendix D of the manual :-),

====
Codeless language modules for use with BBEdit 8.5 and later may specify the "Function Pattern" key as a PCRE-compatible regular expression instead of a
string.

[...]

Thanks - but I was asking if it's possible to use PCREs
for things _other_ than functions, for instance, to
specify comment opening and closing, and/or block
opening and closing, etc. Somebody here said that it
was, but that this isn't documented yet!

PCREs to specify comment opening and closing would
be a great help for writing CLMs for languages which
embed inside other languages (of which there are
very many): because one can at least turn off the
language features for the embedded parts by regarding
these embedded chunks as being comment. So it's
not quite as odd a request as it probably sounds...

The "Function Pattern" key, I am indeed using, though it
seems to have an implicit restriction possibly caused
by having a slightly C-oriented definition of what a
"function" might ever be: while the PCRE matching does
work, it seems perhaps that a function must contain an
open and close block in order for BBEdit to continue
scanning the rest of the file for fresh functions. Without
this, I _think_, "Function Pattern" finds only the first
function and ignores all subsequent ones, because
it considers the whole rest of the file to be part of the
same function - even if the PCRE clearly delineates the
function part as well as the function name.

Well - that's what I think is happening, anyway...
I am fairly sure that Appendix D does not describe the
behaviour at present, I'm afraid.

--
Graham Nelson



--
------------------------------------------------------------------
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