Search in sources :

Example 1 with JavaScriptDamagerRepairer

use of org.apache.syncope.ide.eclipse.plugin.editors.htmlhelpers.JavaScriptDamagerRepairer in project syncope by apache.

the class HTMLSourceConfiguration method getPresentationReconciler.

@Override
public IPresentationReconciler getPresentationReconciler(final ISourceViewer sourceViewer) {
    PresentationReconciler reconciler = new PresentationReconciler();
    DefaultDamagerRepairer dr = null;
    dr = new HTMLTagDamagerRepairer(getTagScanner());
    reconciler.setDamager(dr, HTMLPartitionScanner.HTML_TAG);
    reconciler.setRepairer(dr, HTMLPartitionScanner.HTML_TAG);
    dr = new HTMLTagDamagerRepairer(getTagScanner());
    reconciler.setDamager(dr, HTMLPartitionScanner.PREFIX_TAG);
    reconciler.setRepairer(dr, HTMLPartitionScanner.PREFIX_TAG);
    dr = new HTMLTagDamagerRepairer(getSyncopeTagScanner());
    reconciler.setDamager(dr, HTMLPartitionScanner.SYNCOPE_TAG);
    reconciler.setRepairer(dr, HTMLPartitionScanner.SYNCOPE_TAG);
    dr = new HTMLTagDamagerRepairer(getHTMLScanner());
    reconciler.setDamager(dr, IDocument.DEFAULT_CONTENT_TYPE);
    reconciler.setRepairer(dr, IDocument.DEFAULT_CONTENT_TYPE);
    dr = new HTMLTagDamagerRepairer(getCommentScanner());
    reconciler.setDamager(dr, HTMLPartitionScanner.HTML_COMMENT);
    reconciler.setRepairer(dr, HTMLPartitionScanner.HTML_COMMENT);
    dr = new DefaultDamagerRepairer(getScriptScanner());
    reconciler.setDamager(dr, HTMLPartitionScanner.HTML_SCRIPT);
    reconciler.setRepairer(dr, HTMLPartitionScanner.HTML_SCRIPT);
    dr = new DefaultDamagerRepairer(getDoctypeScanner());
    reconciler.setDamager(dr, HTMLPartitionScanner.HTML_DOCTYPE);
    reconciler.setRepairer(dr, HTMLPartitionScanner.HTML_DOCTYPE);
    dr = new DefaultDamagerRepairer(getDirectiveScanner());
    reconciler.setDamager(dr, HTMLPartitionScanner.HTML_DIRECTIVE);
    reconciler.setRepairer(dr, HTMLPartitionScanner.HTML_DIRECTIVE);
    dr = new JavaScriptDamagerRepairer(getJavaScriptScanner());
    reconciler.setDamager(dr, HTMLPartitionScanner.JAVASCRIPT);
    reconciler.setRepairer(dr, HTMLPartitionScanner.JAVASCRIPT);
    dr = new JavaScriptDamagerRepairer(getCSSScanner());
    reconciler.setDamager(dr, HTMLPartitionScanner.HTML_CSS);
    reconciler.setRepairer(dr, HTMLPartitionScanner.HTML_CSS);
    return reconciler;
}
Also used : JavaScriptDamagerRepairer(org.apache.syncope.ide.eclipse.plugin.editors.htmlhelpers.JavaScriptDamagerRepairer) HTMLTagDamagerRepairer(org.apache.syncope.ide.eclipse.plugin.editors.htmlhelpers.HTMLTagDamagerRepairer) DefaultDamagerRepairer(org.eclipse.jface.text.rules.DefaultDamagerRepairer) IPresentationReconciler(org.eclipse.jface.text.presentation.IPresentationReconciler) PresentationReconciler(org.eclipse.jface.text.presentation.PresentationReconciler)

Aggregations

HTMLTagDamagerRepairer (org.apache.syncope.ide.eclipse.plugin.editors.htmlhelpers.HTMLTagDamagerRepairer)1 JavaScriptDamagerRepairer (org.apache.syncope.ide.eclipse.plugin.editors.htmlhelpers.JavaScriptDamagerRepairer)1 IPresentationReconciler (org.eclipse.jface.text.presentation.IPresentationReconciler)1 PresentationReconciler (org.eclipse.jface.text.presentation.PresentationReconciler)1 DefaultDamagerRepairer (org.eclipse.jface.text.rules.DefaultDamagerRepairer)1