
import com.formdev.flatlaf.FlatDarkLaf;
import com.formdev.flatlaf.FlatLightLaf;
import javax.swing.UIManager;
import jrex.ui.MainFrame;

/**
 * Main class.
 *
 * @author Mark George <mark.george@otago.ac.nz>
 */
public class JRex {

	public static void main(String args[]) throws Exception {
		if (args.length > 0 && "light".equalsIgnoreCase(args[0])) {
			UIManager.setLookAndFeel(new FlatLightLaf());
		} else {
			UIManager.setLookAndFeel(new FlatDarkLaf());
		}
		
		java.awt.EventQueue.invokeLater(new Runnable() {
			@Override
			public void run() {
				MainFrame frame = new MainFrame();
				frame.setLocationRelativeTo(null);
				frame.setVisible(true);
			}
		});
	}
}
