Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add FlatLaf as a L&F option #61

Closed
tferr opened this issue Feb 25, 2022 · 1 comment
Closed

Add FlatLaf as a L&F option #61

tferr opened this issue Feb 25, 2022 · 1 comment

Comments

@tferr
Copy link
Contributor

tferr commented Feb 25, 2022

Suggestion for OptionsLookAndFeel:

Swing is for the most part abandonware, but Flatlaf has been making strides in patching several swing limitations, namely lack of consistent scaling in hiDPI screens (which is nasty on Linux). This is mainly an issue for Java 8 (as of today Java11 solves much of it, but it is not perfect. So this would still be relevant once Java11 is adopted).

Some motivations are laid out at the bottom of this comment: scijava/script-editor#56 (comment)

The tasks for this would be:

  1. Adding FlatLaf as dependency
  2. Make sure that initLookAndFeel() returns the FlatLlaf themes (i.e, FlatLightLaf.NAME, FlatIntelliJLaf.NAME, FlatDarkLaf.NAME, FlatDarculaLaf.NAME)
  3. Have run() calling the Flatalaf setup(), something like:
	switch (lookAndFeelName) {
		case (FlatLightLaf.NAME):
			success = FlatLightLaf.setup();
			break;
		case (FlatIntelliJLaf.NAME):
			success = FlatIntelliJLaf.setup();
			break;
		case (FlatDarkLaf.NAME):
			success = FlatDarkLaf.setup();
			break;
		case (FlatDarculaLaf.NAME):
			success = FlatDarculaLaf.setup();
			break;
		default:
			(...) // existing logic
		}
@imagesc-bot
Copy link

This issue has been mentioned on Image.sc Forum. There might be relevant details there:

https://forum.image.sc/t/shiny-new-script-editor/64160/38

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants