use of org.eclipse.mylyn.wikitext.textile.internal.phrase.ImageTextilePhraseModifier in project mylyn.docs by eclipse.
the class TextileLanguage method addStandardPhraseModifiers.
@Override
protected void addStandardPhraseModifiers(PatternBasedSyntax phraseModifierSyntax) {
boolean escapingHtml = configuration == null ? false : configuration.isEscapingHtmlAndXml();
phraseModifierSyntax.add(new TagEscapeTextilePhraseModifier());
phraseModifierSyntax.add(new HtmlEndTagPhraseModifier(escapingHtml));
phraseModifierSyntax.add(new HtmlStartTagPhraseModifier(escapingHtml));
// $NON-NLS-1$
phraseModifierSyntax.beginGroup("(?:(?<=[\\s\\.,\\\"'?!;:\\)\\(\\{\\}\\[\\]])|^)(?:", 0);
phraseModifierSyntax.add(new EscapeTextilePhraseModifier());
// $NON-NLS-1$
phraseModifierSyntax.add(new SimpleTextilePhraseModifier("**", SpanType.BOLD, Mode.NESTING));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimpleTextilePhraseModifier("??", SpanType.CITATION, Mode.NESTING));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimpleTextilePhraseModifier("__", SpanType.ITALIC, Mode.NESTING));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimpleTextilePhraseModifier("_", SpanType.EMPHASIS, Mode.NESTING));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimpleTextilePhraseModifier("*", SpanType.STRONG, Mode.NESTING));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimpleTextilePhraseModifier("+", SpanType.INSERTED, Mode.NESTING));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimpleTextilePhraseModifier("~", SpanType.SUBSCRIPT, Mode.NORMAL));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimpleTextilePhraseModifier("^", SpanType.SUPERSCRIPT, Mode.NORMAL));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimpleTextilePhraseModifier("@", SpanType.CODE, Mode.SPECIAL));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimpleTextilePhraseModifier("%", SpanType.SPAN, Mode.NESTING));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimpleTextilePhraseModifier("-", SpanType.DELETED, Mode.NESTING));
phraseModifierSyntax.add(new ImageTextilePhraseModifier());
// hyperlinks are actually a phrase modifier see bug 283093
phraseModifierSyntax.add(new HyperlinkPhraseModifier());
// $NON-NLS-1$
phraseModifierSyntax.endGroup(")(?=\\W|$)", 0);
}
Aggregations