[TxMt] [ANN] Select Balanced HTML Tag!!!1!

Thomas Aylott - subtleGradient textmate at subtleGradient.com
Wed Nov 21 02:21:20 UTC 2007


Bah. Excuses excuses... ;)

Thomas Aylott [SubtleGradient] from iPhone

On Nov 20, 2007, at 7:46 PM, Hans-Jörg Bibiko <bibiko at eva.mpg.de>  
wrote:

> On 20.11.2007, at 23:45, Thomas Aylott - subtleGradient wrote:
>> On Nov 20, 2007, at 1:06 PM, Hans-Jörg Bibiko wrote:
>>> I wrote a perl script with a nested tag killer as tmCommand. Fine.  
>>> It works and I believe I caught 99% of all exceptions within HTML/ 
>>> XML ;)
>>> And it is fast even for large document with 10000 lines (ca. 100ms).
>>>
>>> If my document is larger than ca. 540kB the tmCommand doesn't  
>>> work. I don't know why, but I guess there is a maximum size for  
>>> passing parameter, or what ever.
>>>
>> Give me the TMTOOLS version now and we can figure out a better  
>> version later.
> Well, I thought about to avoid TMTOOLS but I couldn't find a  
> solution. I also tried to manipulate the *.tmmacro file directly;  
> call via osascript reloadBundle. It works but it takes times and  
> it's a stony way.
>
> I will write a TMTOOLS command. Actually I did it, but I figured out  
> that if the document is too large Perl crashes with
>
> libperl.dylib    0x977aebd4 S_regmatch + 13756
>
> ASAIK is this a memory exception. Well, TM is stable, but maybe I  
> will try Ruby.
> I also tried to write such a parser in pure Obj-C. It works  
> brilliant but it's slow, thus I guess one has to write it in low- 
> level C.
> It would be VERY nice if one has the chance to use TM's Oniguruma  
> regexp engine within a plug-in, but up to now I didn't get rid of  
> it. Maybe Allan is able to give a hint :) This would simplify  
> thousands of tiny thing :D
>
>
> With Perl I have to fix the coding issue, i.e. byte offset versus  
> character offset; and finally there's a tiny problem with 'Soft  
> Tabs' which I have to solve.
>
> In other words I need a bit time yet ;)
>
> Regards,
> --Hans
>
>
>
> ______________________________________________________________________
> For new threads USE THIS: textmate at lists.macromates.com
> (threading gets destroyed and the universe will collapse if you don't)
> http://lists.macromates.com/mailman/listinfo/textmate



More information about the textmate mailing list