Currently we use two types of highlighters: regex-based one for elements panel and lex-based one for the source view. Latter seems to be faster, we should migrate to it.
Created attachment 47626 [details] [PATCH] Proposed change.
Committing to http://svn.webkit.org/repository/webkit/trunk ... D WebCore/inspector/front-end/CSSSourceSyntaxHighlighter.js D WebCore/inspector/front-end/JavaScriptSourceSyntaxHighlighter.js D WebCore/inspector/front-end/SourceSyntaxHighlighter.js M LayoutTests/ChangeLog M LayoutTests/inspector/syntax-highlight-css-expected.txt M LayoutTests/inspector/syntax-highlight-css.html M LayoutTests/inspector/syntax-highlight-javascript-expected.txt M LayoutTests/inspector/syntax-highlight-javascript.html M LayoutTests/inspector/syntax-highlight.js M WebCore/ChangeLog M WebCore/WebCore.gypi M WebCore/WebCore.vcproj/WebCore.vcproj A WebCore/inspector/front-end/DOMSyntaxHighlighter.js M WebCore/inspector/front-end/ElementsTreeOutline.js M WebCore/inspector/front-end/SourceCSSTokenizer.js M WebCore/inspector/front-end/SourceCSSTokenizer.re2js M WebCore/inspector/front-end/SourceHTMLTokenizer.js M WebCore/inspector/front-end/SourceHTMLTokenizer.re2js M WebCore/inspector/front-end/SourceJavaScriptTokenizer.js M WebCore/inspector/front-end/SourceJavaScriptTokenizer.re2js A WebCore/inspector/front-end/SourceTokenizer.js M WebCore/inspector/front-end/TextEditorHighlighter.js M WebCore/inspector/front-end/WebKit.qrc M WebCore/inspector/front-end/inspector.html Committed r54053