📄 jcomponent.html
字号:
<BR> <a name="jtree_description"> A control that displays a set of hierarchical data as an outline.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> class</CODE></FONT></TD><TD><CODE><B><A HREF="../../../javax/swing/JViewport.html">JViewport</A></B></CODE><BR> The "viewport" or "porthole" through which you see the underlying information.</TD></TR></TABLE> <P><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor"><TD COLSPAN=2>Fields in <A HREF="../../../javax/swing/package-summary.html">javax.swing</A> declared as <A HREF="../../../javax/swing/JComponent.html">JComponent</A></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>protected <A HREF="../../../javax/swing/JComponent.html">JComponent</A></CODE></FONT></TD><TD><CODE><B>DefaultCellEditor.</B><B><A HREF="../../../javax/swing/DefaultCellEditor.html#editorComponent">editorComponent</A></B></CODE><BR> </TD></TR></TABLE> <P><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor"><TD COLSPAN=2>Methods in <A HREF="../../../javax/swing/package-summary.html">javax.swing</A> that return <A HREF="../../../javax/swing/JComponent.html">JComponent</A></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../../javax/swing/JComponent.html">JComponent</A></CODE></FONT></TD><TD><CODE><B>ComponentInputMap.</B><B><A HREF="../../../javax/swing/ComponentInputMap.html#getComponent()">getComponent</A></B>()</CODE><BR> Returns the component the <code>InputMap</code> was created for.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../../javax/swing/JComponent.html">JComponent</A></CODE></FONT></TD><TD><CODE><B>JColorChooser.</B><B><A HREF="../../../javax/swing/JColorChooser.html#getPreviewPanel()">getPreviewPanel</A></B>()</CODE><BR> Returns the preview panel that shows a chosen color.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../../javax/swing/JComponent.html">JComponent</A></CODE></FONT></TD><TD><CODE><B>JToolTip.</B><B><A HREF="../../../javax/swing/JToolTip.html#getComponent()">getComponent</A></B>()</CODE><BR> Returns the component the tooltip applies to.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../../javax/swing/JComponent.html">JComponent</A></CODE></FONT></TD><TD><CODE><B>JFileChooser.</B><B><A HREF="../../../javax/swing/JFileChooser.html#getAccessory()">getAccessory</A></B>()</CODE><BR> Returns the accessory component.</TD></TR></TABLE> <P><TABLE BORDER="1" CELLPADDING="3" CELLSPACING="0" WIDTH="100%"><TR BGCOLOR="#CCCCFF" CLASS="TableSubHeadingColor"><TD COLSPAN=2>Methods in <A HREF="../../../javax/swing/package-summary.html">javax.swing</A> with parameters of type <A HREF="../../../javax/swing/JComponent.html">JComponent</A></FONT></TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B>ToolTipManager.</B><B><A HREF="../../../javax/swing/ToolTipManager.html#registerComponent(javax.swing.JComponent)">registerComponent</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> component)</CODE><BR> Register a component for tooltip management.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B>ToolTipManager.</B><B><A HREF="../../../javax/swing/ToolTipManager.html#unregisterComponent(javax.swing.JComponent)">unregisterComponent</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> component)</CODE><BR> Remove a component from tooltip control.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static void</CODE></FONT></TD><TD><CODE><B>JLayeredPane.</B><B><A HREF="../../../javax/swing/JLayeredPane.html#putLayer(javax.swing.JComponent, int)">putLayer</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> c, int layer)</CODE><BR> Sets the layer property on a JComponent.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static int</CODE></FONT></TD><TD><CODE><B>JLayeredPane.</B><B><A HREF="../../../javax/swing/JLayeredPane.html#getLayer(javax.swing.JComponent)">getLayer</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> c)</CODE><BR> Gets the layer property for a JComponent, it does not cause any side effects like setLayer().</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static <A HREF="../../../javax/swing/RepaintManager.html">RepaintManager</A></CODE></FONT></TD><TD><CODE><B>RepaintManager.</B><B><A HREF="../../../javax/swing/RepaintManager.html#currentManager(javax.swing.JComponent)">currentManager</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> c)</CODE><BR> Return the RepaintManager for the calling thread given a JComponent.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B>RepaintManager.</B><B><A HREF="../../../javax/swing/RepaintManager.html#addInvalidComponent(javax.swing.JComponent)">addInvalidComponent</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> invalidComponent)</CODE><BR> Mark the component as in need of layout and queue a runnable for the event dispatching thread that will validate the components first isValidateRoot() ancestor.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B>RepaintManager.</B><B><A HREF="../../../javax/swing/RepaintManager.html#removeInvalidComponent(javax.swing.JComponent)">removeInvalidComponent</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> component)</CODE><BR> Remove a component from the list of invalid components.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B>RepaintManager.</B><B><A HREF="../../../javax/swing/RepaintManager.html#addDirtyRegion(javax.swing.JComponent, int, int, int, int)">addDirtyRegion</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> c, int x, int y, int w, int h)</CODE><BR> Add a component in the list of components that should be refreshed.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> <A HREF="../../../java/awt/Rectangle.html">Rectangle</A></CODE></FONT></TD><TD><CODE><B>RepaintManager.</B><B><A HREF="../../../javax/swing/RepaintManager.html#getDirtyRegion(javax.swing.JComponent)">getDirtyRegion</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> aComponent)</CODE><BR> Return the current dirty region for a component.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B>RepaintManager.</B><B><A HREF="../../../javax/swing/RepaintManager.html#markCompletelyDirty(javax.swing.JComponent)">markCompletelyDirty</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> aComponent)</CODE><BR> Mark a component completely dirty.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B>RepaintManager.</B><B><A HREF="../../../javax/swing/RepaintManager.html#markCompletelyClean(javax.swing.JComponent)">markCompletelyClean</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> aComponent)</CODE><BR> Mark a component completely clean.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> boolean</CODE></FONT></TD><TD><CODE><B>RepaintManager.</B><B><A HREF="../../../javax/swing/RepaintManager.html#isCompletelyDirty(javax.swing.JComponent)">isCompletelyDirty</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> aComponent)</CODE><BR> Convenience method that returns true if <b>aComponent</b> will be completely painted during the next paintDirtyRegions().</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static void</CODE></FONT></TD><TD><CODE><B>LookAndFeel.</B><B><A HREF="../../../javax/swing/LookAndFeel.html#installColors(javax.swing.JComponent, java.lang.String, java.lang.String)">installColors</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> c, <A HREF="../../../java/lang/String.html">String</A> defaultBgName, <A HREF="../../../java/lang/String.html">String</A> defaultFgName)</CODE><BR> Convenience method for initializing a component's foreground and background color properties with values from the current defaults table.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static void</CODE></FONT></TD><TD><CODE><B>LookAndFeel.</B><B><A HREF="../../../javax/swing/LookAndFeel.html#installColorsAndFont(javax.swing.JComponent, java.lang.String, java.lang.String, java.lang.String)">installColorsAndFont</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> c, <A HREF="../../../java/lang/String.html">String</A> defaultBgName, <A HREF="../../../java/lang/String.html">String</A> defaultFgName, <A HREF="../../../java/lang/String.html">String</A> defaultFontName)</CODE><BR> Convenience method for initializing a components foreground background and font properties with values from the current defaults table.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static void</CODE></FONT></TD><TD><CODE><B>LookAndFeel.</B><B><A HREF="../../../javax/swing/LookAndFeel.html#installBorder(javax.swing.JComponent, java.lang.String)">installBorder</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> c, <A HREF="../../../java/lang/String.html">String</A> defaultBorderName)</CODE><BR> Convenience method for installing a component's default Border object on the specified component if either the border is currently null or already an instance of UIResource.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static void</CODE></FONT></TD><TD><CODE><B>LookAndFeel.</B><B><A HREF="../../../javax/swing/LookAndFeel.html#uninstallBorder(javax.swing.JComponent)">uninstallBorder</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> c)</CODE><BR> Convenience method for un-installing a component's default border on the specified component if the border is currently an instance of UIResource.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static <A HREF="../../../javax/swing/ComponentInputMap.html">ComponentInputMap</A></CODE></FONT></TD><TD><CODE><B>LookAndFeel.</B><B><A HREF="../../../javax/swing/LookAndFeel.html#makeComponentInputMap(javax.swing.JComponent, java.lang.Object[])">makeComponentInputMap</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> c, <A HREF="../../../java/lang/Object.html">Object</A>[] keys)</CODE><BR> Creates a ComponentInputMap from <code>keys</code>.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE> void</CODE></FONT></TD><TD><CODE><B>JColorChooser.</B><B><A HREF="../../../javax/swing/JColorChooser.html#setPreviewPanel(javax.swing.JComponent)">setPreviewPanel</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> preview)</CODE><BR> Sets the current preview panel.</TD></TR><TR BGCOLOR="white" CLASS="TableRowColor"><TD ALIGN="right" VALIGN="top" WIDTH="1%"><FONT SIZE="-1"><CODE>static <A HREF="../../../java/lang/String.html">String</A></CODE></FONT></TD><TD><CODE><B>SwingUtilities.</B><B><A HREF="../../../javax/swing/SwingUtilities.html#layoutCompoundLabel(javax.swing.JComponent, java.awt.FontMetrics, java.lang.String, javax.swing.Icon, int, int, int, int, java.awt.Rectangle, java.awt.Rectangle, java.awt.Rectangle, int)">layoutCompoundLabel</A></B>(<A HREF="../../../javax/swing/JComponent.html">JComponent</A> c,
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -