鍍金池/ 教程/ Java/ AWT Window類
AWT BasicStroke類
AWT ComponentEvent類
AWT Scrollbar類
AWT Graphics2D類
AWT Canvas類
AWT PopupMenu類
AWT Ellipse2D類
ContainerListener 接口
AWT List類
AWT 環(huán)境設(shè)置
AWT Menu類
MouseAdapter 類
AWT CheckBox類
AWT菜單控制
AWT Line2D類
MouseMotionListener 接口
AWTGridLayout
AWT TextField類
MouseListener 接口
WindowAdapter 類
AWT MenuComponent類
AWT MenuBar類
AWT MouseMotionEvent類
AWT 容器(Containers)
ItemListener接口
AWT Event類
AWT ActionListener接口
AWT AdjustmentEvent類
MouseMotionAdapter 類
AWT ActionEvent類
AWT ContainerEvent類
AWT FlowLayout
AWT 教程首頁
AWT MenuItem類
Panel類
AWT Window類
AWT 概述介紹
AWT Image類
ComponentListener接口
AWT CubicCurve2D類
AdjustmentListener 接口
AWT圖形控件
AWT Dialog類
KeyListener 接口
AWT Label類
LayoutManager 接口
AWT PaintEvent類
KeyEvent類
AWT TextArea類
TextListener 接口
AWT
AWT 適配器(Adapters)
AWT事件處理
Frame類
AWT Rectangle2D類
AWT FileDialog類
AWT Choice類
AWT InputEvent類
FocusListener 接口
KeyAdapter類
TextEvent類
AWT 事件監(jiān)聽器(Event Listeners)
AWT Container類
WindowListener 接口
AWT AWTEvent類
AWT控件(Controls)
AWT CardLayout
AWT BorderLayout
AWT 布局(Layouts)
AWT CheckboxMenuItem類
AWT Color類
AWT WindowEvent類
AWT Button類
AWT MouseEvent類
AWT QuadCurve2D類
AWT Font類
LayoutManager2 接口
AWT Component類
AWT CheckBoxGroup類
AWT GridBagLayout
AWT Arc2D類

AWT Window類

窗口(Window )類是一個沒有邊框和菜單欄的頂層窗口。它使用BorderLayout作為默認(rèn)的布局管理器。

類的聲明

以下是聲明的java.awt.Window類:

public class Window
   extends Container
      implements Accessible

類的構(gòu)造函數(shù)

S.N. 構(gòu)造函數(shù)與說明
1 Window(Frame owner) 
Constructs a new, initially invisible window with the specified Frame as its owner.
2 Window(Window owner) 
Constructs a new, initially invisible window with the specified Window as its owner.
3 Window(Window owner, GraphicsConfiguration gc) 
Constructs a new, initially invisible window with the specified owner Window and a GraphicsConfiguration of a screen device.

類方法

    <ol id="hu49p"><source id="hu49p"></source></ol>
    <form id="hu49p"><tbody id="hu49p"><style id="hu49p"></style></tbody></form>
      <s id="hu49p"></s>
      <form id="hu49p"><font id="hu49p"></font></form><ol id="hu49p"><legend id="hu49p"></legend></ol>
          <center id="hu49p"></center>
                <mark id="hu49p"><font id="hu49p"></font></mark>
                    S.N. 方法及說明
                    1 void addNotify() 
                    Makes this Window displayable by creating the connection to its native screen resource.
                    2 void addPropertyChangeListener(PropertyChangeListener listener) 
                    Adds a PropertyChangeListener to the listener list.
                    3 void addPropertyChangeListener(String propertyName, PropertyChangeListener listener) 
                    Adds a PropertyChangeListener to the listener list for a specific property.
                    4 void addWindowFocusListener(WindowFocusListener l) 
                    Adds the specified window focus listener to receive window events from this window.
                    5 void addWindowListener(WindowListener l) 
                    Adds the specified window listener to receive window events from this window.
                    6 void addWindowStateListener(WindowStateListener l) 
                    Adds the specified window state listener to receive window events from this window.
                    7 void applyResourceBundle(ResourceBundle rb) 
                    Deprecated. As of J2SE 1.4, replaced by Component.applyComponentOrientation.
                    8 void applyResourceBundle(String rbName) 
                    Deprecated. As of J2SE 1.4, replaced by Component.applyComponentOrientation.
                    9 void createBufferStrategy(int numBuffers) 
                    Creates a new strategy for multi-buffering on this component.
                    10 void createBufferStrategy(int numBuffers, BufferCapabilities caps) 
                    Creates a new strategy for multi-buffering on this component with the required buffer capabilities.
                    11 void dispose() 
                    Releases all of the native screen resources used by this Window, its subcomponents, and all of its owned children.
                    12 AccessibleContext getAccessibleContext() 
                    Gets the AccessibleContext associated with this Window.
                    13 BufferStrategy getBufferStrategy() 
                    Returns the BufferStrategy used by this component.
                    14 boolean getFocusableWindowState() 
                    Returns whether this Window can become the focused Window if it meets the other requirements outlined in isFocusableWindow.
                    15 Container getFocusCycleRootAncestor() 
                    Always returns null because Windows have no ancestors; they represent the top of the Component hierarchy.
                    16 Component getFocusOwner() 
                    Returns the child Component of this Window that has focus if this Window is focused; returns null otherwise.
                    17 Set<AWTKeyStroke> getFocusTraversalKeys(int id) 
                    Gets a focus traversal key for this Window.
                    18 GraphicsConfiguration getGraphicsConfiguration() 
                    This method returns the GraphicsConfiguration used by this Window.
                    19 List<Image> getIconImages() 
                    Returns the sequence of images to be displayed as the icon for this window.
                    20 InputContext getInputContext() 
                    Gets the input context for this window.
                    21 <T extends EventListener> T[] getListeners(Class<T> listenerType) 
                    Returns an array of all the objects currently registered as FooListeners upon this Window.
                    22 Locale getLocale() 
                    Gets the Locale object that is associated with this window, if the locale has been set.
                    23 Dialog.ModalExclusionType getModalExclusionType() 
                    Returns the modal exclusion type of this window.
                    24 Component getMostRecentFocusOwner() 
                    Returns the child Component of this Window that will receive the focus when this Window is focused.
                    25 Window[] getOwnedWindows() 
                    Return an array containing all the windows this window currently owns.
                    26 Window getOwner() 
                    Returns the owner of this window.
                    27 static Window[] getOwnerlessWindows() 
                    Returns an array of all Windows created by this application that have no owner.
                    28 Toolkit getToolkit() 
                    Returns the toolkit of this frame.
                    29 String getWarningString() 
                    Gets the warning string that is displayed with this window.
                    30 WindowFocusListener[] getWindowFocusListeners() 
                    Returns an array of all the window focus listeners registered on this window.
                    31 WindowListener[] getWindowListeners() 
                    Returns an array of all the window listeners registered on this window.
                    32 static Window[] getWindows() 
                    Returns an array of all Windows, both owned and ownerless, created by this application.
                    33 WindowStateListener[] getWindowStateListeners() 
                    Returns an array of all the window state listeners registered on this window.
                    34 void hide() 
                    Deprecated. As of JDK version 1.5, replaced by setVisible(boolean).
                    35 boolean isActive() 
                    Returns whether this Window is active.
                    36 boolean isAlwaysOnTop() 
                    Returns whether this window is an always-on-top window.
                    37 boolean isAlwaysOnTopSupported() 
                    Returns whether the always-on-top mode is supported for this window.
                    38 boolean isFocusableWindow() 
                    Returns whether this Window can become the focused Window, that is, whether this Window or any of its subcomponents can become the focus owner.
                    39 boolean isFocusCycleRoot() 
                    Always returns true because all Windows must be roots of a focus traversal cycle.
                    40 boolean isFocused() 
                    Returns whether this Window is focused.
                    41 boolean isLocationByPlatform() 
                    Returns true if this Window will appear at the default location for the native windowing system the next time this Window is made visible.
                    42 boolean isShowing() 
                    Checks if this Window is showing on screen.
                    43 void pack() 
                    Causes this Window to be sized to fit the preferred size and layouts of its subcomponents.
                    44 void paint(Graphics g) 
                    Paints the container.
                    45 boolean postEvent(Event e) 
                    Deprecated. As of JDK version 1.1 replaced by dispatchEvent(AWTEvent).
                    46 protected void processEvent(AWTEvent e) 
                    Processes events on this window.
                    47 protected void processWindowEvent(WindowEvent e) 
                    Processes window events occurring on this window by dispatching them to any registered WindowListener objects.
                    48 protected void processWindowFocusEvent(WindowEvent e) 
                    Processes window focus event occuring on this window by dispatching them to any registered WindowFocusListener objects.
                    49 protected void processWindowStateEvent(WindowEvent e) 
                    Processes window state event occuring on this window by dispatching them to any registered WindowStateListener objects.
                    50 void removeNotify() 
                    Makes this Container undisplayable by removing its connection to its native screen resource.
                    51 void removeWindowFocusListener(WindowFocusListener l) 
                    Removes the specified window focus listener so that it no longer receives window events from this window.
                    52 void removeWindowListener(WindowListener l) 
                    Removes the specified window listener so that it no longer receives window events from this window.
                    53 上一篇:AWT Image類下一篇:AWT CubicCurve2D類