div |
---|
|
HTML Table |
---|
|
Table Row (tr) |
---|
Table Cell (td) |
---|
Align |
---|
| Top span |
---|
| Custom Language Support |
|
|
Table Cell (td) |
---|
Align |
---|
|
Next span |
---|
|
Grammar and Parser Wiki Markup |
---|
{div:class=navigation}
{table:width=100%}
{tr}
{td} {align:left}[Previous|Prerequisites] {span:class=sep}\|{span} {span:class=text}Prerequisites{span}{align} {td}
{td} {align:center}[Top|Custom Language Support] {span:class=sep}\|{span} {span:class=text}Custom Language Support{span}{align} {td}
{td} {align:right}[Next|Grammar and Parser] {span:class=sep}\|{span} {span:class=text}Grammar and Parser{span}{align} {td}
{tr}
{table}
{div} |
1. Define a language
Code Block |
---|
package com.simpleplugin;
import com.intellij.lang.Language;
public class SimpleLanguage extends Language {
public static final SimpleLanguage INSTANCE = new SimpleLanguage();
private SimpleLanguage() {
super("Simple");
}
}
|
2. Define an icon
Copy the icon to
span |
---|
|
Wiki Markup |
---|
{span:class=id}com.simpleplugin.icons{span} |
package.
Code Block |
---|
package com.simpleplugin;
import com.intellij.openapi.util.IconLoader;
import javax.swing.*;
public class SimpleIcons {
public static final Icon FILE = IconLoader.getIcon("/com/simpleplugin/icons/jar-gray.png");
}
|
...
Create a file with extension
span |
---|
|
.simple Wiki Markup |
---|
{span:class=id}.simple{span} |
and IntelliJ IDEA will automatically associate it with our language.

div |
---|
|
HTML Table |
---|
|
Table Row (tr) |
---|
Table Cell (td) |
---|
Align |
---|
| Top span |
---|
| Custom Language Support |
|
|
Table Cell (td) |
---|
Align |
---|
|
Next span |
---|
|
Grammar and Parser Wiki Markup |
---|
{div:class=navigation}
{table:width=100%}
{tr}
{td} {align:left}[Previous|Prerequisites] {span:class=sep}\|{span} {span:class=text}Prerequisites{span}{align} {td}
{td} {align:center}[Top|Custom Language Support] {span:class=sep}\|{span} {span:class=text}Custom Language Support{span}{align} {td}
{td} {align:right}[Next|Grammar and Parser] {span:class=sep}\|{span} {span:class=text}Grammar and Parser{span}{align} {td}
{tr}
{table}
{div} |