Java Date Picker v3.2

com.standbysoft.component.date.swing.plaf.basic
Class BasicDatePickerUI

java.lang.Object
  extended byjavax.swing.plaf.ComponentUI
      extended bycom.standbysoft.component.date.swing.plaf.DateUI
          extended bycom.standbysoft.component.date.swing.plaf.basic.AbstractDatePickerUI
              extended bycom.standbysoft.component.date.swing.plaf.basic.BasicDatePickerUI

public class BasicDatePickerUI
extends AbstractDatePickerUI

Implements only what is strictly necessary for a JDatePicker UI delegate. A modified combo box is used to select/edit the date.

If you want to create a custom UI delegate for JDatePicker, then the best solution is to extend this class.


Field Summary
 
Fields inherited from class com.standbysoft.component.date.swing.plaf.basic.AbstractDatePickerUI
comboBox, datePicker, monthView
 
Constructor Summary
BasicDatePickerUI()
           
 
Method Summary
protected  JComboBoxExt createComboBox()
          Creates the combo box that is used by the date picker to select a date.
protected  java.awt.LayoutManager createLayout()
          Creates a LayoutManager that manages the combo box used to select/edit the date.
protected  JMonthView createMonthView()
          Creates the calendar component that will be used by JDatePicker to select a date.
static javax.swing.plaf.ComponentUI createUI(javax.swing.JComponent c)
           
protected  void installComponents()
          Installs all the components needed by JDatePicker to implement its behavior.
protected  void installListeners()
          Creates and installs the listeners for the date picker.
protected  void uninstallComponents()
           
protected  void uninstallListeners()
          Uninstalls the listeners from the date field.
protected  void updateBackground()
          Updates the background color for the supporting combo box.
protected  void updateCalendarBackground()
          Updates the background color of the calendar
protected  void updateCalendarDisplayToday()
          Specifies whether the calendar displays the today button or not.
protected  void updateCalendarForeground()
          Updates the foreground color of the calendar
protected  void updateCalendarRenderer()
           
protected  void updateCalendarTitleBackground()
          Updates the title background color of the calendar
protected  void updateCalendarTitleForeground()
          Updates the title foreground color of the calendar
protected  void updateCalendarTrailingForeground()
          Updates the trailing foreground color of the calendar
protected  void updateCalendarVisible()
          Specifies whether the drop down calendar should be displayed or not.
protected  void updateCalendarWeekNumbersVisible()
          Specifies whether the calendar displays the week numbers or not.
protected  void updateDateFormat()
           
protected  void updateDateSelectionModel()
          Updates the selection model for the components of the date picker
protected  void updateEditable()
          Updates the editable state of the date picker components.
protected  void updateEnabled()
          Updates the enabled state of the children Components based on the enabled state of the JDatePicker.
protected  void updateFont()
          Updates the font for the date picker components.
protected  void updateForeground()
          Updates the foreground color for the supporting combo box.
protected  void updateLocale()
          Updates the locale for the date picker components.
protected  void updateToolTipText()
          Updates the tooltip text for the date picker component.
 
Methods inherited from class com.standbysoft.component.date.swing.plaf.basic.AbstractDatePickerUI
createPropertyChangeListener, installDefaults, installKeyboardActions, installUI, isPopupVisible, registerDateComboBoxUI, setPopupVisible, uninstallDefaults, uninstallUI, unregisterDateComboBoxUI
 
Methods inherited from class javax.swing.plaf.ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount, getMaximumSize, getMinimumSize, getPreferredSize, paint, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BasicDatePickerUI

public BasicDatePickerUI()
Method Detail

createUI

public static javax.swing.plaf.ComponentUI createUI(javax.swing.JComponent c)

installComponents

protected void installComponents()
Description copied from class: AbstractDatePickerUI

Installs all the components needed by JDatePicker to implement its behavior.

Overrides:
installComponents in class AbstractDatePickerUI
See Also:
AbstractDatePickerUI.createLayout(), AbstractDatePickerUI.createMonthView(), AbstractDatePickerUI.createComboBox()

createLayout

protected java.awt.LayoutManager createLayout()
Description copied from class: AbstractDatePickerUI
Creates a LayoutManager that manages the combo box used to select/edit the date.

Specified by:
createLayout in class AbstractDatePickerUI
Returns:
a LayoutManager for the date picker.

createMonthView

protected JMonthView createMonthView()
Description copied from class: AbstractDatePickerUI

Creates the calendar component that will be used by JDatePicker to select a date. If you want to provide your own JMonthView instance, keep in mind that its instance will be used by this delegate so all operations should pass through the JDatePicker interface methods.

Specified by:
createMonthView in class AbstractDatePickerUI
Returns:
a calendar that will be used by the date picker to select dates.

createComboBox

protected JComboBoxExt createComboBox()
Description copied from class: AbstractDatePickerUI
Creates the combo box that is used by the date picker to select a date.

Specified by:
createComboBox in class AbstractDatePickerUI
Returns:
actual combo box.

uninstallComponents

protected void uninstallComponents()
Overrides:
uninstallComponents in class AbstractDatePickerUI

installListeners

protected void installListeners()
Description copied from class: AbstractDatePickerUI
Creates and installs the listeners for the date picker. This method is called when the UI is installed.

Overrides:
installListeners in class AbstractDatePickerUI

uninstallListeners

protected void uninstallListeners()
Description copied from class: AbstractDatePickerUI
Uninstalls the listeners from the date field. This method is called when the UI is uninstalled.

Overrides:
uninstallListeners in class AbstractDatePickerUI

updateEnabled

protected void updateEnabled()
Description copied from class: AbstractDatePickerUI
Updates the enabled state of the children Components based on the enabled state of the JDatePicker.

Specified by:
updateEnabled in class AbstractDatePickerUI

updateFont

protected void updateFont()
Description copied from class: AbstractDatePickerUI
Updates the font for the date picker components.

Specified by:
updateFont in class AbstractDatePickerUI

updateCalendarRenderer

protected void updateCalendarRenderer()
Specified by:
updateCalendarRenderer in class AbstractDatePickerUI

updateCalendarBackground

protected void updateCalendarBackground()
Description copied from class: AbstractDatePickerUI
Updates the background color of the calendar

Specified by:
updateCalendarBackground in class AbstractDatePickerUI

updateCalendarForeground

protected void updateCalendarForeground()
Description copied from class: AbstractDatePickerUI
Updates the foreground color of the calendar

Specified by:
updateCalendarForeground in class AbstractDatePickerUI

updateCalendarTitleBackground

protected void updateCalendarTitleBackground()
Description copied from class: AbstractDatePickerUI
Updates the title background color of the calendar

Specified by:
updateCalendarTitleBackground in class AbstractDatePickerUI

updateCalendarTitleForeground

protected void updateCalendarTitleForeground()
Description copied from class: AbstractDatePickerUI
Updates the title foreground color of the calendar

Specified by:
updateCalendarTitleForeground in class AbstractDatePickerUI

updateCalendarTrailingForeground

protected void updateCalendarTrailingForeground()
Description copied from class: AbstractDatePickerUI
Updates the trailing foreground color of the calendar

Specified by:
updateCalendarTrailingForeground in class AbstractDatePickerUI

updateCalendarDisplayToday

protected void updateCalendarDisplayToday()
Description copied from class: AbstractDatePickerUI
Specifies whether the calendar displays the today button or not.

Specified by:
updateCalendarDisplayToday in class AbstractDatePickerUI

updateCalendarVisible

protected void updateCalendarVisible()
Description copied from class: AbstractDatePickerUI
Specifies whether the drop down calendar should be displayed or not.

Specified by:
updateCalendarVisible in class AbstractDatePickerUI

updateCalendarWeekNumbersVisible

protected void updateCalendarWeekNumbersVisible()
Description copied from class: AbstractDatePickerUI
Specifies whether the calendar displays the week numbers or not.

Specified by:
updateCalendarWeekNumbersVisible in class AbstractDatePickerUI

updateDateSelectionModel

protected void updateDateSelectionModel()
Description copied from class: AbstractDatePickerUI
Updates the selection model for the components of the date picker

Specified by:
updateDateSelectionModel in class AbstractDatePickerUI

updateLocale

protected void updateLocale()
Description copied from class: AbstractDatePickerUI
Updates the locale for the date picker components.

Specified by:
updateLocale in class AbstractDatePickerUI

updateEditable

protected void updateEditable()
Description copied from class: AbstractDatePickerUI
Updates the editable state of the date picker components.

Specified by:
updateEditable in class AbstractDatePickerUI

updateToolTipText

protected void updateToolTipText()
Description copied from class: AbstractDatePickerUI
Updates the tooltip text for the date picker component.

Specified by:
updateToolTipText in class AbstractDatePickerUI

updateForeground

protected void updateForeground()
Description copied from class: AbstractDatePickerUI
Updates the foreground color for the supporting combo box.

Specified by:
updateForeground in class AbstractDatePickerUI

updateBackground

protected void updateBackground()
Description copied from class: AbstractDatePickerUI
Updates the background color for the supporting combo box.

Specified by:
updateBackground in class AbstractDatePickerUI

updateDateFormat

protected void updateDateFormat()
Specified by:
updateDateFormat in class AbstractDatePickerUI

Java Date Picker v3.2

Visit www.javadatepicker.com for further information or send us your suggestions.

Copyright © 2003-2004 Stand By Soft Ltd. All Rights Reserved.