⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 jcolorchooser.html

📁 API資料大全
💻 HTML
📖 第 1 页 / 共 5 页
字号:
</DD><DD><DL><DT><B>Returns:</B><DD>the string "ColorChooserUI"<DT><B>See Also: </B><DD><A HREF="../../javax/swing/JComponent.html#getUIClassID()"><CODE>JComponent.getUIClassID()</CODE></A>, <A HREF="../../javax/swing/UIDefaults.html#getUI(javax.swing.JComponent)"><CODE>UIDefaults.getUI(javax.swing.JComponent)</CODE></A></DL></DD></DL><HR><A NAME="getColor()"><!-- --></A><H3>getColor</H3><PRE>public <A HREF="../../java/awt/Color.html">Color</A> <B>getColor</B>()</PRE><DL><DD>Gets the current color value from the color chooser. By default, this delegates to the model.<DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>the current color value of the color chooser</DL></DD></DL><HR><A NAME="setColor(java.awt.Color)"><!-- --></A><H3>setColor</H3><PRE>public void <B>setColor</B>(<A HREF="../../java/awt/Color.html">Color</A>&nbsp;color)</PRE><DL><DD>Sets the current color of the color chooser to the specified color. This will fire a <code>PropertyChangeEvent</code> for the property named "color".<DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>color</CODE> - the color to be set in the color chooser<DT><B>See Also: </B><DD><A HREF="../../javax/swing/JComponent.html#addPropertyChangeListener(java.beans.PropertyChangeListener)"><CODE>JComponent.addPropertyChangeListener(java.beans.PropertyChangeListener)</CODE></A></DL></DD></DL><HR><A NAME="setColor(int, int, int)"><!-- --></A><H3>setColor</H3><PRE>public void <B>setColor</B>(int&nbsp;r,                     int&nbsp;g,                     int&nbsp;b)</PRE><DL><DD>Sets the current color of the color chooser to the specified RGB color.  Note that the values of red, green, and blue should be between the numbers 0 and 255, inclusive.<DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>r</CODE> - an int specifying the amount of Red<DD><CODE>g</CODE> - an int specifying the amount of Green<DD><CODE>b</CODE> - an int specifying the amount of Blue<DT><B>Throws:</B><DD><CODE><A HREF="../../java/lang/IllegalArgumentException.html">IllegalArgumentException</A></CODE> - if r,g,b values are out of range<DT><B>See Also: </B><DD><A HREF="../../java/awt/Color.html"><CODE>Color</CODE></A></DL></DD></DL><HR><A NAME="setColor(int)"><!-- --></A><H3>setColor</H3><PRE>public void <B>setColor</B>(int&nbsp;c)</PRE><DL><DD>Sets the current color of the color chooser to the specified color.<DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>c</CODE> - an int value that sets the current color in the chooser          where the low-order 8 bits specify the Blue value,          the next 8 bits specify the Green value, and the 8 bits          above that specify the Red value.</DL></DD></DL><HR><A NAME="setPreviewPanel(javax.swing.JComponent)"><!-- --></A><H3>setPreviewPanel</H3><PRE>public void <B>setPreviewPanel</B>(<A HREF="../../javax/swing/JComponent.html">JComponent</A>&nbsp;preview)</PRE><DL><DD>Sets the current preview panel. This will fire a <code>PropertyChangeEvent</code> for the property named "previewPanel".<DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>color</CODE> - the color to be set in the color chooser<DT><B>See Also: </B><DD><A HREF="../../javax/swing/JComponent.html#addPropertyChangeListener(java.beans.PropertyChangeListener)"><CODE>JComponent.addPropertyChangeListener(java.beans.PropertyChangeListener)</CODE></A></DL></DD></DL><HR><A NAME="getPreviewPanel()"><!-- --></A><H3>getPreviewPanel</H3><PRE>public <A HREF="../../javax/swing/JComponent.html">JComponent</A> <B>getPreviewPanel</B>()</PRE><DL><DD>Returns the preview panel that shows a chosen color.<DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>a JComponent object -- the preview panel</DL></DD></DL><HR><A NAME="addChooserPanel(javax.swing.colorchooser.AbstractColorChooserPanel)"><!-- --></A><H3>addChooserPanel</H3><PRE>public void <B>addChooserPanel</B>(<A HREF="../../javax/swing/colorchooser/AbstractColorChooserPanel.html">AbstractColorChooserPanel</A>&nbsp;panel)</PRE><DL><DD>Adds a color chooser panel to the color chooser.<DD><DL></DL></DD></DL><HR><A NAME="removeChooserPanel(javax.swing.colorchooser.AbstractColorChooserPanel)"><!-- --></A><H3>removeChooserPanel</H3><PRE>public <A HREF="../../javax/swing/colorchooser/AbstractColorChooserPanel.html">AbstractColorChooserPanel</A> <B>removeChooserPanel</B>(<A HREF="../../javax/swing/colorchooser/AbstractColorChooserPanel.html">AbstractColorChooserPanel</A>&nbsp;panel)</PRE><DL><DD>Removes the Color Panel specified.<DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>name</CODE> - a string that specifies the panel to be removed<DT><B>Returns:</B><DD>the color panel<DT><B>Throws:</B><DD><CODE><A HREF="../../java/lang/IllegalArgumentException.html">IllegalArgumentException</A></CODE> - if panel is not in list of 			known chooser panels</DL></DD></DL><HR><A NAME="setChooserPanels(javax.swing.colorchooser.AbstractColorChooserPanel[])"><!-- --></A><H3>setChooserPanels</H3><PRE>public void <B>setChooserPanels</B>(<A HREF="../../javax/swing/colorchooser/AbstractColorChooserPanel.html">AbstractColorChooserPanel</A>[]&nbsp;panels)</PRE><DL><DD>Specifies the Color Panels used to choose a color value.<DD><DL></DL></DD><DD><DL><DT><B>Parameters:</B><DD><CODE>panels</CODE> - an array of AbstractColorChooserPanel object</DL></DD></DL><HR><A NAME="getChooserPanels()"><!-- --></A><H3>getChooserPanels</H3><PRE>public <A HREF="../../javax/swing/colorchooser/AbstractColorChooserPanel.html">AbstractColorChooserPanel</A>[] <B>getChooserPanels</B>()</PRE><DL><DD>Returns the specified color panels.<DD><DL></DL></DD><DD><DL><DT><B>Returns:</B><DD>an array of AbstractColorChooserPanel objects</DL></DD></DL><HR><A NAME="getSelectionModel()"><!-- --></A><H3>getSelectionModel</H3><PRE>public <A HREF="../../javax/swing/colorchooser/ColorSelectionModel.html">ColorSelectionModel</A> <B>getSelectionModel</B>()</PRE><DL><DD>Returns the data model that han

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -