object SyntAnal13: TLibSyntAnalyzer
  Formats = <
    item
      DisplayName = 'Heading'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clMaroon
      Font.Height = -19
      Font.Name = 'Consolas'
      Font.Style = [fsBold]
      FormatType = ftCustomFont
    end
    item
      DisplayName = 'Comment'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clGray
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
    end
    item
      DisplayName = 'Quote BG'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clBlack
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
      BgColor = 12645824
      FormatType = ftColor
    end
    item
      DisplayName = 'Text'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clBlack
      Font.Height = -13
      Font.Name = 'Consolas'
      Font.Style = []
    end
    item
      DisplayName = 'Codeblock'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clBlack
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
      BgColor = 15659207
    end
    item
      DisplayName = 'Block'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clBlack
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
      BgColor = 15779980
    end
    item
      DisplayName = 'Link'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = 3289830
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
    end
    item
      DisplayName = 'Image'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = 15086130
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
    end
    item
      DisplayName = 'Reference'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clGreen
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
    end
    item
      DisplayName = 'Footnote'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = 3277030
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
    end
    item
      DisplayName = 'HTML Code'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clTeal
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
    end
    item
      DisplayName = 'Bold'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = [fsBold]
    end
    item
      DisplayName = 'Italic'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = [fsItalic]
    end
    item
      DisplayName = 'Bold-Italic'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = [fsBold, fsItalic]
    end
    item
      DisplayName = 'Definition'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
      BgColor = 14737357
      BorderColorLeft = 16384
    end
    item
      DisplayName = 'List'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
      BgColor = 16763594
    end
    item
      DisplayName = 'Crossed out'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = [fsStrikeOut]
    end
    item
      DisplayName = 'Mark-added'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clBlack
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
      BgColor = 8454016
    end
    item
      DisplayName = 'Mark-deleted'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clBlack
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
      BgColor = 8421631
    end
    item
      DisplayName = 'Mark-edited'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clBlack
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
      BgColor = clYellow
    end
    item
      DisplayName = 'Symbols'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clMaroon
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
    end
    item
      DisplayName = 'Math BG'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clNavy
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
      BgColor = clYellow
      FormatType = ftColor
    end
    item
      DisplayName = 'Table BG'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = []
      BgColor = clMoneyGreen
      FormatType = ftBackGround
    end
    item
      DisplayName = '``` edge'
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clRed
      Font.Height = -13
      Font.Name = 'Courier New'
      Font.Style = [fsBold]
    end>
  TokenRules = <
    item
      DisplayName = '`begin'
      StyleName = '``` edge'
      StatesAdd = 1
      StatesAbsent = 1
      TokenType = 16
      Expression = '^[\x20\x09]*`{3,}\x20*.*$'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = '`end'
      StyleName = '``` edge'
      StatesRemove = 1
      StatesPresent = 1
      TokenType = 17
      Expression = '^[\x20\x09]*`{3,}\x20*$'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = '~begin'
      StyleName = '``` edge'
      StatesAdd = 2
      TokenType = 18
      Expression = '^[\x20\x09]*~{3,}\x20*\w+.*$'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = '~end'
      StyleName = '``` edge'
      StatesRemove = 2
      TokenType = 19
      Expression = '^[\x20\x09]*~{3,}\x20*$'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Bold-Italic'
      StyleName = 'Bold-Italic'
      StatesAbsent = 3
      TokenType = 1
      Expression = '(\*\*\*|___) [^\n\r\x20\*_\\](`.+?`|.)*? \1'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Bold'
      StyleName = 'Bold'
      StatesAbsent = 3
      TokenType = 1
      Expression = '(\*\*|__) [^\n\r\x20\*_\\](`.+?`|.)*? \1'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Italic'
      StyleName = 'Italic'
      StatesAbsent = 3
      TokenType = 1
      Expression = '\* [^\n\r\x20\*_\\](`.+?`|.)*? \*'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Heading'
      StyleName = 'Heading'
      StatesAbsent = 3
      Expression = '^\#+ \x20 .+ |'#13#10'.+\z(-+|=+)$'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Comment'
      StyleName = 'Comment'
      StatesAbsent = 3
      TokenType = 2
      Expression = '(?s)\<!--.*?--\>  |'#13#10'(?s)/\*.*?\*/'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Quote'
      StyleName = 'Quote BG'
      StatesAbsent = 3
      TokenType = 3
      Expression = '^[\x20\x09]*(>[\x20=])+'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'HTML pre'
      StyleName = 'Codeblock'
      StatesAbsent = 3
      TokenType = 4
      Expression = '(?s) <pre\b .+? </pre>'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'HTML entity'
      StyleName = 'Symbols'
      StatesAbsent = 3
      TokenType = 9
      Expression = '\&\#?\w+;'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'HTML tag'
      StyleName = 'HTML Code'
      StatesAbsent = 3
      TokenType = 9
      Expression = '(?s)<[/!]?[\[\w].*?>'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Link github'
      StyleName = 'Link'
      StatesAbsent = 3
      TokenType = 11
      Expression = '\[! \[ [^\]]+ \]\( [^\)]+ \) \] \( [^\)]+ \)'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Link usual'
      StyleName = 'Image'
      StatesAbsent = 3
      TokenType = 11
      Expression = '(?s)(?<=\])\( (\([^\)]*\)|.)*?\) (\{.*?\})?'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Break line'
      StyleName = 'Comment'
      StatesAbsent = 3
      TokenType = 2
      Expression = '^(([\-\*_])\x20+)+\2?$'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'List'
      StyleName = 'List'
      StatesAbsent = 3
      TokenType = 13
      Expression = 
        '^[\x20\x09]*( \d{1,3}\. '#13#10'| [\-\+\*]'#13#10'| \(?\w?[\.\)]'#13#10') \x20(\[[' +
        '\x20xX]\]\x20)? #GitHub: [ ] [x] [X]'#13#10'| ^\(@[^\)]*\)#pandoc list'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Codeblock indented'
      StyleName = 'Codeblock'
      StatesAbsent = 3
      TokenType = 4
      Expression = '^(\x20{4,}|\x09{1,}) [^`<>\n\r].*$'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Footnote'
      StyleName = 'Footnote'
      StatesAbsent = 3
      TokenType = 7
      Expression = '^\[\^[^\]\^]+\]:.*?($|\z) |'#13#10'\[\^[^\]]+\]'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Reference'
      StyleName = 'Reference'
      StatesAbsent = 3
      TokenType = 6
      Expression = 
        '^\x20{0,3}\[[^\]\^]+\]:.*?($|\z) |'#13#10'(?<=\]\x20?)\[.*?\] (\{.*?\}' +
        ')? |'#13#10'\(@.+?\) #pandoc list reference'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Definition'
      StyleName = 'Definition'
      StatesAbsent = 3
      TokenType = 10
      Expression = '^[\x20\x09]*:\ .* '#13#10'# Pandoc Style (:\ \ \ )'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Link desc text'
      StyleName = 'Link'
      StatesAbsent = 3
      TokenType = 11
      Expression = '!?\[ (\[[^\]]*\]|`.+?`|.)*? \]'#13#10'#allow nested [text] and `text`'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Codeblock raw'
      StyleName = 'Block'
      StatesAbsent = 3
      TokenType = 5
      Expression = 
        '(?s) (`+) .+? (\1|\z\z)'#13#10'#to-fix: SublimeText syntax test has ma' +
        'ny errors for this'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Crossed text'
      StyleName = 'Crossed out'
      StatesAbsent = 3
      TokenType = 1
      Expression = '(?s)~+[^\x20\x09\n\r~\\][^\n\r~\\]*? ~+'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Footnote Inline'
      StyleName = 'Footnote'
      StatesAbsent = 3
      TokenType = 7
      Expression = '\^\[.+?\] #Pandoc Inline-Style'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Escaped char'
      StyleName = 'Symbols'
      StatesAbsent = 3
      TokenType = 15
      Expression = '\\.'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Table begin'
      StyleName = 'Symbols'
      TokenType = 20
      Expression = '^\|'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Table end'
      StyleName = 'Symbols'
      TokenType = 21
      Expression = '\|$'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Symbols'
      StyleName = 'Symbols'
      StatesAbsent = 3
      TokenType = 15
      Expression = '[<>]|[\|\+=%\*!~&]+'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Math block'
      StyleName = 'Math BG'
      StatesAbsent = 3
      TokenType = 3
      Expression = '(\${1,2}).+\1'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Mark-added'
      StyleName = 'Mark-added'
      StatesAbsent = 3
      TokenType = 14
      Expression = '\{\+\+[^\+\}]+\+\+\}'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Mark-deleted'
      StyleName = 'Mark-deleted'
      StatesAbsent = 3
      TokenType = 14
      Expression = '\{\-\-[^\-\}]+\-\-\}'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Mark-edited'
      StyleName = 'Mark-edited'
      StatesAbsent = 3
      TokenType = 14
      Expression = '\{~~[^~\}]+~~\}'
      ColumnFrom = 0
      ColumnTo = 0
    end
    item
      DisplayName = 'Text'
      StyleName = 'Text'
      StatesAbsent = 3
      TokenType = 1
      Expression = '(?r)\w+'
      ColumnFrom = 0
      ColumnTo = 0
    end>
  BlockRules = <
    item
      DisplayName = 'Header'
      ConditionList = <
        item
          TokenTypes = 1
        end>
      EndOfTextClose = True
      DisplayInTree = False
      NameFmt = '%sz0'
      HighlightPos = cpAny
      CollapseFmt = '%sz0'
      SelfClose = True
      IgnoreAsParent = False
    end
    item
      DisplayName = '`begin'
      StyleName = 'Codeblock'
      ConditionList = <
        item
          TokenTypes = 65536
        end>
      BlockEnd = '`end'
      DisplayInTree = False
      DynHighlight = dhRange
      HighlightPos = cpAny
      CollapseFmt = '%sz0'
      IgnoreAsParent = False
    end
    item
      DisplayName = '`end'
      BlockType = btRangeEnd
      ConditionList = <
        item
          TokenTypes = 131072
        end>
      HighlightPos = cpAny
      IgnoreAsParent = False
    end
    item
      DisplayName = '~begin'
      StyleName = 'Codeblock'
      ConditionList = <
        item
          TokenTypes = 262144
        end>
      BlockEnd = '~end'
      DisplayInTree = False
      DynHighlight = dhRange
      HighlightPos = cpAny
      CollapseFmt = '%sz0'
      IgnoreAsParent = False
    end
    item
      DisplayName = '~end'
      BlockType = btRangeEnd
      ConditionList = <
        item
          TokenTypes = 524288
        end>
      HighlightPos = cpAny
      IgnoreAsParent = False
    end
    item
      DisplayName = 'Table begin'
      StyleName = 'Table BG'
      ConditionList = <
        item
          TokenTypes = 1048576
        end>
      BlockEnd = 'Table end'
      NotCollapsed = True
      DisplayInTree = False
      DynHighlight = dhRange
      HighlightPos = cpAny
      IgnoreAsParent = False
    end
    item
      DisplayName = 'Table end'
      BlockType = btRangeEnd
      ConditionList = <
        item
          TokenTypes = 2097152
        end>
      HighlightPos = cpAny
      IgnoreAsParent = False
    end>
  CodeTemplates = <>
  SubAnalyzers = <
    item
      DisplayName = 'PHP'
      StatesAbsent = 3
      StartExpression = '<\?'
      EndExpression = '\?>'
      SyntAnalyzer = SyntAnal14
      IncludeBounds = True
    end
    item
      DisplayName = 'JS'
      StatesAbsent = 3
      StartExpression = '(?s)<script\b.*?>'
      EndExpression = '</script>'
      SyntAnalyzer = SyntAnal9
    end
    item
      DisplayName = 'CSS'
      StatesAbsent = 3
      StartExpression = '(?s)<style\b.*?>'
      EndExpression = '</style>'
      SyntAnalyzer = SyntAnal6
    end
    item
      DisplayName = 'YAML front matter'
      StartExpression = '\A---$'
      EndExpression = '^---$'
      SyntAnalyzer = SyntAnal21
    end>
  SampleText.Strings = (
    '---'
    'layout: post'
    'title: Some text'
    '---'
    '[![Test](link here)](link here)'
    ''
    '# Header'
    '<!-- This is a comment -->'
    '/* This, too */ <kbd>Ctrl+C</kbd> and <tagbegin test="test">'
    '$$ math here $$'
    ''
    '`get_prop` id "token_type"; optional `get_prop` param'
    ''
    '`Inline Code` inside a paragraph with *italic*, '
    '**bold** and ***bold italic***, [^footnote] and + '
    
      '[reference][ref] and [reference] [ref]. <HTML> syntax and specia' +
      'l &harr; '
    'chars are highlighted, [Hyperlink text](url "title") '
    'and ![alternative text](image adress "title"). '
    'test: ~~~~crossed~ and ~crossed~~~ is supported '
    '- - -'
    '*  *  *'
    '_  _  _  _'
    ''
    '```c'
    'void F(int s) { return 20; }'
    '```'
    'and'
    ''
    '   ~~~php'
    'void N(n) { return 20; }'
    '   ~~~'
    ''
    '    Codeblock by indent'
    ''
    #9'1. But not for numbered'
    #9'-  or unordered lists'
    '    '#9'+ with several indentions'
    '        '#9'* leading digit, + - * '
    '123. note: unordered needs a sign & blank'
    #9'(a) extended Pandoc interpretation is supported'
    '    '#9'i) with roman numbering (i)    '
    '- [ ] check box'
    '- [x] check box'
    '- [X] check box'
    '12. [x] list item'
    'a) [x] list item'
    ''
    '(@) Pandoc Numbered example lists'
    '(@ref) with or without reference, where (@ref) is'
    'handled as reference'
    ''
    '> quoted **text**'
    '> > *markup* in quote'
    '>        > code in quote, not 2nd quote'
    '  >= quote'
    ''
    'Definition lists'
    ':   In a single line'
    ''
    '    indented definition lists'
    ''
    #9':   paragraph (blank line between)'
    ''
    '[ref]: url "title"'
    '[^footnote]: this is a footnote *italic* '
    ''
    '/* Optional */'
    'header'
    '='
    ''
    
      'Test {++added++} and {--deleted--} and {~~edited text~~} end.   ' +
      ' ')
  TokenTypeNames.Strings = (
    'Heading'
    'Text'
    'Comment'
    'Quote'
    'Codeblock'
    'Block'
    'Reference'
    'Footnote'
    'Footnote-Inline'
    'HTML Code'
    'Definition'
    'Link'
    'Image'
    'List'
    'Mark-inline'
    'Symbols'
    '`begin'
    '`end'
    '~begin'
    '~end'
    'Table begin'
    'Table end')
  Extentions = 'md markdown mkd'
  LexerName = 'Markdown'
  SkipSpaces = False
  Notes.Strings = (
    'Based on original lexer by NoSi (2014)'
    'Fully reworked by Alexey (CudaText)')
  RestartFromLineStart = True
  Charset = DEFAULT_CHARSET
end
