set flag AllPublic. set flag HaveProcessing. lib 1013739 import processing.core.*; static A pMain(final Class c) { ret first(pMainWithFrame(c)); } static Pair pMainWithFrame(final Class c) { ret swing(func -> Pair { fixContextClassLoader(); A a = nuInstance(c); Set frames = asSet(listAWTFrames()); PApplet.runSketch(new S[] { c.getName() }, a); Frame frame = first(listWithoutSet(listAWTFrames(), frames)); ret pair(a, frame); }); } static PApplet2 pMain() { ret pMain(mc()); }