mirror of
https://github.com/JFormDesigner/FlatLaf.git
synced 2026-02-12 23:07:15 -06:00
support loading FlatLaf properties files from named Java modules without the need to open that package in module-info.java (issue #1026)
This commit is contained in:
@@ -38,8 +38,12 @@ public class FlatModularAppTest
|
||||
SwingUtilities.invokeLater( () -> {
|
||||
FlatInterFont.installBasic();
|
||||
|
||||
FlatLaf.registerCustomDefaultsSource( "com.formdev.flatlaf.testing.modular.app.themes" );
|
||||
FlatLaf.registerCustomDefaultsSource( "com.formdev.flatlaf.testing.modular.app.themes2",
|
||||
FlatModularAppTest.class.getClassLoader() );
|
||||
FlatLaf.registerCustomDefaultsSource(
|
||||
FlatModularAppTest.class.getResource( "/com/formdev/flatlaf/testing/modular/app/themes/" ) );
|
||||
FlatModularAppTest.class.getResource( "/com/formdev/flatlaf/testing/modular/app/themes3" ) );
|
||||
|
||||
FlatLightLaf.setup();
|
||||
|
||||
JButton button1 = new JButton( "Hello" );
|
||||
|
||||
@@ -14,7 +14,4 @@
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
@background = #fff
|
||||
@foreground = #f00
|
||||
|
||||
ButtonUI = com.formdev.flatlaf.testing.modular.app.plaf.MyButtonUI
|
||||
|
||||
@@ -0,0 +1,17 @@
|
||||
#
|
||||
# Copyright 2025 FormDev Software GmbH
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# https://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
@background = #efe
|
||||
@@ -0,0 +1,17 @@
|
||||
#
|
||||
# Copyright 2025 FormDev Software GmbH
|
||||
#
|
||||
# Licensed under the Apache License, Version 2.0 (the "License");
|
||||
# you may not use this file except in compliance with the License.
|
||||
# You may obtain a copy of the License at
|
||||
#
|
||||
# https://www.apache.org/licenses/LICENSE-2.0
|
||||
#
|
||||
# Unless required by applicable law or agreed to in writing, software
|
||||
# distributed under the License is distributed on an "AS IS" BASIS,
|
||||
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
# See the License for the specific language governing permissions and
|
||||
# limitations under the License.
|
||||
#
|
||||
|
||||
ButtonUI = com.formdev.flatlaf.testing.modular.app.plaf.MyButtonUI
|
||||
Reference in New Issue
Block a user