Zizouz212 / macwidgets

Automatically exported from code.google.com/p/macwidgets
0 stars 0 forks source link

HUDWindow does not display correctly when using SeaGlass LF #152

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
When using SeaGlass the HUDWindow still has its original SeaGlass-style window 
decorations.

Kathryn came up with a fix for it. Maybe you can add this to MacWidgets:

Ken,

I updated my checked out copy of MacWidgets to the latest and think the 
following should be 
changed beginning at line 82 in HUDWindow.java:

        WindowUtils.makeWindowNonOpaque(fDialog);
        // for Java 5 on platforms other than Mac (those that don't support transparency), it looks
        // nicer to use a black background rather than the default (usually white).
        rootPane.setBackground(Color.BLACK);

should be changed to:

        WindowUtils.makeWindowNonOpaque(fDialog);
        // for Java 5 on platforms other than Mac (those that don't support transparency), it looks
        // nicer to use a black background rather than the default (usually white).
        if (!PlatformUtils.isMac()) {
            rootPane.setBackground(Color.BLACK);
        }
        rootPane.setOpaque(false);
        rootPane.setWindowDecorationStyle(JRootPane.NONE);

You don't want to set the background color to black on a Mac. At least on my 
installation, it 
overrode the transparency.

The other two lines setting the root pane to non-opaque and window decoration 
style to none 
are, I think, good ideas, especially the latter.

Original issue reported on code.google.com by dlemmermann@gmail.com on 22 Jan 2010 at 3:52

GoogleCodeExporter commented 9 years ago

Original comment by kenneth....@gmail.com on 19 Aug 2010 at 11:23