Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Fix LookAndFeel loader NPE if missing libgtk2.0 #8132

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

Merged
cmaglie merged 2 commits into arduino:master from cmaglie:fix-gtk-lnf
Nov 5, 2018

Conversation

Copy link
Member

@cmaglie cmaglie commented Oct 24, 2018

Alternative to #8122 to fix issue #8119

The swing UIManager class detects the correct look and feel settings by
looking inside the `sun.desktop` system property, here's the extract of
the JDK:
 String desktop = AccessController.doPrivileged(new GetPropertyAction("sun.desktop"));
 Toolkit toolkit = Toolkit.getDefaultToolkit();
 if ("gnome".equals(desktop) &&
 toolkit instanceof SunToolkit &&
 ((SunToolkit) toolkit).isNativeGTKAvailable()) {
 // May be set on Linux and Solaris boxs.
 return "com.sun.java.swing.plaf.gtk.GTKLookAndFeel";
 }
Since we want always the GTK look and feel (even if the desktop is not
strictly a GNOME desktop) we force the `sun.desktop` property always to
`gnome`.
@cmaglie cmaglie added this to the Release 1.8.8 milestone Oct 24, 2018
@cmaglie cmaglie merged commit afc0e02 into arduino:master Nov 5, 2018
@cmaglie cmaglie deleted the fix-gtk-lnf branch November 5, 2018 10:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /