Skip to content

Enable darklaf on rsyntaxtextarea again#719

Closed
FSchumacher wants to merge 1 commit intoapache:masterfrom
FSchumacher:reenable-darklaf-jsyntaxtextarea
Closed

Enable darklaf on rsyntaxtextarea again#719
FSchumacher wants to merge 1 commit intoapache:masterfrom
FSchumacher:reenable-darklaf-jsyntaxtextarea

Conversation

@FSchumacher
Copy link
Contributor

Description

SyntaxTextAreas look bad on dark mode with Darklaf, as
the id of the theme has been changed to all lowercase and we didn't recognize it anymore.

Bugzilla Id: 66157

How Has This Been Tested?

Opened a test plan in dark mode with a JSR223 Sampler

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)

Checklist:

  • My code follows the code style of this project.
  • I have updated the documentation accordingly.

The id of the theme has been changed to all lowercase

public static boolean isDarklafTheme() {
return "Darklaf".equals(UIManager.getLookAndFeel().getID()); // $NON-NLS-1$
return "Darklaf".equalsIgnoreCase(UIManager.getLookAndFeel().getID()); // $NON-NLS-1$
Copy link
Collaborator

@vlsi vlsi Jul 5, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wow. This is unexpected for me. I wonder if we could eliminate isDarklafTheme() altogether. It is really surprising that isDarklafTheme() impacts colors.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you know how, it would be great, but I think it comes from JSyntaxTextArea not handling the dark LaF well enough, so that darklaf has some special handling for it. Sadly, that has to be done by hand.

@asfgit asfgit closed this in b914b71 Jul 7, 2022
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

Successfully merging this pull request may close these issues.

2 participants