[TxMt] Highlight current sentence
Charilaos Skiadas
cskiadas at uchicago.edu
Sat Feb 25 20:48:49 UTC 2006
On Feb 25, 2006, at 2:38 PM, Nicholas Cole wrote:
> Pardon my lack of regex and TM skills - would it be possible to set up
> textmate so that I can highlight the current sentence?
>
Not if by highlight you mean to have the syntax recognize it and give
it different color. Allan plans to have some support for such dynamic
scopes for some time in the distant future, but for now the syntax
grammars are static.
You could however write a macro that would *select* the current
sentence, if that is what you want. Having it do a backwards search
with regexp enabled and find: (?<=[\.\n])[^\.\n]*\. would probably do
it. You can tweak it appropriately depending on what kind of
sentences you want to catch.
> Best wishes,
>
> N
Haris
More information about the textmate
mailing list