TextMate begin/endCapture


#1

I have a TextMate grammar in Atom that uses begin/end captures. But I don’t understand why Atom doesn’t apply style names from the begin/endCaptures but only style name from ‘name’ (entity.textinsignificantglobal.k - as per below example)

  {
    'begin': '(/k:)'
    'begincaptures':
      '1':
        'name': 'keyword.plaintextmark' # I want this style name to be applied onto the text
     'end': '(.*?)(:ti/)'
     'endcaptures':
       '1':
         'name': 'keyword.textinsignificant.k' # I want this style name to be applied onto the text
       '2':
         'name': 'keyword.plaintextmark' # I want this style name to be applied onto the text
      'name': 'entity.textinsignificantglobal.k' # But Atom applies only this style name on the entire matched text
  }

#2

Check cases


#3

Oops. Thank you!