public SpritesheetForm(CoderForm cForm) { coderForm = cForm; InitializeComponent(); // enable double buffering for canvasPanel typeof(Panel).InvokeMember("DoubleBuffered", BindingFlags.SetProperty | BindingFlags.Instance | BindingFlags.NonPublic, null, canvasPanel, new object[] { true }); }
static void Main() { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); CoderForm mainForm = new CoderForm(); string[] args = Environment.GetCommandLineArgs(); if (args.Length > 1 && File.Exists(args[1])) { mainForm.LoadProject(args[1]); } Application.Run(mainForm); }