package de.yellowant.janis.xojtoimage;

import java.io.File;

import de.yellowant.janis.xojtoimage.renderer.PageCanvas;

public class InteractiveUserInterface {
	private static final String USAGE = "Uasge:\njava -jar xojtoimage.jar <Xournal file> <format> <scale factor> <ouput file prefix>";

	public static void main(String[] args) {
		try {
			XOJToImage xoj = new XOJToImage(new File(args[0]), new PageCanvas(
					Float.parseFloat(args[2])));
			xoj.exportAll(args[3], args[1]);
		} catch (Exception e) {
			System.err.println("Error, please check your input! ("
					+ e.getMessage() + ")");
			System.out.println(USAGE);
		}
	}
}

@@ -477,16 +477,113 @@
 gs%5B1%5D);%0A
+%09%09%09System.out.println(%22Done. Processed %22%0A%09%09%09%09%09+ xoj.getXournal().getPages().size() + %22 pages.%22);%0A
 %09%09%7D catc

"Done" output