Skip to content

Commit

Permalink
Add Commenter
Browse files Browse the repository at this point in the history
to enable (un)commenting
  • Loading branch information
dweindl committed May 31, 2024
1 parent ac580c8 commit 52ab5e1
Show file tree
Hide file tree
Showing 2 changed files with 37 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
package com.github.dweindl.intellijantimony;

import com.intellij.lang.Commenter;
import org.jetbrains.annotations.Nullable;

public class AntimonyCommenter implements Commenter {
@Nullable
@Override
public String getLineCommentPrefix() {
return "#";
}

@Nullable
@Override
public String getBlockCommentPrefix() {
return "/*";
}

@Nullable
@Override
public String getBlockCommentSuffix() {
return "*/";
}

@Nullable
@Override
public String getCommentedBlockCommentPrefix() {
return null;
}

@Nullable
@Override
public String getCommentedBlockCommentSuffix() {
return null;
}
}
1 change: 1 addition & 0 deletions src/main/resources/META-INF/plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
<lang.braceMatcher language="Antimony" implementationClass="com.github.dweindl.intellijantimony.AntimonyPairedBraceMatcher"/>
<colorSettingsPage implementation="com.github.dweindl.intellijantimony.AntimonyColorSettingsPage"/>
<!-- TODO: code folding -->
<lang.commenter language="Antimony" implementationClass="com.github.dweindl.intellijantimony.AntimonyCommenter"/>
</extensions>

<applicationListeners>
Expand Down

0 comments on commit 52ab5e1

Please # to comment.