|
|
@ -99,12 +99,10 @@ public class wikiCode {
|
|
|
|
return "internal error: " + e.getMessage();
|
|
|
|
return "internal error: " + e.getMessage();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
public String transformLine(String result, plasmaSwitchboard switchboard) {
|
|
|
|
public String replaceHTML(String result) {
|
|
|
|
// transform page
|
|
|
|
int p0;
|
|
|
|
int p0, p1;
|
|
|
|
|
|
|
|
boolean defList = false; //needed for definition lists
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
// avoide html inside
|
|
|
|
// avoide html inside
|
|
|
|
//p0 = 0; while ((p0 = result.indexOf("&", p0)) >= 0) result = result.substring(0, p0) + "&" + result.substring(p0 + 1);
|
|
|
|
//p0 = 0; while ((p0 = result.indexOf("&", p0)) >= 0) result = result.substring(0, p0) + "&" + result.substring(p0 + 1);
|
|
|
|
p0 = 0; while ((p0 = result.indexOf('"', p0)) >= 0) result = result.substring(0, p0) + """ + result.substring(p0 + 1);
|
|
|
|
p0 = 0; while ((p0 = result.indexOf('"', p0)) >= 0) result = result.substring(0, p0) + """ + result.substring(p0 + 1);
|
|
|
@ -113,6 +111,15 @@ public class wikiCode {
|
|
|
|
//p0 = 0; while ((p0 = result.indexOf("*", p0)) >= 0) result = result.substring(0, p0) + "•" + result.substring(p0 + 1);
|
|
|
|
//p0 = 0; while ((p0 = result.indexOf("*", p0)) >= 0) result = result.substring(0, p0) + "•" + result.substring(p0 + 1);
|
|
|
|
p0 = 0; while ((p0 = result.indexOf("(C)", p0)) >= 0) result = result.substring(0, p0) + "©" + result.substring(p0 + 3);
|
|
|
|
p0 = 0; while ((p0 = result.indexOf("(C)", p0)) >= 0) result = result.substring(0, p0) + "©" + result.substring(p0 + 3);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return result;
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
public String transformLine(String result, plasmaSwitchboard switchboard) {
|
|
|
|
|
|
|
|
// transform page
|
|
|
|
|
|
|
|
int p0, p1;
|
|
|
|
|
|
|
|
boolean defList = false; //needed for definition lists
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
result = replaceHTML(result);
|
|
|
|
|
|
|
|
|
|
|
|
//check if line contains any escape symbol of if we are in an esacpe sequence already
|
|
|
|
//check if line contains any escape symbol of if we are in an esacpe sequence already
|
|
|
|
//if that's the case the program will continue further below [MN]
|
|
|
|
//if that's the case the program will continue further below [MN]
|
|
|
|