Jun 12

Daniel Weck left a few comments with good suggestions on how to make the “notification” messages look even better. He suggested making the background darker (not so translucent), and including a drop shadow for the text to make it more readable. What was great is that he even included a link to an example screenshot that showed what he meant. :-)

After taking a look at the screenshot I decided to take a few minutes and implement his ideas. Additionally, I decided to incorporate another effect that I liked from the screenshot, which was the Mac OS X style curve in the notification area. Here is a screenshot of my quick initial effort:

A screenshot of my revised notification GlassPane

I’m still not 100% happy with the “drop shadow” of the text but it’s good enough for now. I might go back later and re-implement the shadow using a Gaussian Blur, but I think the results of this “quick hack” are good enough (and close enough to my goal) that I can release it in it’s unfinished state.

Here are the links to download the source code or to run the example with WebStart:

7 Responses to “Revision to my last GlassPane Example”

  1. Daniel WECK Says:

    Well done !
    Thumbs up this quick response to RFE ! ;)

    The effect looks great.
    Nevertheless, it is extremely slow on my Mac (Java 1.4.x not 1.5).
    (it used to be ultra-responsive before the update)

    I think it’s due to a fade-in/out effect ? Am I right ?

    In my opinion, the text shadow is good as it is.
    If you feel like playing with Gaussian Blur, I would rather suggest to implement a shadow for the black glossy surface (projected onto the background text editor).

    Last point: I get a thin black border around it, is that normal ? (it seems to dissapear when the window position changes).

    Thank you for your experimentations !

    Daniel WECK
    http://del.icio.us/daniel.weck
    http://jroller.com/page/danielweck

  2. Jon Lipsky Says:

    I know for sure there are a few optimizations that could be done to make it run faster (on any computer).

    Normally I test everything on my Mac, but I didn’t get a chance to do it before I posted it to my blog. I’m traveling all this week and I only have my Windows laptop with me, so I’ll test it on the Mac when I get back home.

  3. tonetheman links » Says:

    [...] links — tone @ 3:47 pm

    POD (print on demand) social bookmarking search cool stuff in java (glasspane) cringley on apple and intel 50 writing tools mini slack (slackware based distro) [...]

  4. Jens Andersen Says:

    Hi Jon,

    WOW… your sample is looking very very cool. I’m looking forward to an optimized version of the GlassPane, and please keep that UI stuff coming because I’m learning a lot with regards to Swing and UI by reading your blog. I especially liked the “JTabbedPane delegates” examples.

    Regards,

    j3ns

  5. Anubhav Manak Says:

    Hi Jon,

    This example is really nice.

    Regards
    Anubhav

  6. Brian Says:

    Found you through sitepoint. Great post, awesome blog… Can’t wait to read more! Keep the Swing stuff comin’

  7. Loyl Says:

    Nice work, I code a custom class of GlassPane to my GPL project. See the result :

    [img]http://analysesi.free.fr/img/analysesi1.png[/img]

Leave a Reply