public class HTMLTextPainter
extends java.lang.Object
Constructor and Description |
---|
HTMLTextPainter(PsiFile psiFile,
Project project,
HtmlStyleManager htmlStyleManager,
boolean printLineNumbers,
boolean useMethodSeparators) |
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
convertCodeFragmentToHTMLFragmentWithInlineStyles(PsiElement context,
java.lang.String codeFragment)
Converts the code fragment to HTML with in-line styles.
|
PsiFile |
getPsiFile() |
void |
paint(java.util.Map<java.lang.Integer,PsiReference> refMap,
java.io.Writer writer,
boolean isStandalone) |
public PsiFile getPsiFile()
public void paint(java.util.Map<java.lang.Integer,PsiReference> refMap, java.io.Writer writer, boolean isStandalone) throws java.io.IOException
java.io.IOException
public static java.lang.String convertCodeFragmentToHTMLFragmentWithInlineStyles(PsiElement context, java.lang.String codeFragment)
context
parameter.
The code tokens in HTML are highlighted by lexer-based highlighter.
There is no formatting activity in this call.context
- the element that provide information about language, project and markup settingscodeFragment
- the code fragment that need to be converted to HTMLpre
-tag container