Search code examples
javaswinguser-interfacetranslucencyshaped-window

changing the shape of jframe


I don't know whether it is possible or not.Is there any way to change the shape of jframe into circle


Solution

  • Essentially what you have to do is make the outer part of your JFrame rendered surface transparent and then draw your own custom shape in the middle.

    This will get you started:

    http://java.sun.com/developer/technicalArticles/GUI/translucent_shaped_windows/

    And this is a finished implementation:

    http://www.codeproject.com/KB/java/shaped-transparent-jframe.aspx