@Test public void underScore() throws OfxAuthoringException { String txt = "xx_2"; String result = TexSpecialChars.replace(txt); logger.info(result); }
public static String replace(String s) { s=s.replaceAll("#", "\\\\#"); s=s.replaceAll("∞","\\$ \\\\inf \\$"); s=s.replaceAll("&", "\\\\&"); s=s.replaceAll("_", "\\\\_"); return s; }
TexSpecialChars { public static String replace(String s) { s=s.replaceAll("#", "\\\\#"); s=s.replaceAll("∞","\\$ \\\\inf \\$"); s=s.replaceAll("&", "\\\\&"); s=s.replaceAll("_", "\\\\_"); return s; } }
TexSpecialChars { public static String replace(String s) { s=s.replaceAll("#", "\\\\#"); s=s.replaceAll("∞","\\$ \\\\inf \\$"); s=s.replaceAll("&", "\\\\&"); s=s.replaceAll("_", "\\\\_"); return s; }  }
TexSpecialChars { public static String replace(String s) { s=s.replaceAll("#", "\\\\#"); s=s.replaceAll("∞","\\$ \\\\inf \\$"); s=s.replaceAll("&", "\\\\&"); s=s.replaceAll("_", "\\\\_"); return s; }  static String replace(String s); }
TexSpecialChars { public static String replace(String s) { s=s.replaceAll("#", "\\\\#"); s=s.replaceAll("∞","\\$ \\\\inf \\$"); s=s.replaceAll("&", "\\\\&"); s=s.replaceAll("_", "\\\\_"); return s; }  static String replace(String s);  }