nl_tokens: Check if current caret position is inside style attribute of HTML element
pl_tokens: function ( editor ) { var content = String ( editor . getContent ( ) ) ; var caretPos = editor . getCaretPos ( ) ; var tree = require ( 'xmlEditTree' ) . parseFromPosition ( content , caretPos , true ) ; if ( tree ) { var attr = tree . itemFromPosition ( caretPos , <mask> ) ; return attr && attr . name ( ) . toLowerCase ( ) == 'style' && attr . valueRange ( true ) . cmp ( caretPos , 'lte' , 'gte' ) ; } return false ; }