{"name":"FontForge Script","scopeName":"source.fontforge","patterns":[{"include":"#main"}],"repository":{"codepoint":{"name":"constant.numeric.other.codepoint.fontforge","match":"o[uU][A-Fa-f0-9]+"},"comments":{"patterns":[{"name":"comment.line.number-sign.fontforge","begin":"#","end":"$","beginCaptures":{"0":{"name":"punctuation.definition.comment.fontforge"}}},{"name":"comment.block.fontforge","begin":"/\\*","end":"\\*/","beginCaptures":{"0":{"name":"punctuation.definition.comment.begin.fontforge"}},"endCaptures":{"0":{"name":"punctuation.definition.comment.end.fontforge"}}},{"name":"comment.line.double-slash","begin":"//","end":"$","beginCaptures":{"0":{"name":"punctuation.definition.comment.fontforge"}}}]},"control":{"name":"keyword.control.$1.fontforge","match":"\\b(if|elseif|else|endif|while|endloop|foreach|break|return|shift)\\b"},"integer":{"patterns":[{"name":"constant.numeric.integer.hexadecimal.fontforge","match":"(?\u003c!\\w)[-+]?0[Xx][A-Fa-f0-9]+"},{"name":"constant.numeric.integer.octal.fontforge","match":"(?\u003c!\\w)[-+]?(?=0)\\d+"},{"name":"constant.numeric.integer.decimal.fontforge","match":"(?\u003c!\\w)[-+]?\\d+"}]},"main":{"patterns":[{"include":"#comments"},{"include":"#codepoint"},{"include":"#strings"},{"include":"#control"},{"include":"#real"},{"include":"#integer"},{"include":"#operators"},{"include":"#procedureCall"},{"include":"#punctuation"},{"include":"#variables"}]},"operators":{"patterns":[{"name":"keyword.operator.comparison.fontforge","match":"==|!=|\u003e=|\u003c=|\u003e|\u003c"},{"name":"keyword.operator.assignment.compound.fontforge","match":"=|[-+*/%]="},{"name":"keyword.operator.decrement.fontforge","match":"--"},{"name":"keyword.operator.increment.fontforge","match":"\\+{2}"},{"name":"keyword.operator.arithmetic.fontforge","match":"[-+/*~!]"},{"name":"keyword.operator.logical.fontforge","match":"\u0026\u0026|\\|\\|"},{"name":"keyword.operator.bitwise.fontforge","match":"\u0026|\\||\\\\\\^"},{"name":"keyword.operator.pathspec.fontforge","match":":[htre]","captures":{"0":{"patterns":[{"include":"#punctuation"}]}}}]},"procedureCall":{"name":"meta.function-call.fontforge","contentName":"meta.function-call.arguments.fontforge","begin":"(\\w+)\\s*(\\()","end":"\\)","patterns":[{"include":"$base"}],"beginCaptures":{"1":{"name":"entity.name.function.fontforge"},"2":{"name":"punctuation.definition.arguments.begin.bracket.round.fontforge"}},"endCaptures":{"0":{"name":"punctuation.definition.arguments.end.bracket.round.fontforge"}}},"punctuation":{"patterns":[{"name":"punctuation.separator.comma.fontforge","match":","},{"name":"punctuation.terminator.statement.fontforge","match":";"},{"name":"punctuation.delimiter.colon.fontforge","match":":"},{"name":"meta.expression.chained.fontforge","begin":"\\[","end":"\\]","patterns":[{"include":"$base"}],"beginCaptures":{"0":{"name":"punctuation.bracket.begin.square.fontforge"}},"endCaptures":{"0":{"name":"punctuation.bracket.end.square.fontforge"}}},{"name":"meta.expression.fontforge","begin":"\\(","end":"\\)","patterns":[{"include":"$base"}],"beginCaptures":{"0":{"name":"punctuation.bracket.begin.round.fontforge"}},"endCaptures":{"0":{"name":"punctuation.bracket.end.round.fontforge"}}}]},"real":{"name":"constant.numeric.float.fontforge","match":"(?\u003c!\\w)[-+]?\\d*\\.\\d+"},"shared":{"patterns":[{"include":"#codepoint"},{"include":"#strings"},{"include":"#real"},{"include":"#integer"},{"include":"#punctuation"},{"include":"#operators"}]},"stringEscapes":{"patterns":[{"name":"constant.character.escape.newline.fontforge","match":"\\\\n"}]},"strings":{"patterns":[{"name":"string.double.quoted.fontforge","begin":"\"","end":"\"|$","patterns":[{"include":"#stringEscapes"}],"beginCaptures":{"0":{"name":"punctuation.definition.string.begin.fontforge"}},"endCaptures":{"0":{"name":"punctuation.definition.string.end.fontforge"}}},{"name":"string.single.quoted.fontforge","begin":"'","end":"'|$","patterns":[{"include":"#stringEscapes"}],"beginCaptures":{"0":{"name":"punctuation.definition.string.begin.fontforge"}},"endCaptures":{"0":{"name":"punctuation.definition.string.end.fontforge"}}}]},"variables":{"patterns":[{"name":"variable.language.readonly.positional.fontforge","match":"(\\$)\\d+(?=\\W)","captures":{"1":{"name":"punctuation.definition.variable.fontforge"}}},{"name":"variable.language.readonly.fontforge","match":"(\\$)\\w+","captures":{"1":{"name":"punctuation.definition.variable.fontforge"}}},{"name":"variable.other.global.fontforge","match":"(_)\\w+","captures":{"1":{"name":"punctuation.definition.variable.fontforge"}}},{"name":"variable.other.font.fontforge","match":"(@)\\w+","captures":{"1":{"name":"punctuation.definition.variable.fontforge"}}},{"name":"variable.other.local.fontforge","match":"(?=[A-Za-z])\\w+"}]}}}
