mirror of
https://github.com/processing/processing4.git
synced 2026-06-16 04:26:26 +02:00
Visual fixes for Linux
This commit is contained in:
@@ -31,6 +31,8 @@ import processing.app.Messages;
|
||||
import processing.app.Preferences;
|
||||
import processing.core.PApplet;
|
||||
|
||||
import javax.swing.*;
|
||||
|
||||
|
||||
public class LinuxPlatform extends DefaultPlatform {
|
||||
String homeDir;
|
||||
@@ -39,6 +41,9 @@ public class LinuxPlatform extends DefaultPlatform {
|
||||
public void initBase(Base base) {
|
||||
super.initBase(base);
|
||||
|
||||
JFrame.setDefaultLookAndFeelDecorated(true);
|
||||
System.setProperty("flatlaf.menuBarEmbedded", "true");
|
||||
|
||||
// Set X11 WM_CLASS property which is used as the application
|
||||
// name by Gnome 3 and other window managers.
|
||||
// https://github.com/processing/processing/issues/2534
|
||||
|
||||
@@ -618,12 +618,10 @@ public abstract class Editor extends JFrame implements RunnerListener {
|
||||
toolTipWarningColor = Theme.get("errors.selection.warning.bgcolor");
|
||||
toolTipErrorColor = Theme.get("errors.selection.error.bgcolor");
|
||||
|
||||
if(Platform.isWindows()) {
|
||||
UIManager.put("RootPane.background", color);
|
||||
UIManager.put("TitlePane.embeddedForeground", Theme.getColor("editor.fgcolor"));
|
||||
getRootPane().updateUI();
|
||||
UIManager.put("RootPane.background", null);
|
||||
}
|
||||
UIManager.put("RootPane.background", color);
|
||||
UIManager.put("TitlePane.embeddedForeground", Theme.getColor("editor.fgcolor"));
|
||||
getRootPane().updateUI();
|
||||
UIManager.put("RootPane.background", null);
|
||||
|
||||
JPopupMenu popup = modePopup.getPopupMenu();
|
||||
// Cannot use instanceof because com.formdev.flatlaf.ui.FlatPopupMenuBorder
|
||||
|
||||
Reference in New Issue
Block a user