use of org.eclipse.mylyn.wikitext.markdown.internal.token.InlineImageReplacementToken in project mylyn.docs by eclipse.
the class MarkdownLanguage method addStandardPhraseModifiers.
@Override
protected void addStandardPhraseModifiers(PatternBasedSyntax phraseModifierSyntax) {
// inline HTML
phraseModifierSyntax.add(new HtmlEndTagPhraseModifier());
phraseModifierSyntax.add(new HtmlStartTagPhraseModifier());
// images
phraseModifierSyntax.add(new InlineImageReplacementToken());
phraseModifierSyntax.add(new ReferenceStyleImageReplacementToken());
// links
phraseModifierSyntax.add(new InlineLinkReplacementToken());
phraseModifierSyntax.add(new ReferenceStyleLinkReplacementToken());
phraseModifierSyntax.add(new AutomaticLinkReplacementToken());
// backslash escaped span elements
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("**"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("__"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("*"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("_"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("\\"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("`"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("{"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("}"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("["));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("]"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("("));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier(")"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("#"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("+"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("-"));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("."));
// $NON-NLS-1$
phraseModifierSyntax.add(new BackslashEscapePhraseModifier("!"));
// emphasis span elements
// $NON-NLS-1$
phraseModifierSyntax.add(new SimplePhraseModifier("``", SpanType.CODE));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimplePhraseModifier("`", SpanType.CODE));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimplePhraseModifier("**", SpanType.STRONG));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimplePhraseModifier("__", SpanType.STRONG));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimplePhraseModifier("*", SpanType.EMPHASIS));
// $NON-NLS-1$
phraseModifierSyntax.add(new SimplePhraseModifier("_", SpanType.EMPHASIS));
}
use of org.eclipse.mylyn.wikitext.markdown.internal.token.InlineImageReplacementToken in project mylyn.docs by eclipse.
the class MarkdownLanguage method addStandardTokens.
@Override
protected void addStandardTokens(PatternBasedSyntax tokenSyntax) {
// HTML entities are preserved
tokenSyntax.add(new PreserverHtmlEntityToken());
// inline links have to be handled as tokens, as they can be embedded in phrases
tokenSyntax.add(new InlineLinkReplacementToken());
tokenSyntax.add(new InlineImageReplacementToken());
// two or more spaces at end of line force a line break
// $NON-NLS-1$
tokenSyntax.add(new PatternLineBreakReplacementToken("( {2,})$"));
}
Aggregations