Merge pull request #5011 from JakubValtar/blow-up

Window placement and pixel density cleanup
This commit is contained in:
Ben Fry
2017-04-21 16:57:20 -04:00
committed by GitHub
9 changed files with 293 additions and 314 deletions

View File

@@ -24,6 +24,7 @@ package processing.mode.java.runner;
import processing.app.*;
import processing.app.exec.StreamRedirectThread;
import processing.app.ui.Toolkit;
import processing.core.*;
import processing.data.StringList;
import processing.mode.java.JavaBuild;
@@ -466,6 +467,10 @@ public class Runner implements MessageConsumer {
// removed for 3.0a6 because it would break the args passed to sketches.
params.append(PApplet.ARGS_SKETCH_FOLDER + "=" + build.getSketchPath());
if (Toolkit.zoom(100) >= 200) { // Use 100 to bypass possible rounding in zoom()
params.append(PApplet.ARGS_DENSITY + "=2");
}
params.append(build.getSketchClassName());
}
// Add command-line arguments to be given to the sketch itself