Class Frame

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible
Direct Known Subclasses:
JFrame

public class Frame extends Window
Emulator for Frame.
See Also:
  • Field Details

  • Constructor Details

  • Method Details

    • remove

      public void remove(MenuComponent arg0)
      Specified by:
      remove in interface MenuContainer
      Overrides:
      remove in class Component
    • getState

      public int getState()
    • setState

      public void setState(int state)
    • paramString

      protected String paramString()
      Overrides:
      paramString in class Container
    • setMenuBar

      public void setMenuBar(MenuBar arg0)
      An AWT menu bar renders nothing here — MenuBar is not a Component and SB-Emulators ports no peer for it, where a Swing JMenuBar goes through JFrame.setJMenuBar(JMenuBar). So the effect drops and the state stays: AWT stores the bar and fires nothing (D_window_fanout), and its parent/peer wiring is what needed the peer.
    • setMaximizedBounds

      public void setMaximizedBounds(Rectangle bounds)
    • setTitle

      public void setTitle(String title)
    • setResizable

      public void setResizable(boolean b)
    • getExtendedState

      public int getExtendedState()
    • setExtendedState

      public void setExtendedState(int state)
    • isUndecorated

      public boolean isUndecorated()
    • setOpacity

      public void setOpacity(float opacity)
      Description copied from class: Window
      AWT's other two throws are not reproduced, and deliberately: both ask the platform whether it can do translucency at all — a browser can, so the answers would be "yes, supported" and the throws unreachable. What is declined is the peer push, so the window renders fully opaque.
      Overrides:
      setOpacity in class Window
      Parameters:
      opacity - in [0, 1]
    • setShape

      public void setShape(Shape shape)
      Overrides:
      setShape in class Window
    • setBackground

      public void setBackground(Color bgColor)
      Overrides:
      setBackground in class Window
    • setCursor

      public void setCursor(int type)
    • getTitle

      public String getTitle()
    • getIconImage

      public Image getIconImage()
    • getMenuBar

      public MenuBar getMenuBar()
    • isResizable

      public boolean isResizable()
    • getMaximizedBounds

      public Rectangle getMaximizedBounds()
      Returns:
      what setMaximizedBounds(Rectangle) stored; null until set, as in AWT
    • setUndecorated

      public void setUndecorated(boolean b)
    • getCursorType

      public int getCursorType()
    • getFrames

      public static Frame[] getFrames()
    • getAccessibleContext

      public AccessibleContext getAccessibleContext()
      Specified by:
      getAccessibleContext in interface Accessible
      Overrides:
      getAccessibleContext in class Window