Skip to content

Commit 5190073

Browse files
authored
Merge pull request #85 from KeineDX4/rf_dobrochan_markup_support
DobrochanRefuge: markup support
2 parents 416fbe1 + c83b6cb commit 5190073

File tree

2 files changed

+12
-1
lines changed

2 files changed

+12
-1
lines changed

extensions/refugedobrochan/build.gradle

+1-1
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ apply plugin: 'chan-extension'
33
chan {
44
nameUpper 'RefugeDobrochan'
55
packageName 'com.trixiether.dashchan.chan.refugedobrochan'
6-
versionName '1.4'
6+
versionName '1.5'
77
apiVersion 1
88
hosts 'rf.dobrochan.net'
99
}

extensions/refugedobrochan/src/com/trixiether/dashchan/chan/refugedobrochan/RefugeDobrochanChanMarkup.java

+11
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package com.trixiether.dashchan.chan.refugedobrochan;
22

33
import chan.content.VichanChanMarkup;
4+
import chan.text.CommentEditor;
45

56
public class RefugeDobrochanChanMarkup extends VichanChanMarkup {
67

@@ -9,6 +10,16 @@ public RefugeDobrochanChanMarkup() {
910
addTag("s", TAG_STRIKE);
1011
}
1112

13+
@Override
14+
public CommentEditor obtainCommentEditor(String boardName) {
15+
CommentEditor commentEditor = new CommentEditor();
16+
commentEditor.addTag(TAG_BOLD, "**", "**", CommentEditor.FLAG_ONE_LINE);
17+
commentEditor.addTag(TAG_ITALIC, "*", "*", CommentEditor.FLAG_ONE_LINE);
18+
commentEditor.addTag(TAG_STRIKE, "~~", "~~", CommentEditor.FLAG_ONE_LINE);
19+
commentEditor.addTag(TAG_SPOILER, "%%", "%%", CommentEditor.FLAG_ONE_LINE);
20+
return commentEditor;
21+
}
22+
1223
@Override
1324
public boolean isTagSupported(String boardName, int tag) {
1425
return ((SUPPORTED_TAGS | TAG_STRIKE) & tag) == tag;

0 commit comments

Comments
 (0)