|
JIDE 3.5.15 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object java.awt.Component java.awt.Container javax.swing.JComponent javax.swing.JPanel com.jidesoft.combobox.PopupPanel com.jidesoft.combobox.ButtonPopupPanel com.jidesoft.combobox.FontChooserPanel
public class FontChooserPanel
A popup panel for font.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class javax.swing.JPanel |
---|
JPanel.AccessibleJPanel |
Nested classes/interfaces inherited from class javax.swing.JComponent |
---|
JComponent.AccessibleJComponent |
Nested classes/interfaces inherited from class java.awt.Container |
---|
Container.AccessibleAWTContainer |
Nested classes/interfaces inherited from class java.awt.Component |
---|
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy |
Field Summary | |
---|---|
protected JCheckBox |
_boldCheckBox
|
protected JComboBox |
_fontNameComboBox
|
protected ComboBoxModel |
_fontNameComboBoxModel
|
protected JCheckBox |
_italicCheckBox
|
protected JLabel |
_previewLabel
|
protected JSpinner |
_sizeSpinner
|
Fields inherited from class com.jidesoft.combobox.ButtonPopupPanel |
---|
_cancelAction, _cancelButton, _okAction, _okButton |
Fields inherited from class com.jidesoft.combobox.PopupPanel |
---|
_previousSelectedObject, SELECTED_BY_MOUSE_ROLLOVER |
Fields inherited from class javax.swing.JComponent |
---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
Fields inherited from class java.awt.Component |
---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
Fields inherited from interface java.awt.image.ImageObserver |
---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
---|---|
FontChooserPanel()
|
|
FontChooserPanel(Action okAction,
Action cancelAction)
|
Method Summary | |
---|---|
protected JComponent |
createFontChooserPanel()
|
protected DefaultComboBoxModel |
createFontNameComboBoxModel()
Creates the default combo box model. |
protected JComponent |
createPreviewPanel()
|
ComboBoxModel |
getFontNameComboBoxModel()
Gets the font name combo box model. |
String |
getPreviewText()
Gets the preview text. |
protected String |
getResourceString(String key)
Gets the localized string from resource bundle. |
Font |
getSelectedFont()
Gets the selected font. |
Object |
getSelectedObject()
Gets the selected object. |
protected void |
initComponents()
|
protected void |
installListeners()
|
protected void |
prepareSelectedObject()
|
void |
setFontNameComboBoxModel(ComboBoxModel fontNameComboBoxModel)
Sets the font name combo box model. |
void |
setLocale(Locale l)
|
protected void |
setPreviewLabelFont()
Sets the selected font to preview label. |
void |
setPreviewText(String previewText)
Sets the preview text. |
void |
setSelectedFont(Font font)
Sets the selected font. |
void |
setSelectedObject(Object object)
Sets the selected object and fire ItemEvent . |
Methods inherited from class com.jidesoft.combobox.ButtonPopupPanel |
---|
createButtonPanel, getCancelAction, getDefaultButton, getOkAction, getOkButton, setCancelAction, setOkAction |
Methods inherited from class javax.swing.JPanel |
---|
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected JLabel _previewLabel
protected JComboBox _fontNameComboBox
protected JSpinner _sizeSpinner
protected JCheckBox _boldCheckBox
protected JCheckBox _italicCheckBox
protected ComboBoxModel _fontNameComboBoxModel
Constructor Detail |
---|
public FontChooserPanel()
public FontChooserPanel(Action okAction, Action cancelAction)
Method Detail |
---|
protected void installListeners()
protected void setPreviewLabelFont()
protected DefaultComboBoxModel createFontNameComboBoxModel()
setFontNameComboBoxModel(javax.swing.ComboBoxModel)
to
customize it.
getFontNameComboBoxModel()
public ComboBoxModel getFontNameComboBoxModel()
public void setFontNameComboBoxModel(ComboBoxModel fontNameComboBoxModel)
fontNameComboBoxModel
- the combo box modelprotected void initComponents()
protected JComponent createFontChooserPanel()
protected JComponent createPreviewPanel()
public void setLocale(Locale l)
setLocale
in class Component
public Font getSelectedFont()
setSelectedFont(java.awt.Font)
public void setSelectedFont(Font font)
font
- the selected fontgetSelectedFont()
public Object getSelectedObject()
PopupPanel
getSelectedObject
in class PopupPanel
protected void prepareSelectedObject()
prepareSelectedObject
in class ButtonPopupPanel
public void setSelectedObject(Object object)
PopupPanel
ItemEvent
. It will still fire event even the new selected object
is the same as old selected object.
setSelectedObject
in class PopupPanel
object
- new selected objectpublic String getPreviewText()
setPreviewText(String)
public void setPreviewText(String previewText)
previewText
- the preview textgetPreviewText()
protected String getResourceString(String key)
key
- the key
|
JIDE 3.5.15 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |