diff --git a/lib/rsyntaxtextarea-2.5.6.jar b/lib/rsyntaxtextarea-2.5.6.jar new file mode 100644 index 0000000..b60def6 Binary files /dev/null and b/lib/rsyntaxtextarea-2.5.6.jar differ diff --git a/nbproject/project.properties b/nbproject/project.properties index 3cbc6c2..327010f 100644 --- a/nbproject/project.properties +++ b/nbproject/project.properties @@ -38,6 +38,7 @@ file.reference.js-engine.jar=lib/js-engine.jar file.reference.js.jar=lib/js.jar file.reference.jython-standalone-2.7-b3.jar=lib/jython-standalone-2.7-b3.jar file.reference.log4j-1.2.11.jar=lib/log4j-1.2.11.jar +file.reference.rsyntaxtextarea-2.5.6.jar=lib/rsyntaxtextarea-2.5.6.jar file.reference.symja-2014-11-01.jar=lib/symja-2014-11-01.jar includes=** jar.archive.disabled=${jnlp.enabled} @@ -51,7 +52,8 @@ javac.classpath=\ ${file.reference.htmlcleaner-2.10.jar}:\ ${file.reference.js-engine.jar}:\ ${file.reference.js.jar}:\ - ${file.reference.jython-standalone-2.7-b3.jar} + ${file.reference.jython-standalone-2.7-b3.jar}:\ + ${file.reference.rsyntaxtextarea-2.5.6.jar} # Space-separated list of extra javac options javac.compilerargs= javac.deprecation=false diff --git a/src/net/apocalypselabs/symat/CodeEditor.java b/src/net/apocalypselabs/symat/CodeEditor.java index 37b8a3c..55e371a 100644 --- a/src/net/apocalypselabs/symat/CodeEditor.java +++ b/src/net/apocalypselabs/symat/CodeEditor.java @@ -423,8 +423,8 @@ public class CodeEditor extends javax.swing.JInternalFrame { private void execCode(String lang) { CodeRunner cr = new CodeRunner(lang); - System.out.println(lang); - System.out.println(codeBox.getText()); + Debug.println(lang); + Debug.println(codeBox.getText()); Object result = cr.evalString(codeBox.getText()); try { outputBox.append(result.toString() + "\n"); diff --git a/src/net/apocalypselabs/symat/CodeRunner.java b/src/net/apocalypselabs/symat/CodeRunner.java index 0fe238c..ce4b53d 100644 --- a/src/net/apocalypselabs/symat/CodeRunner.java +++ b/src/net/apocalypselabs/symat/CodeRunner.java @@ -145,7 +145,6 @@ public class CodeRunner { private String wrapMath(String eval) { if (wrapRequired) { String with = "with(SyMAT_Functions){with(Math){" + eval + "}}"; - //System.out.println(with); return with; } return eval; diff --git a/src/net/apocalypselabs/symat/Debug.java b/src/net/apocalypselabs/symat/Debug.java index 5e11355..99e1997 100644 --- a/src/net/apocalypselabs/symat/Debug.java +++ b/src/net/apocalypselabs/symat/Debug.java @@ -35,7 +35,7 @@ package net.apocalypselabs.symat; public class Debug { // If output should be on or off - public static final boolean DEBUG = true; + public static final boolean DEBUG = false; public static void println(Object data) { if (DEBUG) { diff --git a/src/net/apocalypselabs/symat/MainGUI.java b/src/net/apocalypselabs/symat/MainGUI.java index 18f7449..6ee3cd8 100644 --- a/src/net/apocalypselabs/symat/MainGUI.java +++ b/src/net/apocalypselabs/symat/MainGUI.java @@ -45,7 +45,8 @@ import javax.swing.JInternalFrame; public class MainGUI extends javax.swing.JFrame { public static final String APP_NAME = "SyMAT 0.7"; - public static final double APP_CODE = 0.7; + public static final double APP_CODE = 7; + public static final String VERSION_NAME = "0.7"; public static String argfile = ""; public static boolean skipPython = false; // Skip python init on start? @@ -57,24 +58,25 @@ public class MainGUI extends javax.swing.JFrame { setIconImage((new ImageIcon(getClass().getResource("icon.png"))).getImage()); setLocationRelativeTo(null); try { - URL url = new URL("http://symat.aplabs.us/version.txt"); + URL url = new URL("http://symatapp.com/version.txt"); InputStream is = url.openStream(); BufferedReader br = new BufferedReader(new InputStreamReader(is)); String line = br.readLine(); br.close(); is.close(); - double version = Double.parseDouble(line); + double version = Double.parseDouble(line.split("\\|")[0]); if (version > APP_CODE) { if (PrefStorage.getSetting("update-ignore").equals(APP_CODE + "|" + version)) { System.out.println("An update was found, but has been ignored by the user."); } else { - loadFrame(new Update(version)); + loadFrame(new Update(line.split("\\|")[1])); } } } catch (IOException | NumberFormatException e) { System.err.println("Fail: Cannot check update server. \n" + " Assuming local copy up-to-date."); + e.printStackTrace(); } // Open shell unless prog was run with argument diff --git a/src/net/apocalypselabs/symat/SplashScreen.form b/src/net/apocalypselabs/symat/SplashScreen.form index 65b9430..c52fc59 100644 --- a/src/net/apocalypselabs/symat/SplashScreen.form +++ b/src/net/apocalypselabs/symat/SplashScreen.form @@ -2,7 +2,7 @@