From 852e2495f963fc5b30d25a9932c70d6736c5dd59 Mon Sep 17 00:00:00 2001 From: Ben Fry Date: Sat, 30 Apr 2022 10:09:29 -0400 Subject: [PATCH] tweaking the flatlaf props --- app/build.xml | 2 +- app/src/processing/app/laf/FlatLaf.properties | 3 ++- app/src/processing/app/platform/DefaultPlatform.java | 11 ++++------- 3 files changed, 7 insertions(+), 9 deletions(-) diff --git a/app/build.xml b/app/build.xml index 36295d9f6..ee7887073 100644 --- a/app/build.xml +++ b/app/build.xml @@ -140,7 +140,7 @@ - + diff --git a/app/src/processing/app/laf/FlatLaf.properties b/app/src/processing/app/laf/FlatLaf.properties index 207eccdfd..181041155 100644 --- a/app/src/processing/app/laf/FlatLaf.properties +++ b/app/src/processing/app/laf/FlatLaf.properties @@ -1 +1,2 @@ -defaultFont = 14 "Processing Sans Pro", "Open Sans", "Noto Sans", Roboto, Arial \ No newline at end of file +defaultFont = 14 "Processing Sans Pro", "Open Sans", "Noto Sans", Roboto, Arial +ScrollBar.width = 24 \ No newline at end of file diff --git a/app/src/processing/app/platform/DefaultPlatform.java b/app/src/processing/app/platform/DefaultPlatform.java index c8ba50bdf..06afb4fb9 100644 --- a/app/src/processing/app/platform/DefaultPlatform.java +++ b/app/src/processing/app/platform/DefaultPlatform.java @@ -120,16 +120,13 @@ public class DefaultPlatform { UIManager.put("ScrollBar.minimumThumbSize", new Dimension(16, 24)); */ - // dummy font call so that it's registered for the LaF + // dummy font call so that it's registered for FlatLaf Toolkit.getSansFont(12, Font.PLAIN); - FlatLaf.registerCustomDefaultsSource("processing.app.ui"); - //if ("dark".equals(Theme.get("laf.mode"))) { - //UIManager.setLookAndFeel(new FlatDarkLaf()); - //} else { + // + FlatLaf.registerCustomDefaultsSource("processing.app.laf"); UIManager.setLookAndFeel(new FlatLightLaf()); - //} - UIManager.put("ScrollBar.width", 16); + //UIManager.put("ScrollBar.width", 16); // moved to properties } else { UIManager.setLookAndFeel(laf);